Zen Cart Logo

DUAL Pricing v2

Views: 363,359

Results 701 to 720 of 1,504
21 Jan 2011, 11:44 PM
#701
missmobtown avatar

missmobtown

New Zenner

Join Date:
Oct 2010
Location:
San Francisco
Posts:
6
Plugin Contributions:
0

DUAL Pricing v2

Yes, that did it for fixing the error message. Now logging in on the front side works fine.

But, it looks like I'm left with a lingering problem; in Admin/Customers, I can edit customers and try to change their Wholesale Pricing level, but it seems like that info isn't being saved. Even I try to switch my fake wholesale customers to 0 (retail), it doesn't show a number in the Request Wholesale column in my customers table. Any thoughts on this, or do I need to PM you for reversal instructions and...sigh... start from scratch?

BTW, your debugging of this mod for this version of Zen Cart is pretty brilliant. Well done, and thanks.

CG

22 Jan 2011, 12:09 AM
#702
twitchtoo avatar

twitchtoo

Totally Zenned

Join Date:
Apr 2007
Location:
Ontario, Canada
Posts:
1,733
Plugin Contributions:
14

Re: DUAL Pricing v2

missmobtown:

Yes, that did it for fixing the error message. Now logging in on the front side works fine.

But, it looks like I'm left with a lingering problem; in Admin/Customers, I can edit customers and try to change their Wholesale Pricing level, but it seems like that info isn't being saved. Even I try to switch my fake wholesale customers to 0 (retail), it doesn't show a number in the Request Wholesale column in my customers table. Any thoughts on this, or do I need to PM you for reversal instructions and...sigh... start from scratch?

BTW, your debugging of this mod for this version of Zen Cart is pretty brilliant. Well done, and thanks.

CG

This is a result of a missed 'customers_wholesale' replacement **OR **not removing the duplicate entries listed in one or more of the files.

This is the exact problem that led me to the bug and the fix!

If it's happening in the admin, check that your admin/customers.php file has all the necessary replacements. This is the file that is controlling the input and then the read from the SQL database fields.

Look to see there are no duplicate c.customers_wholesale or any of the old incorrect customer_whole/customer_wholesale anywhere in the customers.php file.

Thanks!

Twitch.

22 Jan 2011, 12:43 AM
#703
missmobtown avatar

missmobtown

New Zenner

Join Date:
Oct 2010
Location:
San Francisco
Posts:
6
Plugin Contributions:
0

Re: DUAL Pricing v2

twitchtoo:

This is a result of a missed 'customers_wholesale' replacement **OR **not removing the duplicate entries listed in one or more of the files.

AHHHHH YESSS! I got it, I found that missing little bugger in customers.php, and it was exactly in the code where it made sense. Thank you, thank you for your instructions. Everything on the backend AND the front end is working perfectly now. You should be elevated to "Totally Zenned" automatically!

All the best,
CG

27 Jan 2011, 9:12 PM
#704
kteluv avatar

kteluv

New Zenner

Join Date:
Jan 2011
Posts:
4
Plugin Contributions:
0

Re: DUAL Pricing v2

[QUOTE=twitchtoo;983284]Ok, here it is, step by step installation, bug fix and testing!

DO NOT use the install.sql.
Instead use the following SQL patch:

ALTER TABLE products ADD products_price_w VARCHAR( 150 ) DEFAULT '0' AFTER products_price;
ALTER TABLE products_attributes ADD options_values_price_w VARCHAR( 150 ) DEFAULT '0' AFTER options_values_price;
ALTER TABLE products_discount_quantity ADD discount_price_w VARCHAR( 150 ) DEFAULT '0' AFTER discount_price;
ALTER TABLE customers ADD customers_wholesale VARCHAR( 4 ) DEFAULT '0' NOT NULL AFTER customers_wholesale;


Hello there,
This module is exactly what I've been looking for, thanks! I'm trying to install this module and have encountered a problem. I've been following the instructions & did not install the install.sql. Instead I went into the admin>install SQL patch & pasted the above patch. It does not 'take' and I end up with an error message:

