Make a news product menu

  • Posts: 363
  • Thank you received: 28
  • Hikashop Multisite
2 years 6 months ago #343560

-- HikaShop version -- : 4.6.0
-- Joomla version -- : 4.1.5
-- PHP version -- : 8.0

Hi,
I try to put a menu link with only the news products.

If i make a Hikashop product list menu, i can select for the classement "product_created".
But at this point, it will show all the shop product, but order by date created.

Is there a way to limit this number of products with a date ? Ex all product added in the last 15 days ?

Regards


“Si tu ne travaille pas pour tes rêves, quelqu'un t'embauchera pour travailler pour les siens" - Steeve Jobs
"La sagesse, c’est d’avoir des rêves suffisamment grands pour ne pas les perdre de vue quand on les poursuit." - Oscar Wilde

Please Log in or Create an account to join the conversation.

  • Posts: 4785
  • Thank you received: 650
  • MODERATOR
2 years 6 months ago #343564

Hello,

For your case, the most easy and efficient, as product can have several categories, is to create a category for this product you want to display in your Item Menu only.
Hope this will fit your needs.

Regards

Please Log in or Create an account to join the conversation.

  • Posts: 363
  • Thank you received: 28
  • Hikashop Multisite
2 years 6 months ago #343572

Hi,
OK, too bad that there is not an option to limit the number of product show in the configuration menu.
Because it would be better if there is no need to manually put that in a special category.

But if it is the only way...

And if i put for example in the grid select, 4x7, it will show 28 products. So it can work, if i can hide the pagination for this layout only ?
I dont know if possible ?

Regards.


“Si tu ne travaille pas pour tes rêves, quelqu'un t'embauchera pour travailler pour les siens" - Steeve Jobs
"La sagesse, c’est d’avoir des rêves suffisamment grands pour ne pas les perdre de vue quand on les poursuit." - Oscar Wilde
Last edit: 2 years 6 months ago by thefbi.

Please Log in or Create an account to join the conversation.

  • Posts: 4785
  • Thank you received: 650
  • MODERATOR
2 years 6 months ago #343579

Hello,

There can be an infinity of criteria depending on the needs of each other.
So the most flexible and easy to implement solution remains the product categories.

But if this solution poses a problem for a reason that escapes us, we can perhaps refine our advice once you explain to us what is bothering you with this first solution.

For hide the pagination for this page only, the most easy and quick is a custom css command, like this :

.specific_classORid_page .pagination_class {
    display: none;
}
Note : learn here how to add your custom css command.

Regards

Last edit: 2 years 6 months ago by Philip.

Please Log in or Create an account to join the conversation.

  • Posts: 363
  • Thank you received: 28
  • Hikashop Multisite
2 years 6 months ago #343697

OK, thank you.
I will se with the client if the category solution is OK.

In fact, on this site, there will be many vendors, who will post items. So the idea was that the new items would be added to this menu automatically.

So with the category idea, the shop manager will have to manually pass the products he wants to set as "New".
Here is the reason that escapes you :)

Regards.


“Si tu ne travaille pas pour tes rêves, quelqu'un t'embauchera pour travailler pour les siens" - Steeve Jobs
"La sagesse, c’est d’avoir des rêves suffisamment grands pour ne pas les perdre de vue quand on les poursuit." - Oscar Wilde

Please Log in or Create an account to join the conversation.

  • Posts: 2143
  • Thank you received: 747
2 years 6 months ago #343699

Hi thefbi,

Of course, the "category solution" is very awkward and impractical.

However, this will work perfectly fine:

thefbi wrote: And if i put for example in the grid select, 4x7, it will show 28 products. So it can work, if i can hide the pagination for this layout only ?

Yes, exactly. So, create a menu item of the type product listing, set the grid as you need and configure it to display products from all categories, sorted by created date / descending. Then hide the pagination per CSS in this listing only. No problem at all.

Alternatively you could use a Module as well, of course.


Need help with customisations of layouts, style or other site development? PM me!
(Don't forget to turn on "E-mail notification of new messages" )

Please Log in or Create an account to join the conversation.

  • Posts: 363
  • Thank you received: 28
  • Hikashop Multisite
2 years 6 months ago #343889

Philip wrote: Hello,

There can be an infinity of criteria depending on the needs of each other.
So the most flexible and easy to implement solution remains the product categories.

But if this solution poses a problem for a reason that escapes us, we can perhaps refine our advice once you explain to us what is bothering you with this first solution.

For hide the pagination for this page only, the most easy and quick is a custom css command, like this :

.specific_classORid_page .pagination_class {
    display: none;
}
Note : learn here how to add your custom css command.

Regards


Hi,
Sorry, but you link to the custom css is not the good link... But if it is correct, i have to put this code in the layout configuration, in custom css.
The problem is i dont understand how i can select the specific page ? How i have to write the code ?


“Si tu ne travaille pas pour tes rêves, quelqu'un t'embauchera pour travailler pour les siens" - Steeve Jobs
"La sagesse, c’est d’avoir des rêves suffisamment grands pour ne pas les perdre de vue quand on les poursuit." - Oscar Wilde

Please Log in or Create an account to join the conversation.

  • Posts: 4785
  • Thank you received: 650
  • MODERATOR
2 years 6 months ago #343892

Hello,

My link is correct, this indeed starts from a completely different context, but it shows how to add your own Css commands in the frontend file, to create (if this is not yet the case) a frontend_custom Css file.

Regards

Last edit: 2 years 6 months ago by Philip.

Please Log in or Create an account to join the conversation.

  • Posts: 363
  • Thank you received: 28
  • Hikashop Multisite
2 years 6 months ago #343910

OK, I figured out how to add custom css, since I already use it.
What I don't understand is how to modify only the desired page.

If I take your example, and create a custom class like this:

.fred2 .hikashop_products_pagination_bottom {
	display: none;
}

How can I tell my page to take this class ?
I tried in the menu link but it doesn't work. See screenshot.


“Si tu ne travaille pas pour tes rêves, quelqu'un t'embauchera pour travailler pour les siens" - Steeve Jobs
"La sagesse, c’est d’avoir des rêves suffisamment grands pour ne pas les perdre de vue quand on les poursuit." - Oscar Wilde
Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 4785
  • Thank you received: 650
  • MODERATOR
2 years 6 months ago #343913

Hello,

Then, you have to get your specific listing html id, in order to restrict your custom css to your required listing page.
the specific html ID uses your menu item ID, example :

<div id="html_specific_ID_ 252">
  <div...

Hope this will help you to achieve this.
Regards

Last edit: 2 years 6 months ago by Philip.

Please Log in or Create an account to join the conversation.

  • Posts: 363
  • Thank you received: 28
  • Hikashop Multisite
2 years 6 months ago #343923

YES !
It work, thank you !
So the right code for this page :

#hikashop_category_information_menu_408 .hikashop_products_pagination_bottom {
	display: none;
}


“Si tu ne travaille pas pour tes rêves, quelqu'un t'embauchera pour travailler pour les siens" - Steeve Jobs
"La sagesse, c’est d’avoir des rêves suffisamment grands pour ne pas les perdre de vue quand on les poursuit." - Oscar Wilde
The following user(s) said Thank You: Philip

Please Log in or Create an account to join the conversation.

Time to create page: 0.080 seconds
Powered by Kunena Forum