Skip to main content
Grupo

Salesforce CPQ

A place to share information and ideas and discuss challenges with Salesforce CPQ
Hable de esto en Slack para conseguir respuestas con mayor rapidez y ayuda en tiempo real.

Hi Team,

We have the following scenario and would appreciate your thoughts on how best to handle it.

A customer has a Credit Note with a total value of approximately $100,000. The customer has requested that we allocate the credit as follows:

  • $20,000 against an invoice generated in Salesforce.
  • $80,000 against an invoice generated in an external system outside Salesforce.

Since the $80,000 invoice is not recorded in Salesforce, how can we account for this amount so that it is reduced to zero and the total credit allocation reconciles to $100,000?

We would prefer to avoid creating dummy invoices in Salesforce solely for allocation purposes.

What alternative approaches or standard Salesforce functionalities can we use to achieve this requirement while maintaining accurate credit allocation and financial reconciliation?

Thanks in advance for your suggestions and recommendations.

2 respuestas
  1. 29 oct, 10:17

    Hi @Murali Dittakavi, 

    As far as I know, standard Salesforce Billing only lets you allocate a credit note to invoices (or invoice lines) that exist in Salesforce. So there’s no out-of-the-box way to apply the $80,000 against an external invoice and have it drop to zero. 

    Here’s what I’d do without dummy invoices: 

    1. Split the credit. Issue two credit notes instead of one: $20,000 and $80,000. Allocate the $20,000 one to the Salesforce invoice as usual. Treat the $80,000 one as belonging to the external invoice.
    2. Track the external allocation on the credit note. Add a couple of custom fields on the $80,000 credit note, such as “Applied Externally” (checkbox) and “External Invoice Number”. That way the balance is clearly accounted for and reporting can exclude it from open credits.
    3. Let the system that owns the invoice do the reduction. If the external system is the source of truth for that invoice, the credit should be applied there. Salesforce just holds the record of the credit and where it went. If you want this automated, an integration or Flow can push the allocation to the external system and update the fields above.

     

    I’d go with option 1 combined with option 2. It keeps the Salesforce allocation clean and gives finance a clear audit trail without inventing invoices. 

      

    Hope this helps! If it does, please mark it as the best answer. 

     

  1. The user adds a parent product in the Quote Line Editor (QLE).
  2. Custom QLE JavaScript detects the addition of the parent product.
  3. The JavaScript evaluates the applicable shipping rules stored in a custom Salesforce object.
  4. Based on the matching rules, it adds the corresponding dependent shipping product to the current QLE model.
  5. The dependent shipping product should become visible immediately in the QLE, without requiring the user to save the quote or reopen the Quote Line Editor.

Current Issue: The dependent shipping product is being added to the QLE model, but it is not displayed immediately. It only becomes visible after saving and reopening the QLE. The objective is to make the product appear dynamically as soon as the parent product is added.

1 respuesta
  1. 18 oct, 18:11

    Attempting to dynamically push a dependent shipping product into the Quote Line Editor model via custom JavaScript without saving often causes state desync issues. Because the Quote Line Editor requires a server-side save to trigger the calculation engine and update its reactive state, client-side manipulation alone will not render the changes immediately. The most reliable approach is to rely on the standard save-and-refresh cycle or pivot to native product rules and option constraints to manage the relationship structurally.

Hi All,

Currently, I'm updating our Oracle CPQ manage package to 8.6 version from 7.0 version.

The new version requires install two manage package. This process is already done and now i'm migrating some apex classes and test classes.

When I'm running my test classes, I'm facing next issue:

 

caused by: cafsl.DataSetService.DataSetException: Could not load the transaction; integration settings are missing.

 

I'm already creating a record of cpq site settings and embedded cpq site setting in my test classes and it's still failing. Does anyone know what I need to create?

 

Thanks

 

@Salesforce CPQ 

@* Salesforce Revenue Cloud * 

5 respuestas
  1. 16 sept, 13:01

    Have you created the cafsl__Embedded_CPQ_Settings__c record in the test class? If not, please try adding it.

Once invoices are generated, how are you managing payment reminders, dunning, and collections follow-up? Custom Flow/Apex, a third-party AR tool, or still manual chasing in Service Cloud or spreadsheets?  

 

Disclosure: I work on Quick Receivable, an AR automation app for Salesforce. Genuinely curious what teams here are doing post-invoice, not trying to pitch anything. 

 

#Salesforce CPQ & Billing

1 respuesta
  1. 7 sept, 14:44

    We’ve found Flow is fine for basic reminders, but collections gets messy pretty quickly once invoices go overdue in different ways. At that point I’d rather have a proper AR tool handling the follow ups than keep adding more Flow rules or tracking things in spreadsheets.

Using Enterprise Edition with CPQ. On a CPQ quote a sales rep pushes a custom button to book the order, which creates a case that moves on to Contracts, then the Sales Order team for entry into the ERP. There is a one-to-one lookup relationship between CQP Quote and Case. On the case, once the Sales Order teams confirms the quote is good, I would like to put a button or a checkbox on the case that runs a flow that goes to the quote and checks the box Ordered, which creates an order. The flow should then get the newly created order and do the same actions that clicking the Activate button does. I suspect it runs the two CPQ Apex triggers, on named OrderTrigger and the other named OrderProductTrigger. The main question is, would this take care of all the things that the order's Activate button does if you select it manually? Any other advice on how to "press the Activate button" via automation rather than manual action?

1 respuesta
  1. 12 ago, 15:03

    Setting the Order Status to Activated should run the triggers and perform the same actions as using the button.  

     

    Note that Order creation runs some async processes that must complete before you Activate. Check the documentation for this. Some of the processes include creating price schedules (if needed) or contracting an amendment (if needed). You may need to build in a delay before triggering activation automatically. There may be some documentation or a knowledge article with more details. 

     

    -Frank 

Hello All,

 

We have been working with the CPQ API for some time now, and are only recently leveraging the QCP JavaScript plugin. 

 

What i'm curious about and find odd is that when we do a database insert of quote lines for a quote, and then use the CPQ API to save/calculate the quote within Apex, i'm not seeing any signs that the JavaScript QCP is executing. 

 

So my question for anyone how might be familiar with QCP, does it execute when saving the quote and initiating calculate outside of the Quote Line Editor? 

 

The calculation sequence suggests that the plugin(s) run whenever calculation is initiated, but this isn't what I'm observing. Instead I only see the script execute from directly inside the quote line editor when either Save, Quick Save, and Calculate are clicked.

 

I've also noticed that when a new quote is created on the renewal opportunity which is initiated when the "Renewal Quoted" checkbox is checked on the contract, the plugin JavaScript is executed as the new quote is created. 

 

Thanks for your help.

7 respuestas
  1. 21 nov 2022, 22:22

    Antonio - I just tested this out and was able to update a quote line field with the script outside of the cart.  I tested both the Calculate button on the quote as well as triggering a re-calc by updating a field in the Calculating Fields field set.  In both scenarios, the script ran and I am seeing my desired outcomes (in my case, I am simply updating a quote line text field via the script).

     

    Have you tried all of the methods available with the QCP?  Something has to be getting in the way of the calculate.

I'm trying to disable the billing trigger for a specific usage type. CPQ uses the standard trigger to roll usages into the usage summary—any suggestions? 

 

I need to diable billing triggers from apex, if usage have type field equals to rebate. we are creating usages using scheduler apex.

3 respuestas
  1. 14 jul, 15:46

    Hi Subham 

     

    Salesforce Billing's managed package triggers generally can't be selectively disabled from custom Apex. If CPQ/Billing automatically rolls Usage records into Usage Summaries, there isn't a supported API to bypass the trigger for only one Usage Type (such as Rebate). A better approach is to:

    •  Verify whether the managed package provides a custom setting, custom metadata, or feature flag to exclude specific usage types. 
    •  If possible, prevent Rebate usage records from being processed by the Billing engine through configuration rather than trying to disable the trigger. 
    •  If you're creating Usage records in a scheduled Apex job, consider staging the rebate records in a custom object and only creating Billing Usage records for the types that should be summarized. 

    If this behavior isn't configurable, I'd recommend opening a Salesforce Billing support case, as managed package trigger behavior isn't intended to be bypassed from custom Apex. 

     

    Best, 

    Golla

I have a use case where a product is discountable, however it can only be discounted to 10%. If a user puts in a Quote line group of 50%, every line can be discounted to 50%, however, the line that contains this specific product, must have its discount capped at 10%

1 respuesta
  1. 7 jul, 8:31

    Hi @Felix Philip  Yes, this can be achieved in Salesforce CPQ. Solution: Create a Price Rule or Product Rule to validate or automatically cap the discount at 10% for that specific product. This ensures that even if a higher group discount is applied, the product's discount won't exceed the allowed limit. You can also display a validation message to inform users when they enter a discount above 10%, helping maintain pricing policies while still allowing group-level discounts for other products. 

2 respuestas
  1. 7 jul, 8:23

    Hi @Gourav Rathod Yes, this is possible. Add a condition to your Product Search Filter or Product Rule so the bundle is displayed only when the Quote's Account Record Type = "Partner". If the search filter alone doesn't support this logic, use a Product Rule or custom configuration to control the bundle's visibility.

I deleted a price rule and attempted to restore it from the recycle bin, some of the selected items were restored but the price rule record and price condition record failed to restore. Please the error encountered below.

 

"An error occurred while trying to update the record. Please try again. SBQQ.PriceConditionAfter: execution of AfterUndelete caused by: System.DmlException: Update failed. First exception on row 0 with id a043X00000ywSZsQAM; first error: FIELD_INTEGRITY_EXCEPTION, There is already an item in this list with the name Field 38: Name: [Name] (System Code) An error occurred while trying to update the record. Please try again. SBQQ.PriceRuleAfter: execution of AfterUndelete caused by: System.DmlException: Update failed. First exception on row 0 with id a043X00000ywSZsQAM; first error: FIELD_INTEGRITY_EXCEPTION, There is already an item in this list with the name Field 38: Name: [Name] (System Code)"

 

FIELD_INTEGRITY_EXCEPTION - Unable to create or edit price rule and unable to access quote lines

 

Now I can't access any quote line, I keep getting the error message below when I click on the Edit lines on quotes.

 

"We could not find the quote record you are trying to access. It may have been deleted by another user, or there may have been a system error. Ask your administrator for help"

 

Quote Line Error.png

 

Kindly assist.

6 respuestas