"1054 Unknown column 'customers_wholesale' in 'kldcustomers'
in:
[ALTER TABLE kldcustomers ADD customers_wholesale VARCHAR( 4 ) DEFAULT '0' NOT NULL AFTER customers_wholesale;]
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."

Also, when I go to customers in Admin, I get this message:

"1054 Unknown column 'c.customers_wholesale' in 'field list'
in:"

Did I not add the patch properly? I left off trying to install at step 13.

Thanks for help!

27 Jan 2011, 9:14 PM
#705
kteluv avatar

kteluv

New Zenner

Join Date:
Jan 2011
Posts:
4
Plugin Contributions:
0

Re: DUAL Pricing v2

[QUOTE=kteluv;988393]> twitchtoo:

Ok, here it is, step by step installation, bug fix and testing!

DO NOT use the install.sql.
Instead use the following SQL patch:

ALTER TABLE products ADD products_price_w VARCHAR( 150 ) DEFAULT '0' AFTER products_price;
ALTER TABLE products_attributes ADD options_values_price_w VARCHAR( 150 ) DEFAULT '0' AFTER options_values_price;
ALTER TABLE products_discount_quantity ADD discount_price_w VARCHAR( 150 ) DEFAULT '0' AFTER discount_price;
ALTER TABLE customers ADD customers_wholesale VARCHAR( 4 ) DEFAULT '0' NOT NULL AFTER customers_wholesale;

Hello there,
This module is exactly what I've been looking for, thanks! I'm trying to install this module and have encountered a problem. I've been following the instructions & did not install the install.sql. Instead I went into the admin>install SQL patch & pasted the above patch. It does not 'take' and I end up with an error message:

"1054 Unknown column 'customers_wholesale' in 'kldcustomers'
in:
[ALTER TABLE kldcustomers ADD customers_wholesale VARCHAR( 4 ) DEFAULT '0' NOT NULL AFTER customers_wholesale;]
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."

Also, when I go to customers in Admin, I get this message:

"1054 Unknown column 'c.customers_wholesale' in 'field list'
in:"

Did I not add the patch properly? I left off trying to install at step 13.

Thanks for help!

27 Jan 2011, 9:38 PM
#706
twitchtoo avatar

twitchtoo

Totally Zenned

Join Date:
Apr 2007
Location:
Ontario, Canada
Posts:
1,733
Plugin Contributions:
14

Re: DUAL Pricing v2

[quote=kteluv;988394]> kteluv:

Hello there,
This module is exactly what I've been looking for, thanks! I'm trying to install this module and have encountered a problem. I've been following the instructions & did not install the install.sql. Instead I went into the admin>install SQL patch & pasted the above patch. It does not 'take' and I end up with an error message:

"1054 Unknown column 'customers_wholesale' in 'kldcustomers'
in:
[ALTER TABLE kldcustomers ADD customers_wholesale VARCHAR( 4 ) DEFAULT '0' NOT NULL AFTER customers_wholesale;]
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."

Also, when I go to customers in Admin, I get this message:

"1054 Unknown column 'c.customers_wholesale' in 'field list'
in:"

Did I not add the patch properly? I left off trying to install at step 13.

Thanks for help!

You have installed the patch incorrectly. 'kldcustomers' is NOT part of any variable in the patch. 'c.customers_wholesale' is not the correct variable name replacement in one of the files listed in the patch.

For each step of the patch, read what the computer 'finds' BEFORE 'replacing' it to ensure you are replacing the correct variable name.

Be sure to apply the extra SQL patch in post #695.

Try again and keep me posted.

Twitch.

31 Jan 2011, 7:29 PM
#707
supersnow avatar

supersnow

Zen Follower

Join Date:
Apr 2007
Location:
California, USA
Posts:
233
Plugin Contributions:
0

Re: DUAL Pricing v2

