Tags/topics: 
1
Answers
Vote up!
0
Vote down!

Quantity

Hello,
I am setting up a fabrics shop and would like to know how to do the following :

Fabrics : price per meter, e.g. 15 EUR
Customer should be able to indicate how he would like to buy :
mininum quantity 15 cm
increments by 5 cm

e.g. he should be able to fill directly 0,75 or 1 or 1,25

how can I do this? I have tried in the standard quantity field, but decimals are refused.

Asked by: jasminedb
on April 1, 2013

1 Answer

Vote up!
1
Vote down!

I would create a pricing rule based on a line item field.

1) Create a line item field ... maybe use a "Select or Other" field or a Field Stepper or perhaps a Slide Field?

http://www.drupalcommerce.org/videos/demo/introduction-line-item-fields

2) Create a Pricing Rule that takes a line item field and multiplies the price based on the line item field. I did something like this for the "Pizza Shop" video:

http://www.drupalcommerce.org/videos/tutorials/customizable-products-piz...

So your product's quantity would really be "1" with a length of "floating point number in increments of 5cm"

Josh

Josh Miller
Answer by: Josh Miller
Posted: Apr 2, 2013

Comments

Hello, thank you for your answers! I'm going for the last option. I hadn't found this module and I'll let you know whether it's what I envisaged.

Jasmine

- jasminedb on April 3, 2013