Build a Data Model for a Recruiting App: Create Custom Recruiting Fields

Study for the Administrator Certification Exam > Object Manager and Lightning App Builder (15%) > Build a Data Model for a Recruiting App > Create Custom Recruiting Fields

이번 단원에서는 Recruiter들이 면접과정을 모니터링할 수 있도록 필드를 추가할거에요. 그리고 면접에 대한 결과를 저장할 수 있도록 Review객체에 Rate이나 comment필드를 추가할겁니다.

Create Custom Picklists

지원자의 Core Competencies를 평가할 필드를 Review객체에 추가할게요.

  1. Setup > Object Manager > Review > Fields & Relationships > New
    • Data Type: Picklist
  2. Next
    • Field Label: Core Competencies
    • ✅ Enter values, with each value separated by a new line
      • 1
      • 2
      • 3
      • 4
      • 5
    • Help Text: For this category, rate candidate on a scale of 1 (lowest) to 5 (highest)
  3. Next, Next, Save & New

지원자의 Leadership Skills를 평가할 필드를 Review객체에 추가할게요.

  1. Setup > Object Manager > Review > Fields & Relationships > New
    • Data Type: Picklist
  2. Next
    • Field Label: Leadership Skills
    • ✅ Enter values, with each value separated by a new line
      • 1
      • 2
      • 3
      • 4
      • 5
    • Help Text: For this category, rate candidate on a scale of 1 (lowest) to 5 (highest)
  3. Next, Next, Save & New

지원자의 Experience를 평가할 필드를 Review객체에 추가할게요.

  1. Setup > Object Manager > Review > Fields & Relationships > New
    • Data Type: Picklist
  2. Next
    • Field Label: Experience
    • ✅ Enter values, with each value separated by a new line
      • 1
      • 2
      • 3
      • 4
      • 5
    • Help Text: For this category, rate candidate on a scale of 1 (lowest) to 5 (highest)
  3. Next, Next, Save & New

Create Custom Text Fields

Core Competencies Comments:

  1. Data Type: Text Area
  2. Field Label: Core Competencies Comments
  3. Next, Next, Save & New

Leadership Skills Comments:

  1. Data Type: Text Area
  2. Field Label: Leadership Skills Comments
  3. Next, Next, Save & New

Experience Comments:

  1. Data Type: Text Area
  2. Field Label: Experience Comments
  3. Next, Next, Save & New

Recommend for Hire:

  1. Data Type: Checkbox
  2. Field Label: Recommend for Hire
  3. Help Text: Do you recommend that we hire this candidate?
  4. Next, Next, Save & New

reasons they recommend:

  1. Data Type: Text Area
  2. Field Label: Reason Recommended
  3. Next, Next, Save & New

Interviewer:

  1. Data Type: Lookup Relationship
  2. Related To: Interviewer
  3. Field Label: Interviewer
  4. Next, Next, Next, Save & New

Finally, create a master-detail relationship field for Job Application.

  1. Data Type: Master-Detail Relationship
  2. Related To: Job Application
  3. Field Label: Job Application
  4. Next, Next, Next, Save

Build a Data Model for a Recruiting App: Create a Self Relationship with the Position Object

Study for the Administrator Certification Exam > Object Manager and Lightning App Builder (15%) > Build a Data Model for a Recruiting App > Create a Self Relationship with the Position Object

HR팀에서 생각하기를 어떤 지원다는 다른 Position에 더 적합할거 같은데 지원자 서류를 보면서 비슷한 자격요건을 가진 다른 포지션을 볼수 있다면 좋겠다 싶습니다. lookup relationship로 구현해볼게요.

Create a Lookup Field

Position에 Related Position이라는 Lookup필드를 추가할게요:

  1. Setup > Object Manager > Position > Fields & Relationships > New
    • Data Type: Lookup Relaitonship
  2. Next
    • Related To: Position
  3. Next
    • Field Label: Related Position
    • Field Name: Related_Position
  4. Next, Next, Next
    • Related List Label: Related Positions
  5. Save

Add Lookup Filters

