Introducing a new way to review your PRs.

Read the announcement

frappe / crm

Fully featured, open source CRM

View on GitHub

24 documents · Updated Nov 23, 2026

docs / crm-record-management

CRM record management

CRM record management is the shared model for tracking people, companies, potential work, active sales work, and scheduled customer meetings. Leads and deals carry the working relationship with a customer. Contacts and organizations provide reusable identity and company records that connect across that work. Booking pages add a public scheduling path that can create a lead or deal from a new guest. The client presents these records as searchable lists, focused detail views, and work dashboards, while the server keeps links, ownership, status, response timing, and related work consistent.

Record model

The CRM uses separate records for a person, an organization, a lead, a deal, and a scheduled booking. A lead is an early customer or opportunity record. A deal is an active sales opportunity that can point to a lead, an organization, and one or more contacts. An organization represents a company or account. A contact represents a person and can belong to an organization or appear on many deals. A booking records a meeting requested through a booking page and connects the guest, host, time, and related CRM work. Leads and deals also hold sales context such as source, products, response timing, interaction state, and ownership. crm/…/crm_lead.json• L124-247, crm/…/crm_deal.json• L93-175, crm/…/crm_booking.json• L7-166

RecordMain purposeImportant relationships
LeadHold an unconverted person or company opportunityCan name an organization and can become a deal
DealTrack an active sales opportunityLinks to a lead, one organization, and many contacts
ContactRepresent a person and their communication detailsCan belong to an organization and appear on many deals
OrganizationRepresent a company or accountGroups contacts and deals by organization
Booking pageOffer a schedulable meeting typeDefines hosts, availability, meeting rules, and the CRM record type created for a new guest
BookingRecord a scheduled or canceled meetingLinks to a booking page, host, event, and a related lead or deal

Working records keep some customer values for direct use. For example, a deal keeps the primary contact's communication details while its contact list identifies that person. A deal or lead can also keep company details that came from an organization. A booking keeps the guest's name and contact details with the meeting so the scheduled work remains usable even when it also points to a CRM record. Enrichment fills empty values without replacing information entered by a user. crm/…/crm_deal.json• L149-175, crm/…/crm_booking.json• L83-110, crm/…/cross_record.py• L79-112

References: crm/…/crm_lead.json• L124-247 crm/…/crm_deal.json• L93-243 crm/…/crm_organization.json• L26-121 crm/…/crm_booking.json• L7-166 crm/…/crm_booking_page.json• L7-227 crm/…/crm_booking_page_host.json• L7-42 crm/…/cross_record.py• L79-112

Record relationships

Relationships let the application move from a customer record to the work around it. Organization views show related deals and contacts. Contact views show related deals. Deal views show contacts and the linked organization. Booking records add a path from a scheduled meeting to its booking page, host, event, and related lead or deal. These views use record links rather than separate copies of customer records. frontend/…/Organization.vue• L156-223, frontend/…/Contact.vue• L127-177, crm/…/api.py• L5-35, crm/…/crm_booking.json• L113-137

The main relationship rules are:

The shared document service also follows direct and dynamic links when it displays related documents or prepares a deletion. It clears references before a bulk delete when the user has write access. Contact removal uses the contact fields on the linked record so that the remaining record does not point to a deleted person. crm/…/doc.py• L688-729, crm/…/doc.py• L732-805, crm/…/doc.py• L808-850

See Contacts and organizations for the person and company records and their dedicated views.

References: crm/…/crm_lead.py• L233-355 crm/…/crm_deal.py• L132-167 crm/…/api.py• L5-35 crm/…/crm_booking.json• L30-137 crm/…/crm_call_log.py• L148-156 crm/…/crm_call_log.py• L214-356 crm/…/contact.py• L9-27 crm/…/doc.py• L688-850 frontend/…/Contact.vue• L145-177 frontend/…/Organization.vue• L173-223 frontend/…/Organization.vue• L490-503

Record creation and conversion

