A potential opportunity or customer inquiry - the entry point of the CRM funnel (Status: New, Contacted, Nurturing, Lost, Converted). Can be raised manually or generated from service origins, which it links back to: Asset, AssetMaintenance, ServiceCampaign/ServiceCampaignMember, Case, ItemServiceContract, ItemMaintenanceSchedule. On insert the handler auto-assigns PartnerAccountId and BranchId from PostalCode via the BranchPostalCode mapping and can auto-assign the owning Resource. Conversion actions create an Account (when accountId is empty), a Contact, and an Opportunity linked back via Lead.opportunityId - a lead with opportunityId set is already converted and cannot be converted again. Activity roll-ups (isEmailedOrCalled, eventTaskCount) are recomputed from Activity rows, not incremented.
Fields
| Field | Label | Type | Required | What it does |
AccountId | Account | Lookup → Account | | |
AccountName | Account Name | Calculated (calculated) | | |
AssetId | Asset | Lookup → Asset | | |
AssetMaintenanceId | Asset Maintenance | Lookup → AssetMaintenance | | |
BranchId | Branch | Lookup → Branch | | |
CaseId | Case | Lookup → Case | | |
City | City | PickList | | Values: Mumbai, Pune, Kolkata, Delhi. |
ContactId | Contact | Lookup → Contact | | |
ContactName | Contact Name | Text | | |
CreatedById | Created By | Lookup → UserAccount | Yes | |
CreatedDateTime | Created Date | DateAndTime | Yes | |
DateTimeOpened | Date Time Opened | DateAndTime | | |
DocumentDate | Document Date | Date | | |
DocumentSeriesField | Document Series Field | Calculated (calculated) | | series |
Email | Email | Text | | |
EventTaskCount | Event Task Count | Boolean | | Activity roll-up, recomputed from Activity rows: the number of Task/Event/Meeting activities on the lead. Like IsEmailedOrCalled it is set-based and never hand-maintained. |
FirstName | First Name | Text | | |
Id | Id | Guid | Yes | |
InterestedItemId | Interested Item | Lookup → Item | | |
IsEmailedOrCalled | Is Emailed Or Call | Boolean | | Activity roll-up, recomputed (not incremented) from Activity rows: true when a Call or Email activity exists for the lead. Stays correct across activity edits and deletes; intended to be read by Business Rules that derive Status. |
ItemMaintenanceScheduleId | Item Maintenance Schedule | Lookup → ItemMaintenanceSchedule | | |
ItemServiceContractId | Item Service Contract | Lookup → ItemServiceContract | | |
LastName | Last Name | Text | | |
LeadDueDate | Lead Due Date | Date | | |
LeadRating | Lead Rating | PickList | | Values: Hot, Warm, Cold. |
LeadSource | Lead Source | PickList | | Values: Dealer, Campaign, Visit based, Web, AMC, Scheduled Maintenance, Employee Referal, Social Media. |
LeadType | Lead Type | PickList | | Values: Recall, Maintenance Schedule, Manual, Contract Schedule. |
LostReason | Lost Reason | PickList | | Values: Others. |
ModifiedById | Modified By | Lookup → UserAccount | Yes | |
Name | Document Number | Text | Yes | |
OpportunityId | Opportunity | Lookup → Opportunity | | The Opportunity created from this lead by a convert action. Doubles as the conversion guard: convert validation rejects any lead whose OpportunityId is already set ("an opportunity has already been created for this lead"). |
OwnerId | Owner | Lookup → UserAccount | Yes | |
PartnerAccountId | Partner Account | Lookup → Account | | |
PhoneNumber | Phone Number | Text | | |
PostalCode | Postal Code | Text | | Drives dealer assignment on insert: the handler resolves the code through PostalCode and BranchPostalCode rows and stamps the lead's BranchId and PartnerAccountId from the mapping. When PostalCode is present, the convert-time partner/branch mandatory validation is bypassed. |
PotentialRevenue | Potential Revenue | Currency | | |
RecordTypeId | Record Type | Guid, hidden | | |
Remarks | Remarks | Text | | |
ReminderOffsetNumber | Reminder Offset Number | Number | | |
ResourceId | Executive | Lookup → Resource | | |
ServiceCampaignBatchInstanceId | Service Campaign Batch Instance | Text | | |
ServiceCampaignId | Service Campaign | Lookup → ServiceCampaign | | |
ServiceCampaignMemberId | Service Campaign Member | Lookup → ServiceCampaignMember | | |
ServiceContractItemId | ServiceContractItem | Lookup → Item | | |
SKUId | SKU | Lookup → SKU | | |
State | State | PickList | | Values: Maharashtra. |
Status | Status | PickList | | Lifecycle picklist: New, Contacted, Nurturing, Lost, Converted. The LeadLost server action sets Lost; conversion flows set Converted. Business Rules reading the activity roll-up fields may also move it - the roll-up recompute itself never writes Status. Values: New, Contacted, Nurturing, Lost, Converted. |
UIProps | UI Props | Text | | |
UpdatedDateTime | Modified Date | DateAndTime | Yes | |
Actions
| Action | Label | Type | What it does |
BulkDelete | Delete | Delete | Delete |
Clone | Clone | ServerAction (Clone) | Create a copy of this record |
ConvertLead | Lead | ServerAction (ConvertLead) | Full lead conversion in one step: when the lead has no account it creates a new customer Account named from the lead's AccountName plus a Contact for it; when an existing account is linked but has no primary contact it creates that contact; then it always creates an Opportunity carrying the lead's account/partner/branch/asset/contract links and stamps Lead.OpportunityId. Refused when OpportunityId is already set (already converted). Record types are mapped from the lead's record type to the Opportunity equivalent. |
Delete | Delete | Delete | Delete |
DeleteInList | Delete | Delete | Delete |
Edit | Edit | Edit | Edit |
EditInLine | Edit | Edit | Edit |
EditInLine2 | Edit | EditInline | Edit |
EditRow | Edit | EditInline | Edit |
LeadLost | Lead Lost | ServerAction (LeadLost) | Lead Lost |
New | New | New | New |
NewSales | New | New | New |
PerformLeadToOpportunity | Perform Lead To Opportunity | ServerAction (PerformLeadToOpportunity) | Dialog-driven convert: arguments choose per record whether to create or reuse - CreateNewAccount/CreateNewContact/CreateNewOpportunity flags, explicit AccountId/ContactId/OpportunityId picks, AccountFields/ContactFields/OpportunityFields value arrays typed in the dialog, and an optional ConvertedStatus for the lead. ContactFields are applied for both new and existing accounts, and the created/selected account always wins over the lead's old account on the resulting Opportunity. Same preconditions as ConvertLead (no existing OpportunityId; partner/branch resolved). |
PerformReleaseOpportunity | Opportunity | ServerAction (PerformReleaseOpportunity) | Creates an Opportunity from the lead (OpportunityService.CreateOpportunityFromLead). Preconditions: the lead must not already have an OpportunityId, and PartnerAccountId + BranchId are mandatory unless the lead carries a PostalCode (which auto-resolves them). |
PerformReleaseOrder | Order | ServerAction (PerformReleaseOrder) | Creates a sales Order directly from the lead (OrderService.CreateOrderFromLead), skipping the opportunity/quote stages. PartnerAccountId and BranchId are mandatory unless PostalCode is set. |
RunMacro | Run Macro | ServerAction (RunMacro) | Runs a Macro's steps against this lead through the generic macro engine (IMacroRunner) - the same entity-agnostic RunMacro handler used on cases; no lead-specific behavior. |
testLeadConvert | Opportunity | ServerAction | convert Lead |
Validations
| Validation | Applies to | Error message | Notes |
| AccountNamerequired | AccountName, Error | Account Name is mandatory. | Account Name is mandatory. |
| Email Validation Rule | Email, Error | Enter Valid Email. | Enter Valid Email. |
| Mobile Validation Rule | PhoneNumber, Error | Enter Valid No. | Enter Valid No. |
Lookup filters
| Filter | Lookup field | Notes |
| Branch For Partner Account | BranchId | Branch For Partner Account - Service |
| Branch For Partner Account | BranchId | |
| Customer Account Filter | AccountId | |
| Customer Account Filter | AccountId | Customer Account |
| Executive Filter | ResourceId | Executive Filter |
| Executive Filter | ResourceId | |
| Partner Account Filter | PartnerAccountId | PartnerAccountFilter |
| Partner Account Filter Service | PartnerAccountId | Partner Account |