방금 생성한 Lookup필드에 department와 record ID로 검색하도록 필터를 추가합니다.

  1. Setup > Object Manager > Position > Fields & Relationships > Related Position > Edit > Lookup Filter > Show Filter Settings
    • Field: Related Position: Department
    • Operator: equals
    • Field: Position: Department
  2. AND
    • Field: Position: Record ID
    • Operator: not equal to
    • Field: Related Position: Record ID
  3. If it doesn’t, display this error message on save:
    • The related position must be in the same department. You cannot relate a position to itself.
  4. Save

Check the Result

  1. App Launcher > Recruiting > Positions > New
    *새로 추가한 Related Position이 아직 반영이 안되었을수도 있으니 Related Position필드가 보일때까지 새로고침을 합니다.
    • Title: Awesome Sales Rep
    • Department: Sales
    • Approval Status: Approved
    • Location: US
    • Job Description: Sales rep to join the AW Computing team serving the western region of AMER
    • Related Position: Super Sales Rep
      * 클릭하면 모든 포지션이 보이고, 검색하며 ID와 department로 검색이 됩니다.
  2. Save
    * 새로고침하면 Related Position이 레코드상세에 보입니다

Build a Data Model for a Recruiting App: Create a Custom Junction Object for Job Postings

Study for the Administrator Certification Exam > Object Manager and Lightning App Builder (15%) > Build a Data Model for a Recruiting App > Create a Custom Junction Object for Job Postings

Salesforce가 Many-to-Many를 구현하는 방법

하나의 Position은 여러 Job Posting Site에 게시될 수 있고, 하나의 Job Posting Site도 여러 Position을 게시할 수 있기 때문에 두 객체의 관계는 Many-to-Many이다.
Salesforce에서는 Many-to-Many 관계를 직접 만들 수 없기 때문에 별도의 객체(Junction Object) 를 생성한다.
그리고 이 Junction Object에 두 개의 Master-Detail 관계를 만들어 각 부모 객체와 연결한다.
이렇게 하면 각 부모 레코드는 여러 개의 Junction Object 레코드를 가질 수 있게 되어 Many-to-Many 관계가 구현된다.

Create a Custom Object

Job Posting객체를 만들어서 PositionJob Posting Site를 Master-Detail관계로 묶어줍니다. Job Posting은 관계만 정의합니다.

  1. Setup > Object Manager > Create > Custom Object
    • Label: Job Posting
    • Plural Label: Job Postings
    • Record Name: Job Posting Number
    • Data Type: Auto number
    • Display Format: JOBPOST-{0000}
    • Starting Number: 1
  2. Save

필드추가:

Position
   1
   |
   N
Job Posting (Junction Object)
   N
   |
   1
Job Posting Site
  1. Setup > Object Manager > Job Posting > Fields & Relationships > New
    • Data Type: Master-Detail Relationship
    • Related To: Position
    • Field Label: Position
  2. Next, Next, Next, Save & New
    • Data Type: Master-Detail Relationship
    • Related To: Job Posting Site
    • Field Label: Job Posting Site
  3. Next, Next, Next, Save

Modify the Page Layouts

Position의 Related List에 Job Posting Site필드들을 추가합니다.

  1. Setup > Object Manager > Position > Page Layouts > Edit > Related Lists > Job Postings > Wrench icon
    • Job Posting Site: Site Name
    • Job Posting Site: Status
    • Job Posting Site: Technical Site
  2. Add
    • Job Posting: Job Posting Number
    • Job Posting: Job Posting Name
  3. Remove
  4. OK
  5. Save

Job Posting Site의 Related List에 Job Postings필드들(Position)을 추가합니다.

  1. Setup > Object Manager > Job Posting Site > Page Layouts > Job Posting Site Layout > Edit > Related Lists > Job Postings > Wrench icon
    • Position: Status
    • Position: Title
  2. Add
    • Job Posting: Job Posting Number
    • Job Posting: Job Posting Name
  3. Remove
  4. OK
  5. Save

Check the Result

새로운 Job Posting Site를 등록합니다.

  1. App Launcher > Job Posting Sites > New
    • Site Name: Jobs-R-Us
    • Job Posting Site URL: www.jobsrus.com
    • Status: Active
  2. Save

Position을 신규등록합니다.

  1. App Launcher > Recruiting > Positions > New
    • Title: Super Sales Rep
    • Department: Sales
    • Approval Status: Approved
    • Location: US
    • Job Description: Sales rep to join the AW Computing team serving the eastern region of AMER
  2. Save

Related List에 Position을 등록합니다.

  1. App Launcher > Position > Super Sales Rep > Related
    * 만약 Related탭이 아직 비어있다면 조금 기다린 뒤 새로고침하세요
  2. > Job Postings > New
    • Position: Super Sales Rep
    • Job Posting Site: Jobs-R-Us
  3. Save

Build a Data Model for a Recruiting App: Create a Custom Object for Job Posting Sites

Study for the Administrator Certification Exam > Object Manager and Lightning App Builder (15%) > Build a Data Model for a Recruiting App > Create a Custom Object for Job Posting Sites

Job Posting Site객체를 생성해서 4개의 필드를 추가한 뒤, Recruiting앱의 네비게이션에 추가하도록 하겠습니다.

Create the Job Posting Site Object

  1. Setup > Object Manager > Create > Custom Object
    • Label: Job Posting Site
    • Plural Label: Job Posting Sites
    • Object Name: Job_Posting_Site__c
    • Record Name: Site Name
    • Data Type: Text
    • ✅ Allow Reports
    • ✅ Track Field History
    • Deployment Status:
      • ✅ Deployed
    • ✅ Allow Search
    • ✅ Add Notes and Attachments related list to default page layout
    • ✅ Launch New Custom Tab Wizard after saving this custom object
  2. Save
    • Object: Job Posting Site
    • Tab Style: Real Estate Sign
  3. Next, Next
    • Deselect 🔲 Include Tab
    • ✅ Append tab to users’ existing personal customizations
  4. Save

Create Custom Fields

  1. Fields & Relationships > New
    • Data Type: URL
    • Field Label: Job Posting Site URL
  2. Next, Next, Save & New
    • Data Type: Picklist
    • Field Label: Status
    • Select ✅ Enter values, with each value separated by a new line
      • Active
      • Inactive
  3. Next, Next, Save & New
    • Data Type: Checkbox
    • Field Label: Technical Site
  4. Next, Next, Save & New
    • Data Type: Text Area
    • Field Label: Description
  5. Next, Next, Save

Add Job Posting Site to the Recruiting App

  1. Setup > App Manager > Recruiting > Edit > Navigation Items
    • Selected Items (추가)
      • Job Posting Sites
  2. Save
  3. left arrow which is back button

Build a Data Model for a Recruiting App: Create a Custom Object for Reviews

Study for the Administrator Certification Exam > Object Manager and Lightning App Builder (15%) > Build a Data Model for a Recruiting App > Create a Custom Object for Reviews

Get Your Trailhead Playground Username and Password

일전에 Playground의 username과 password를 설정해서 Trailhead에서 Launch버튼을 누르지 않고도 Playground에 접속하는 방법에 대해서 알려드렸습니다. Trailhead Playground Management: Playground Username and Password를 참고하셔서 Playground의 username과 password를 설정해주세요.

  • username: sol1000@cunning-panda-4lvqld.com

Install the Unmanaged Package

“Recruiting App Package”를 설치하여 Recruiting앱의 기본가닥을 만들고, 이후에 객체를 추가하여 앱을 완성하도록 하겠습니다.

  1. Open https://login.salesforce.com/packaging/installPackage.apexp?p0=04t0P000000N9rs
  2. Login with the username and password
    • ✅ Install for Admins Only
    • Install
  3. Done

Create a Review Custom Object

  1. Setup > Object Manager > Create > Custom Object
    • Label: Review
    • Plural Label: Reviews
    • Record Name: Review Number
    • Data Type: Auto-Number
    • Display Format: REV-{0000}
    • Starting Number: 1
    • ✅ Allow Reports
    • ✅ Track Field History
    • ✅ Add Notes and Attachments related list to default page layout
  2. Save

Customize a Salesforce Object: Create Validation Rules

Study for the Administrator Certification Exam > Object Manager and Lightning App Builder (15%) > Customize a Salesforce Object > Create Validation Rules

The Rundown

  • enter support plan expiration date when Has Support Plan checkbox is selected
  • enter Close Reason when opportunity is lost

