- Posts: 71
- Thank you received: 0
(SOLVED) Some problems when add order in backend
12 years 6 months ago - 12 years 5 months ago #147580
by vaughan
(SOLVED) Some problems when add order in backend was created by vaughan
-- url of the page with the problem -- :
wpb.es
-- HikaShop version -- : 2.2.3 bussiness
-- Joomla version -- : 3.2.1
-- PHP version -- :5.4
-- Browser(s) name and version -- : XXXXX x.x.x
-- Error-message(debug-mod must be tuned on) -- : Error_message
Hi
I have 2 problems.
1- When I add a new order in backend, don´t increases 1 unit in table hikashop_product in field product_sales
2- When I add a new order in backend, reduce 2 units in stock, but I add select 1 unit
I need add orders in backend, because some clinets phone me to buy directly, and I need know how many sales I have in all products
I use variants in each product
Regards
-- HikaShop version -- : 2.2.3 bussiness
-- Joomla version -- : 3.2.1
-- PHP version -- :5.4
-- Browser(s) name and version -- : XXXXX x.x.x
-- Error-message(debug-mod must be tuned on) -- : Error_message
Hi
I have 2 problems.
1- When I add a new order in backend, don´t increases 1 unit in table hikashop_product in field product_sales
2- When I add a new order in backend, reduce 2 units in stock, but I add select 1 unit
I need add orders in backend, because some clinets phone me to buy directly, and I need know how many sales I have in all products
I use variants in each product
Regards
Last edit: 12 years 5 months ago by vaughan. Reason: Solved
Please Log in or Create an account to join the conversation.
12 years 6 months ago #147609
by Xavier
Replied by Xavier on topic Some problems when add order in backend
Hi,
I tried to reproduce the problem on my end, but the stock is increased correctly, like the product sales.
Could you give us more informations about the installed extensions, modules or plugins you have.
It's probably one of them which is causing the issue.
I tried to reproduce the problem on my end, but the stock is increased correctly, like the product sales.
Could you give us more informations about the installed extensions, modules or plugins you have.
It's probably one of them which is causing the issue.
The following user(s) said Thank You: vaughan
Please Log in or Create an account to join the conversation.
12 years 6 months ago #148354
by vaughan
Replied by vaughan on topic Some problems when add order in backend
I find part of my error, there was an error in my database structure in order_product table, there was not autoincrement in order_id field.
Now deduct 1 unit in each order, but the sales not increment in 1 unit (maybe a similar error) I'm comparing a new installation tables wint my production site, but ican't find my error....
Now deduct 1 unit in each order, but the sales not increment in 1 unit (maybe a similar error) I'm comparing a new installation tables wint my production site, but ican't find my error....
Please Log in or Create an account to join the conversation.
12 years 6 months ago #148357
by Jerome
Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.
Replied by Jerome on topic Some problems when add order in backend
Hi,
If you do not have the official tables in your database. It will be difficult to reproduce your problem.
It asked for a deep analyze in order to understand why the stock is not modified and look at the request which generally increase the product sale counter.
Regards,
If you do not have the official tables in your database. It will be difficult to reproduce your problem.
It asked for a deep analyze in order to understand why the stock is not modified and look at the request which generally increase the product sale counter.
Regards,
Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.
The following user(s) said Thank You: vaughan
Please Log in or Create an account to join the conversation.
12 years 6 months ago - 12 years 6 months ago #151042
by vaughan
Replied by vaughan on topic Some problems when add order in backend
Hi
Well I solved my probelms with tables, but I still having some problem when I add an order in backend, don´t add 1 unit in product sales but only happen this error if the product has variants (characteristics) I check in the yellow box to add a product and select variants in select list and then I select the variant I want to add into the order, It's correct?. If I make a order in frontend like a customer, works fine and add 1 unit in product_sales, in backend NO.
I see o
I installed a local test site, a new installation, and I have same problem, don´t add 1 unit in product_sales field in the table hikashop_product when I create a new order in a product with variants in backend.
Why it happens?
Thanks for all
Well I solved my probelms with tables, but I still having some problem when I add an order in backend, don´t add 1 unit in product sales but only happen this error if the product has variants (characteristics) I check in the yellow box to add a product and select variants in select list and then I select the variant I want to add into the order, It's correct?. If I make a order in frontend like a customer, works fine and add 1 unit in product_sales, in backend NO.
I see o
I installed a local test site, a new installation, and I have same problem, don´t add 1 unit in product_sales field in the table hikashop_product when I create a new order in a product with variants in backend.
Why it happens?
Thanks for all
Last edit: 12 years 6 months ago by vaughan.
Please Log in or Create an account to join the conversation.
12 years 5 months ago #151773
by Jerome
Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.
Replied by Jerome on topic Some problems when add order in backend
Hi,
Please edit the file "administrator/components/com_hikashop/classes/order_product.php" and replace the line
By:
It should fix your problem.
Regards,
Please edit the file "administrator/components/com_hikashop/classes/order_product.php" and replace the line
Code:
$query = 'UPDATE '.hikashop_table('product').' SET product_sales = product_sales + '.$k.' WHERE product_sales >= '.(-$k).' AND '.implode(' AND ',$filters);
Code:
$query = 'UPDATE '.hikashop_table('product').' SET product_sales = product_sales + '.$k.' WHERE product_sales >= '.(-$k).' AND ('.implode(' OR ',$filters).')';
Regards,
Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.
The following user(s) said Thank You: vaughan
Please Log in or Create an account to join the conversation.
12 years 5 months ago #151838
by vaughan
Replied by vaughan on topic Some problems when add order in backend
Great! Great! Great! Great! Great! Great! Great! Great! Great! Great! :woohoo: :woohoo: :woohoo:
Thanks a lot!!!! works fine!!!
Best regards!
Thanks a lot!!!! works fine!!!
Best regards!
Please Log in or Create an account to join the conversation.
Time to create page: 0.232 seconds