So I can start modifying the sales report module so I can see the sales orders by wholesale customers as apposed to retail customers I need to add to the order table the customer wholesale status. Does anyone have any ideas?

I would think this might be important for a number of people as it stands unless you look at the amounts in an order you have no idea if an order is a retail order or a wholesale order - unless I am missing something.

Thanks for any help

31 Jan 2011, 8:23 PM
#708
twitchtoo avatar

twitchtoo

Totally Zenned

Join Date:
Apr 2007
Location:
Ontario, Canada
Posts:
1,733
Plugin Contributions:
14

Re: DUAL Pricing v2

supersnow:

So I can start modifying the sales report module so I can see the sales orders by wholesale customers as apposed to retail customers I need to add to the order table the customer wholesale status. Does anyone have any ideas?

I would think this might be important for a number of people as it stands unless you look at the amounts in an order you have no idea if an order is a retail order or a wholesale order - unless I am missing something.

Thanks for any help

It should be easy to echo in the customers_wholesale values wherever you'd like in the report. Unfortunately I do not have time to do this immediately... but if i find a spare moment i'll pitch in!

Twitch.

3 Feb 2011, 9:52 PM
#709
mlconti avatar

mlconti

New Zenner

Join Date:
Jan 2011
Posts:
5
Plugin Contributions:
0

Re: DUAL Pricing v2

Hi all, I have been going over this like a mad man, I think I have most of this mod working, I am however not getting the words "whole sale" pricing on my product page. The price amount does seem to be working if I login with my "wholesale" customer.

Any ideas would be great.

I also have both columns for my customer

customers_whole
customers_wholesale

I am accessing my database via filemaker ODBC link. - but this does not effect my zen cart operation.

Thanks in advance!

Mike

3 Feb 2011, 10:51 PM
#710
mlconti avatar

mlconti

New Zenner

Join Date:
Jan 2011
Posts:
5
Plugin Contributions:
0

Re: DUAL Pricing v2

mlconti:

Hi all, I have been going over this like a mad man, I think I have most of this mod working, I am however not getting the words "whole sale" pricing on my product page. The price amount does seem to be working if I login with my "wholesale" customer.

Any ideas would be great.

I also have both columns for my customer

customers_whole
customers_wholesale

I am accessing my database via filemaker ODBC link. - but this does not effect my zen cart operation.

Thanks in advance!

Mike

:oops:

Also after more investigation it appears the price swapping feature is only using the customers_whole - column "flag" - not sure if that helps.

4 Feb 2011, 1:25 AM
#711
twitchtoo avatar

twitchtoo

Totally Zenned

Join Date:
Apr 2007
Location:
Ontario, Canada
Posts:
1,733
Plugin Contributions:
14

Re: DUAL Pricing v2

mlconti:

:oops:

Also after more investigation it appears the price swapping feature is only using the customers_whole - column "flag" - not sure if that helps.

In order to get my bug fix working you must follow all of the steps in post #687 then add the missing SQL patch in post #695.

You will **NOT **be using customers_whole. If you followed the instructions in post #687 you will not have any customers_whole field in your Db either. (if you have installed the SQL patch that came with the download I can help remove it if the extra fields are producing errors)

Let me know if you need further assistance. I'm interested in your FM ODBC link...

Twitch.

4 Feb 2011, 3:48 PM
#712
mlconti avatar

mlconti

New Zenner

Join Date:
Jan 2011
Posts:
5
Plugin Contributions:
0

Re: DUAL Pricing v2

twitchtoo:

In order to get my bug fix working you must follow all of the steps in post #687 then add the missing SQL patch in post #695.

You will **NOT **be using customers_whole. If you followed the instructions in post #687 you will not have any customers_whole field in your Db either. (if you have installed the SQL patch that came with the download I can help remove it if the extra fields are producing errors)

Let me know if you need further assistance. I'm interested in your FM ODBC link...

Twitch.

ok, here is the response from that patch in 687