Note: An important point to keep in mind when working with validation rules is the impact on existing data. Validation rules apply to both future data and current data so the admin may need to populate the required data of the existing records to ensure any future integrations aren’t blocked. 

Create Validation Rules

First, create an account validation rule that forces users to enter a Support Plan Expiration Date when Has Support Plan is selected.

  1. Setup > Object Manager > Account > Validation Rules > New
    • Rule Name: Support_plan_expiration_date_required
    • Active ✅
    • Description: Support plan expiration date is required when account is marked as having support plan.
    • Formula:
      • Has_Support_Plan__c = True && ISBLANK(Support_Plan_Expiration_Date__c)
    • Check Syntax
    • Error Message: You must enter an expiration date when an account has a support plan.
    • Error Location: ✅ Field: Support Plan Expiration Date
  2. Save

Next, create an opportunity validation rule to force users to enter a Close Reason when the opportunity Stage is Closed Lost.

  1. Setup > Object Manager > Opportunity > Validation Rules > New
    • Rule Name: Close_reason_required_when_lost
    • Active ✅
    • Description: A close reason is required when opportunity is closed lost.
    • Formula:
      • ISPICKVAL( StageName ,”Closed Lost”) && ISBLANK(Close_Reason__c)
    • Check Syntax
    • Error Message: You must enter a close reason when opportunity is closed lost.
    • Error Location: ✅ Field: Close Reason
  2. Save!

You’ve created picklists, lookup filters, formula fields, and record types; set up custom record pages, page layouts, and field history tracking; and established validation rules. Using these tools, you’ve enabled the ops, sales, and service teams to do their jobs better and more efficiently by customizing how they work with the important data they need day to day. Good work, Admin!

Customize a Salesforce Object: Enable Account Field History Tracking

Study for the Administrator Certification Exam > Object Manager and Lightning App Builder (15%) > Customize a Salesforce Object > Enable Account Field History Tracking

The Rundown

  • 매주 어떤 Account가 Having Support Plans마킹이 되었는지
    어떤 Account가 Support Plan Expiration Date가 없는지
  • Enable History Tracking
    • 이 기능을 사용하면 개체의 표준 필드 또는 사용자 정의 필드 최대 20개에 대한 변경 사항을 추적할 수 있으며, 해당 변경 이력은 레코드의 이력 관련 목록이나 이력 보고서에서 확인할 수 있습니다. 각 필드에 대해 변경 날짜 및 시간, 변경 사용자, 이전 값 및 새 값이 기록됩니다.

Enable Field History Tracking

Field History Tracking을 활성화하여 Has Support Plan필드와 Support Plan Expiration Date필드의 변화를 추적합니다.

  1. Setup > Object Manager > Account > Fields & Relationships > Set History Tracking!
    • ✅ Enable Account History
      • ✅ Has Support Plan
      • ✅ Support Plan Expiration Date
  2. Save

Add the Account History related list to the Customer Account Page.

  1. Setup > Object Manager > Account
    App Launcher > Sales > Accounts > All Accounts > Edge Communications > 우측상단 톱니바퀴 > Edit Object
  2. Page Layouts > Account Layout > Related Lists > 팔레트의 Account History를 끌어다가
  3. Related Lists > Contacts밑으로 끌어다 놓으면 그 밑으로 섹션이 하나 추가됨
  4. Save
  5. No
  6. App Launcher > Sales > Accounts > All Accounts > Edge Communications에 들어가서 새로고침해보면 Related List에 Account History가 들어가있음

Customize a Salesforce Object: Customize Record Pages

Study for the Administrator Certification Exam > Object Manager and Lightning App Builder (15%) > Customize a Salesforce Object > Customize Record Pages

The Rundown

Noah Larkin, AW Computing’s VP of Services, is concerned that his Consulting team uses accounts to capture details of consulting partners, but some of the fields they see aren’t applicable to their partner accounts. He would like all sales-related information removed.

컨설팅팀이 컨설팅 파트너 정보를 저장하기 위해 Account를 사용하는데, 어떤 필드들은 파트너정보를 저장하기에 적절하지 않은것들이 있어요. Sales관련한 정보는 전부 안보이게 해주세요.

