Add/Update Salesforce Account Object

Add/Update Salesforce Account Object 20211102
This workflow is for adding and updating a Salesforce trading partner record. In the case of a new registration, the supplier record is added to the supplier object. If the registration information is changed, the supplier record is updated. It is assumed that this workflow is automatically started when a trial version is applied or a new order is received.
Worker (#of Swimlane: 1)
  • Sales/Marketing Professional
    • A person who obtains business contact information for potential/existing customers
Business Flow (Complexity of Workflow: 13)
  • 01. Change customer information
    • The person in charge will register the Salesforce account update information.
  • 241. Enter additional information for the account object
    • The person in charge will add and register the Salesforce customer information.
  • 21Create JSON for transmission
    • The workflow platform sets the data to be added/updated (in JSON format) to be passed to the Salesforce API.
  • 28Set Title
    • The workflow platform sets the subject and the add/update type.
  • 29Set Title
    • The workflow platform sets the subject and the add/update type.
  • 25[Add] Salesforce Account Object
    • The workflow platform will launch the Salesforce integration app (for additional users).
  • 22[Update] Salesforce Account Object
    • The workflow platform launches the Salesforce integration app (for updates).
Workflow Diagram (click to open)
Business Process Variables (#of Data Item: 10)
  • Customer to be Updatedq_customer_object_for_update10*
    • When updating a salesforce account object, the target account is stored.
  • Customer Nameq_customer_object_name6
    • The name of the customer is stored.
  • Websiteq_customer_object_website7
    • Contains the business partner’s website.
  • Telephone Number q_customer_object_phone 8
  • Number of Employees q_customer_object_NumberOfEmployees 9
  • Corporate Number q_customer_object_CorporateNumber 4
  • List of Registered Account Objects in Salesforceq_customer_object_list2
    • The customer information (option master) that matches the selected customer name will be stored.
  • JSON for Transmissionq_json_to_salesforce12
    • This stores the data (JSON format) used to execute the Salesforce Account object addition/update API.
  • ◆ Script3
    • Script to control the input screen when updating a customer
  • Add / Updateq_post_or_update5
    • The execution type (add/update) of this application is stored.

Field Name, num, Initial Value

Download

This archive contains the BPMN icons that are not available in the Basic edition.

Notes

  • You need to associate the Swimlane settings according to your organizational structure upon import
  • This app uses the Salesforce Cooperation Process. Before importing this app, please download, import, configure, and release it using the Salesforce Cooperation Process.
  • When updating a record of a Salesforce Account object, a choice master used in the App Shared Add-on Select-type data item is used.
    • Before using this app, please prepare and set up the Customer Name Master (ID: Salesforce Customer Object ID, Display Label: Customer Company Name) and Customer Information Master (ID: Salesforce Transaction Object ID, Display Label: Various Customer Information).
    • Please take advantage of the App Automatic Update of Customer Choice Master, Salesforce Customer Object Import which can obtain data from Salesforce. (Currently Japanese version only.)
    • This app is set up to use two masters: “demo-customer-name-master-on-salesforce.xml” and “demo-customer-information-master-on-salesforce.xml”.

Arrangement Tips

Spoiler title
<script type="text/javascript">
jQuery(document).ready(function(){
	jQuery('select[name="data[2].selects"]').parent().parent().parent().hide();
	var objs = new Array(jQuery('select[name="data[2].selects"]'));
	var htmls = new Array(jQuery('select[name="data[2].selects"]').html());
	jQuery('select[name="data[10].selects"]').change(function(){
		pcode = jQuery('select[name="data[10].selects"]').val();
		for(var i=0; i < objs.length; i++){
			objs[i].html(htmls[i]);
			objs[i].children().each(function(){
				try{
					var val =  jQuery(this).attr("value");
					if(val.indexOf(pcode, 0) != 0){
						jQuery(this).remove();
					}
				}catch(e){
					objs[i].html(htmls[i]);
				}
			});
		}
		var infos = (jQuery('select[name="data[2].selects"]').text().replace(/^\s+|\s+$/g, "")).split("|:|");
		jQuery('input[name="data[6].input"]').val(infos[0]);
		jQuery('input[name="data[7].input"]').val(infos[1]);
		jQuery('input[name="data[8].input"]').val(infos[2]);
		jQuery('input[name="data[9].input"]').val(infos[3]);
		jQuery('input[name="data[4].input"]').val(infos[4]);
	});
});
</script>

Capture

Example of “1. Change customer information” process input
Example of customer name and customer information master registration

See also

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Scroll to Top

Discover more from Questetra Support

Subscribe now to keep reading and get access to the full archive.

Continue reading