The Documentation below is organized by Feature, each section will have the relevent inputs and outputs as well as references to the logic that processes the input and outputs.
Business Process this supports: Territory Success Planning
Overview: The goal of TSP is to keep a set of staging fields consistently up to date from a variety of data sources, then at given intervals copy these vales to the "Actual" set of fields for general use. This allows for us to constantly receive changes but only apply those changes in a controled fashion. This also allows us to easily track exceptions. Note: This project was orginally referred to as ATAM, which is why the API names of the fields reference that instead of TSP.
Logic Locations: AccountJob.cls Code Units:
Inputs: DataFox, Zoominfo, Manually Entered Address & Employee Data, Account Parenting Hierarchy
Outputs: Here is the outline between of two sets of fields we are setting on the Account object. Staging(TSP / ATAM) are set nightly via an APEX job. Actuals are set at given intervals found in the business documentation.
|Data Name||Actual - Field API Name||TSP - Field API Name|
Business Process this supports: This supports our contact ownership rules
Overview: The goal of the Contact Ownership code is to ensure that contacts are owned by the appropriate user within salesfore in an automated fashion so that contact ownership is maintained without any work needed by team members.
Logic Locations: ContactJob Code Units:
Inputs: Contact Owner, Account Owner, Account SDR Assigned, Account Type, Sales Segment
Outputs: Contact Owner
Business Process this supports: Security and compliance requierments for federal customers
Overview: The goal of our record sharing settings in Salesforce is so that the Public Sector Team and approved supporting functions can view public sector records. A Public Sector recrod is considered any record in Salesforce that is owned by the Public Sector team. This is accomplished by the use of sharing rules and groups within Salesforce. If a record is owned by a member of the Public Sector Group then that record is only shared and visible to other members of the Public Sector Group. If the record is owned by anyone other then a member of the public sector group, then that record is visible to all internal users within our Salesforce Instance. Membership to these applicable groups is controlled by System Administrators and Sales Operations.
Business Process this supports: Discount Approvals
Overview: According to the Deal Approval Matrix Quotes must have discounts approved by different management levels depending on discount percentage and term length. To achieve this, we have written automation to stamp a quote with each potential approver, revised the code that determines which approvals are required, and revised the actual approval process in Salesforce.
Quote Management Stamp When a Quote is inserted, get the owner of the related Opportunity. Then, find the manager of the owner and the manager of the manger for each manager, five mangers down. Record the first active Regional Director, Area Sales Manager, and Vice President on the Quote. These lookup fields will be used in the Approval Process, if needed.
Quote Approval Code This is a table of the Quote (API Name: zqu__Quote__c) fields that trigger quoteApprovals to recalculate and what must happen to them.
|Field API Name||What Must Happen|
If any of these events happen, all "Required_Approvals" fields (Required_Approvals_From_CEO__c, Required_Approvals_From_CFO__c, Required_Approvals_From_CRO__c, Required_Approvals_From_CS__c, Required_Approvals_From_Legal__c, Required_Approvals_From_VP_of_Channel__c, Required_Approvals_From_VP_of_Sales_RD__c, Required_Approvals_From_RD__c, Required_Approvals_From_ASM__c) are cleared. These are the rich text area fields that show which management levels need to approve the Quote on the page layouts. Then, all relevant Quote Rate Plan Charges (API Name: zqu__QuoteRatePlanCharge__c) related to the Quote are queried, these are what hold the term, product, and discount information we need to determine what approvals are required. Following the Deal Approval Matrix, we determine what level of management the Quote Rate Plan Charge needs and stamp the correct "Required_Approvals" fields with the discount percentage, type, and term. Similar logic is then run for any Quote Rate Plan Charges related to Professional Services products. Finally, the Quote's Approval_Stage__c field records whether it needs approval, doesn't need approval, or has been approved.
Quote Approval Process This utilizes Salesforce's built-in Approval Process functionality. We have two Approval Processes for Zuora Quotes, the first for undiscounted, and the other for ones with discounts. The Quote must be submitted using the "Submit for Approval" button on the page layout to enter the correct Approval Process.
Business Process this supports: The field needs a streamlined process to address their concerns on specifc salesforce records within salesforce. This is also used by the finance team to help address record specific billing issues, as well as the Commmunity Advocate team to manage the influx of requests the team receives.
Overview: The goal of the Chatter To Cases functionality is to allow a streamlined communication channel that the field can leverage while also providing a streamlined case management system for the supportung team members to manage the requests that are sent to them from the field. If a team members uses an appropraite tag in salesforce a salesforce case record will automatically be created. Once these records are created supporting team members can work through the respective cases that are created to address the fields needs and concerns.
Inputs: Chatter text within Salesforce
Outputs: Salesforce Case Records
Logic Locations: Code Units:
@SMB Flat Renewals
Steps to add a Group:
ChatterFeedItemClassto monitor for the use of the Chatter Group in chatters within Salesforce (Changeset)
CaseClassto include the new groups Id so that it updates the case owner what ownd by this queue.
Originfield on the case object (In Production)
Business Process this supports The sales cycle, if a GitLab sales rep encounters an issue that requires legal knowledge, opinion, or action.
Overview A sales rep can quickly and easily create a Case for our legal team directly from an Opportunity's page layout in Salesforce. The legal team have access to a Salesforce dashboard to see how many Cases have been created for them, how many are in their name, etc. Clicking the "Legal Request" button on each Opportunity's page will bring the user to a page that asks a few questions that the legal team would like to know. Once the page is submitted, a Case is created with the Origin marked as "Legal Request." The legal team has dashboards that view Cases with Origin equal to "Legal Request" and can assign and take action from there.
Business Process this supports The sales cycle and the financial processes around deals.
Overview We are now ensuring Opportunities in Salesforce have only one Quote that is marked as Primary. If multiple Quotes are being inserted under an Opportunity marked as primary in the same transaction, only the first in the list will be the primary. If a Quote is being inserted as primary, and there is an existing primary Quote, the existing will become not-primary and the incoming will be the new primary. If more than one Quote under the same Opportunity is being updated to become primary in the same transaction, an error message will prevent the update. A primary quote will not be allowed to be deleted. To change which Quote is primary, simply navigate to the Quote you want to be primary and update it as such, the previous primary Quote will automatically be updated to no longer be primary.
Business Process this supports The sales cycle and analytics.
Overview The goal of this functionality is to capture the progression of an opportunity through the stages in the sales process. To support this, a check box and date stamp will be automatically populated for each stage as the oportunity advances and or moves back in stage. The tracking begins at stage 0-Pending Acceptance (an opportunity in stage 00, will not be stamped). In the event an opportunity advances forward and skips stages, all of the skiped stages will be stamped with the same date as the resting stage. In the event of Closed Lost and Unqualified, the checks and dates will only apply for the stages that were actually met. To avoid data loss and confusion, the stage progression tracking will only run once, the first time through the stages.
Business Process this supports: In order to provide reliable and accurate historical data to the analytics team, the sales organization and to the companye as a whole we need to ensure that historical opportunities and relevant information on opportunities is not changed once the opportunity is closed.
Overview: The goal of this blocking logic is to close a backdoor that Salesforce has built into the system. While we have a number of validation rules in place to prevent information from changing on closed opportunities it was possible to change histoircal opportunity owners (as well as fields that are derived from the owner field) while transferring accounts. Anyone who could have been able to change the owner on an account would have been able change historical opportuntiy data that they would not be able to edit otherwise. This logic still allows users to complete this account ownership transfer without any impact to historical opportunities while also allowing the various business teams at GitLab to manually update the owners of opportunites at month close.
Inputs: Account records that are changing ownership
Outputs: Reverts opportunity owners to their original owners if the user attempted to change them
Logic Locations: Code Units: * ProtectClosedOppOwnersBefore * ProtectClosedOppOwnersAfter
Business Process this supports: New vs Connected New vs Growth
Overview: The goal of the Order Type system is to determine a given Opportunity's relationship with the business. Did it start a new customer relationship, cross into a related segment of the customer, or grow an existing relationship.
Logic Locations: AccountJob.cls
Inputs: Salesforce Account Hierarchy, Salesforce Opportunity Close Date and Stage.
Outputs: Populates the Order Type field on the Opportunity with New - First Order, New - Connected or Growth based on the following logic:
| Order Type | Description |
| New - First Order | The First Closed Won Opportunity in an Account Family. |
| New - Connected | The First Closed Won Opportunity on an individual Account, that is not the first one in the Account Family.|
| Growth | All opportunities that follow the
New - First Order or
New - Connected opportunities. This includes Add-ons, Renewals, and additional Subscriptions. |
Business Process this supports: Sales Segmentation
Overview: Leads should be sorted into different Sales Segments based on their company's employee count so the appropriate salesperson can persue them. We have a number of different information sources to get company size, so we must also establish a hierarchy for them.
|Info Source||Salesforce Lead Field API Name|
Logic Locations: LeadClass.cls Code Unit: