M
M
Mesuti2017-08-28 15:07:37
CMS
Mesuti, 2017-08-28 15:07:37

How to mix search results in OpenCart?

Good afternoon!
We have a catalog of goods (loaded from 1c), it contains two types of goods - one group of goods is ours, the second group of goods is suppliers.
How to solve the problem of displaying sorting by price?
If you click on the sort by price button, then the first group of goods comes first with a price from 20 rubles to 1000 rubles, and after the last most expensive product, the second group begins with a minimum price of 20 rubles and up to 1000 rubles
Where can I find the search settings?
Thanks for answers!
8bOV4FCgwS7Qha00QUKq8YnNI10twmNS1Dq_OgYt

Answer the question

In order to leave comments, you need to log in

2 answer(s)
M
Mesuti, 2017-08-28
@Mesuti

I found the search code, they say you need to insert "order by product_group, price"
Can you tell me where to enter it?

<div class="sort">
Сортировка по
<a <?=$sort != 'price' ? 'style="color: black"' : ''?> href="<?=$sorts['price'][$sort == 'price' && $order == 'asc' ? 'desc' : 'asc']?>">цене <b><?=$sort == 'price' ? ($order == 'desc' ? '&darr;' : '&uarr;') : ''?></b></a>
</div>

I threw the search engine code on jsfiddle , suddenly it will be easier to help.
Thank you!

P
Pavel, 2017-08-28
@PavelMonro

In the catalog/model/catalog/product.php search model, without knowledge of php and queries in the database, you will not understand.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question