Page 5 of 12 FirstFirst ... 34567 ... LastLast
Results 41 to 50 of 113
  1. #41
    Join Date
    Jan 2007
    Location
    Los Angeles, California, United States
    Posts
    7,010
    Plugin Contributions
    27

    Default Re: Admin Simple Create Order Support Thread

    Thanks for your insight DrByte.. You confirmed what I thought was going to be required to execute this, and with that I am tapping out of doing anything more with this add-on than I've already done..

    I've got Create Orders working with Edit Orders 2.xx, and frankly if I am "creating" an order from the admin, I can live with manually entering in the state for those orders/customers which require it..

    The name of this add-on is Admin SIMPLE Create Orders.. This title amply describes what I have working on my test store.. a SIMPLE order creation method. So I'll let someone else have a go with building out the rest of this nightmarish add-on with all those other bells and whistles (shipping rates, order confirmation e-mails, etc..) I'll steer clear of that and minimize the amount of grey hair I have on my head thank you very much..

    After I finish up the Super Orders release me and my fellow Zenners have been working diligently on, and a boatload of other REAL work I've got on my plate, I'll probably bundle up my working version of this add-on and submit it to the downloads..

    It won't have the bells and whistles in it (shipping rates, order confirmation e-mails, etc..), but IMHO what is currently available right now is only half functioning anyway. AND there are adequate "workarounds" for those bells and whistles.. (shipping rates can be looked up and the existing comments features will work JUST FINE for customer order notification)

    IMHO, until someone comes along ('cause I'm done!) and wants to build this add-on out with all the PROPERLY WORKING bells and whistles, an add-on which at least serves the basic intent of this add-on is better than one that contains features which are buggy and/or do not work well..

    To the community: Please do not PM me about sending over my working version of Create Orders.. I have other projects on my plate, and it will be a minute before I have enough free time to properly bundle this up and submit it..

    In the meantime there are PLENTY of good tips in THIS support thread which will help others to get Create Orders to the state I have it in my test store.. All I really did to get it to work was to follow those tips. There is a required correction I discovered for one of the tips posted. I will follow-up this post with a correction to that tip..
    Quote Originally Posted by DrByte View Post
    As far as the customer address book entries go, it's either/or, not both.
    And the same details are carried over to the orders table when an order is created during checkout.

    entry_state is only ever to be filled in if there is no zone defined for their state in their country

    entry_zone_id is set if the customer's country+state matches a zone combination in the zones table. In such cases, entry_state is left blank, because the entry_zone_id points to the zone name which has the correct spelling etc of that state/zone name.

    Obviously, to present a list of available states/zones for a given country, you need to provide a pulldown menu such as is seen on the create-account page ... which also has some javascript to auto-update the list of available zones whenever the country pulldown selection is changed. And then, when a selection is made, the corresponding entry_zone_id is set based on the selection made.
    My Site
    I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.

  2. #42
    Join Date
    Jan 2007
    Location
    Los Angeles, California, United States
    Posts
    7,010
    Plugin Contributions
    27

    Default Re: Admin Simple Create Order Support Thread

    The following change needs to be made this previously posted tip.. I've highlighted in red the changes I made when implementing this in my test store..

    Quote Originally Posted by DivaVocals View Post
    I implemented this by creating a extra functions folder for Create Orders (versus updating the one for Edit Orders).

    I created admin/includes/functions/extra_functions/create_order_functions.php with the the following code:
    Code:
    <?php
    //
    // +----------------------------------------------------------------------+
    // |zen-cart Open Source E-commerce                                       |
    // +----------------------------------------------------------------------+
    // | Copyright (c) 2007 Numinix Technology                           |
    // |                                                                      |
    // | http://www.zen-cart.com/index.php                                    |
    // +----------------------------------------------------------------------+
    // | This source file is subject to version 2.0 of the GPL license,       |
    // | that is bundled with this package in the file LICENSE, and is        |
    // | available through the world-wide-web at the following url:           |
    // | http://www.zen-cart.com/license/2_0.txt.                             |
    // | If you did not receive a copy of the zen-cart license and are unable |
    // | to obtain it through the world-wide-web, please send a note to       |
    // | license@zen-cart.com so we can mail you a copy immediately.          |
    // +----------------------------------------------------------------------+
    /* 
     * @version $Id: edit_orders.php, v 1.0.0 12/11/2007 12:08:59 numinix $
     *
     */
     
      ////////////////////////////////////////////////////////////////////////////////////////////////
      //    Function    : zen_get_currency_value
      //    Arguments   : currency_code        currency code string
      //    Return      : currency_value
      //    Description : Function to retrieve the currency_value based on the currency's code
      ///////////////////////////////////////////////////////////////////////////////////////////////
      function zen_get_currency_value($currency_code) {
       global $db;
        $currency_query = $db -> Execute("select * from " . TABLE_CURRENCIES . " where code = '" . $currency_code . "'");
        return $currency_query->fields['value'];
      }
    
    ?>
    My Site
    I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.

  3. #43
    Join Date
    Jan 2007
    Location
    Los Angeles, California, United States
    Posts
    7,010
    Plugin Contributions
    27

    Default Re: Admin Simple Create Order Support Thread

    Quote Originally Posted by bluedotted
    Only issue I am really having is that the when adding a product it takes me back to the home page. I have tried all the suggestions and none seemed to work.

    Any ideas maybe on that issue?
    The only way that happens is if you are running Zen Cart v1.39 and have not updated Edit Orders to the newest version.. (this was discussed earlier in this support thread -- See pages 3-4)
    My Site
    I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.

  4. #44
    Join Date
    Jan 2007
    Location
    Los Angeles, California, United States
    Posts
    7,010
    Plugin Contributions
    27

    Default Re: Admin Simple Create Order Support Thread

    Now I KNOW it's time to go to bed.. I just re-read what you posted, and realized that (duh!) I overlooked a KEY part of what you said (I highlighted what I am chirping on about..)

    If I am understanding you correctly, while Create Orders and Add Customer's from Admin do work, to capture state information correctly, they probably needs some re-working to reflect the correct usage of entry_state and entry_zone_id.. Do I understand this correctly?? Are there consequences for using these mods if these changes don't make their way into the codebase??

    Quote Originally Posted by DrByte View Post
    As far as the customer address book entries go, it's either/or, not both.
    And the same details are carried over to the orders table when an order is created during checkout.

    entry_state is only ever to be filled in if there is no zone defined for their state in their country

    entry_zone_id
    is set if the customer's country+state matches a zone combination in the zones table. In such cases, entry_state is left blank, because the entry_zone_id points to the zone name which has the correct spelling etc of that state/zone name.

    Obviously, to present a list of available states/zones for a given country, you need to provide a pulldown menu such as is seen on the create-account page ... which also has some javascript to auto-update the list of available zones whenever the country pulldown selection is changed. And then, when a selection is made, the corresponding entry_zone_id is set based on the selection made.
    My Site
    I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.

  5. #45
    Join Date
    Jan 2007
    Location
    Los Angeles, California, United States
    Posts
    7,010
    Plugin Contributions
    27

    Default Re: Admin Simple Create Order Support Thread

    One more thing, the blank page issue has been discussed in this thread.. I re-posted a correction to the suggested fix tonight:
    http://www.zen-cart.com/forum/showpo...0&postcount=42

    Dunno if this will fix your specific issue, but this is a required mod to get Create Orders to work correctly..

    Quote Originally Posted by kalastaja View Post
    Hmmmmm. Done all the colorful things. And so I try to create an order and a blank page appears....... Could I perhaps get the Diva-versions of this?
    Quote Originally Posted by DivaVocals View Post
    I don't have a version of this to share with the community.. All I did in all that chatter I posted is about what would happen if I upgraded Edit Orders from v1.53 to v2.03/2.04. I had attempted to add in the shipping table and the "Send Confirmation E-mail" code that Ivan originally included (was going to share THAT until it failed to work the way I felt it should).. When that code didn't work well, I just left that code out and used Edit Orders 2.03/2.04 unedited..

    Did you download Edit orders from the link previously posted??? Does Edit Orders work standalone?? (ie: can you edit an existing order using Edit Orders?)
    My Site
    I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.

  6. #46
    Join Date
    Oct 2008
    Posts
    64
    Plugin Contributions
    0

    Default Re: Admin Simple Create Order Support Thread

    Quote Originally Posted by DivaVocals View Post
    One more thing, the blank page issue has been discussed in this thread.. I re-posted a correction to the suggested fix tonight:
    http://www.zen-cart.com/forum/showpo...0&postcount=42

    Dunno if this will fix your specific issue, but this is a required mod to get Create Orders to work correctly..
    This now causes a 500 internal error using this file you created with the code suggested also the page 3 and 4 fix you posted did not fix the issue, tried it on 4 or 5 different test installs fresh right out of the box still takes me to the admin page when trying to add a product.

    Thought I would note that as well.

  7. #47
    Join Date
    Jan 2007
    Location
    Los Angeles, California, United States
    Posts
    7,010
    Plugin Contributions
    27

    Default Re: Admin Simple Create Order Support Thread

    Quote Originally Posted by bluedotted View Post
    This now causes a 500 internal error using this file you created with the code suggested also the page 3 and 4 fix you posted did not fix the issue, tried it on 4 or 5 different test installs fresh right out of the box still takes me to the admin page when trying to add a product.

    Thought I would note that as well.
    What version of Edit Orders are you running???

    What version of Zen Cart are you running??

    Did you download this mod from Ivan's site or here in the downloads section??

    If you renamed your admin folder, did you make sure that all the files in the "admin" folders of these three add-ons are in YOUR store's admin folder???

    You say you've tried "everything" but I don't know what you mean by "everything". So it will be helpful if you can provide some additional information..

    I didn't do anything fancy to get it to work.. These are the steps I took to get it to work on a Zen Cart 1.3.9h install:


    1. Downloaded and installed the version of this mod from Ivan's blog (I ONLY installed the Create Orders files, I replaced the Add Customer from Admin and Edit Orders files with ones from the latest versions of those two add-ons)
    2. Downloaded and installed Edit Orders v2.04 (link to this version is posted in this thread)
    3. Downloaded and installed Add Customer from Admin v1.07
    4. Created admin/includes/functions/extra_functions/create_order_functions.php as per my previous post
    5. Made the modifications to orders.php as per the instructions in Edit Orders v2.04 (the instructions Ivan provided do not appear to work correctly)


    That's it.. Once I got it all installed it worked PERFECTLY!
    My Site
    I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.

  8. #48
    Join Date
    Oct 2008
    Posts
    64
    Plugin Contributions
    0

    Default Re: Admin Simple Create Order Support Thread

    Downloaded both from here http://www.ivankristianto.com/

    Using 1.3.9h - All versions tested on

    Edit Orders 2.0.4
    simple create orders 1.00

    Yes folder is renamed in live website but tests sites are not. I assure you they have been placed in their correct locations.

    Do not remember saying tried everything just tried everything the readme.txt has in it but failed, also tried the modified files that came with the mod.

    Maybe I am missing something but I have used winmerge and all software I can think of and they all seem to be exact but the Add Product Function fails.

  9. #49
    Join Date
    Jan 2007
    Location
    Los Angeles, California, United States
    Posts
    7,010
    Plugin Contributions
    27

    Default Re: Admin Simple Create Order Support Thread

    It was late and I left out a few of the steps I took. (all minor changes)

    I eliminated the following files from Ivan's install package:

    • admin/includes/classes/order.php
    • admin/includes/classes/shipping_admin.php
    • admin/includes/classes/shipping_cart_admin.php

    These 3 class files support the admin e-mail and the shipping tables features, but as I previously documented, these features did not work particularly well, and so I deprecated them all.

    Made the following change as per step 3 of the readme file:
    3. Make the following changes to admin/includes/functions/general.php:

    Find:
    Code:
       function zen_get_countries($default = '') {
        global $db;
        $countries_array = array();
        if ($default) {
          $countries_array[] = array('id' => '',
                                     'text' => $default);
        }
        $countries = $db->Execute("select countries_id, countries_name
                                   from " . TABLE_COUNTRIES . "
                                   order by countries_name");
    
        while (!$countries->EOF) {
          $countries_array[] = array('id' => $countries->fields['countries_id'],
                                     'text' => $countries->fields['countries_name']);
          $countries->MoveNext();
        }
    
        return $countries_array;
      }
    replace with:
    Code:
       function zen_get_countries($countries_id = '', $with_iso_codes = false) {
        global $db;
        $countries_array = array();
        if (zen_not_null($countries_id)) {
          if ($with_iso_codes == true) {
            $countries = "select countries_name, countries_iso_code_2, countries_iso_code_3 
                          from " . TABLE_COUNTRIES . " 
                          where countries_id = '" . (int)$countries_id . "' 
                          order by countries_name";
    
            $countries_values = $db->Execute($countries);
    
            $countries_array = array('countries_name' => $countries_values->fields['countries_name'],
                                     'countries_iso_code_2' => $countries_values->fields['countries_iso_code_2'],
                                     'countries_iso_code_3' => $countries_values->fields['countries_iso_code_3']);
          } else {
            $countries = "select countries_name 
                          from " . TABLE_COUNTRIES . " 
                          where countries_id = '" . (int)$countries_id . "'";
    
            $countries_values = $db->Execute($countries);
    
            $countries_array = array('countries_name' => $countries_values->fields['countries_name']);
          }
        } else {
          $countries = "select countries_id, countries_name 
                        from " . TABLE_COUNTRIES . " 
                        order by countries_name";
    
          $countries_values = $db->Execute($countries);
    
          while (!$countries_values->EOF) {
            /*$countries_array[] = array('countries_id' => $countries_values->fields['countries_id'],
                                       'countries_name' => $countries_values->fields['countries_name']);*/
            $countries_array[] = array('id' => $countries_values->fields['countries_id'],
                                     'text' => $countries_values->fields['countries_name']);
            $countries_values->MoveNext();
          }
        }
    
        return $countries_array;
      }
    Quote Originally Posted by DivaVocals View Post
    I didn't do anything fancy to get it to work.. These are the steps I took to get it to work on a Zen Cart 1.3.9h install:


    1. Downloaded and installed the version of this mod from Ivan's blog (the version on Ivan's blog is 1.01. I ONLY installed the Create Orders files, I replaced the Add Customer from Admin and Edit Orders files with ones from the latest versions of those two add-ons)
    2. Downloaded and installed Edit Orders v2.04 (link to this version is posted in this thread)
    3. Downloaded and installed Add Customer from Admin v1.07
    4. Created admin/includes/functions/extra_functions/create_order_functions.php as per my previous post
    5. Made the modifications to orders.php as per the instructions in Edit Orders v2.04 (the instructions Ivan provided do not appear to work correctly)


    That's it.. Once I got it all installed it worked PERFECTLY!
    The version here in the downloads section is v1.00, the version on Ivan's blog is v1.01. Are you sure you have the right version??

    You say you used Winmerge, but what files did you modify using Winmerge?? (I only made two changes to core files in my install)

    In my install there are only TWO core files I modified. admin/orders.php as per the instructions in Edit Orders for adding the proper "Edit" buttons and admin/includes/functions/general.php as per the instructions in the Create Orders readme.

    I made NO EDITS AT ALL to the Edit Order or Add Customer from Admin add-on files. In Ivans package, there are edits made to Edit Orders that are meant to support the shipping rate tables and the order e-mails..

    Though I had in my earlier attempts to get this working with Edit Orders v2.03/2.04 tried to add this code in to the latest version of Edit Orders, I eventually opted to incorporated NONE of this code because of the issues I previously documented with these features not working well. (order e-mails are formatted incorrectly, and do not send correctly/consistently, the shipping rate tables do not display the correct rates for all shipping modules). This is also the reason I did NOT include any of the admin class files from Ivan's install package.


    Quote Originally Posted by bluedotted View Post
    Downloaded both from here http://www.ivankristianto.com/

    Using 1.3.9h - All versions tested on

    Edit Orders 2.0.4
    simple create orders 1.00

    Yes folder is renamed in live website but tests sites are not. I assure you they have been placed in their correct locations.

    Do not remember saying tried everything just tried everything the readme.txt has in it but failed, also tried the modified files that came with the mod.

    Maybe I am missing something but I have used winmerge and all software I can think of and they all seem to be exact but the Add Product Function fails.
    My Site
    I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.

  10. #50
    Join Date
    Jan 2007
    Location
    Los Angeles, California, United States
    Posts
    7,010
    Plugin Contributions
    27

    Default Re: Admin Simple Create Order Support Thread

    Quote Originally Posted by kalastaja
    BTW. If you have multiple tax classes (which is ok by ZenCart) this nice "little" exercise goes haywire.... I do have a (working) suggestion, if someone is interested.
    It's a community forum, and all ideas suggestions are always welcome.. No need to wait for permission.. Just post your suggestion..
    My Site
    I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.

 

 
Page 5 of 12 FirstFirst ... 34567 ... LastLast

Similar Threads

  1. Simple Zen Template - Support Thread
    By jettrue in forum Addon Templates
    Replies: 461
    Last Post: 27 Apr 2013, 01:33 AM
  2. v150 Admin New Order [Support Thread]
    By lhungil in forum All Other Contributions/Addons
    Replies: 52
    Last Post: 18 Apr 2013, 06:07 PM
  3. Admin Simple Create Order
    By stesouthby in forum All Other Contributions/Addons
    Replies: 0
    Last Post: 23 Mar 2011, 02:35 PM
  4. Admin Simple Create Order
    By dmm2020 in forum All Other Contributions/Addons
    Replies: 0
    Last Post: 13 Nov 2010, 04:26 PM
  5. [Support Thread] Simple Video Manager
    By yellow1912 in forum All Other Contributions/Addons
    Replies: 6
    Last Post: 1 Nov 2008, 02:44 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •