Jump to content
blucollarguy

Multi_Vendor_Shipping new thread

Recommended Posts

I set the shop up with one item having two shipping methods, flat rate ($5.00) and UPS. On checkout_shipping.php I selected neither, hit continue, and went on my merry way. I really don't think it's the FedEx module.

 

Also, those options were never displayed for FedEx in the admin section of the site, removing one of the modules will not do anything. If the option to change shipping options for each vendor using FedEx had been available, I would have never installed the second FedEx module.

 

Did you personally experience Dry Goods not quoting for 3 day air and ground? I found that only happened if I set the shipping address to be the same as the store address (brain fart on that one I'd say).

 

Thank you,

Stew


Do, or do not. There is no try.

 

Order Editor 5.0.6 "Ultra Violet" is now available!

For support or to post comments, suggestions, etc, please visit the Order Editor support thread.

Share this post


Link to post
Share on other sites

I can't reproduce this with my test store. Try it yourself and see. I think that you have an error somewhere in your modifications. Check the patch mentioned above.

 

The FedEx module does not have the option of removing some of the shipping methods. This should be added, but nobody's done it yet that I know of. Your modification may have caused the problem you are seeing with the missing shipping options.

 

Dry goods did not quote 3 day air or ground for shipment to me. I can see it not quoting air for me, since I'm a bit far from a major airport, but I can see no reason that it wouldn't quote ground. I know that I can get FedEx ground shipments in. Again, I suspect your modified FedEx module is hiding part of the quote.

 

Regards

Jim


See my profile for a list of my addons and ways to get support.

Share this post


Link to post
Share on other sites

Jim-

 

I can't reproduce this with my test store. Try it yourself and see. I think that you have an error somewhere in your modifications. Check the patch mentioned above.

 

I'll take your word for it- if no one else is experiencing this then it must be in the code for my store.

 

The FedEx module does not have the option of removing some of the shipping methods. This should be added, but nobody's done it yet that I know of. Your modification may have caused the problem you are seeing with the missing shipping options.

 

I don't quite understand what you're getting at here. If the options never existed then what has the discussion been about? If you mean within the module itself, you simply comment out the options you don't need or want. Which reminds me of something, maybe I left a comma or parantheses or something lying around. Wouldn't be the first time! :) I'll have to check that out.

 

Dry goods did not quote 3 day air or ground for shipment to me. I can see it not quoting air for me, since I'm a bit far from a major airport, but I can see no reason that it wouldn't quote ground. I know that I can get FedEx ground shipments in. Again, I suspect your modified FedEx module is hiding part of the quote.

 

Regards

Jim

 

It doesn't happen all the time- perhaps it's a problem with the FedEx server? Maybe I'm too reluctant to inspect my clone hack. The only problem I have with changing it is that I won't have the flexibility that I currently enjoy.

 

Thank you for all your time and attention to this. Maybe I can get you a pie? We have many flavors, far more than are currently offered on the site.....


Do, or do not. There is no try.

 

Order Editor 5.0.6 "Ultra Violet" is now available!

For support or to post comments, suggestions, etc, please visit the Order Editor support thread.

Share this post


Link to post
Share on other sites

Line 83 from includes/modules/vendor_shipping.php:

 

if ( !tep_session_is_registered('shipping') || ( tep_session_is_registered('shipping') && ($shipping == false) ) )  $shipping = $shipping_modules->cheapest($vendor_id);

 

Line 186:

 

if ( !tep_session_is_registered('shipping') || ( tep_session_is_registered('shipping') && ( $shipping == false || ( !isset($shipping['vendor'][$vendor_id]) ) ) ) )  $shipping['vendor'][$vendor_id] = $shipping_modules->cheapest($vendor_id);

 

 

I uploaded the file again just to be sure... and it still does it! GAAAAAAAAAAYYYYYYYYYYYYAHHHHAAAAAAAAAA


Do, or do not. There is no try.

 

Order Editor 5.0.6 "Ultra Violet" is now available!

For support or to post comments, suggestions, etc, please visit the Order Editor support thread.

Share this post


Link to post
Share on other sites

I have the test store and one live store running this, and neither seem to have the problem. Other people are running this as well, and several have tested for this exact problem. I'm sorry that I can't give you more exact help, but I am seeing that --none-- choice in your database that shouldn't be there. That indicates that you have one missing patch. Fixing that may fix the problem for you.

 

I meant that the FedEx module does not allow you to exclude shipping methods in the module setup in the admin, which it should. You have to modify the module itself. I understand why you have created two modules; I'm just trying to eliminate sources of problems to localize the bug. I now suspect that the problem is not in the FedEx module at all. At least that's some progress.

 

I hope to get my development box back in working order tomorrow. Whenever that happens, I'll be able to take a good look at the code for you. Maybe I will be able to come up with some better ideas.

 

Regards

Jim


See my profile for a list of my addons and ways to get support.

Share this post


Link to post
Share on other sites

I will go back over the contrib and see if I missed something. What "none" is it that you're referring to? When selecting Products Vendors?

 

Here's one for ya- what does this mean (from /admin/categories.php?cPath=1&pID=29&action=new_product_preview&read=only):

 

1054 - Unknown column 'pd.products_head_title_tag' in 'field list'

select p.products_id, pd.language_id, pd.products_name, pd.products_description, pd.products_head_title_tag, pd.products_head_desc_tag, pd.products_head_keywords_tag, pd.products_url, p.products_quantity, p.products_model, p.vendors_prod_id, p.products_image, p.products_price, p.vendors_product_price, p.products_price1, p.products_price2, p.products_price3, p.products_price4, p.products_price5, p.products_price6, p.products_price7, p.products_price8, p.products_price1_qty, p.products_price2_qty, p.products_price3_qty, p.products_price4_qty, p.products_price5_qty, p.products_price6_qty, p.products_price7_qty, p.products_price8_qty, p.products_qty_blocks, p.products_weight, p.products_dim_type, p.products_length, p.products_width, p.products_height, p.products_ready_to_ship, p.vendors_prod_comments, p.products_date_added, p.products_last_modified, p.products_date_available, p.products_status, p.manufacturers_id, p.vendors_id from products p, products_description pd where p.products_id = pd.products_id and p.products_id = '29'

 

This has started since installing MVS.


Do, or do not. There is no try.

 

Order Editor 5.0.6 "Ultra Violet" is now available!

For support or to post comments, suggestions, etc, please visit the Order Editor support thread.

Share this post


Link to post
Share on other sites

The "none" may have been in somebody else's code. I've been trying to debug code on the forums, in email/PMs, and over the phone for several people, all without having the code in front of me. I'm probably confusing your site with somebody else's.

 

The "unknown column" error is from some code from another Contribution that slipped into some of the MVS code early on. I thought that we had all of that scrubbed out. Please let me know where that error message is appearing so I can get rid of it.

 

Regards

Jim


See my profile for a list of my addons and ways to get support.

Share this post


Link to post
Share on other sites

Ok-

 

So the patches you posted for modules/vendor_shipping.php should clear up the problem I'm having, right (being able to checkout without paying for shipping)? I've checked them what seems like a hundred times. So maybe it's in checkout_shipping.php?

 

The unknown column error pops up in admin/categories.php after you open a category folder, select an item from that category, then click on the little blue triangle for that item in the "Action" column.

 

I'm trying to figure out a new way to say thanks....

 

B)

 

Stew


Do, or do not. There is no try.

 

Order Editor 5.0.6 "Ultra Violet" is now available!

For support or to post comments, suggestions, etc, please visit the Order Editor support thread.

Share this post


Link to post
Share on other sites

That patch solved the problem for other people. You may have a different problem that causes the same result. With code this complex that's entirely possible. There is a lot of code to make things happen in checkout_shipping.

 

I'll take a look at the admin side as soon as I get a chance. That should be an easy fix.

 

Regards

Jim


See my profile for a list of my addons and ways to get support.

Share this post


Link to post
Share on other sites
Mark: You could have a problem with vendor_order_info.php . This file is used to display the extra order  information that MVS provides.

 

Lori: All of the demo sites are occasionally down for testing of upgrades. Or, in this case, an apparent database problem. You can try my site, which is currently running RC3 with all of the patches. I'm going to upgrade to a patched RC5 as soon as I have the time. Or possibly RC6, depending on how long it takes me.  :blush:

 

Regards

Jim

 

Nope, that was not it.

 

Additional problem I have at the moment is that the welcome page, which worked

fine before, now displays php code instead the html such as:

 

al prices (if any) $specials_query = tep_db_query("select specials_new_products_price from " . TABLE_SPECIALS . " where products_id = '" . (int)$products_id . "' and status = '1'" ); if (tep_db_num_rows ($specials_query)) { $specials = tep_db_fetch_array($specials_query); $products_price = $specials['specials_new_products_price']; } //Add values to the output array $this->vendor_shipping[$vendors_id]['weight'] += ($quantity * $products_weight); $this->vendor_shipping[$vendors_id]['cost']

Share this post


Link to post
Share on other sites

I installed the RC5 successfully and it's working great ( Offline ) ... after i uploaded my site to the internet im facing a problem

 

when i click on Manage in the vendors page i get the modules page but it's empty and it doesnt load any modules in .... The modules folder is existing and it's reading the right path .. help please

Share this post


Link to post
Share on other sites

Update on my problems- I thought that maybe the old multi vendor shipping code was interfering with MVS in some way, so I went back through and deleted everything from that contrib, but this had no effect on the problem of being able to checkout without paying for shipping. Also, I used a raw checkout_shipping.php in place of the one on my site, still the same problem. When I have more time I will go back through all the other pages to see if there is anything else that I missed.

 

If someone could point me in the direction of certain files that are most likely to be the problem that would be greatly appreciated (ie, where is the code that controls whether or not someone is able to checkout without selecting a shipping method, or where is the code that is supposed to automatically select a certain method if that is what is supposed to happen).

 

Also, I believe someone mentioned something about a default shipping method- this might just be semantics, but I've never seen an option of choosing an option as default. I can turn modules off and on, and change the sort order, but there is no "default" option that I've seen.


Do, or do not. There is no try.

 

Order Editor 5.0.6 "Ultra Violet" is now available!

For support or to post comments, suggestions, etc, please visit the Order Editor support thread.

Share this post


Link to post
Share on other sites

Suhayb-

 

It sounds to me like the includes/modules/vendors_shipping folder is missing or empty. Have you tried uploading it again just to be sure?


Do, or do not. There is no try.

 

Order Editor 5.0.6 "Ultra Violet" is now available!

For support or to post comments, suggestions, etc, please visit the Order Editor support thread.

Share this post


Link to post
Share on other sites

Does this give you the option to have products shipped via UPS and also shipped via a flat rate? I have two products in my site that need to be charged a flat rate for LTL pickup but the other products need to ship regulary via the UPS XML Module.. will this contrib solve my problem?

Share this post


Link to post
Share on other sites

Yes- that's how it works. There was some discussion, I believe, about the UPS XML module, so you should look through the posts to see what the problem was/is with that module specifically.

 

For a more detailed answer to your original question, here is how I use this contribution:

 

One set of goods can be shipped FedEx 2-Day Air or faster.

 

Another set of goods can be shipped any method by FedEx (Home Delivery, 2-Day, whatever your heart desires).

 

Yet another set of goods is set to free shipping (Flat Rate $0.00).

 

If a customer were to purchase from each of the three categories, on checkout_shipping.php they would choose the shipping method of their choice for the items from the first two classes of goods, and would be charged nothing for shipping the items from the third class of goods. On checkout_payment.php they would see a grand total for all the shipping charges plus the cost of their goods as well as tax if applicable.

 

Hope this helps!


Do, or do not. There is no try.

 

Order Editor 5.0.6 "Ultra Violet" is now available!

For support or to post comments, suggestions, etc, please visit the Order Editor support thread.

Share this post


Link to post
Share on other sites

After installing this contrib, I get the following errors for each shipping method. Can somebody tell me what I missed?

 

thanks

nick

 

Warning: constant(): Couldn't find constant MODULE_SHIPPING_FEDEX1_SORT_ORDER_1 in c:\!\_proj\catalog\includes\modules\vendors_shipping\fedex1.php on line 120

 

