I would like to give the user a little more freedom in the adjusted prices part of the attribute system.

The part in question is in the product node where the options of the attribute are shown like ( option 1 + $ 3.44). The $3.44 part is now the total price or price increase for the default qty (or 1 if there is no default quantity). I would like to add an extra check box in /admin/store/settings/attributes giving the end user the chance to specify if he would like the current situation (default_qty) or prefers '1'. My wholesale business uses quite big default quantities and customers are mostly interested in the price (total or increase for 1 product).

I could code it very simple in a few lines, keeping the functionality working as it is now (with 1 extra choice) and would be happy to make a patch, just checking if anyone thinks this is a good idea and will it make any chance to get into core?

Thanks
Mark

(ps. Ubercart site is down?)

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

splash112’s picture

Status: Active » Needs review
FileSize
1.85 KB

Small patch file attached for the idea above.

It's absolutely non intrusive and any site will work as before, only with some extra functionality.

Mark

splash112’s picture

TR’s picture

The $3.44 part is now the total price or price increase for the default qty (or 1 if there is no default quantity).

Does *anyone* need to see the total price or price increase for the default qty? Shouldn't this *always* be for qty=1? I personally don't use default qty. Is the display price set to be the sell_price multiplied by the default qty? It seems it would have to, to be consistent with what's done for the attribute price adjustments. That sounds like it would confuse the customer - I think prices should always be for 1 piece. If necessary, the display price could be themed to say "each" after the price if default qty > 1.

splash112’s picture

Fair point. If somebody would like to have the price per default quantity, a simple hook_price_alter would probably do the trick..

toitimhcm’s picture

it worked, thanks
--------------

longwave’s picture

Thinking we should revisit this, and agreeing with TR that there is no real need to multiply by qty, so perhaps we should just remove that part. I guess most users have a default qty of 1 anyway so this doesn't affect them.

splash112’s picture

Hi Longwave,

Thanks for checking back on this. Attached is a patch conform TR's comment.

Thanks
Mark

longwave’s picture

Alternative patch that simplifies the code further.

longwave’s picture

Version: 6.x-2.x-dev » 7.x-3.x-dev
Status: Needs review » Patch (to be ported)

Committed, needs porting to 7.x.

longwave’s picture

Status: Patch (to be ported) » Fixed

Committed.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.