Failed: 4
ERROR: Cannot ADD column products_price_w because it already exists.
ERROR: Cannot ADD column options_values_price_w because it already exists.
ERROR: Cannot ADD column discount_price_w because it already exists.
ERROR: Cannot ADD column customers_wholesale because it already exists.
Note: 4 statements ignored. See "upgrade_exceptions" table for additional details.

I tried to install this way back before the bugs were known, but did not put much effort into making it work until yesterday. So if you think the original install created some unknown issue, let me know.

I can prob delete the customers_whole via phpmyadmin, however it is the only thing allowing it to work so I'd rather find the bug and then remove the unnecessary data.

I will work on this some more and keep you posted. let me know about your fix.

I will be glad to share my knowledge to make the bridge into zen cart from FM.

Thanks.

M

4 Feb 2011, 6:07 PM
#713
mlconti avatar

mlconti

New Zenner

Join Date:
Jan 2011
Posts:
5
Plugin Contributions:
0

Re: DUAL Pricing v2

I also got this message while working in the admin section of zen cart

1054 Unknown column 'p.product_price_w' in 'field list'
in:
[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.product_price_w, p.products_virtual, p.products_weight, p.products_date_added, p.products_last_modified, p.products_date_available, p.products_status, p.manufacturers_id, p.products_quantity_order_min, p.products_quantity_order_units, p.products_priced_by_attribute, p.product_is_free, p.product_is_call, p.products_quantity_mixed, p.product_is_always_free_shipping, p.products_qty_box_status, p.products_quantity_order_max, p.products_sort_order from products p, products_description pd where p.products_id = pd.products_id and p.products_id = '1']
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.

any advise?

Thanks,

M

4 Feb 2011, 10:10 PM
#714
twitchtoo avatar

twitchtoo

Totally Zenned

Join Date:
Apr 2007
Location:
Ontario, Canada
Posts:
1,733
Plugin Contributions:
14

Re: DUAL Pricing v2

mlconti:

ok, here is the response from that patch in 687

Failed: 4
ERROR: Cannot ADD column products_price_w because it already exists.
ERROR: Cannot ADD column options_values_price_w because it already exists.
ERROR: Cannot ADD column discount_price_w because it already exists.
ERROR: Cannot ADD column customers_wholesale because it already exists.
Note: 4 statements ignored. See "upgrade_exceptions" table for additional details.

I tried to install this way back before the bugs were known, but did not put much effort into making it work until yesterday. So if you think the original install created some unknown issue, let me know.

I can prob delete the customers_whole via phpmyadmin, however it is the only thing allowing it to work so I'd rather find the bug and then remove the unnecessary data.

I will work on this some more and keep you posted. let me know about your fix.

I will be glad to share my knowledge to make the bridge into zen cart from FM.

Thanks.

M

If you followed the instructions in my bug fix customers_whole no longer exists.

**What version of the dual pricing module do you have and what version of ZenCart?
**
I have the SQL patch to remove the customers_whole field properly, I used it in my original install successfully.

The error above is ok it means the other fields already exist.

Twitch.

4 Feb 2011, 10:40 PM
#715
mlconti avatar

mlconti

New Zenner

Join Date:
Jan 2011
Posts:
5
Plugin Contributions:
0

Re: DUAL Pricing v2

Zen Cart is v1.3.9h and well I think the latest dual price is 1.7c?

I also had tried installing the hide dual price or something like that. - not sure that even worked or was installed.

What are your thoughts?

8 Feb 2011, 8:42 AM
#716
twitchtoo avatar

twitchtoo

Totally Zenned

Join Date:
Apr 2007
Location:
Ontario, Canada
Posts:
1,733
Plugin Contributions:
14

Re: DUAL Pricing v2

mlconti:

Zen Cart is v1.3.9h and well I think the latest dual price is 1.7c?

I also had tried installing the hide dual price or something like that. - not sure that even worked or was installed.

What are your thoughts?

Personally I would start over with the default template files, install the dual pricing module, walk through the bug fix that I made, make sure it works... then attempt to install another module.