Allison Wheeler also contacted you with a request. She’s concerned that the new account fields appear together in the top section of account record detail pages. She’d like them organized into different sections to make it easier for her team to find the right information.

Account Detail페이지에 새로운 필드가 다 한곳에 보이는데 필드들을 섹션에 나누어 볼수 있게 정리하고 싶어요.

요구사항 정리:

  • Sales User와 Support User는 Region과 Zone을 별도의 섹션에서 보여주기 (우측 사이드바)
  • Partner Account일때는 Region과 Zone섹션을 보여주지 않도록

Adjust the Fields on the Page

Default Page를 수정해서 Sales와 Support User들에게만 보여줄 Customer Account Page를 생성합니다.

  1. App Launcher > Sales > Accounts > All Accounts > Edge Communications
  2. 우측 최상단 톱니아이콘 > Edit Page > Page (우측 속성 창)
    • Label: Customer Account Page
    • API Name: Customer_Account_Page
  3. Canvas (가운데 창) > Detail 탭 > 레코드Details 클릭 (우측 속성창에 Page > Record Detail로 나옴)
  4. 우측 속성 창 > Page > Record Detail > Upgrade Now버튼 클릭
  5. Next
  6. ✅ Account Layout
  7. Finish
    이제 필드를 개별선택할 수 있습니다.
  8. 좌측 툴바 > Field 탭 > Field Section을 드래그해서 Additional Information섹션 밑에 끌어다 놓음
    • 해당 섹션을 선택한 상태에서
    • 우측 속성 창 > Page > Field Section
      • Custom Label: Sales Region
  9. 좌측 툴바 > Field 탭 > Field Section을 드래그해서 Sales Region섹션 밑에 끌어다 놓음
    • 해당 섹션을 선택한 상태에서
    • 우측 속성 창 > Page > Field Section
      • Custom Label: Support Plan Information

한군데 모여있던 필드들을 아래와 같이 이동시켜줍니다:

  1. Region
    • Sales Region > Left
  2. Zone
    • Sales Region > Right
  3. Has Support Plan
    • Support Plan Informaiton > Left
  4. Support Plan Expiration Date
    • Support Plan Information > Right

Sales Region섹션이랑 Support Plan Information섹션이 너무 밑에 있는 것 같아요. 오른쪽 사이드바로 옮겨줄게요.

  1. Sales Region섹션에 마우스를 올리면 Move component 아이콘이 나옵니다. 그걸 잡아다 끌어서 오른쪽 사이드바의 Activity and Chatter있는데다가 옮겨놓으세요. 섹션이 그 윗쪽으로 배치가 됩니다.
  2. 마찬가지로 Support Plan Information섹션도 Sales Region밑으로 섹션의 위치를 옮겨주세요.

Lastly, make the Prospect Rating field required.

  1. 가운데 창 > 메인바디 > Details 탭 > Account Information > Prospect Rating필드 선택
  2. 우측 속성 창 > UI Behavior
    • ✅ Required
  3. Save
  4. Not Yet

Lightning App Builder에서 화면에 보여지는 부분을 담당한다면, 해당 페이지에 데이타를 제공하는 부분은 바로 Page Layout Editor가 합니다. 즉, Page Layout Editor에서 데이타를 제공해야 Lightnign App Builder에서 예쁘게 배치를 할수가 있다는 말이에요.

  • Page Layout → 데이터 구조 / 필드 관리
    • 어떤 Field를 보여줄지
    • 필드 순서
    • Section 구성
    • Related List
    • Quick Actions
  • Lightning App Builder → 화면 UI 구성
    • Tabs
    • Accordion
    • Related Record component
    • Report
    • Visualforce
    • Custom components

이번에는 Do Not Call칼럼을 Contacts의 Related List에 추가해 볼게요:

  1. Lightning App Builder의 좌측상단에 Back (Back)버튼을 클릭해서 Edge Communications상세 페이지로 돌아가세요.
  2. 우측 최상단 톱니바퀴 > Edit Object > Page Layouts > Account Layout > Related List > Contacts > wrenchWrench icon
    • Add “Do Not Call” to Selected Fields
  3. OK

