Hi,
we are using your extension for exporting orders as a CSV file, which should be send by email via cronjob daily at 10am. Is there a possibility to skip the cronjob / the email sending, if no data have been collected (CSV file contains "No data has been found for the selections made" )?
- WIRKOM
- RO CSVI
- Wednesday, 11 December 2019
- Subscribe via email
0
Accepted Answer
Pending Moderation
Hello,
If you edit your template and go to the Source tab. Click on the Advanced button and notice you get the option if you want to output an empty file. Set this to No and save your template. That should meet your request I think.
If you edit your template and go to the Source tab. Click on the Advanced button and notice you get the option if you want to output an empty file. Set this to No and save your template. That should meet your request I think.
Kind regards,
RolandD
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
RolandD
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Accepted Answer
Pending Moderation
Hi again,
we have now another problem: We want the CSV export to be sent only, if orders were made from certain countries. We saw that there is a possibility to adjust the filter via the order shipping method. We don't know why, but in the dropdown field there are just 4 available, but we have 64 shipping methods. So we created a rule to skip, if the country code matches certain values. This works, but it creates an empty CSV file and the mail will be sent...
we have now another problem: We want the CSV export to be sent only, if orders were made from certain countries. We saw that there is a possibility to adjust the filter via the order shipping method. We don't know why, but in the dropdown field there are just 4 available, but we have 64 shipping methods. So we created a rule to skip, if the country code matches certain values. This works, but it creates an empty CSV file and the mail will be sent...
Attachments (4)
Accepted Answer
Pending Moderation
Hello,
The dropdown shows only 4 because you have orders only for these 4 shipping methods. There is no use in including shipments which do not have orders in the filter as we know export will get no records for these.
Yes and that is because record count for export has value and because of Skip rule we do not display them in export file. Please load the attached patch file and check the export.
We want the CSV export to be sent only, if orders were made from certain countries. We saw that there is a possibility to adjust the filter via the order shipping method. We don't know why, but in the dropdown field there are just 4 available, but we have 64 shipping methods.
The dropdown shows only 4 because you have orders only for these 4 shipping methods. There is no use in including shipments which do not have orders in the filter as we know export will get no records for these.
So we created a rule to skip, if the country code matches certain values. This works, but it creates an empty CSV file and the mail will be sent...
Yes and that is because record count for export has value and because of Skip rule we do not display them in export file. Please load the attached patch file and check the export.
Attachments (1)
Kind regards,
Tharuna
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Tharuna
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Accepted Answer
Pending Moderation
Thank you for the quick response.
But we set up this template to cover automatically orders. We don't have orders from the other shipping methods yet, but there might be some in the future. So I don't get the logic here.
Ok, what will this patch do?
The dropdown shows only 4 because you have orders only for these 4 shipping methods. There is no use in including shipments which do not have orders in the filter as we know export will get no records for these.
But we set up this template to cover automatically orders. We don't have orders from the other shipping methods yet, but there might be some in the future. So I don't get the logic here.
Yes and that is because record count for export has value and because of Skip rule we do not display them in export file. Please load the attached patch file and check the export.
Ok, what will this patch do?
Accepted Answer
Pending Moderation
Hello,
The logic here is that if there is no order for the shipment method, there is no use in showing the shipment in filter. You will not have any record in export for shipments which do not have orders yet. In future when there are orders coming into other shipments, those shipment methods will be automatically added to the filter. The intention of limiting this list is not to have a lengthy filter. But with Shipment methods there will be only a few number of them and so we have added code to list out all the shipment methods in the filter. This change is included in the attached patch file.
Say if there are 3 records RO CSVI gets when you run the export. If all 3 records are skipped because of skip rule, the count of the records as per RO CSVI in export is still 3. The delete empty file check is based on the records got on export and since record count was still 3, email was sent on export even though the file is empty. We have fixed this issue where the record count will decrease when the record is skipped. Run your export and check if it works as expected.
Please load the attached modified patch file for both shipment method filter and Skip record count fixes.
But we set up this template to cover automatically orders. We don't have orders from the other shipping methods yet, but there might be some in the future. So I don't get the logic here.
The logic here is that if there is no order for the shipment method, there is no use in showing the shipment in filter. You will not have any record in export for shipments which do not have orders yet. In future when there are orders coming into other shipments, those shipment methods will be automatically added to the filter. The intention of limiting this list is not to have a lengthy filter. But with Shipment methods there will be only a few number of them and so we have added code to list out all the shipment methods in the filter. This change is included in the attached patch file.
Ok, what will this patch do?
Say if there are 3 records RO CSVI gets when you run the export. If all 3 records are skipped because of skip rule, the count of the records as per RO CSVI in export is still 3. The delete empty file check is based on the records got on export and since record count was still 3, email was sent on export even though the file is empty. We have fixed this issue where the record count will decrease when the record is skipped. Run your export and check if it works as expected.
Please load the attached modified patch file for both shipment method filter and Skip record count fixes.
Attachments (1)
Kind regards,
Tharuna
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Tharuna
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Accepted Answer
Pending Moderation
Just noticed, after installing the patch, we get an error if we try to do something in the maintanance of RO CSVI.
Attachments (1)
Accepted Answer
Pending Moderation
Hello,
The patch should not be a cause for the error as the files sent in the patch are not related to RO CSVI Maintenance page. Does this happen with all the maintenance task or any specific task?
The patch should not be a cause for the error as the files sent in the patch are not related to RO CSVI Maintenance page. Does this happen with all the maintenance task or any specific task?
Kind regards,
Tharuna
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Tharuna
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
- Page :
- 1
There are no replies made for this post yet.
Be one of the first to reply to this post!
Be one of the first to reply to this post!
Please login to post a reply
You will need to be logged in to be able to post a reply. Login using the form on the right or register an account if you are new here. Register Here »