The creation flow starts with a lead, a deal, a related contact or organization, or a booking page. New leads and deals receive a default open status when none is supplied. A lead needs a person's name, an organization name, or an email to establish its display identity. A deal can reuse or create the organization and contact supplied by its entry data. A booking page can choose whether a booking for a new person creates a lead or a deal, and can pass a configured source into that record. Contact and organization detail pages also start deal creation with the current customer context. crm/…/crm_lead.py• L123-156, crm/…/crm_deal.py• L125-130, crm/…/crm_deal.py• L484-520, crm/…/crm_booking_page.json• L164-203, frontend/…/Contact.vue• L299-315, frontend/…/Organization.vue• L21-26

Booking pages turn availability into a customer entry point. Each page has a public route, meeting duration, location, one or more hosts, weekly hours, time-zone and holiday rules, slot limits, and booking notice limits. The page can show a confirmation message, send a guest reminder, and restrict which sites can embed it. Multiple hosts let bookings move to a free host in turn. crm/…/crm_booking_page.json• L40-161, crm/…/crm_booking_page.json• L205-226, crm/…/crm_booking_page_host.json• L11-27

Lead conversion turns an early record into a deal while preserving customer context. The process locks the lead before it checks conversion state. It then marks the lead as converted, moves it to the qualified state when that state exists, reuses or creates the contact and organization, and links the new deal back to the source lead. The deal inherits compatible lead data, including matching custom fields, and keeps the lead's response information when it exists. Assigned users also carry over to the new deal. A caller can choose to create another deal, return the existing deal, or fail when the lead was already converted. A lost lead cannot be converted. crm/…/crm_lead.py• L357-439, crm/…/crm_lead.py• L548-609

Calls provide another entry into lead creation. The call flow checks access to both the call and the lead record type, copies safe lead fields, uses the call number when no mobile number is supplied, and links the new lead back to the call. crm/…/crm_call_log.py• L246-356

When a lead links to an existing organization, company enrichment fills empty lead fields while preserving values entered by the user. This keeps the shared organization data useful without changing the meaning of the lead's own data. crm/…/crm_lead.py• L270-322

The relationship flow is summarized below.

flowchart LR
    Input[Lead, deal, contact, organization, booking, or call] --> Match[Match contact and organization]
    Match --> Reuse[Reuse existing records]
    Match --> Create[Create missing records]
    Reuse --> Link[Link customer records]
    Create --> Link
    Booking[Booking page] --> Meeting[Schedule meeting]
    Meeting --> CRM[Create or link lead or deal]
    Link --> Work[Create or update deal]
    Lead[Lead] -->|Convert| Work
    CRM --> Context[Customer context and sales work]
    Work --> Context

See Lead and deal lifecycle for status progression and conversion behavior.

References: crm/…/crm_lead.py• L123-156 crm/…/crm_lead.py• L233-322 crm/…/crm_lead.py• L357-439 crm/…/crm_lead.py• L548-609 crm/…/crm_deal.py• L484-520 crm/…/crm_booking_page.json• L40-226 crm/…/crm_booking_page_host.json• L11-27 crm/…/crm_call_log.py• L246-356 frontend/…/Contact.vue• L299-315 frontend/…/Organization.vue• L21-26

Record display and update

The client gives each record type a list view and a detail view. Leads and deals support list, grouped, and kanban views. The shared document service supplies rows, columns, filters, counts, and view metadata for these surfaces. Saved view settings and record-specific defaults can shape the same list contract without changing the record model. crm/…/doc.py• L257-371, crm/…/doc.py• L373-545, frontend/…/Leads.vue• L1-43, frontend/…/Deals.vue• L1-43

Users can save list, grouped, and kanban choices as private or public views. A view can define filters, sort order, grouping, visible columns, row fields, and kanban fields. The system keeps one default view per user and record type. Standard record defaults are merged into saved rows so required business columns do not disappear when a user customizes a view. crm/…/crm_view_settings.py• L46-84, crm/…/crm_view_settings.py• L87-162, crm/…/crm_view_settings.py• L169-197, crm/…/crm_view_settings.py• L201-288