Warning: constant(): Couldn't find constant MODULE_SHIPPING_FEDEX1_SORT_ORDER_1 in c:\!\_proj\catalog\includes\modules\vendors_shipping\fedex1.php on line 120

Share this post


Link to post
Share on other sites

From page 37:

 

Incidentally, (chironae in particular, but others might be interested,) I've fixed the sort_order thing in code. Every vendors_shipping module needs to be modified.

 

The easiest way would be to change the calls from constant(x) to @constant(x). But that leaves a '0' in the Sort Order column, which (a) is different from the other osCommerce modules and (cool.gif leaves you without any way to tell which modules are installed and not installed.

 

The better way (in my not-so-humble opinion) is to replace the sort_order functions in each module with something else. Here's what I did in catalog/includes/modules/vendors_shipping/item.php, for example:

 

CODE

    function sort_order($vendors_id='1') {

    $sort_order = constant ('MODULE_SHIPPING_ITEM_SORT_ORDER_' . $vendors_id);

    if (isset ($sort_order)) {

      $this->sort_order = $sort_order;

    } else {

      $this->sort_order = '0';

    }

    return $this->sort_order;

  }

 

 

changed to:

 

CODE

  function sort_order($vendors_id='1') {

    $sort_order = 'MODULE_SHIPPING_ITEM_SORT_ORDER_' . $vendors_id;

    if (defined($sort_order)) {

      $this->sort_order = constant($sort_order);

    } else {

      $this->sort_order = '-';

    }

    return $this->sort_order;

  }

 

 

See, instead of taking constant() blindly, we set up a variable name (so we don't have to do the concatenation multiple times), then check to see if it's defined. If not, we use a non-numeric sort order, which will result in a blank in the Sort Order column, just like the standard modules.

 

It's not a tough change, from a coding standpoint. You've just got to make sure you hit every module.

 

Jude


Do, or do not. There is no try.

 

Order Editor 5.0.6 "Ultra Violet" is now available!

For support or to post comments, suggestions, etc, please visit the Order Editor support thread.

Share this post


Link to post
Share on other sites
Ok-

 

So the patches you posted for modules/vendor_shipping.php should clear up the problem I'm having, right (being able to checkout without paying for shipping)?  I've checked them what seems like a hundred times.    So maybe it's in checkout_shipping.php?

 

The unknown column error pops up in admin/categories.php after you open a category folder, select an item from that category, then click on the little blue triangle for that item in the "Action" column.

 

I'm trying to figure out a new way to say thanks....

 

B)

 

Stew

  Update on my problems- I thought that maybe the old multi vendor shipping code was interfering with MVS in some way, so I went back through and deleted everything from that contrib, but this had no effect on the problem of being able to checkout without paying for shipping. Also, I used a raw checkout_shipping.php in place of the one on my site, still the same problem. When I have more time I will go back through all the other pages to see if there is anything else that I missed.

 

If someone could point me in the direction of certain files that are most likely to be the problem that would be greatly appreciated (ie, where is the code that controls whether or not someone is able to checkout without selecting a shipping method, or where is the code that is supposed to automatically select a certain method if that is what is supposed to happen).

 

Also, I believe someone mentioned something about a default shipping method- this might just be semantics, but I've never seen an option of choosing an option as default. I can turn modules off and on, and change the sort order, but there is no "default" option that I've seen.

 

Stew and others,

I am currently working on the issue of being able to checkout without selecting a shipping method as well, I have received several emails asking for help with this particular issue and I beleive this is the single most disturbing bug we have with MVS. Files to check for this bug will be:

in catalog->

checkout_shipping.php

checkout_process.php

checkout_payment.php(though should not have been affected by MVS)

in catalog->includes

application_top.php

in catalog->includes->classes

order.php

shopping_cart.php

vendor_shipping.php

 

These files are the only ones changed by MVS that could create this issue, there will be a check to make sure a shipping method was chosen and, if not, kick back to "checkout_shipping.php".

 

If I find it, obviously I will post the fix immediately and update the next release.

 

The "default" shipping method is automatically selected as the "cheapest" method available, you cannot pick wich one is used, it is hard coded to the "cheapest".

 

The "unknown" column message your getting is from "Header Tags" contribution. Do you have that installed? You may have accidently wiped out that column during MVS installation.

 

Seperately, USPS has been a major headache for me, all I get is messages from USPS that they can't give me quote, if someone is using the USPS module with success, could you please send me a copy through PM? If I can keep my hair and not go grey over this particular issue I will be trying to post another bugfix update to MVS soon.

 

Special thanks to Jim for his incredible efforts with MVS, we all owe him a great deal of gratitude. I am sure he never expected to be so involved when he agreed to work with me on MVS, he got much more than he bargained for, so thank him every chance you get. He's a great guy as well as a $@&* of a coder.

 

Craig :)


