Update stock only within a specific manufacture_id

  • Posts: 344
  • Thank you received: 3
7 years 5 months ago #254130

-- HikaShop version -- : 2.6.4
-- Joomla version -- : 3.6.4
-- PHP version -- : 7

I have many products with different brands

Brand A
Brand B
Brand C

My stock CSV update file contains "only" product_code, and product_quantity.
It contains product_codes within both Brand A, Brand B and Brand C

I only want to uppdate the quanity for the products with Brand A.

Brand A have manufacture_id: 781

Therefore I havel selected under filters: product_manufacture_id = 781

Se image below



So when I process the Mass action it still updates the quanity of the products within Brand B and Brand C.(actually every product_code in the csv file)

How can I force mass action to only update the product_code from the CSV file that goes within manufacture_id: 781) ?

Hope my explenation makes sense.

Attachments:
Last edit: 7 years 5 months ago by river.

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

  • Posts: 81515
  • Thank you received: 13069
  • MODERATOR
7 years 5 months ago #254143

Hi,

There is no option to do that.

The CSV filter get the products data from the CSV, saves it in the database, and them returns the elements so that they can be filtered further down if necessary so that the actions of your mass action apply only to them.

What you want to do is not supported.

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

  • Posts: 344
  • Thank you received: 3
7 years 5 months ago #254305

OK tnx for reply.

Anyway I have a new question.

I.e: I have a main product with 3 variants. All of the 3 variants have "product quanity: Unlimeted".

But the quanity of the main products has been set to "0", so my customers get the message in the front-end that it's sold out.

How can I force the product quantity of the variants to override the quantity of the main product ?

So that my customers in the front-end can buy the product even tough the quanity of the main product is set to "0".

The problem is that sometimes I forget to remove quantity"0" from the main products after I have updated the vaules of the variants.

Last edit: 7 years 5 months ago by river.

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

  • Posts: 81515
  • Thank you received: 13069
  • MODERATOR
7 years 5 months ago #254359

Hi,

The quantity of the variants override the quantity of the main product, unless you don't set a quantity in the variants and leave it to unlimited. In that case, it uses the quantity of the main product instead.
That's how the system works.
Having it work like you want would prevent other merchants to have products with the global quantity in the main product for all the variants and no quantity for each variant.
Changing that for yourself is not impossible but not easy as all the system is made to work like it does now.
You'll need to have a developer modify the code to be able to do that.
The first place to look would be the checkVariants function of the file administrator/components/com_hikashop/classes/product.php

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

Time to create page: 0.063 seconds
Powered by Kunena Forum