List metadata also controls which fields appear in a record list. Framework-hidden fields are left out of a custom or saved view, while a record type's own default list may explicitly keep one of those fields visible. This lets a record-specific list contract override the general hidden-field rule without exposing hidden fields in other views. crm/…/doc.py• L299-359

Detail pages load the record, show editable fields in a side panel, and expose related customer data beside the record. Configured layouts can organize quick-entry, side-panel, data, grid-row, and required fields. The layout service removes fields that do not exist and marks fields read-only or hidden when the user's field permission does not allow the matching action. crm/…/crm_fields_layout.py• L29-109, crm/…/crm_fields_layout.py• L112-191

Contact and organization pages make their relationships actionable. A contact page shows linked deals and can open a prefilled new deal. An organization page shows both deals and contacts, can open a deal for that organization, and can attach or create a contact. Organization enrichment reloads the record and its side-panel fields after it completes. frontend/…/Contact.vue• L145-177, frontend/…/Contact.vue• L299-315, frontend/…/Organization.vue• L15-51, frontend/…/Organization.vue• L173-223, frontend/…/Organization.vue• L305-308

Lead and deal pages use the same work surface for status, owner, customer details, and activity. The activity area separates emails, comments, calls, tasks, notes, attachments, WhatsApp messages, and data fields. Users can create the related work from the active tab, while live document and message events refresh the record view. Call details can show permitted linked tasks, notes, leads, and deals. frontend/…/Activities.vue• L1-13, frontend/…/Activities.vue• L382-441, frontend/…/Activities.vue• L538-611, frontend/…/ActivityHeader.vue• L1-71, frontend/…/AllModals.vue• L18-110, crm/…/crm_call_log.py• L246-294

Tasks are the main dated follow-up attached to a lead or deal. A task can also stand alone. Open linked tasks drive follow-up views, while completed and canceled tasks stop being treated as active follow-ups. Timed tasks use the user's time zone. All-day tasks use their stored day, so their due and overdue state does not shift with time zone conversion. crm/…/crm_task.json• L10-106, crm/…/rules.py• L13-31, crm/…/rules.py• L42-108

Field changes and status changes use the save path, so server rules apply to both direct edits and client actions. Table fields also support row creation, editing, deletion, and reordering while carrying field permissions into each row. frontend/…/Field.vue• L21-53, frontend/…/Field.vue• L535-595, frontend/…/Grid.vue• L65-83, frontend/…/Grid.vue• L696-750

The server applies shared rules when records are saved. It records status changes, assigns or shares the owner, validates lost reasons, applies service-level timing, and updates values that depend on the selected organization or primary contact. This keeps direct edits and client actions subject to the same record rules. crm/…/crm_lead.py• L91-121, crm/…/crm_deal.py• L90-123

Task reminders turn an upcoming linked follow-up into a record notification. They skip all-day tasks, avoid repeat reminders for the same due time, and point the user back to both the task and its lead or deal. crm/…/reminders.py• L22-77, crm/…/crm_notification.py• L63-86

See Record productivity workflows for the work surfaces attached to records, such as tasks, notes, communication, files, and assignment.

References: crm/…/doc.py• L257-545 crm/…/doc.py• L299-359 crm/…/crm_view_settings.py• L46-162 crm/…/crm_view_settings.py• L169-197 crm/…/crm_view_settings.py• L201-305 crm/…/crm_fields_layout.py• L29-191 crm/…/rules.py• L13-108 crm/…/reminders.py• L22-77 crm/…/crm_notification.py• L63-86 frontend/…/Contact.vue• L145-177 frontend/…/Contact.vue• L299-315 frontend/…/Organization.vue• L15-51 frontend/…/Organization.vue• L173-223 frontend/…/Organization.vue• L305-308 frontend/…/Lead.vue• L50-67 frontend/…/Lead.vue• L482-548 frontend/…/Deal.vue• L45-63 frontend/…/Activities.vue• L538-611 crm/…/crm_call_log.py• L246-294 frontend/…/Field.vue• L535-595 frontend/…/Grid.vue• L590-750 crm/…/crm_lead.py• L91-121 crm/…/crm_deal.py• L90-123

CRM home dashboard

The CRM home dashboard turns shared records and follow-up data into a daily work view. It separates the user's own work from the team's work and shows the records that need a reply, a next step, or assignment. Managers also get workload, response, overdue follow-up, and unassigned-record views. crm/…/brief.py• L302-432, crm/…/home_widgets.py• L63-101, crm/…/team_widgets.py• L45-107

The dashboard respects CRM visibility and assignment rules. The personal view uses owned records and open assignments. The team view uses the user's sales hierarchy or the full sales team when the user has broad access. This keeps counts and links aligned with what the user can work on. crm/…/home_scope.py• L14-53

Users can choose whether the home view shows leads, deals, or both. They can also arrange permitted widgets and set period or shared-field filters. Manager-only widgets stay unavailable to other roles. crm/…/home_layout.py• L21-46, crm/…/home_layout.py• L133-220

The dashboard connects record state to action in one path:

flowchart LR
    Records[Leads and deals] --> Signals[Replies, tasks, assignments, and activity]
    Signals --> Scope[Personal or team scope]
    Scope --> Brief[Work brief]
    Scope --> Cards[Sales and workload cards]
    Brief --> Lists[Filtered record or task lists]
    Cards --> Lists

Recent activity combines views, communication, comments, notes, tasks, calls, messages, assignments, and updates into one latest-action row per readable record. Reply channels use the latest inbound email or WhatsApp message, and a deal also considers its source lead. crm/…/recent_activity.py• L31-80, crm/…/reply_channel.py• L4-35

References: crm/…/brief.py• L302-432 crm/…/home_widgets.py• L63-101 crm/…/home_scope.py• L14-67 crm/…/home_layout.py• L21-220 crm/…/recent_activity.py• L31-129 crm/…/reply_channel.py• L4-76 crm/…/team_widgets.py• L45-107

Sales views and CRM analytics

Sales views summarize the same lead and deal records for planning and review. Home cards show funnel movement, won value, expected revenue, and top open deals. They use the user's ownership scope and express monetary values in the CRM base currency. Forecast cards are available only when forecasting is enabled. crm/…/sales_widgets.py• L24-54, crm/…/sales_widgets.py• L57-154

The CRM Insights workbook provides shared reporting views for lead volume, deal stages, sources, territories, sales users, funnel conversion, sales trends, won deals, and forecasted revenue. Its queries join records to status, owner, and status-change history so reports use the same sales meaning as the record screens. crm/…/crm.json• L1-665, crm/…/crm.json• L1268-1803

References: crm/…/sales_widgets.py• L24-174 crm/…/crm.json• L1-665 crm/…/crm.json• L1268-1803

Shared CRM settings

CRM settings shape how users create, edit, view, and measure shared records. Forecasting is optional. When enabled, deal forms require an expected deal value and expected closure date, and the home and reporting views can show forecast measures. When disabled, those fields are not required and the forecast section is removed from the main deal layouts. crm/…/fcrm_settings.json• L85-97, crm/…/fcrm_settings.py• L74-187, crm/…/crm_deal.py• L275-283

The CRM base currency becomes read-only after it is set. This keeps monetary values on leads and deals tied to one stable reporting currency. Deal exchange rates convert deal values into that base for sales cards and analytics. crm/…/fcrm_settings.py• L107-115, crm/…/crm_deal.json• L409-448, crm/…/crm.json• L1377-1384

Sales hierarchy permissions can limit lead and deal visibility to a manager's reports. Communication settings control whether new messages update record time, mark a record as replied, or reopen its communication state. The morning digest setting enables a daily summary of follow-ups, replies, assignments, and tasks. crm/…/fcrm_settings.json• L91-103, crm/…/fcrm_settings.json• L178-203

References: crm/…/fcrm_settings.json• L85-110 crm/…/fcrm_settings.json• L178-203 crm/…/fcrm_settings.py• L74-187 crm/…/crm_deal.py• L275-304 crm/…/crm_deal.json• L409-448 crm/…/crm.json• L1377-1486

Shared status and ownership

Lead and deal statuses are configurable records with a name, type, position, and display color. Deal statuses can also define a probability used for forecasting. Each working record keeps a status-change log with the old and new status, dates, duration, and owner. crm/…/crm_lead_status.json• L8-46, crm/…/crm_deal_status.json• L8-51, crm/…/crm_status_change_log.json• L8-78

Status type gives the workflow its broad meaning. Open, ongoing, and on-hold states keep work active. Won and lost states close the business path. Lost states require a reason. An Other reason also requires a note. A won deal receives a closed date. crm/…/crm_lead.py• L176-186, crm/…/crm_deal.py• L285-305

Ownership is part of the record context. A lead owner or deal owner is assigned to the record. Changing the owner updates sharing and assignment so the responsible user can work on it. CRM invitations create or update users with CRM roles, add inherited sales roles where needed, and give sales users the CRM app as their default access. A pending invitation uses a single-use key. An existing user must sign in before an invitation can be accepted unless that user already owns the session. crm/…/crm_lead.py• L103-118, crm/…/crm_deal.py• L98-120, crm/…/crm_invitation.py• L29-123, crm/…/__init__.py• L102-130

Record notifications carry a sender, recipient, type, message, and optional dynamic reference. This lets assignments, mentions, automation, WhatsApp events, replies, and task reminders point back to the record that needs attention. Updates publish a real-time event for the recipient. crm/…/crm_notification.json• L25-110, crm/…/crm_notification.py• L32-86

References: crm/…/crm_lead_status.json• L25-46 crm/…/crm_deal_status.json• L26-51 crm/…/crm_status_change_log.json• L20-78 crm/…/crm_lead.py• L103-118 crm/…/crm_deal.py• L98-120 crm/…/crm_invitation.py• L29-143 crm/…/__init__.py• L102-130 crm/…/crm_notification.json• L25-110 crm/…/crm_notification.py• L32-86

Application navigation

The application navigation gives users one entry point to the shared CRM records and their related work. It exposes the main record areas, saved views, search, notifications, settings, and help so users can move from a record list to the work attached to that record. frontend/…/AppSidebar.vue• L24-35, frontend/…/AppSidebar.vue• L66-113, frontend/…/AppSidebar.vue• L144-182

Saved and pinned views appear beside the standard record areas. Selecting a view preserves its record type, view mode, and saved filters, while the active item follows the current route. The same navigation works in the mobile drawer, where selecting a route also closes the drawer. frontend/…/AppSidebar.vue• L275-375

The sidebar also connects onboarding to the CRM record flow. It can guide a user from creating a first lead to converting that lead into a deal and then scheduling a follow-up task. Manager-only steps can guide email setup and team invitations. frontend/…/AppSidebar.vue• L506-594

References: frontend/…/AppSidebar.vue• L24-35 frontend/…/AppSidebar.vue• L66-113 frontend/…/AppSidebar.vue• L144-182 frontend/…/AppSidebar.vue• L275-375 frontend/…/AppSidebar.vue• L506-594

Change checklist

