1. Dtorr1981
  2. RO CSVI
  3. Tuesday, 22 January 2019
  4.  Subscribe via email
Hi Guys,

I am setting up a product feed from my supplier and would like to mark all products as 'Discontinued' in VM if the product sku is in the import file.

I already run a stock update cron successfully and have started the process in the similar way. I have mapped the product_sku field to the related field in the import so all I want to do now is mark every product in the feed as discontinued within the Virtuemart product, please see attached screenshot.

Does anyone know how I would go about doing this?

Regards
Donna
Screenshot 2019-01-22 at 17.37.00.png
Accepted Answer Pending Moderation
Hello Donna,
Along with product_sku field you need to have product_discontinued field with value set to Y/Yes/1 in your import file. This will set the product related to product_sku as discontinued.
Kind regards,

Tharuna

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # 1
Accepted Answer Pending Moderation
Thanks Tharuna,

The import file comes directly from the supplier, thus I want to import it regularly via CRON. I have attached the file for your reference. How would I then just use the product_sku field and add the product_discontinued field automatically? Ideally I would only want the discontinued flag to be applied if the stock level is 0.

Or would this be the wrong way to do it?

Regards
Donna

datafeed.csv
Attachments (1)
  1. more than a month ago
  2. RO CSVI
  3. # 2
Accepted Answer Pending Moderation
Hello Donna,

What you need to do is the following:

  1. In your template set the Import using file to No

  2. Define all fields you have in your CSV file in your template fields.

  3. Finally add the field product_discontinued as well with a default value of Y



What happens is that CSVI will read all the fields from your import file as they match the fields you defined in the template fields. The discontinued field doesn't match as there is nothing in your file but then will take the default value. As a result this product will be marked as discontinued.
Kind regards,

RolandD

=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
  1. more than a month ago
  2. RO CSVI
  3. # 3
  • Page :
  • 1


There are no replies made for this post yet.
Be one of the first to reply to this post!