Originally posted by Matt Zimmermann
View Post
Announcement
Collapse
No announcement yet.
Miva 10.03
Collapse
X
-
Hi Matt, As far as I can tell that seems to fix everything :) Thanks so much for your help!
-
Hi Jim,Originally posted by Jim Cockerham View PostIs the the new feature "Edit Product Attributes on the Basket Page" working for most of you? I followed the instruction here: https://github.com/mivaecommerce/rea...ows/issues/127 . I am only using single attributes for my products and I am seeing the "Edit" button on the BASK page , but it does nothing. Does it only work if you have multiple attributes? I have gone over the instructions twice and it all looks good.
I have updated the instructions. There are three areas that need to be updated, edit-basket-attributes.js, Basket -> Basket Contents, and Basket -> Content.
Leave a comment:
-
Hi Jim,
I am working through a potential fix for that and will have more details a little later today.
Leave a comment:
-
Hi Matt, thank you for all of your help with this. Now it's a little unpredictable. If I add a product with an attribute to the Basket first and then add a product without an attribute to the Basket, both will have the Edit link, but if I add the product without an attribute to the Basket first it will not have the Edit link.Originally posted by Matt Zimmermann View PostHi Jim,
Under User Interface -> Templates -> Pages -> BASK -> Contents, replace the MVT:IF statement with this:
Code:<mvt:if expr="l.settings:group:product:productsubscriptionsettings:enabled OR miva_array_elements(l.settings:has_attributes) GT 0">
Leave a comment:
-
Kent Multer The function to apply shipping, payment or calculate tax to an order it this one:
https://docs.miva.com/json-api/funct...lculatecharges
In most cases, you're going to be calling it from a Miva page. In that case you use the helper function we provide in Runtime.js here:
https://docs.miva.com/miva10/referen...mejs-referenceCode:Runction Runtime_CalculateCharges( shipping_method, payment_method, callback, delegator ) { return AJAX_Call_JSON( callback, 'runtime', 'Runtime_CalculateCharges', { ShippingMethod: shipping_method, PaymentMethod: payment_method }, delegator ); }
Here is an example of its usage:
Tax is always re-calculated anytime this function runs.Code:Runtime_CalculateCharges('flatrate:overnight', 'check:check', function(response) { //update basket contents on page to reflect changes });
Leave a comment:
-
Hi Jim,
Under User Interface -> Templates -> Pages -> BASK -> Contents, replace the MVT:IF statement with this:
Code:<mvt:if expr="l.settings:group:product:productsubscriptionsettings:enabled OR miva_array_elements(l.settings:has_attributes) GT 0">
Leave a comment:
-
Hi Matt, Were close. Now the Edit button is gone on products without attributes. Products with subscriptions still get the edit button, but it doesn't do anything, unless a different product with an attribute is also in the Basket.Originally posted by Matt Zimmermann View Post
Hi Jim,
Under User Interface -> Templates -> Pages -> BASK -> Basket Contents, insert
right belowCode:<mvt:assign name="l.settings:has_attributes" value="0" />
That should do the trick.Code:<mvt:assign name="g.basket_subtotal" value="0" />
Leave a comment:
-
Hi Jim,Originally posted by Jim Cockerham View Post
Hi Matt, thank you, it does now seem to work. There is a quirk though. The edit button is shown for every product, whether or not the product has attributes. While the edit button is displayed, it does nothing if the product does not have attributes. However if there is a product in the cart that does have attributes and a product that does not have attributes the edit button will work for both products.
Under User Interface -> Templates -> Pages -> BASK -> Basket Contents, insert
right belowCode:<mvt:assign name="l.settings:has_attributes" value="0" />
That should do the trick.Code:<mvt:assign name="g.basket_subtotal" value="0" />
Leave a comment:
-
Thanks, Brennan. That function does the "view," but not the "update" part. Is there another function for that?Originally posted by Brennan View PostI'll add the links to that page but here is the new function:
https://docs.miva.com/json-api/funct...ethodlist_load
No hurry; I don't have an immediate need for this functionality. Being a writer as well as a programmer, I tend to notice these things; and I figured I should bring it to someone's attention.
Thanks --
Leave a comment:
-
Hi John, I was out of town for a few days. I'll be replying to you shortly.Originally posted by TheTeaTable View PostBTW Kent, I sent you an email last week.
Leave a comment:
-
Hi Matt, thank you, it does now seem to work. There is a quirk though. The edit button is shown for every product, whether or not the product has attributes. While the edit button is displayed, it does nothing if the product does not have attributes. However if there is a product in the cart that does have attributes and a product that does not have attributes the edit button will work for both products.Originally posted by Matt Zimmermann View PostHi Jim,
Try creating an item with:- Code: runtimejs
- Module: cmp-mv-runtimejs
Leave a comment:
-
I don't do this stuff, but I didn't understand it either. The previous, highlighted "Before" and "After" method made a lot more sense to me.Originally posted by Kent Multer View PostI looked at that page, and some of the pages that it links to. I found a few mentions of viewing and updating the selected payment method, but no details on how to actually do it. Sorry if I'm missing something ...
Thanks --
BTW Kent, I sent you an email last week.
Leave a comment:
-
Hi Jim,
Try creating an item with:- Code: runtimejs
- Module: cmp-mv-runtimejs
Leave a comment:
-
Hi Matt, It doesn't look like I have that item. Do I need to add it?Originally posted by Matt Zimmermann View PostHi Jim,
Looks like I missed one step in that documentation. Apply the "runtimejs" item to the BASK page.
Thanks
Leave a comment:
-
Hi Jim,
Looks like I missed one step in that documentation. Apply the "runtimejs" item to the BASK page.
Leave a comment:
Leave a comment: