Bookmark and Share

January 16, 2009 by Ivan  

Simple Create Order module – Zen cart

Ads by Google

I have created a simple module in zen-cart. This module called Simple Create Order v1.0. I created this module because i can’t find any module for create order from the admin back end.

After did some search on google and looking in Zen-Cart forum.  I found that there are 2 modules related to mine: those are super order 2.0 and edit order v1.5.3.

I thought i can use super order 2.0, but i did found that the developer of this module discontinued the project and there are many bugs and many complicated patch in the forum,  after that i decided to not use that module.

And then i come up for the second choice that is  edit order v1.5.3,  i think this module is the one i looking for, but this module only edit existing order made by the customer, not create a new one.

And then i have an idea, how about if i create my own module by recode the edit order module? After a several hours i did have my own module that is “Simple Create Order v1.0″.

My idea is really simple, i did join 2 modules (edit order v1.5.3 and add customer v1.02) with a little modifications and create my own create order module. You can download it here.

HOW TO INSTALL:

===============

1. Download the zip file.
Download
Downloaded 644 times
2. Upload files to your store directory; the directory structure design for zen cart 1.3.8a, if you still have standard installation you can just upload files in modifications folder, if not please refer to instruction manual include in zip file.

HOW TO USE:

===============

For create an order: In ADMIN->CUSTOMERS->Create Order

For create an customer: In ADMIN->CUSTOMERS->Add customer

For edit an Order: In ADMIN->CUSTOMERS->ORDERS->EDIT make necessary changes to customer’s order (i.e. to delete a product, change quantity to 0) and then click UPDATE.

PATCH:

===============

5 Agustus 2010: Fixed Cannot Delete Order… Finally :)

18 Sep 2009: Update add customer from admin module to v1.06

11 May 2009: Add resent invoice as request by Melissa.

29 April 2009: Fixed for anyone using prefix database table name. (Thanks to Brandy)

SCREENSHOT (click to enlarge):

=======================

Create Order

Create Order

Edit Order

Edit Order

Create Customer

Create Customer

Found any bugs or a suggestion please post here.  Enjoy…

If you find my coding tips, plugins, or tutorials then buy me a cup of coffee or leave a comment.

What people search:

Reader Comments

  1. Kent says:

    Hi, Thanks for your plugin.

    I’m using that, but a small problem when sent the email to customer, the invoice link is shop/admin/account_history_info.php?order_id=1007 and I found there was no account_history_info.php file in your plugin…

    Don’t konw what happened, ask for help, thanks

  2. Ty says:

    Thanks for taking the time to write the mod. I did notice that it ignors the disocunt of a product so you have to make sure that you catch the differance. Most of our products are discounted because we show the list price then "slash" it (using discount).

  3. Ivan says:

    @Ty
    Yes i did notice that. But it is from edit order module. But i will fix it in the next release.
    Thanks for the notice.

  4. Hello and thanks for this module!

    I dont see shipping price changing when adding or removing products. Maybe missing is also option to change shipping method?

  5. Sams says:

    Hi Ivan – thank you so much for this – we receive a lot of phone orders – so just what we are after :)
    We already have 'add customers' and 'edit orders' – so the addition of 'create orders' will be wonderful!

    Just wondering – with Step 2, the 3rd set of code seems the same? (but I might be having a blond day)

    Find:
    $contents[] = array('align' => 'center', 'text' => '<a href="' . zen_href_link(FILENAME_ORDER_EDIT, zen_get_all_get_params(array('oID', 'action')) . 'oID=' . $oInfo->orders_id . '&action=edit', 'NONSSL') . '">' . zen_image_button('button_edit.gif', IMAGE_EDIT) . '</a> <a href="' . zen_href_link(FILENAME_ORDERS, zen_get_all_get_params(array('oID', 'action')) . 'oID=' . $oInfo->orders_id . '&action=delete', 'NONSSL') . '">' . zen_image_button('button_delete.gif', IMAGE_DELETE) . '</a>');

    Replace With:
    $contents[] = array('align' => 'center', 'text' => '<a href="' . zen_href_link(FILENAME_ORDER_EDIT, zen_get_all_get_params(array('oID', 'action')) . 'oID=' . $oInfo->orders_id . '&action=edit', 'NONSSL') . '">' . zen_image_button('button_edit.gif', IMAGE_EDIT) . '</a> <a href="' . zen_href_link(FILENAME_ORDERS, zen_get_all_get_params(array('oID', 'action')) . 'oID=' . $oInfo->orders_id . '&action=delete', 'NONSSL') . '">' . zen_image_button('button_delete.gif', IMAGE_DELETE) . '</a>');

    My apologies if I've missed something….

    Many thanks
    Sams

  6. Primus says:

    Hello Ivan, just installed your add-on, thanks, but I have this problem.
    With the orders.php modified as per instruction, I have no "delete order" button.

    If I put back the original orders.php file, your addon will work on adding customers, and creating new orders, but not on editing orders.

    Looking for an answer, regards.

  7. Ivan says:

    @Sams and Primus
    Please use a file compare software, and compare original admin/orders.php and my modification/orders.php
    i forgot to update the instruction file.
    I'm so sorry.
    I will update it soon.

  8. Sams says:

    Thanks Ivan!
    I can see the correct info by doing the file comparing as you suggested.

    One more question – the admin/edit_orders file – I have the 'Edit Orders' module installed – and when I compared (your) file with the orig file, there are dozens of differences – If I install your 'all in one' program, can I safely use your edit_orders file and overwrite the old one?

    Many thanks
    Sams

  9. Ivan says:

    I only add auto calculation shipping module and resend invoice.
    You can use my edit_orders file, but make sure you backup your old one first.
    Cheers.

  10. cwill78295 says:

    Ivan, I am new to zen cart but would like to use your plugin. I will be uploading to the modifications folder. But, What is the full path to the modifications folder? \\store_name\?

  11. Ivan says:

    @cwill78295: it mean full path to your zencart installation folder

  12. Chris says:

    Ivan, I have installed your add on to my existing running store but I am getting the following error when I try to create a new order. Can you advise where I have gone wrong
    Thanks in advance.

  13. Chris says:

    Sorry Ivan, didn't add the error

    1109 Unknown table 'customers' in where clause
    in:
    [SELECT `customers_firstname` , `customers_lastname` , `customers_email_address` , `customers_telephone`, `entry_company` , `entry_street_address` , `entry_suburb` , `entry_postcode` , `entry_city` , `entry_state` , `entry_country_id` , `entry_zone_id` FROM zen_customers JOIN zen_address_book ON ( `customers_default_address_id` = `address_book_id` ) WHERE `customers`.`customers_id` = 240]
    If you were entering information, press the BACK button in your browser and re-check the information you had entered to be sure you left no blank fields.

  14. Ivan says:

    Hi Chris,
    Please download the one from this site.
    Thanks.

  15. Gary says:

    Thanks Ivan!
    This tool is very powerful!
    I lost a order in my zen cart orders, it's very usefully!

  16. Lyle says:

    Hi Ivan,

    Great add-on!! everything seems to be working except I can't seem to delete any orders?

    What does this code do?

    case 'deleteconfirm':
    // demo active test
    if (zen_admin_demo()) {
    $_GET['action']= '';
    $messageStack->add_session(ERROR_ADMIN_DEMO, 'caution');
    zen_redirect(zen_href_link(FILENAME_ORDERS, zen_get_all_get_params(array('oID', 'action')), 'NONSSL'));
    }
    $oID = zen_db_prepare_input($_GET['oID']);

    zen_remove_order($oID, $_POST['restock']);

    zen_redirect(zen_href_link(FILENAME_ORDERS, zen_get_all_get_params(array('oID', 'action')), 'NONSSL'));
    break;

    why the reference to zen_admin_demo()???

    Thanks in advance for all your hard work and effort!!!

    Lyle

  17. Ivan says:

    Hi Lyle,
    Please update your orders.php.
    You can download from my blog, i fixed it.

  18. Nate says:

    Hello. I am unable to delete orders after installing this mod. I went through the instructions and I believe I've made all the required changes correctly. I'm using file coparison software to see the differences between the orders.php file, but i confess I am lost as to where the issue lies. Looking at the past threads it looks like there is an update to the order.php file on a blog, but I do not know where it it. I can't seem to find it. I am using 1.3.9c. Can anyone help? Thanks!

  19. Ivan says:

    Hi Nate,
    Please update your orders.php.
    You can download from my blog. thanks.

  20. mike says:

    i was just starting to test the system out but for some reason it doesn't like my countries postal code it gives it and error when adding a customer. i'm assuming there are rules set for the add customer form could you pint me in the right direction thank you

  21. ldmorton says:

    Our orders.php has been patched to work with php 5.3. Will using your replacement break our patched file? We have not yet installed the “Simple Create Order” module.

  22. Magnus says:

    Is this issue fixed now? :)

  23. Please use file compare and merge your orders.php and my orders.php

  24. I think that case is came from the fedex and usps compatibility with your postal code. what is your postal code?

  25. Use file comparer to compare my files and your orders.php.
    And merge them.
    Thanks

  26. Hi Magnus, i'm afraid not.
    Zencart 2.0 will release soon.
    I'm wonder if this feature available on the new zencart or not.
    Thanks

  27. Ivan,

    We're having trouble with our shopping cart's shipping estimator. As soon as we finished installing this module, the shipping estimator quit working. We donated $5, and would be happy to donate another $5 if you could help us fix it.

    Thanks,
    Preston Mitchell
    Berridge Farms

  28. Hi Preston,
    What is your shipping estimator?
    i'm using usps and fedex.
    Please checek your shipping module configuration from the admin.

  29. Melissa says:

    Hi Ivan, I am having the issue of not being able to delete orders, which I see that you've addressed by telling people to download the new orders.php file from your blog. firstly, this is your blog, no? I can't find the updated version of this file anywhere. I just downloaded the mod today from this page… so where EXACTLY can I find the new orders.php file?

    Thank you!

  30. Did you download the one from this blog?

  31. Melissa says:

    Yes, I downloaded at the “Download” button linked above. The modifications orders.php file did not resolve my problem of not being able to delete.
    Thanks!

  32. Jordans shoes says:

    I love your post, thank you for sharing.

  33. Breda says:

    Hi,
    I'm trying out this mod and I have a problem with the tax, it shows the product price net of text, and it shows the tax rate in the tax box but it does not add the tax rate to the total? I dont have any tax mods switched on, only the standard Zen cart tax. Any idea waht I need to do to get it to show the total including tax?
    Regards
    Breda

  34. Glen says:

    Same issue here. I have tried everything but cannot delete orders

  35. HI Breda,
    For the tax you need to add it manually and calculate it manually too,
    Thanks

  36. i wonder what is wrong with the delete order. because i fixed it long time ago.
    But i will find what cause it.
    Thanks.

  37. For those who have problem with cannot delete the order.
    Please download the latest patch from this post.
    Just press download, and overwrite the order.php from modifications > admin > orders.php
    or see around line 849 and 851 for the fixes.
    Thanks.

  38. win iphone says:

    Hey there, Was looking for opportunity to post here as it beats phoning! My group is extremely astounded by the actual contribution additional webmasters are making on your site and hope to chip in in addition any time i can. I agree with the particular preceding commentor and anticipate to check back now and again.

  39. Dan Jones says:

    Hey there Ivan. We’ve installed the module on our websites – it is a really great module. However, I’ve noticed a big problem for us. When I input the delivery address, it does not appear on the online invoice and the invoice print off which will cause a massive problem with our delivery company. Is there an easy solution?

    Thanks so much,

    Dan Jones

  40. Imy says:

    Hi, I was wondering if you can create a search for product box in the add product page instead of step1 2 etc?

    Thanks
    Love the mod by the way!

Please do not add HTML tags in your comments. All comments are moderated.

Add a comment

(required, use real name)
(required, will not be published)
(optional, will not be published)
blog comments powered by Disqus