Related List 안에 섹션이 여러개 있잖아요. 그중에서 Opportunities섹션을 가장 위에 보여줘 볼게요:

  1. Related Lists > Opportunities
  2. 상단 회색바를 잡고 맨위로 끌어다 옮기세요
  3. Save
  4. Yes

Activate the Customer Account Page

아까 만든 “Customer Account Page”를 Customer Account Record Type에서 보여주도록 하겠습니다.

  1. Setup > Lightning App Builder > Customer Account Page > Edit > Activation
  2. APP, RECORD TYPE, AND PROFILE 탭 > Assign to Apps, Record Types, and Profiles
    • Lightning Apps:
      • ✅ Sales
  3. Next
    • ✅ Desktop and phone
  4. Next
    • Record Types:
      • ✅ Customer Account
  5. Next
    • Profiles:
      • ✅ Sales User
      • ✅ Support User
  6. Next
  7. Save
  8. Save

Create a Partner Account Page

이제 드디어 Partner Account Page를 만들어서 Record Type에 따라 Customer Account Page와 다르게 보이는 것을 구현해보도록 하겠습니다. 우선 Customer Account Page를 Clone해서 Partner Account Page를 생성해주세요.

  1. Setup > Lightning App Builder > Customer Account Page > Clone
  2. 우측 속성창 > Page
    • Label: Partner Account Page
    • API Name: Partner_Account_Page
  3. 가운데 창 > 메인정보 > Details탭 > Account Information > Prospect Rating > Delete(Delete)
  4. 가운데 창 > 우측 사이드바 > Sales Region 섹션 > Delete(Delete)
  5. 가운데 창 > 우측 사이드바 > Support Plan Information 섹션 > Delete(Delete)
  6. Save
  7. Activate
    • APP, RECORD TYPE, AND PROFILE > Assign to Apps, Record Types, and Profiles
      • Lightning Apps:
        • ✅ Sales
      • Next
        • ✅ Desktop and phone
      • Next
        • Record Types:
          • ✅ Partner Account
      • Next
        • Profiles:
          • ✅ Sales User
          • ✅ Support User
      • Next
    • Save
    • Save!

Customize a Salesforce Object: Create Record Types

Study for the Administrator Certification Exam > Object Manager and Lightning App Builder (15%) > Customize a Salesforce Object > Create Record Types

The Rundown

Record types determine the business processes, page layouts, and picklist values users have access to.

Create Record Types

Customer Account라는 Record Type을 만들고, Consulting과 Educaiton은 picklist 목록에서 제외

  1. Setup > Object Manager > Account > Record Types New
    • Existing Record Type: Master
    • Record Type Label: Customer Account
    • Record Type Name: Customer_Account
    • Description: For customers and prospects
    • Active: ✅ (selected)
    • Deselect 🔲 Make Available (Deselect all)
      • Sales User ✅ Make Available
      • System Administrator ✅ Make Available
  2. Next
    • ✅ Apply one layout to all profiles: Account Layout
  3. Save
  4. Industry > Edit
    • Remove Consulting and Education from Selected Values
    • Available Values:
      • Consulting
      • Educaiton
  5. Save

Create a new account record type called Partner Account.

  1. Setup > Object Manager > Account > Record Types New
    • Existing Record Type: Master
    • Record Type Label: Partner Account
    • Record Type Name: Partner_Account
    • Description: For consulting partners.
    • Active: ✅ (selected)
    • Deselect 🔲 Make Available (Deselect all)
      • Partner App Subscription User ✅ Make Available
      • Partner Community Login User ✅ Make Available
      • Partner Community User ✅ Make Available
  2. Next
    • ✅ Apply one layout to all profiles: Account Layout
  3. Save
  4. Industry > Edit
    • Remove all items from Selected Values except:
      • Consulting
      • Educaiton
  5. Save
  6. Type > Edit
    • Remove from Selected Values:
      • Prospect
      • Customer – Direct
      • Customer – Channel.

Customize a Salesforce Object: Create Formula Fields

Study for the Administrator Certification Exam > Object Manager and Lightning App Builder (15%) > Customize a Salesforce Object > Create Formula Fields

요구사항

  • collecting additional information on opportunities
  • sales and executive users to see their commission calculated for won opportunities
  • regions and zones of accounts displayed on opportunities for all to see
  • in an effort to enhance pipeline accuracy
    • display the discounted amount whenever a discount has been applied to an opportunity