When these files or sections are changed, remember to consider these:

  • Changes to the booking page record type must stay aligned across its public route, host list, availability rules, slot limits, booking notice rules, form record type, source field, confirmation message, reminder choice, and embedding restrictions.
  • Changes to booking creation must preserve the link from a booking to its page, host, event, and dynamic lead or deal reference. Keep guest details available when the linked CRM record is created or updated.
  • Changes to booking hosts must preserve the required user link and the host name shown in the editable host list.
  • Changes to the primary contact rule must stay aligned across the deal contact table, copied deal contact fields, the read-permission check in the deal contact API, contact update hooks, and contact-related views.
  • Changes to contact or organization detail actions must preserve the defaults passed into new deal and contact forms, the link used to attach an existing contact, and the reload of related lists.
  • Changes to lead conversion must preserve lead locking, already-converted behavior, the reuse rules for contacts and organizations, the link from the new deal back to the source lead, custom-field mapping, response data, and assignee transfer.
  • Changes to organization links must preserve fill-empty enrichment behavior and must not replace user-entered lead or deal data.
  • Changes to status types or names must stay aligned with lost-reason validation, won-date behavior, status logs, list filters, kanban columns, dashboard active-record rules, and analytics stage queries.
  • Changes to record reference fields must preserve dynamic links used by tasks, notes, calls, bookings, and notifications and the cleanup behavior used by bulk deletion.
  • Changes to call-log lead creation must preserve call-log write permission, lead-create permission, safe lead-field filtering, phone transfer, and the new lead link.
  • Changes to forecasting settings must stay aligned with deal field requirements, deal layouts, home sales widgets, and forecast analytics.
  • Changes to list metadata must preserve the shared contract between filters, saved views, grouped or kanban data, default list columns, hidden-field handling, and detail-page links.
  • Changes to field layouts must preserve permission-based visibility, required-field coverage, side-panel sections, and the field controls used by normal forms and grid rows.
  • Changes to activity tabs or related work creation must preserve the reference to the current record and the live refresh path for document, communication, and WhatsApp events.
  • Changes to task due rules must stay aligned across linked-task filters, user time-zone handling, dashboard cards, morning summaries, and reminder selection.
  • Changes to notifications must preserve recipient-only access, dynamic links back to the task and source record, duplicate suppression, and real-time refresh.
  • Changes to invitations must keep role inheritance, CRM app access, role-profile checks, guest key acceptance, sign-in redirects for existing users, one-time key use, and expiry behavior aligned with user creation and ownership rules.
  • Changes to dashboard scope or widget settings must preserve the match between personal and team visibility, role limits, filters shared by lead and deal views, and links that open the counted records.
  • Changes to the sidebar navigation must keep standard routes, saved-view route parameters, active-item tracking, and mobile drawer behavior aligned.
  • Changes to onboarding steps must keep step dependencies, role conditions, stored progress reconciliation, and the lead-to-deal-to-task path aligned.

Important failure modes

