Page 1 of 1

Product "More Info" Question

PostPosted: Fri May 15, 2015 9:44 am
by tmlogo
I was wondering if there is an easy way to add a field in the more information product page that will allow a customer to select a one time fee associated with ordering the product(s). For example, they want to do an imprint on the entire order and there is a one time setup fee of $50 for the entire order. I have done a workaround up to now that is extensive, but we are redesigning and wanted to know if there is something straight forward we are missing.

Thanks in advance

Re: Product "More Info" Question

PostPosted: Fri May 15, 2015 10:51 am
by Jim
I can think of at least 2 ways this could be done.
1. Use order options and have one for just the product and the other for product with the setup fee
2. Use subproducts and have a multi-add to cart form for the subproducts. That way they select the main product and have a separate checkbox to check if they need the setup fee. (With subproducts the main product will need to be added as a subproduct to itself along with the option for setup fee as another subproduct.) Sample code for multi-add to cart can be found http://www.shopsite.com/templates/cookbook/tips-multiaddtocart-page.shtml. Note this is for a page with products on it but the same thing can be done for a product by putting the main form as the main part of the moreinfo page template and the subproduct define as the product part of the template.

Re: Product "More Info" Question

PostPosted: Fri May 15, 2015 11:03 am
by tmlogo
Thanks Jim.

Option #2 is basically what I have been doing. Each setup fee has been set as a product. I don't believe Option #1 will work as most of our orders are for multiple items of the same product and if I am correct they would be paying the setup fee for each item instead of for the entire order.

Thanks again for your help.

Re: Product "More Info" Question

PostPosted: Thu Jun 11, 2015 2:46 pm
by tmlogo
I have been unable to work on this until recently. I am confused how I can get the name and value of the subproduct added into the form and multi add. Assuming the simple form layout on the sample template for now......

(Check Box) Main Product $150 Quantity (Box with Quantity)

(Check Box) Subproduct1 $60 Quantity (Box with Quantity)

(Check Box) Subproduct2 $35 Quantity (Box with Quantity

Add to Cart

Hope this makes sense.....

Re: Product "More Info" Question

PostPosted: Thu Jun 11, 2015 4:05 pm
by Jim
The overall layout would be similar to the Page and product layouts for multi-add to cart form described on http://www.shopsite.com/help/12.0/en-US/sc/pro/custom.template.multi-add.html .
In the product template for the body of the product use code from the Page section of the template to create the form for adding the items to the cart. You would start with the
Code: Select all
# Start the Form. This custom template tag is very important!
<FORM action="[-- SHOPPING_CART_URL BASE --]/order.cgi" method=post>
and copy everything down to the
Code: Select all
# End the FORM
</FORM>

You will need to modify the
Code: Select all
#Display the Products - The Products must us a special Template also
[--LOOP PRODUCTS --]
  [--PRODUCT--]
[--END_LOOP PRODUCTS--]

to reference the subproducts.
Code: Select all
#Display the Products - The Products must us a special Template also
[--LOOP SUBPRODUCTS --]
  [--SUBBPRODUCTS--]
[--END_LOOP SUBPRODUCTS--]


In the [-- DEFINE SUBPRODUCT --] section of the template you would use the code from the Product section of the above mentioned Multi-add to cart help page http://www.shopsite.com/help/12.0/en-US/sc/pro/custom.template.multi-add.html . I think you could just copy the entire DEFINE PRODUCT section and change that to be [--DEFINE SUBPRODUCT --] and end with {-- END_DEFINE SUBPR)DUCT --]

To get your main product listed along with all the other sub products you simply assign it as a subproduct to itself. You can then arrange the subproducts to make sure the main product is listed as the first subproduct.

Re: Product "More Info" Question

PostPosted: Thu Jun 11, 2015 4:25 pm
by tmlogo
Got it!!!! Thank you!

Re: Product "More Info" Question

PostPosted: Thu Jun 11, 2015 4:53 pm
by tmlogo
Just one more thing....Is there a "workaround" so the product (which now has itself as a subproduct) not have a check box next to it?

Re: Product "More Info" Question

PostPosted: Fri Jun 12, 2015 8:29 am
by Jim
The main product should not have a check box by it if the template was done correctly. Only the product as a subproduct should have the checkbox and you could just remove it as a subproduct to not have the checkbox.
You should not include the add to cart part of the form for the main product, i.e. it should just have image, text description etc with no add to cart button.

Re: Product "More Info" Question

PostPosted: Fri Jun 12, 2015 9:07 am
by tmlogo
Thanks Jim! I've actually figured out a way to get it looking just the way I wanted.