- Posts: 237
- Thank you received: 5
Is this even possible?
-- Joomla version -- : 3.3.6
Hello,
I have a clients website with an online ecommerce HikaShop that users can purchase product manuals.
They would like some customisation as to how the order is processed once received. For every order placed on the website they would like a CSV file of the order to be sent via SFTP to a remote folder.
I think the logic would go something like:
1. Order is created by end user via HikaShop website.
2. Customer and store receive an email confirmation of the order.
3. The order data is held in the HikaShop Joomla database.
4. Some sort of cron / extension polls the orders every hour (?)
5. If a new one is present then it generates the CSV file from the Joomla DB.
6. This is then sent via SFTP to the remote server for processing.
7. The order is fulfilled and everyone is happy
Does that make sense and if so is it possible?
Thanks
Lee
Please Log in or Create an account to join the conversation.
- Posts: 12953
- Thank you received: 1778
Note that you'll be able to export orders using the "Mass action" feature via "Hikashop->System->Mass actions" : www.hikashop.com/support/support/documen...massaction-form.html
Please Log in or Create an account to join the conversation.
Thank you so much for the reply, I did not know about the Mass Action and that is could achieve 99% of what I need!
Thanks so much.
However I have setup a mass action to save a CSV file and email a copy but it does not appear to run when an order is created. Attached is a screenshot of my setup. Can you please review and tell me how I can get this to process everytime an order is placed.
Whats should the folder path look like is it the website url:
www.someurl.com/csv/
or does it need to be a server path?
thank you.
Lee
Please Log in or Create an account to join the conversation.
This mass action must work every time an order is created.
Please check if there is no other plugin called which could interract, or try to use the "After an order is updated" and filter on the order status.
Please Log in or Create an account to join the conversation.
Thanks for the reply. I have tried changing the filter and other settings and nothing seems to work. It does send an email but the email is blank with no CSV file attached.
How can I send you login details to take a look?
Thanks
Lee
Please Log in or Create an account to join the conversation.
Please try to set the Joomla error reporting level to "maximum" this will display a potential php error.
To send login details you can do that via private messages or via our contact form.
In both case please don't forget to give a link to that topic.
Please Log in or Create an account to join the conversation.
Sorry I haven't seen your question in a previous post, the path must be an absolute one and a server path.
For example: /var/www/mysite/folder/myfile.csv
If this path is not correct, so the email can't attach the file and make an error.
Please set a valid path, test it and add an email address once it has been verified..
Please Log in or Create an account to join the conversation.
I have added the correct server path and tried a test purchase, but it is still not creating the CSV file on the server or emailing it.
Did you receive the login details to take a look?
Thank you
Lee
Please Log in or Create an account to join the conversation.
I have added a display results to the actions and when I process the Mass action within the results displayed is this error:
Catchable fatal error: Object of class stdClass could not be converted to string in /administrator/components/com_hikashop/views/massaction/tmpl/results.php
on line 363
What does this mean and is this preventing the CSV being created?
Please Log in or Create an account to join the conversation.
I don't think because this error is in a view, and that view is not used for the csv file generation.
But, there is maybe the same kind of error in the export csv file.
Are you sure that the path set is a valid one ? Is the folder set in the path writeable ? (correct permissions)
If yes, so please give us ftp details to debug that directly on your end.
Regards,
Please Log in or Create an account to join the conversation.
I have been able to connect to the server, but please give me the absolute path to reach the website folder.
Actually I have access to the root of the server and not access to the home folder.
I looked into the /var/www folder but don't found anything here.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
What Xavier says is that there is no public_html folder when you connect to the FTP. You arrive at the root of the hard drive where you see var etc usr etc.
I actually tried again but got a timeout error when trying to connect to the server.
Did you change something ?
Please Log in or Create an account to join the conversation.
Sorry but I have still no access to the "/home" folder on your server so can't see the files.
Regarding the path you set and the restrictions, we can potentially not write anything into the folder "/home".
Could you try another path to a less protected folder ?
And grant our FTP access in order to debug the issue.
Please Log in or Create an account to join the conversation.
I'm not sure what you mean by /home folder? do you mean the root of the site with the Joomla filebase on?
Also have you been using SFTP on port 5819? regular FTP connections will not be allowed. I need your IP Address to ensure the server has not banned you.
Do you have Skype so we can communicate and try and solve this connection issue?
Lee
Please Log in or Create an account to join the conversation.
Yes we are using the port 5819. After checking again it seems that we are not banned.
We arrive at the root folder of the server, so see the list of all the main folders.
You tell us that the site is under the /home/... folder, but when I try to see the content of that folder it's not possible, I have an icon displayed which show that we don't have the rights to reach the folder.
I sent you a screenshot in PM.
Please Log in or Create an account to join the conversation.
There was indeed some Notices but a Catchable error.
I have improved a check in the code to avoid that error.
Please tell me if it is working fine for you now. You should have received the email with the csv file attached.
Please Log in or Create an account to join the conversation.
Yes I have received the CSV file and it is also saving to the server! AWESOME
Thank you so much, hope the code changes make it into the next release!
Thank you for all your time and patience!
Please Log in or Create an account to join the conversation.
They will
Thanks for your feedback.
Regards,
Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.
Please Log in or Create an account to join the conversation.
Is there any way I can change the name of the csv file generated to include additional information, such as the order ID, say?
I need each order / CSV file to be individual and unique to each order so a filename similar to:
new_order_ORDER_ID.csv
where the ORDER_ID would be dynamically replaced on each order.
Thanks
Lee
Please Log in or Create an account to join the conversation.