Happy Coding!

Craig Garrison Sr

Anything worth having, is worth working for.

Multi Vendor Shipping V1.1 Demo Catalog

3 Vendors, each category, "buy" a product from each category to see how MVS works during checkout.

Multi Vendor Shipping V1.1 Demo Admin

login: webmaster@blucollarsales.com

pass: mvs_demo

MVS Thread:

Multi-Vendor Shipping

My contribs:

Download Multi Vendor Shipping V1.1

Vendor Email

Vendor Info in easypopulate

EZ Price Updater

And more to come!

Share this post


Link to post
Share on other sites

Hi all,

 

I am setting up a new store, and have just added MVS RC5. I LOVE :thumbsup: what I see so far! I have most of the bugs that I encountered worked out, but I have 3 that seem to elude me at this point. I would appreciate any assistance that could be provided.

 

Here they are (in no particular order!)

 

1. At the checkout shipping page, if I try to select an alternative shipping method other than the pre-selected "cheapest method", I get this error:

Line 24

Error: 'document.checkout_address.shipping.0' is null or not an object

I am also getting the error for line 328

 

(I can post the checkout_shipping code if needed)

 

2. The shipping cost and Sales tax on the invoice are showing 3 decimal places. I have tax decimal places set to 2, and currency (USD) decimal places set to 2 also.

 

3. I am trying to get this to work with the Order Editor 1.61b (http://www.oscommerce.com/community/contributions,1435) and can not get it to work right. When you attempt to edit an order, it will pull the editing page up just fine, but then when you select the "update" button after making any changes (or not) I get the following error:

Cannot modify header information - Headers already sent by output started at /hsphere/local/home/johnseyb/greenmountainspecialties.com/admin/includes/classes/vendor_order_data.php:11) in /hsphere/local/home/johnseyb/greenmountainspecialties.com/admin/includes/functions/general.php on line 45

After this, it corrupts the order, and some of the prices are deleted out of the database.

 

Any ideas where to start on any of these?

 

You all have a great product here! Keep it up!

 

John

Share this post


Link to post
Share on other sites
The "unknown" column message your getting is from "Header Tags" contribution. Do you have that installed? You may have accidently wiped out that column during MVS installation.

 

No? This is what the section of code looks like in my installed admin/categories.php:

 

 //vendors_email start   Many additions here, the order they are listed is very important, all new fields have vendor or vendors in the name,
//(ie, "p.vendors_product_price,")
     $product_query = tep_db_query("select p.products_id, pd.language_id, pd.products_name, pd.products_description, pd.products_head_title_tag, pd.products_head_desc_tag, pd.products_head_keywords_tag, pd.products_url, p.products_quantity, p.products_model, p.vendors_prod_id, p.products_image, p.products_price, p.vendors_product_price, p.products_price1, p.products_price2, p.products_price3, p.products_price4, p.products_price5, p.products_price6, p.products_price7, p.products_price8, p.products_price1_qty, p.products_price2_qty, p.products_price3_qty, p.products_price4_qty, p.products_price5_qty, p.products_price6_qty, p.products_price7_qty, p.products_price8_qty, p.products_qty_blocks, p.products_weight, p.products_dim_type, p.products_length, p.products_width, p.products_height, p.products_ready_to_ship, p.vendors_prod_comments, p.products_date_added, p.products_last_modified, p.products_date_available, p.products_status, p.manufacturers_id, p.vendors_id from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_id = pd.products_id and p.products_id = '" . (int)$HTTP_GET_VARS['pID'] . "'");
     $product = tep_db_fetch_array($product_query);
