(7)-d. Insert Sample Code

[Custom button from Unit tab】

Insert sample code for a custom button placed on the design canvas by dragging and dropping from the Unit tab.


Property

Description

Back

Back event written in JavaScript will be inserted to the canvas of Event editing dialog

Close Quick Action

Closing quick action event written in JavaScript will be inserted to the canvas of Event editing dialog

Open standard "Create Record" dialog

Click to open "Object Setting" dialog 

PropertyDescription
Object

Choose the main object on the new dialog 
You can choose from all the objects that are used on the connected Salesforce. 

  • Account : Account
  • Campaign : Campaign
  • Case : Case
  • Contact : Contact
  • Lead: Lead
  • Opportunity : Opportunity
  • Order : Order
  • Pricebook : Pricebook2
  • Product : Product2
  • Quote : Quote
  • User: User
  • All the custom objects

Creating record of the selected object event written in JavaScript will be inserted to the canvas 

Show Toast 

Click to open "Show Toast" dialog

Please refer to < (7)-d-1. Show Toast > for more details. 

Use Input Field value 

Click to open "Use Input Field value" dialog 

Property Description
Input Field 

Choose input fields 
You can choose an input field object from the objects that are placed on Design canvas. 

Using input field value event written in JavaScript will be inserted to the canvas. 


The dialog below will show when there is no input field object placed on Design canvas. 

Open URL

Click to open "Open URL" dialog 

Opening URL event written in JavaScript will be inserted to the canvas. 

Please refer to < (7)-d-2. Open URL > for more details. 

Call ApexClass

Click to open "Call Apex Class" dialog 

Calling Apex Class methods event written in JavaScript will be inserted to the canvas. 

Please refer to < (7)-d-3. Call ApexClass > for more details. 



【Custom button in data table】

Insert sample code for a custom button placed in a data table.


プロパティ名

設定内容

Open Reference Page

Opening Record Page event written in JavaScript will be inserted to the canvas. 

Open Edit Page

Opening Edit Page event written in JavaScript will be inserted to the canvas. 

Open URL

Click to open "Open URL" dialog 

Opening URL event written in JavaScript will be inserted to the canvas. 

Please refer to < (7)-d-2. Open URL > for more details. 

Call ApexClass

Click to open "Call Apex Class" dialog 

Calling Apex Class methods event written in JavaScript will be inserted to the canvas. 

Please refer to < (7)-d-3. Call ApexClass > for more details.