mirror of
https://github.com/openclassify/openclassify.git
synced 2026-01-11 18:01:10 -06:00
remove unused routes and clean a repo function
This commit is contained in:
parent
def13ddf3e
commit
3077d105da
@ -30,7 +30,7 @@
|
||||
<a href="{% if(viewType != "map") %}
|
||||
{{ appendRequestURL(request_query(),url_route('adv_list_seo', [catId.slug, citySlug]),{},['page']) }}
|
||||
{% else %}
|
||||
{{ appendRequestURL(request_query(),url_route('advs_map'),{'cat':id},['page']) }}
|
||||
{{ appendRequestURL(request_query(),url_route('adv_list_seo'),{'cat':id},['page']) }}
|
||||
{% endif %}" class="list-group-item list-group-item-action text-truncate">
|
||||
<i class="fas fa-dot-circle"></i>
|
||||
{{ name }}
|
||||
@ -42,7 +42,7 @@
|
||||
<a href="{% if(viewType != "map") %}
|
||||
{{ appendRequestURL(request_query(),url_route('adv_list_seo', [subCatId.slug, citySlug]),{},['page']) }}
|
||||
{% else %}
|
||||
{{ appendRequestURL(request_query(),url_route('advs_map'),{'cat':subcat.id},['page']) }}
|
||||
{{ appendRequestURL(request_query(),url_route('adv_list_seo'),{'cat':subcat.id},['page']) }}
|
||||
{% endif %}" class="list-group-item list-group-item-action text-truncate">
|
||||
{{ subcat.name }}
|
||||
</a>
|
||||
|
||||
@ -35,7 +35,10 @@ class CategoryRepository extends EntryRepository implements CategoryRepositoryIn
|
||||
|
||||
public function mainCats()
|
||||
{
|
||||
return $this->model->where('parent_category_id', null)->where('deleted_at', null)->orderBy('sort_order')->get();
|
||||
return $this->newQuery()
|
||||
->whereNull('parent_category_id')
|
||||
->orderBy('sort_order')
|
||||
->get();
|
||||
}
|
||||
|
||||
public function getItem($cat)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user