Service Portal Add to Cart Issue

Blair5
Tera Guru

We are on Helsinki Patch 11 and have the cart showing on our service portal. When a user fills out the fields on a cat item and adds to cart, the ability to change some of those fields and add again isn't working. I saw a mention in another post - Add to Cart functionality for Service Portal - where you can disable this, but I don't see how. Any help? This featured is used pretty regularly by our users.

1 ACCEPTED SOLUTION

Hi Blair,



Now that we know it the same code and disabled in all.. I thought let me figure this   and found it



Some steps



  • Clone the sc catalog item widget (else it is read only)
  • Attache the cloned widget the the Service catalog page
  • Look for the ng-disabled="submitted" on the line containing Add to cart and DELETE the   ng-disabled="submitted"


find_real_file.png


  • You also need to make changes to the client script highlighted below (EDIT Updated code to fix submit greyed out after add)
  • find_real_file.png

I didnt test for other side effects but add to cart works and does not get disabled after adding


Let us know how it goes. breinhart


Mine...


find_real_file.png


View solution in original post

27 REPLIES 27

Cool. Hope it was helpful


Hello Ravindran,

Thank you for this post. I have a requirement to make some of the fields on the form read only, leaving the other fields editable after an item is added to the cart.  Your code makes entire form readable/non readable. Instead if I need some fields to be made readable, how do I approach. I really appreciate your response.

Thank you Ravindran in advance. 

Hi Swapna,

Apologies for delay as I have not been active in the community for over last 3 4 months. 

I just checked my London developer instance and the Catalog Item widget has changed (the one we are looking on these posts is deprecated and there is a new v2 widget-sc-cat-item-v2). Need to re-look at the code to understand what has changed.

I'm not sure I totally understand your question. However, if you want to handle for individual items probably you might need to do some custom checks in the client code using some additional flags etc. 

Please send a screenshot with quick example scenario and I will have a look to see how we can solve. Also, probably create a new post (and send the link here) as mostly we would be looking at the widget-sc-cat-item-v2 widget on London instance.

Regards

Ravindran