- Posts: 100
- Thank you received: 1
Item Number in Stock & Stock Notifications
12 years 5 months ago #151566
by PubSite
Item Number in Stock & Stock Notifications was created by PubSite
Hello,
I want to ask for help on two issues I'm facing with my HikaShop.
1. How can I force the system to only decrement items when the order is "PAID"? Because some people make the order and don't pay it for a while but the items are decremented from my stock. Others can't order items this way... What can I do about this? I want items to be subtracted from the stock ONLY IF they're paid for.
2. How can I have a notification for USERS when there's only 5 items left in my stock? I don't want the number to be there all the time because I don't want them to see all items I have in my stock. Only when we're down to 5 or less, I want them to see a text near the item or smth like this. How can I do this?
Site URL : www.222publications.com
Thanks in advance,
Blessings,
Simon
I want to ask for help on two issues I'm facing with my HikaShop.
1. How can I force the system to only decrement items when the order is "PAID"? Because some people make the order and don't pay it for a while but the items are decremented from my stock. Others can't order items this way... What can I do about this? I want items to be subtracted from the stock ONLY IF they're paid for.
2. How can I have a notification for USERS when there's only 5 items left in my stock? I don't want the number to be there all the time because I don't want them to see all items I have in my stock. Only when we're down to 5 or less, I want them to see a text near the item or smth like this. How can I do this?
Site URL : www.222publications.com
Thanks in advance,
Blessings,
Simon
Please Log in or Create an account to join the conversation.
12 years 5 months ago #151613
by Xavier
Replied by Xavier on topic Item Number in Stock & Stock Notifications
Hi,
1. There is an option for that in HikaShop, Configuration > Main > Product > "Update the product stock on confirmed status".
2. You have to make a view override for the view "product / quantity", add an if condition to display the stock level only if it"s less than 6. something like:
1. There is an option for that in HikaShop, Configuration > Main > Product > "Update the product stock on confirmed status".
2. You have to make a view override for the view "product / quantity", add an if condition to display the stock level only if it"s less than 6. something like:
Code:
if($this->row->product_quantity < 6){
echo '<span class="hikashop_product_stock_count">'.JText::sprintf('X_ITEMS_IN_STOCK',$this->row->product_quantity).'<br/></span>';
}
The following user(s) said Thank You: PubSite
Please Log in or Create an account to join the conversation.
12 years 5 months ago #151663
by PubSite
Replied by PubSite on topic Item Number in Stock & Stock Notifications
Thanks a lot Xavier..
I added the code you suggested. I don't know where to put it exactly in the php file.. It might not be working because of that...
we only have 2 of this book left : www.222publications.com/newcatalog/fa/ho...ncebooks/product/24-
but I can't see any notification even though I've added the code.
Thanks in advance.
God bless,
Simon
I added the code you suggested. I don't know where to put it exactly in the php file.. It might not be working because of that...
we only have 2 of this book left : www.222publications.com/newcatalog/fa/ho...ncebooks/product/24-
but I can't see any notification even though I've added the code.
Thanks in advance.
God bless,
Simon
Please Log in or Create an account to join the conversation.
12 years 5 months ago #151668
by PubSite
Replied by PubSite on topic Item Number in Stock & Stock Notifications
now it's showing 2 lines of available items in stock. I want it to show only one line and ONLY if there's 5 or less.. Shall I add an else to that if statement? Please help me with the code. You'll see what I mean if you click on the link above.
Thanks!
Thanks!
Please Log in or Create an account to join the conversation.
12 years 5 months ago #151676
by Xavier
Replied by Xavier on topic Item Number in Stock & Stock Notifications
Hi,
So you just have to remove the other line (the one not in your if condition):
So you just have to remove the other line (the one not in your if condition):
Code:
echo '<span class="hikashop_product_stock_count">'.JText::sprintf('X_ITEMS_IN_STOCK',$this->row->product_quantity).'<br/></span>';
The following user(s) said Thank You: PubSite
Please Log in or Create an account to join the conversation.
12 years 5 months ago #151734
by PubSite
Replied by PubSite on topic Item Number in Stock & Stock Notifications
Thank you so much! You've done me a huge favor Xavier. I appreciate it.
Just a quick question. Although I've fixed this issue with my CSS before, it's came back. I don't know why. I even checked the code and it's as it was before. I've floated all addresses to Center. But as you can see in my screenshots, when I'm in the checkout process, the addresses are corrupted and price titles too...! What can I do about this?
www.dropbox.com/s/9mzjdjfrs2aymc6/Screen...04-10%2014.09.18.png
www.dropbox.com/s/7gv8x79vnq72cpz/Screen...04-10%2014.10.04.png
Regards,
Simon
Just a quick question. Although I've fixed this issue with my CSS before, it's came back. I don't know why. I even checked the code and it's as it was before. I've floated all addresses to Center. But as you can see in my screenshots, when I'm in the checkout process, the addresses are corrupted and price titles too...! What can I do about this?
www.dropbox.com/s/9mzjdjfrs2aymc6/Screen...04-10%2014.09.18.png
www.dropbox.com/s/7gv8x79vnq72cpz/Screen...04-10%2014.10.04.png
Regards,
Simon
Please Log in or Create an account to join the conversation.
12 years 5 months ago #151763
by Xavier
Replied by Xavier on topic Item Number in Stock & Stock Notifications
Hi,
As you say it' a css issue. www.hikashop.com/support/support/documen...ize-the-display.html
Thanks to create a test account in order to see directly from what that come.
But we don't support css issues.
As you say it' a css issue. www.hikashop.com/support/support/documen...ize-the-display.html
Thanks to create a test account in order to see directly from what that come.
But we don't support css issues.
Please Log in or Create an account to join the conversation.
Time to create page: 0.208 seconds