If you install anything that wants to overwrite ANY of the files used in the dual pricing module you will have to compare them and manually add in the code. Be sure to backup any files that are working correctly prior to the changes!

Twitch.

9 Feb 2011, 12:23 AM
#717
missta avatar

missta

New Zenner

Join Date:
Jan 2011
Location:
Colorado
Posts:
15
Plugin Contributions:
0

Re: DUAL Pricing v2

Hey Twitch,
First of all i would like to thank you for the great guide. For a new new zenner like me, i was able to understand it easily.

I followed all the steps. No more errors like before.

One problem: After changing the customer to level 1, they don't see 2 prices (retail & wholesale) when i logged in as a customer. All i see is the wholesale price.

I did this, but do not see 2 prices.
"Step 17 - Click on Catalog, Select a Product, Add in a Wholesale Price (right below the 'Products Price (Gross)')

Step 18 - Log into your live ZenCart test account - like a customer would, you will see 'Whole Sale Price:' below the retail price of the product you added a wholesale price to in Step 17." Quote from http://www.zen-cart.com/forum/showthread.php?t=35450&page=69

Step 19 - Thank me. :hug: Thank you very much. :smile:

You can see with is screenshop:http://greenletdesigns.com/no2prices.jpg

Did i forget to do something?

9 Feb 2011, 12:36 AM
#718
twitchtoo avatar

twitchtoo

Totally Zenned

Join Date:
Apr 2007
Location:
Ontario, Canada
Posts:
1,733
Plugin Contributions:
14

Re: DUAL Pricing v2

missta:

Hey Twitch,
First of all i would like to thank you for the great guide. For a new new zenner like me, i was able to understand it easily.

I followed all the steps. No more errors like before.

One problem: After changing the customer to level 1, they don't see 2 prices (retail & wholesale) when i logged in as a customer. All i see is the wholesale price.

I did this, but do not see 2 prices.
"Step 17 - Click on Catalog, Select a Product, Add in a Wholesale Price (right below the 'Products Price (Gross)')

Step 18 - Log into your live ZenCart test account - like a customer would, you will see 'Whole Sale Price:' below the retail price of the product you added a wholesale price to in Step 17." Quote from http://www.zen-cart.com/forum/showthread.php?t=35450&page=69

Step 19 - Thank me. :hug: Thank you very much. :smile:

You can see with is screenshop:http://greenletdesigns.com/no2prices.jpg

Did i forget to do something?

This issue has two parts. The part I fixed looks to be the part you are trying to see, that is that when you edit a product you should see this:

Tax Class: --none-- GST on Kids Clothing GST on Shipping GST/HST/PST Class Taxable Goods Products Price (Net): Products Price (Gross): Wholesale Price (Net)
If there is no wholesale price, set this field to 0

Once you have a price entered it will work correctly when you log in as a wholesale customer, or as a retail customer. NOTE that you must log out and log back in if you are toggling the wholesale feature on and off in admin. The session only records the customers_wholesale value on the login page.

The second part I am working on a bug fix right now, that is pricing with attributes, multiple sizes, colours and multiple prices by size for retail and wholesale. I have not completed the fix for this bug yet. When I do, I will post it here... and take a day off!

Twitch.

9 Feb 2011, 12:44 AM
#719
twitchtoo avatar

twitchtoo

Totally Zenned

Join Date:
Apr 2007
Location:
Ontario, Canada
Posts:
1,733
Plugin Contributions:
14

Re: DUAL Pricing v2

Here is the image you should see:

I missed the window of time to get it in the post above...

Twitch.

9 Feb 2011, 5:59 AM
#720
missta avatar

missta

New Zenner

Join Date:
Jan 2011
Location:
Colorado
Posts:
15
Plugin Contributions:
0

Re: DUAL Pricing v2

Twitch,

This is what I see in the admin page:


But when I sign in as a customer-with level one: I only see 1 price.
I cleared & closed the browser, cleared all browsing history from last day. Tried with internet explorer too. and this is what i see. :wacko: