Is there a way to configure shipping by product?

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
14 years ago
Most of the products in our store ship via UPS, and I have that working fine. However, we have a few CD's that we ship using USPS at a flat rate of $5. Is there a way to assign just the $5 shipping option to only the CD products and leave the rest alone?
14 years ago
It's not possible now
14 years ago
Andrei,

a suggestion on how to allow specific postage costs for individual items( though it would be per product not per item type which is what i think rtjulian was after)

currently, if shipping is enabled for a product, we have the option to set the item as free shipping
and we have the option to add  add extra shipping value ( ' Additional shipping charge ' )

- this extra shipping value is ignored if free shipping is enabled

- how easy would it be (and would there be any other side effects) if this shipping value was not ignored even if free shipping was also selected ?

the outcome of this is that we could specify the exact price of shipping for an individual item (if we wanted) - and and by selecting 'free shipping'  the cart would ignore the normal shipping options


@rtjulian
as a work around, would this work for you ?  if you set the product weight to 0 and set an additional shipping charge to $5   (it would be a problem if you need to send the weight to the shipper & it would mean that buying 2+ items would bump up shipping by 100% per item)
14 years ago
haydie wrote:
how easy would it be (and would there be any other side effects) if this shipping value was not ignored even if free shipping was also selected ?

I think it could be customized to support this behavior (not tested). ShippingManager.GetShippingOptions() method, add the following code at the end the method:
shippingOptions.ForEach(so => so.Rate+=additionalShippingCharge)
13 years ago
I had this same scenario for gifts cards, where I wanted to charge $2 for 1st class mail only for gift cards.

What I wound up doing is modifying the description of gift cards so that it says $2 is automatically added to the cost of the card to cover shipping.

I did this buy modifying the PriceHelps.cs GetUnitPrice method to add $2 when the customer supplies the price (only used for gift cards in my case):

                if (productVariant.CustomerEntersPrice)
                {
                    finalPrice = shoppingCartItem.CustomerEnteredPrice + Convert.ToDecimal(2.00);
                }

I then modified CheckOutShippingMethod.ascx.cs so that if the sum of the shipping methods is zero, to skip the selection of shipment methods altogether and proceed to checkoutpayment:

                string error = string.Empty;
                Address address = NopContext.Current.User.ShippingAddress;
                var shippingOptions = ShippingManager.GetShippingOptions(Cart, NopContext.Current.User, address, ref error);
                if (!String.IsNullOrEmpty(error))
                {
                    LogManager.InsertLog(LogTypeEnum.ShippingError, error, error);
                    phSelectShippingMethod.Visible = false;
                    lShippingMethodsError.Text = Server.HtmlEncode(error);
                }
                else
                {
                    foreach (var so2 in shippingOptions)
                    {
                        ttlshiprates += so2.Rate;
                    }
                    if (shippingOptions.Count > 0 && ttlshiprates > 0)
                    {
                        phSelectShippingMethod.Visible = true;
                        dlShippingOptions.DataSource = shippingOptions;
                        dlShippingOptions.DataBind();
                    }
                    else
                    {
                        NopContext.Current.User.LastShippingOption = shippingOptions[1];
                        Response.Redirect("~/CheckoutPaymentMethod.aspx");
                    }


It seems to be working like a charm.  I thought I'd post my solution in case it benefits anyone else.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.