TriggerConsequenceGuard
A booking page has a duplicate routeThe public page cannot have a unique routeThe route field is required and unique. crm/…/crm_booking_page.json• L48-55
A booking page has no host or weekly availabilityThe page has no valid owner or bookable scheduleHosts and weekly hours are required table fields. crm/…/crm_booking_page.json• L98-126
A booking has no booking page, host, time, guest name, or guest emailThe meeting record is incompleteThe booking schema requires each of these core fields. crm/…/crm_booking.json• L30-45, crm/…/crm_booking.json• L61-95
A canceled booking does not provide its reasonThe cancellation context is missing from the recordThe cancel-reason field is shown when status is Cancelled. crm/…/crm_booking.json• L48-55, crm/…/crm_booking.json• L162-166
A booking page selects a new-person record type without preserving its source settingThe created lead or deal can lose its configured originThe page ties the source field to the create-record setting. crm/…/crm_booking_page.json• L191-203
A deal has more than one primary contactThe deal cannot saveThe deal validates that at most one contact is primary. crm/…/crm_deal.py• L145-153
A deal has no primary contactDeal email, mobile, and phone fields are clearedThe deal derives these fields only from the primary contact. crm/…/crm_deal.py• L145-167
A user requests contacts for a deal without read accessThe contact list is rejectedThe deal contact API checks read permission before it loads linked contacts. crm/…/api.py• L5-10
A lead or deal enters a lost status without the required reasonThe save failsLost status validation requires a reason and requires notes when the reason is Other. crm/…/crm_lead.py• L176-186, crm/…/crm_deal.py• L285-293
A lead is created without a person, organization, or emailThe lead has no valid display identityLead validation rejects the record unless one of those identity sources exists. crm/…/crm_lead.py• L143-153
A lost lead is sent through conversionNo deal is createdConversion checks the lead status before it creates linked records. crm/…/crm_lead.py• L563-576
Two conversion requests arrive for the same leadThe requests can create conflicting deal stateConversion locks the lead and supports an explicit already-converted outcome. crm/…/crm_lead.py• L563-600
A call-log user lacks write access or lead-create accessLead creation from the call is rejectedThe call-log flow checks both permissions before it creates and links the lead. crm/…/crm_call_log.py• L320-326
A contact update changes the primary email or phoneLinked primary-deal contact fields can become stale if the update hook is bypassedContact updates synchronize primary contact details to linked deals. crm/…/contact.py• L5-27
Forecasting is enabled without an expected value or closure dateA deal cannot saveSettings make both fields required when forecasting is enabled. crm/…/crm_deal.py• L275-283
A linked record cannot be written during link cleanupThe source record can be deleted while a reference remainsLinked-document cleanup checks write permission before clearing or deleting a reference. crm/…/doc.py• L781-805
A dynamic link points to a missing or invalid documentThe related item is not shownRelated-document lookup skips missing or invalid targets. crm/…/doc.py• L688-710
A custom or saved list view requests a framework-hidden field without declaring it in the record type's default listThe field is removed from the displayed columnsThe list service keeps hidden fields only when the record's default list explicitly includes the field. crm/…/doc.py• L299-359
A layout includes a field outside the user's read or write permissionThe field is hidden or read-only in the record formThe layout service applies field permission levels before returning the layout. crm/…/crm_fields_layout.py• L149-176
A private view is edited by a user who does not own itThe view change is rejectedView permissions allow the owner, a System Manager, or an authorized manager for public views. crm/…/crm_view_settings.py• L151-162
An all-day task is evaluated as a timed taskThe task can appear due or overdue on the wrong dayTask rules compare all-day tasks by the user's calendar day and timed tasks by their instant. crm/…/rules.py• L49-80
A task is rescheduled to the same assigneeThe old reminder state suppresses the new reminderReminder selection compares the stored reminder time with the current due time. crm/…/reminders.py• L44-52
A reminder is created for a task whose source record cannot be readThe notification can point to a record the user cannot openRecord dashboard and list queries apply read access, and notification delivery is limited to its recipient. crm/…/crm_notification.py• L37-60, crm/…/recent_activity.py• L110-129
A non-manager requests team dashboard dataThe team view is rejectedThe brief checks the user's manager role before building the team view. crm/…/brief.py• L578-597
A dashboard filter names a field not shared by all selected record typesThe dashboard configuration is rejectedWidget validation checks every selected doctype before accepting the filter. crm/…/home_widgets.py• L26-35, crm/…/home_layout.py• L179-202
A dashboard includes a manager-only widget for an agentThe layout cannot be saved or the widget is removedLayout validation and display both filter widgets by role. crm/…/home_layout.py• L133-158
Forecast analytics run while forecasting is disabledThe home forecast card has no forecast valueThe sales widget reports forecasting as disabled and settings remove the required deal fields. crm/…/sales_widgets.py• L86-101, crm/…/fcrm_settings.py• L74-105
An invitation is reused after acceptance or remains pending beyond three daysThe account is not created or the invitation becomes invalidAcceptance requires Pending status, clears the key after acceptance, and expiry changes old pending invitations to Expired. crm/…/crm_invitation.py• L71-91, crm/…/crm_invitation.py• L134-145
An invitation for an existing user is opened by a different sessionThe user is sent to sign in and the invitation remains pendingThe public acceptance route redirects to login before accepting an existing user's invitation. crm/…/__init__.py• L108-119
An existing invitee has a role profileThe invitation cannot safely apply CRM rolesInvitation validation rejects users whose roles are managed by a role profile. crm/…/crm_invitation.py• L105-108, crm/…/user.py• L246-258
A view default is set without scoping the cleanup to the user's record typeA default for another record type can be clearedDefault-view updates clear only the current user's other default for the same doctype. crm/…/crm_view_settings.py• L201-215
A saved view route loses its view name or view typeThe user opens the wrong list state or loses the saved view selectionNavigation passes the saved view name, record route, and view type together. frontend/…/AppSidebar.vue• L307-319
Onboarding adds a step without reconciling saved progressExisting users can miss the step or the checklist can show the wrong completion stateSidebar startup merges current steps with stored progress and keeps valid hidden steps. frontend/…/AppSidebar.vue• L415-478, frontend/…/AppSidebar.vue• L596-613