//vendors_email end

 

This is what a raw MVS version of that code looks liike:

 

 //vendors_email start   Many additions here, the order they are listed is very important, all new fields have vendor or vendors in the name,
   //(ie, "p.vendors_product_price,")
     $product_query = tep_db_query("select p.products_id, pd.language_id, pd.products_name, pd.products_description, pd.products_url, p.products_quantity, p.products_model, p.vendors_prod_id, p.products_image, p.products_price, p.vendors_product_price, p.products_weight, p.vendors_prod_comments, p.products_date_added, p.products_last_modified, p.products_date_available, p.products_status, p.manufacturers_id, p.vendors_id from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_id = pd.products_id and p.products_id = '" . (int)$HTTP_GET_VARS['pID'] . "'");
     $product = tep_db_fetch_array($product_query);
     //vendors_email end

 

So WTF is going on? Where the hell did all that extra code come from? I don't have any recollection of any other contrib being added in recently, certainly not one that would add all that gobbedlygook (though I wouldn't put it past myself). It looks like maybe something that would go along with separate pricing per customer, but I've never even downloaded that contrib, only thought about it.

 

It's a simple fix, I just commented out the crazy code (just in case it turns out that I need it) and put in the proper code, but that's a weird one.

 

Sorry about that one, by the way, I should have caught it way sooner. It wasn't a real huge problem though and I really never looked at it very hard.

 

Thanks for your help, and if you have any ideas on where the crazy code comes from, thanks for that too!

 

Stew


Do, or do not. There is no try.

 

Order Editor 5.0.6 "Ultra Violet" is now available!

For support or to post comments, suggestions, etc, please visit the Order Editor support thread.

Share this post


Link to post
Share on other sites

Wait a second- I got that from the instructions!!!!

 

From Admin_Install.txt:

 

=====================
Find Lines 670 & 671
=====================

     $product_query = tep_db_query("select p.products_id, pd.language_id, pd.products_name, pd.products_description, pd.products_url, p.products_quantity, p.products_model, p.products_image, p.products_price, p.products_weight, p.products_date_added, p.products_last_modified, p.products_date_available, p.products_status, p.manufacturers_id  from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_id = pd.products_id and p.products_id = '" . (int)$HTTP_GET_VARS['pID'] . "'");
     $product = tep_db_fetch_array($product_query);


=============
Replace With
=============

//vendors_email start   Many additions here, the order they are listed is very important, all new fields have vendor or vendors in the name,
//(ie, "p.vendors_product_price,")
     $product_query = tep_db_query("select p.products_id, pd.language_id, pd.products_name, pd.products_description, pd.products_head_title_tag, pd.products_head_desc_tag, pd.products_head_keywords_tag, pd.products_url, p.products_quantity, p.products_model, p.vendors_prod_id, p.products_image, p.products_price, p.vendors_product_price, p.products_price1, p.products_price2, p.products_price3, p.products_price4, p.products_price5, p.products_price6, p.products_price7, p.products_price8, p.products_price1_qty, p.products_price2_qty, p.products_price3_qty, p.products_price4_qty, p.products_price5_qty, p.products_price6_qty, p.products_price7_qty, p.products_price8_qty, p.products_qty_blocks, p.products_weight, p.products_dim_type, p.products_length, p.products_width, p.products_height, p.products_ready_to_ship, p.vendors_prod_comments, p.products_date_added, p.products_last_modified, p.products_date_available, p.products_status, p.manufacturers_id, p.vendors_id from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_id = pd.products_id and p.products_id = '" . (int)$HTTP_GET_VARS['pID'] . "'");
     $product = tep_db_fetch_array($product_query);
//vendors_email end

 

I'm assuming at this point that the code found in the file admin/categories.php included with the contrib is correct. If not, please advise.

 

Stew


Do, or do not. There is no try.

 

Order Editor 5.0.6 "Ultra Violet" is now available!

For support or to post comments, suggestions, etc, please visit the Order Editor support thread.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×