Skip to Content

C4C Account of Opportunity not mandatory

I would like to disable the account field in the opportunity.
When I just remove the field from the layout and try to save, the following message appears: "Please enter a party with role Account.".

In KUT the mandatory indicator is greyed out and active and when I set it to false via a rule the message also appears ("Please enter a party with role Account.")

Is there any possibility to disable this behavior?
I also tried to set a default account via ABSL AfterSave, but I was not able to do this.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Jun 26, 2017 at 09:25 PM

    Hi Peter,

    Account is mandatory in opportunity, and it is part of the involved party settings.

    From Business Configuration, open the Activity list and search for opportunities and open the same.You will find the link for involved parties, and you will notice that Account party role is mandatory.

    If you disable the account using KUT, the party rule validation will execute and hence you will get the error message.

    You can try to default the account via ABSL during the creation (Modify) to avoid the error.

    But I am curious to know the use case where account is disabled for opportunity.

    Thanks & regards

    Pramodh

    Add comment
    10|10000 characters needed characters exceeded

    • Hi Peter,

      You can try this logic on Root Modify for ex:

      Please note: Code is from the class which was not mass enabled.

      var prosParty = this.ProspectParty;
      if (prosParty.IsSet() && prosParty.PartyKey.PartyID.content == ""){
      prosParty.PartyKey.PartyID.content = "1001321"; // Account ID
      }else{
      prosParty = this.ProspectParty.Create();
      prosParty.PartyKey.PartyID.content = "1001321"; // Account ID
      }