Key files

FileWhy to read it
crm/…/crm_lead.pyLead identity, matching, enrichment, conversion, assignment, and save rules
crm/…/crm_deal.pyDeal relationships, primary contact behavior, forecasting, and save rules
crm/…/api.pyPermission-aware deal contact retrieval
crm/…/crm_lead.json and crm/…/crm_deal.jsonThe shared lead and deal record shapes, links, status fields, response fields, and forecast fields
crm/…/crm_booking_page.jsonBooking entry points, availability, hosts, meeting rules, and lead or deal creation settings
crm/…/crm_booking.jsonScheduled meeting identity, guest data, event link, and lead or deal reference
crm/…/crm_booking_page_host.jsonThe host relationship used by booking pages
crm/…/test_crm_lead.pyThe tested lead creation and conversion contract
crm/…/crm_call_log.pyCall links, permission-aware related records, recordings, and lead creation from calls
crm/…/test_crm_call_log.pyThe call-log linking, permission, recording, and lead-creation contract
crm/…/crm_invitation.pyCRM user invitation, role assignment, acceptance, single-use keys, and expiry
crm/…/test_crm_invitation.pyThe invitation contract for roles, key use, existing-user sign-in, new-user setup, and expiry
crm/…/__init__.pyThe public invitation route and its login or password setup redirects
crm/…/crm_notification.py and crm/…/crm_notification.jsonRecipient access, notification types, dynamic record references, and real-time updates
crm/…/crm_task.py, crm/…/rules.py, and crm/…/reminders.pyFollow-up links, assignment, due-date meaning, time zones, and reminders
crm/…/fcrm_settings.py and crm/…/fcrm_settings.jsonSettings that change forecasting, currency, visibility, communication, and digests
crm/…/home_scope.py and crm/…/home_widgets.pyRecord scope and shared work widgets for the CRM home view
crm/…/brief.py and crm/…/team_widgets.pyPersonal and team work summaries, workload, replies, and overdue follow-ups
crm/…/home_layout.pyDashboard roles, widget settings, filters, and layout rules
crm/…/recent_activity.py and crm/…/reply_channel.pyRecent record activity and the channel of the latest inbound reply
crm/…/sales_widgets.pyHome sales cards, ownership scope, currency, and forecast behavior
crm/…/crm.jsonShared lead, deal, funnel, sales trend, and forecast analytics
crm/…/crm_organization.jsonOrganization identity, company data, and enrichment fields
crm/…/crm_contacts.jsonDeal-to-contact child relationship and primary-contact fields
crm/…/contact.pyContact-to-deal synchronization and linked-deal lookup
crm/…/doc.pyShared list views, list metadata and hidden-field handling, filters, linked-document lookup, assignments, and bulk link cleanup
crm/…/crm_fields_layout.pyConfigurable record layouts and permission-aware field display
crm/…/crm_view_settings.pySaved, public, pinned, and default record views
crm/…/cross_record.pyOrganization-to-lead or deal company-data propagation
frontend/…/Organization.vueOrganization detail view, related deal and contact display, and relationship actions
frontend/…/Contact.vueContact detail view, related deals, and prefilled deal creation
frontend/…/Lead.vueLead detail view, status control, conversion entry point, and activity surface
frontend/…/Deal.vueDeal detail view, organization context, contact management, and activity surface
frontend/…/Leads.vue and frontend/…/Deals.vueShared list and kanban entry points for working records
frontend/…/Activities.vueRecord activity tabs, timeline data, live refresh, and related work surfaces
frontend/…/ActivityHeader.vue and frontend/…/AllModals.vueActions that create emails, comments, calls, notes, and tasks from a record
frontend/…/Field.vue and frontend/…/Grid.vueRecord field editing and table-row behavior
frontend/…/AppSidebar.vueMain CRM navigation, saved and pinned view entry points, notifications, help, and onboarding links
crm/…/crm_lead_status.json and crm/…/crm_deal_status.jsonStatus types and the values that shape record workflows