Customer Engagement & Dynamics CRM Forum

Expand all | Collapse all

Closing quote security issue

  • 1.  Closing quote security issue

    TOP CONTRIBUTOR
    Posted 13 days ago
    I have a few salespeople reporting to me that they can close (won/lost) some of their quotes but not others. The log file gives a generic "Cannot Update a Read-Only EntityDetail:" (see details below). Based on that log file, it gets as far as the ValidateForUpdate() before it throws the exception.
    I am fairly sure it is a security role issue because a System Administrator can close the quote.
    The salesperson is the owner of the quote and they have all business-unit rights to the quote entity.
    There are 3 referential lookup fields on the quote and the salesperson has full organization rights to those entities.
    The quote is not part of the BPF.

    Any thoughts where I should look?

    Here is the log file downloaded:

    Unhandled exception:
    Exception type: System.ServiceModel.FaultException`1[Microsoft.Xrm.Sdk.OrganizationServiceFault]
    Message: Cannot Update a Read-Only EntityDetail:
    <OrganizationServiceFault xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.microsoft.com/xrm/2011/Contracts">
    <ActivityId>76b0998a-1445-4b28-9c6d-3534a2e8ab28</ActivityId>
    <ErrorCode>-2147220946</ErrorCode>
    <ErrorDetails xmlns:d2p1="http://schemas.datacontract.org/2004/07/System.Collections.Generic">
    <KeyValuePairOfstringanyType>
    <d2p1:key>CallStack</d2p1:key>
    <d2p1:value xmlns:d4p1="http://www.w3.org/2001/XMLSchema" i:type="d4p1:string"> at System.Environment.GetStackTrace(Exception e, Boolean needFileInfo)
    at System.Environment.get_StackTrace()
    at Microsoft.Dynamics.Solution.Common.CrmException.BuildOrganizationServiceFault(Exception innerException, Int32 errorCode, Int32 statusCode, String message)
    at Microsoft.Dynamics.Solution.Common.CrmException..ctor(String message, Exception innerException, Int32 errorCode, Int32 statusCode, Boolean isFlowControlException, Boolean enableTrace)
    at Microsoft.Dynamics.Solution.Common.CrmException..ctor(String message, Exception innerException, Int32 errorCode, Int32 statusCode, Boolean isFlowControlException)
    at Microsoft.Dynamics.Solution.Common.CrmException..ctor(String message, Int32 errorCode)
    at Microsoft.Crm.Sales.ObjectModel.QuoteService.ValidateForUpdate(Quote preImage, Quote quote, IPluginContext context)
    at Microsoft.Dynamics.Sales.Plugins.PreOperationQuoteUpdate.ExecuteCrmPlugin(LocalPluginContext localContext)
    at Microsoft.Dynamics.Solution.Common.PluginBase.Execute(IServiceProvider serviceProvider)
    ...snip
    [Microsoft.Dynamics.Sales.Plugins: Microsoft.Dynamics.Sales.Plugins.PreOperationQuoteUpdate]
    [16e34e29-2155-e611-810a-00155dacf82e: Pre-Update validation of quote]
    Entered Microsoft.Dynamics.Sales.Plugins.PreOperationQuoteUpdate.Execute(), Correlation Id: 1ab9bcd2-fd6c-40d6-9557-6db43071e312, Initiating User: 734e69f5-391b-e911-a870-000d3a33a9a3
    Exception: Microsoft.Dynamics.Solution.Common.CrmException: Cannot Update a Read-Only Entity (Fault Detail is equal to Exception details:
    ErrorCode: 0x8004022E
    Message: Cannot Update a Read-Only Entity
    StackTrace:
    at System.Environment.GetStackTrace(Exception e, Boolean needFileInfo)
    at System.Environment.get_StackTrace()
    at Microsoft.Dynamics.Solution.Common.CrmException.BuildOrganizationServiceFault(Exception innerException, Int32 errorCode, Int32 statusCode, String message)
    at Microsoft.Dynamics.Solution.Common.CrmException..ctor(String message, Exception innerException, Int32 errorCode, Int32 statusCode, Boolean isFlowControlException, Boolean enableTrace)
    at Microsoft.Dynamics.Solution.Common.CrmException..ctor(String message, Exception innerException, Int32 errorCode, Int32 statusCode, Boolean isFlowControlException)
    at Microsoft.Dynamics.Solution.Common.CrmException..ctor(String message, Int32 errorCode)
    at Microsoft.Crm.Sales.ObjectModel.QuoteService.ValidateForUpdate(Quote preImage, Quote quote, IPluginContext context)
    at Microsoft.Dynamics.Sales.Plugins.PreOperationQuoteUpdate...)., Correlation Id: 1ab9bcd2-fd6c-40d6-9557-6db43071e312, Initiating User: 734e69f5-391b-e911-a870-000d3a33a9a3
    Exiting Microsoft.Dynamics.Sales.Plugins.PreOperationQuoteUpdate.Execute(), Correlation Id: 1ab9bcd2-fd6c-40d6-9557-6db43071e312, Initiating User: 734e69f5-391b-e911-a870-000d3a33a9a3
    </TraceText>
    </OrganizationServiceFault>

    ------------------------------
    Thanks.
    Nelson Johnson, Solution Architect
    BroadPoint, Inc., Bethesda MD
    Link with me! https://www.linkedin.com/in/nelsonjohnson/
    ------------------------------
    Conference-CRMUG_200x200


  • 2.  RE: Closing quote security issue

    GOLD CONTRIBUTOR
    Posted 12 days ago
    Nelson,

    It might be that the security role those users are in needs to have Create permission on Process Session.

    ------------------------------
    Andy Arndt
    Minitab, Inc.
    State College PA
    ------------------------------

    Conference-CRMUG_200x200


  • 3.  RE: Closing quote security issue

    TOP CONTRIBUTOR
    Posted 12 days ago
    Hi Andy. I just checked and they have business unit rights to create / update/ delete Process Session, and full read rights.

    ------------------------------
    If this answered your question, please click on the arrow button next to Reply Inline and choose 'Make Best Answer.'
    Thanks.
    Nelson Johnson, Solution Architect
    BroadPoint, Inc., Bethesda MD
    Link with me! https://www.linkedin.com/in/nelsonjohnson/
    ------------------------------

    Conference-CRMUG_200x200


  • 4.  RE: Closing quote security issue

    Posted 12 days ago
    Edited by Scott Florance 12 days ago
    Hi Nelson,

    I have seen an issue similar to this before and for us it was tied to permissions on the order entity since winning the quote creates the order. There was Field Level Security on a field on the order and this was preventing the creation thus throwing the entire quote close process.

    ------------------------------
    Scott Florance
    Business Applications Consultant
    KTL Solutions, Inc, Frederick, MD
    ------------------------------

    Conference-CRMUG_200x200


  • 5.  RE: Closing quote security issue

    TOP CONTRIBUTOR
    Posted 12 days ago
    Thanks Scott. The FLS was a good idea, but the 6 fields we have in FLS are on accounts and opportunities.

    ------------------------------
    If this answered your question, please click on the arrow button next to Reply Inline and choose 'Make Best Answer.'
    Thanks.
    Nelson Johnson, Solution Architect
    BroadPoint, Inc., Bethesda MD
    Link with me! https://www.linkedin.com/in/nelsonjohnson/
    ------------------------------

    Conference-CRMUG_200x200


If you've found this thread useful, dive deeper into User Group community content by role