Zen Cart Logo

DUAL Pricing v2

Views: 363,361

Results 901 to 920 of 1,504
21 Dec 2011, 8:30 PM
#901
robwag avatar

robwag

New Zenner

Join Date:
Dec 2011
Posts:
2
Plugin Contributions:
0

DUAL Pricing v2

Sorry if this solution is buried in the posts, I tried a search but didn't see an answer.

Is there a way to show the MSRP / Retail price along with the WS price?

Thanks,

--RW

22 Dec 2011, 2:50 AM
#902
robwag avatar

robwag

New Zenner

Join Date:
Dec 2011
Posts:
2
Plugin Contributions:
0

Re: DUAL Pricing v2

robwag:

Sorry if this solution is buried in the posts, I tried a search but didn't see an answer.

Is there a way to show the MSRP / Retail price along with the WS price?

Thanks,

--RW

UPDATE:

I reinstalled again just to make sure and noticed I didn't overwrite a couple of files the first time.

Success:

Retail Price: Starting at: $135.00
Whole Sale Price: Starting at: $100.00

Just what we needed. Thanks for making the addon.

--RW

28 Dec 2011, 2:02 AM
#903
bobvilla2011 avatar

bobvilla2011

New Zenner

Join Date:
Dec 2011
Posts:
1
Plugin Contributions:
0

Re: DUAL Pricing v2

I finally got attributes to add to the cart with the right price when logged in as wholesale customer or retail. :clap:

I followed all the steps on post #687

As Twitch suggested I changed all variables:

  • customer_whole
  • customer_wholesale and
  • customers_whole

to only 'customers_wholesale'.

Then I only added two small bits of code to shopping_cart.php.

It can be found /includes/classes/shopping_cart.php

Find line (around 755):

$new_attributes_price = zen_get_discount_calc($product->fields['products_id'], $attribute_price->fields['products_attributes_id'], $attribute_price->fields['options_values_price'], $qty);

Add this below:

if ($_SESSION['customer_id']) {
			  if ($customer_check->fields['customers_wholesale'] != "0") {
              $new_attributes_price = zen_get_discount_calc($product->fields['products_id'], $attribute_price->fields['products_attributes_id'], $attribute_price->fields['options_values_price_w'], $qty);
		      }
			  }

Then find line (around line 946):

$new_attributes_price = zen_get_discount_calc($products_id, $attribute_price->fields['products_attributes_id'], $attribute_price->fields['options_values_price'], $qty);

Add this below:

 if ($_SESSION['customer_id']) {
			  if ($customer_check->fields['customers_wholesale'] != "0") {
              $new_attributes_price = zen_get_discount_calc($products_id, $attribute_price->fields['products_attributes_id'], $attribute_price->fields['options_values_price_w'], $qty);
		      }
			  }

The first code will adjust the sub total in the cart to match the wholesale pricing. The second will make the actually price match the wholesale price. If you have other discounts applied like coupons or sales you will have modify the codes similar to what I have done. I'm not using any discounts so this works for me. At least this gives you the idea of what you have to do.

Thanks for all of your help!

3 Jan 2012, 10:47 PM
#904
al_musafir avatar

al_musafir

New Zenner

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

Re: DUAL Pricing v2

greatss!!!
That works fine!!!
Thank you very much!!!!

:clap::clap::clap:

23 Jan 2012, 3:11 PM
#905
idc1 avatar

idc1

Zen Follower

Join Date:
Jul 2011
Posts:
139
Plugin Contributions:
0

Re: DUAL Pricing v2

edingtoncollection:

under: //get specials price or sale price

if ($_SESSION['customer_whole'] && $_SESSION['customer_whole'] != '0' ) {
$special_price = false;
} else {

if ($specials->RecordCount() > 0) {
$special_price = $specials->fields['specials_new_products_price'];
} else {
$special_price = false;
}
}

and under: // return special price only

