What type of field is Component Custom Total? I tried replicating the same on my local org following the same steps from the video but my Component Custom Total field on Quote Line editor is not populated.
@SalesforceCPQ3 жыл бұрын
This field must be override by CPQ's own calculation. Instead of this field use any other custom field just to verify that if QCP populating it correctly or not
@sureshcks3 жыл бұрын
This video is very helpful!! Is there a way to add multiple logics for different scenarios as we can have only one custom script in an Org?
@SalesforceCPQ3 жыл бұрын
you can add multiple functions and invoke them as per need in QCP logic
@kunkans45463 жыл бұрын
Hi Team, Need some inputs on the below items regarding the QCP plugin , where my requirements is to make callout to third party System to fetch the pricing details 1) If we use the REST callout in QCP plugin , will the callout happens everytime when any one of the field is changed on QL in QLE or else only when we click on Save or Quick Save in Quote Line editor 2)If we specify one of the field in the calculating field set lets say Discount , if the discount field is changed in one of the quote line outside of QLE, then the QCP plugin will fire right ?
@SalesforceCPQ3 жыл бұрын
1. Yes this will be fired on save/calculate button event. 2. If you add any field lets say discount as you mentioned into calculated field set on product then also it will fire
@kunkans45463 жыл бұрын
@@SalesforceCPQ Thanks , and for the point 2 , if we modify the QL in QLE , lets say if we change the discount for first Quote line , then QCP will be fired and after successful callout , then if I change 2nd QL's discount again the REST callout will be fired , is my understanding correct ? Can you please help me in giving few of the drawbacks why we should not QCP plugin (where REST callout is implemented) Thanks for your help ..
@kunkans45463 жыл бұрын
@@SalesforceCPQ And another additional question , is the callout synchronous or asynchronous, I can see in the SF documentation that if we use promise then it will be async, I think we should use promise in the QCP .. developer.salesforce.com/docs/atlas.en-us.222.0.cpq_dev_plugins.meta/cpq_dev_plugins/cpq_dev_jsqcp_guidelines.htm So if we use this, the prices will not be loaded in real time ..
@SalesforceCPQ3 жыл бұрын
@@kunkans4546 Through QLE it will not, Out of QLE field change will trigger calculation event.
@kunkans45463 жыл бұрын
@@SalesforceCPQ Your inputs are highly appreciated . What about Synchronous vs Asynchronous ??
@nipunkalal4 жыл бұрын
I want to apply for a discount on quoteline if a field on a custom object changes it should trigger the recalculation. Can I do it using QCP?
@SalesforceCPQ4 жыл бұрын
Discount field is already part of recalculation. So if you change the discount then recalculation happened automatically. Yes you can use QCP to fetch record from custom object and update to discount field
@nipunkalal4 жыл бұрын
@@SalesforceCPQ I'm updating discount on quote line on a before insert trigger and it does not work. The field is added in the field set. Am I making any mistake here?
@SalesforceCPQ4 жыл бұрын
@@nipunkalal I never suggest to use trigger for quote line object, it always conflict with quote calculation. Modification to pricing related field using process builder or trigger is not recommended. Use price rules / QCP
@nipunkalal4 жыл бұрын
@@SalesforceCPQ The field that is retriggering the calculation is on custom object. Can I still use QCP here? If the field on the custom object is changed then the discount on QLIs should also change.
@brahmareddy70483 жыл бұрын
is it possible Quoteline bundle product field compare with Quote field value using custom script while save the quote and through an error msg
@SalesforceCPQ3 жыл бұрын
Yes
@brahmareddy70483 жыл бұрын
@@SalesforceCPQ Could you please help me with some sample code,?
@SalesforceCPQ3 жыл бұрын
@@brahmareddy7048 I tried but access denied for code repo :)
@anirbandas2600 Жыл бұрын
How to add a product automatically in quote whenever we select another product by JavaScript code
@SalesforceCPQ Жыл бұрын
Use Salesforce CPQ APIs, call rest method from QCP to achieve this
@sanils67384 жыл бұрын
Hi Team, Can you please let me know if we can call an apex class(other than rest service )from the CustomScript code which is written in JS ,
@SalesforceCPQ4 жыл бұрын
Yes you can call it from JS code.
@sanils67384 жыл бұрын
@@SalesforceCPQ Thanks , can you please provide sample code , as i am unable to achieve , but i am able to call the REST Class. Thanks !! Below is the link which i am able to achieve salesforce.stackexchange.com/questions/273624/integrating-salesforce-cpq-with-sap-to-get-realtime-pricing-data
@SalesforceCPQ4 жыл бұрын
@@sanils6738 Yes, this is correct, have you annotated your apex class with this header @RestResource(UrlMapping='/restName/*')?
@sanils67384 жыл бұрын
@@SalesforceCPQ Thanks , yes i am able to call the class .But i need similar code where i can call webservice method from Customscript. global class test { webservice static void getData(){ // some sample code } } In this example , i dont have the rest class annotated , but i want to call the class from custom script , what will be the syntax in custom script . Do you have any sample code which you help me .. Thanks !!
@SalesforceCPQ4 жыл бұрын
Try this code as well, var body = { quoteId: quoteId}; conn.apex.post("/APEXCLASSNAME/", body, function(err, res) { console.log('res' + res); if (err) { console.log('error' + err); } else { if(res != "true") { return reject(res); } } return resolve();
@ScorpionCloud5 жыл бұрын
Sound is low? But the video details are good and a nice explanation discussing plugins.