Setting Customer Defaults

Is it possible to set defaults for new customers? At the moment we’re particularly interested in one-time ship, but are wondering how to set other defaults, and where we can do that in the system.

Customer.GetNewCustomer POST process BPM (Method Directive)

Since that method has nothing under it I just need to add the functionality to set particular fields to the desired value?

Yes. If you add a post processing method directive as @Chris_Conn has said on the Customer.GetNewCustomer method, right after the method is called, your method directive will be called. For instance, you could use the BPM designer to set the Customer.GroupCode = “A” which would populate that field with the A code immediately upon GetNewCustomer being executed. This is preferred because it allows users to change these values before the initial save if desired.

In the instance where you have some customization or integration that is creating your customers without calling this method, then you could put the customer defaults on Customer.Update and set the fields of the “added” row if nothing was specified, but this is less preferable because it needs to be evaluated on each update.


Hi can I put filters on to these methods? I am interested in putting a method when a new cust is added - to send an email to the appropriate sales rep depending on what territory they are located.

Yes, you can use the condition widget to conditionally send an email based on territory. You can also use a query widget to populate data based on the local territory field, then email the returned emails.

Not sure what you mean by “filter”, but if you use BPM widgets, the “Condition” widget has tons of options to control when BPMs fire…

If you’re sending an email you have to think through what point in the series of method calls do you actually have the data you need (it won’t be Customer.GetNewCustomer). If the territory field is required, then a Customer.Update pre or post proc should work (filtered on the condition of RowMod = ‘A’). You’d also need to think through if you need to send another email if/when the territory is changed…

I have something like this setup:
Where I set a variable to ttCustomerRow.TerritoryID and have it setup so that it sends out an email to each sales rep letting them know that a new customer is added within their region. However when testing this, nothing fires. I have this setup as a Method Directive under Post-Processing. Any clue to what I may be doing wrong?

Usually when a new customer is added - the territory is also filled out as well. Would this still not be in Customer.GetNewCustomer?

If the Territory is initially blank and then the user selects one, then the Territory field in the Customer.GetNewCustomer post processing dataset would also be blank.

That said, I’m not sure if there is some sort of CRM config setting that may be adding default territories to new customers.

I would use a Standard Data Directive as that happens after the customer is saved to the database.

Hi - that’s what I originally tried and I received this error discussed here: ttCustomer has more than one record error - BPM for email alert when new cust is added - #8 by ale_spruce

Can you please help?

Not knowing how your Customer creation process is set up makes it a little difficult, but I would do something like this.

  • Create a Standard Data Directive on Customer
  • Have the first widget be a Condition to check for whatever you want to check for
  • Next widget would be Invoke BO Method to Get By ID on SalesRep BO
  • Last have a Send E-mail widget that uses the returned dataset to fill in the email address, name, etc in the email


If none of the automated row selectors are returning the correct data, you can try changing the first widget to a c# block with the following code:

var ttCustomer_xRow = ttCustomer.Where(x => x.Added()).FirstOrDefault();
TerritoryID = ttCustomer_xRow.TerritoryID;

As an aside, because this is usually not information that needs to be delivered at the time the transaction is created, my preference on solving your problem is to create a report that shows new customers (including territory and sales rep email). Then, add a report style with breaking and routing: break by Territory and send to the sales rep email on file. This way, the sales reps will have a nice daily PDF that gives them any information they’ll need about all of their new customers in their territory.