- Posts: 61
- Thank you received: 0
How to limit sold product quantity during 1 day for 1 user?
9 years 10 months ago #254185
by DimLVL
-- HikaShop version -- : 2.6.4
-- Joomla version -- : 3.6.4
-- PHP version -- : 5.6
Hello,
I want to sell up to 5 pcs of Each product daily. Not more, to avoid wholesalers during our sales.
We will have 2000+ product, so adding filters manually for each product in Hikashop -> Products -> Limit is not a good idea. Nor we can't limit category. Selling multiple products up to 5 pcs is good for us.
As I understood, the limit in product listing is for always, but we need to reset it next day after purchase.
How can I manage that?
-- Joomla version -- : 3.6.4
-- PHP version -- : 5.6
Hello,
I want to sell up to 5 pcs of Each product daily. Not more, to avoid wholesalers during our sales.
We will have 2000+ product, so adding filters manually for each product in Hikashop -> Products -> Limit is not a good idea. Nor we can't limit category. Selling multiple products up to 5 pcs is good for us.
As I understood, the limit in product listing is for always, but we need to reset it next day after purchase.
How can I manage that?
Please Log in or Create an account to join the conversation.
9 years 10 months ago #254195
by nicolas
Replied by nicolas on topic How to limit sold product quantity during 1 day for 1 user?
Hi,
A global "per day per user per product" option doesn't exist.
You can have a restriction per order per product with the "Quantity per order" setting of the products, and you can have a "per day per per user per product" for one product with limits. But indeed, that means creating thousands of limits.
So either you use the CSV export/import function of your PHPMyAdmin on the hikashop_limit table in order to rapidely generate all the limits in excel by duplicating the entries, or you need to write a small plugin implementing the "onBeforeOrderCreate" trigger in order to add your check with some PHP.
A global "per day per user per product" option doesn't exist.
You can have a restriction per order per product with the "Quantity per order" setting of the products, and you can have a "per day per per user per product" for one product with limits. But indeed, that means creating thousands of limits.
So either you use the CSV export/import function of your PHPMyAdmin on the hikashop_limit table in order to rapidely generate all the limits in excel by duplicating the entries, or you need to write a small plugin implementing the "onBeforeOrderCreate" trigger in order to add your check with some PHP.
Please Log in or Create an account to join the conversation.
Time to create page: 0.179 seconds