if ($_SESSION['customer_whole'] && $_SESSION['customer_whole'] != '0' ) {
return false;
} else {
if ($specials_price_only==true) {
if (zen_not_null($special_price)) {
return $special_price;
} else {
return false;
}
} else {

  $product_to_categories = $db->Execute("select master_categories_id from " . TABLE_PRODUCTS . " where products_id = '" . $product_id . "'");
  $category = $product_to_categories->fields['master_categories_id'];

  $sale = $db->Execute("select sale_specials_condition, sale_deduction_value, sale_deduction_type from " . TABLE_SALEMAKER_SALES . " where sale_categories_all like '%," . $category . ",%' and sale_status = '1' and (sale_date_start <= now() or sale_date_start = '0001-01-01') and (sale_date_end >= now() or sale_date_end = '0001-01-01') and (sale_pricerange_from <= '" . $product_price . "' or sale_pricerange_from = '0') and (sale_pricerange_to >= '" . $product_price . "' or sale_pricerange_to = '0')");

if ($sale->RecordCount() < 1) {
     return $special_price;
  	}
}

The above logic is from edingtoncollection and tells the system to ignore the sales price when logged in. I am trying to do the opposite. I want it to ignore the sales price when NOT logged in and to apply the sales price when logged in. I am still struggling to make this happen. I thought it would have been as simple as changing != '0' to ='0' but that did not work. Can someone offer some assitance?

23 Jan 2012, 5:29 PM
#906
badarac avatar

badarac

Totally Zenned

Join Date:
Aug 2009
Location:
Longs, SC
Posts:
635
Plugin Contributions:
0

Re: DUAL Pricing v2

I've checked the confirmed working mods thread http://www.zen-cart.com/forum/showthread.php?p=1097138#post1097138. I can't find any mention of dual pricing or hidden wholesale. Is this mod compatible and if not are there any suggestions for a 1.5 compatible mod?

23 Jan 2012, 5:32 PM
#907
twitchtoo avatar

twitchtoo

Totally Zenned

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

Re: DUAL Pricing v2

badarac:

I've checked the confirmed working mods thread http://www.zen-cart.com/forum/showthread.php?p=1097138#post1097138. I can't find any mention of dual pricing or hidden wholesale. Is this mod compatible and if not are there any suggestions for a 1.5 compatible mod?

I am upgrading the wholesale/dual pricing cart I built to 1.50 right now. I will keep you posted if it works...

Twitch

25 Jan 2012, 4:41 AM
#908
slingblade01 avatar

slingblade01

New Zenner

Join Date:
Dec 2011
Location:
Atlanta, GA
Posts:
32
Plugin Contributions:
0

Re: DUAL Pricing v2

twitchtoo:

I am upgrading the wholesale/dual pricing cart I built to 1.50 right now. I will keep you posted if it works...

Twitch

How about an update, any mods necessary so far?

3 Feb 2012, 12:50 PM
#909
divagal avatar

divagal

New Zenner

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

Re: DUAL Pricing v2

I made the changes to my functions_prices.php as per edingtoncollection post. However, the wholesale account holder is still seeing the specials price and not the wholesale price.

This is such a great mod, I can't believe someone doesn't have a solution to this.

Anyone?

10 Feb 2012, 4:28 AM
#910
johntitsworth avatar

johntitsworth

New Zenner

Join Date:
Mar 2011
Posts:
17
Plugin Contributions:
0

Re: DUAL Pricing v2

I have version 1.3.9h

I have the mod installed, but when someone who is wholesale actually adds product to the cart, the price is incorrect and is the retail price. Any advice?

12 Feb 2012, 5:42 PM
#911
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: DUAL Pricing v2

badarac:

I've checked the confirmed working mods thread http://www.zen-cart.com/forum/showthread.php?p=1097138#post1097138. I can't find any mention of dual pricing or hidden wholesale. Is this mod compatible and if not are there any suggestions for a 1.5 compatible mod?
If it's not listed, then it's not compatible.. and like nearly all Zen Cart modules there WILL be changes required to get any mod to work with v1.5. What changes are required will vary from mod to mod..

12 Feb 2012, 6:21 PM
#912
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: DUAL Pricing v2

So before I install this mod for my client, I need to know how much patching and repairing I need to do.. It appears after going through this entire support thread that there are a few outstanding issues that HAVE NOT made their way into the version available in the free downloads:

  1. http://www.zen-cart.com/forum/showpost.php?p=1083324&postcount=893 (Missing security tokens in the attributes controller file)
  2. http://www.zen-cart.com/forum/showpost.php?p=1070183&postcount=878 (Sales pricing not being correctly applied to wholesale versus retail customers)
  3. http://www.zen-cart.com/forum/showpost.php?p=1089888&postcount=903 (attributes not properly being added to products when added to the shopping cart)
    Is this pretty much the list of old/current issues with this add-on or am I missing other issues??

I also noticed that JTheed took the time to synch up the Dual Pricing and Hidden Wholesale modules to use a common codebase. Will the Zen Cart v1.5 updates being worked on for Dual Pricing be doing the same thing (or better yet combining these features into ONE module)?? Hidden Wholesale is just as important as Dual Pricing.. I have a client who needs to set wholesale and retail pricing for her consultants as well as offering "wholesale only" products that retail customers will not be able to see (and she doesn't want to create a special category JUST for these products)..

14 Feb 2012, 4:18 PM
#913
spembleton avatar

spembleton

Zen Follower

Join Date:
Jun 2010
Location:
Holland, MI
Posts:
232
Plugin Contributions:
0

Re: DUAL Pricing v2

I am testing out Dual Pricing and Hidden Wholesale on a test site, using ZC 1.5. I have read the strings above about compatability with V1.5, and it seems that it is ok to use if I do not use attribute pricing and sales pricing. Is that true? Since I do not plan to use either of these features, and since it seems to work fine on my 1.5 test site, I am thinking I am ok to install it.

Any thoughts?

14 Feb 2012, 5:27 PM
#914
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: DUAL Pricing v2

SPembleton:

I am testing out Dual Pricing and Hidden Wholesale on a test site, using ZC 1.5. I have read the strings above about compatability with V1.5, and it seems that it is ok to use if I do not use attribute pricing and sales pricing. Is that true? Since I do not plan to use either of these features, and since it seems to work fine on my 1.5 test site, I am thinking I am ok to install it.

Any thoughts?
Short answer is no.. Zen Cart v1.5 made MANY security changes, and ALL add-ons will have to be reviewed and updated so that they not only work, but work correctly a without compromising the new security features.. Personally I will NOT use any add-on on a client production store that has not been properly updated.:no:

24 Feb 2012, 1:11 PM
#915
roekoe avatar

roekoe

New Zenner

Join Date:
Feb 2010
Posts:
38
Plugin Contributions:
0

Re: DUAL Pricing v2

DivaVocals:

Short answer is no.. Zen Cart v1.5 made MANY security changes, and ALL add-ons will have to be reviewed and updated so that they not only work, but work correctly a without compromising the new security features.. Personally I will NOT use any add-on on a client production store that has not been properly updated.:no:

Hi,

So the conslusion is that for the dual price users the upgrade to 1.5 can't be done? I'm currently using using 1.3.8 and was hoping to upgrade to 1.5. What would be the best to thing to do, upgrade to 1.3.9h and skip the 1.5 version? Or hope that this mod will work eventually with 1.5?

gr.

24 Feb 2012, 1:43 PM
#916
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: DUAL Pricing v2

roekoe:

Hi,

**So the conslusion is that for the dual price users the upgrade to 1.5 can't be done? **I'm currently using using 1.3.8 and was hoping to upgrade to 1.5. What would be the best to thing to do, upgrade to 1.3.9h and skip the 1.5 version? Or hope that this mod will work eventually with 1.5?

gr.Can't be done until this add-on has been PROPERLY updated to be compatible with v1.5..

24 Feb 2012, 2:24 PM
#917
roekoe avatar

roekoe

New Zenner

Join Date:
Feb 2010
Posts:
38
Plugin Contributions:
0

Re: DUAL Pricing v2

DivaVocals:

Can't be done until this add-on has been PROPERLY updated to be compatible with v1.5..

TY, I'll spend my time by upgrading to the latest 1.3X version then.

24 Feb 2012, 5:05 PM
#918
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: DUAL Pricing v2

Goodness I have repeated the SAME information in three different posts.. So let me combine them all into ONE "Is DUAL Pricing v2 compatible with Zen Cart v1.5?" answer..:laugh:

DivaVocals:

If it's not listed, then it's not compatible.. and like nearly all Zen Cart modules there WILL be changes required to get any mod to work with v1.5. What changes are required will vary from mod to mod..

DivaVocals:

Short answer is no.. Zen Cart v1.5 made MANY security changes, and ALL add-ons will have to be reviewed and updated so that they not only work, but work correctly a without compromising the new security features.. Personally I will NOT use any add-on on a client production store that has not been properly updated.:no:

DivaVocals:

Can't be done until this add-on has been PROPERLY updated to be compatible with v1.5..

24 Feb 2012, 11:40 PM
#919
danielle avatar

danielle

Totally Zenned

Join Date:
Oct 2004
Posts:
973
Plugin Contributions:
0

Re: DUAL Pricing v2

The issue with the attribute pricing not being carried into the shopping cart has never been solved, correct? Does anyone who has worked on this mod have any thoughts on how to fix it? I'm happy to give it a shot, just wondering if anyone has tried yet and can provide a bit of direction :) If I figure it out, I'll post the fix!

Thanks!

24 Feb 2012, 11:46 PM
#920
divavocals avatar

divavocals

Totally Zenned

Join Date:
Jan 2007
Location:
Los Angeles, California, United States
Posts:
10,011
Plugin Contributions:
3

Re: DUAL Pricing v2

Danielle:

The issue with the attribute pricing not being carried into the shopping cart has never been solved, correct? Does anyone who has worked on this mod have any thoughts on how to fix it? I'm happy to give it a shot, just wondering if anyone has tried yet and can provide a bit of direction :) If I figure it out, I'll post the fix!

Thanks!
Posted in this thread..

(hint: I even posted the link to the fix just a few posts up -- which is why it pays to search the thread:yes:)