Handle these requests by creating custom formula fields, which allow you to define calculations that reference other fields to display new numeric, text, date, or checkbox values specific to business requirements. Time to get started.

Calculate the Commission

Opportunity에 Closed Won이 된 레코드에 10 percent commission을 보여주세요.

  1. Setup > Object Manager > Opportunity > Fields & Relationships > New
    • Data Type: Formula
  2. Next
    • Field Label: Commission
    • Formula Return Type:
      • Currency
  3. Next
    • Select Field Type: Opportunity
    • Insert Feild: Amount
    • Insert Operator: *Multiply
    • Commission (Currency) =:
      • Amount * 0.1
    • Description: Calculates sales rep commission of 10 percent when opportunity is won.
    • Help Text: Sales rep commission when opportunity is won.
  4. Next
    • Visible > Check > Uncheck (=clear the checkboxes)
    • Sales User: Check ✅ Visible
    • System Administrator: Check ✅ Visible
  5. Next
  6. Save

방금 만든 Commission필드는 Opportunity의 Stage가 Closed Won일때만 보여주세요.

  1. Setup > Object Manager > Opportunity > Fields & Relationships > Commission > Edit > Advanced Formula
    • Commission (Currency) =
      • IF( ISPICKVAL( StageName , “Closed Won”) , Amount * 0.1, 0)
    • Check Syntax!
  2. Save!

Customize Formula Fields

Account의 Region / Zone을 Opportunity에서 보여주기 위해 Formula Field를 사용합니다.

  1. Setup > Object Manager > Opportunity > Fields & Relationships > New
    • Data Type: Formula
  2. Next
    • Field Label: Region/Zone
    • Field Name: Region_Zone
    • Formula Return Type: Text
  3. Next
    • Advanced Formula > Region/Zone (Text) =
      • Functions: TEXT > Insert Selected Function!
        TEXT( value )
      • select “value” > Insert Field! > Opportunity > Account > Region > Insert!
        TEXT( Account.Region__c )
      • Insert Operator > & Concatenate
        TEXT( Account.Region__c ) &
      • enter "/"
        TEXT( Account.Region__c ) & “/”
      • Insert Operator > & Concatenate
        TEXT( Account.Region__c ) & “/” &
      • Functions: TEXT > Insert Selected Function!
        TEXT( Account.Region__c ) & “/” & TEXT(value)
      • select “value”> Insert Field! > Opportunity > Account > Zone > Insert!
        TEXT( Account.Region__c ) & “/” & TEXT( Account.Zone__c )
    • Check Syntax
    • Description: Displays the Region and Zone values from the account record.
    • Help Text: Account region and zone.
  4. Next, Next, Save

Add New Field, Discount Percentage

  1. Setup > Object Manager > Opportunity > Fields & Relationships > New
    • Data Type: Percent
  2. Next
    • Field Label: Discount Percentage
    • Length: 3
  3. Next
    • Visible > Check > Uncheck (=clear the checkboxes)
    • Sales User: Check ✅ Visible
    • System Administrator: Check ✅ Visible
  4. Next, Save

Now create the formula.

  1. Setup > Object Manager > Opportunity > Fields & Relationships > New
    • Data Type: Formula
  2. Next
    • Field Label: Amount After Discount
    • Formula Return Type: ✅ Currency
  3. Next
    • Simple Formula!
    • Amount After Discount (Currency) =
      • Select Field Type: Opportunity
      • Insert Field: Amount
        Amount
      • Insert Operator: * Multiply
        Amount *
      • Insert Operator: ( Open Parenthesis
        Amount * (
      • Enter 1
        Amount * ( 1
      • Insert Operator: – Subtract
        Amount * ( 1 –
      • Insert Field: Discount Percentage
        Amount * ( 1 – Discount_Percentage__c
      • Insert Operator: ) Close Parenthesis
        Amount * ( 1 – Discount_Percentage__c )
    • Check Syntax!
    • Description: Calculates the opportunity amount after any discount has been applied.
    • Help Text: Opportunity amount after discount has been applied.
  4. Next, Next, Save