Advance Plan

Module: Layaway / EMA Plans

1. Overview

The Advance Plan form allows administrators to configure ADP (Advance Deposit Plan) schemes for the Layaway / EMA module. It defines the plan type, structure, installment rules, collection window, commission settings, early closure conditions, and channel access controls. The plan configuration drives enrollment, collection, and closure transactions for customers.

AttributeValue
Form NameAdvance Plan
ModuleLayaway / EMA Plans
Form TypeMaster Configuration
Primary TableemaADPPlanHDR
Approval WorkflowYes
Multi-Location SupportNo
Soft DeleteYes – Active flag on HDR

2. Database

Database: SioniqAdminDB

3. Primary Tables

Table NameTypeDescription
emaADPPlanHDRHDRStores all header-level plan configuration: plan type, name, structure type, maturity, commission, enrollment limits, and approval status.
emaADPPlanRuleDTLDTLStores collection window rule per plan: window type, from/to days, cutoff period, missed installment limits, and partial collection flags.
emaADPPlanInstallmentDTLDTLStores one row per installment term. Holds installment number, term name, discount/commission values, channel blocking flags, and FK to the installment rule.
emaADPPlanInstallmentRuleDTLDTLStores the installment rule type (Fixed Selection, Ranged, Predefined Term Amount, Progressive Term Formula, Fully Flexible, Flexible with Limits, Advanced Formula) for each installment.
emaADPPlanInstallmentRuleValueDTLDTLStores the value parameters for each installment rule: installment amount, starting/ending amount, multiple-with, progression type, calculation type, progression value, and formula expressions.
emaADPPlanInstallmentRuleValueFormulaDTLDTLStores formula components for Advanced Formula rule type: component type, installment reference or static value, operator, and sort order.
emaADPPlanEarlyClosureConditionDTLDTLStores early closure eligibility conditions: closure basis, comparison operator, value, connector, and sort order.
emaADPPlanChannelAccessDTLDTLStores channel access control rows per action type (Enrollment, Collection, Closing) with online/offline block flags.

Table Relationship Diagram

emaADPPlanHDR PK: ADPPlanID emaADPPlanRuleDTL FK: ADPPlanID emaADPPlanChannelAccessDTL FK: ADPPlanID emaADPPlanEarlyClosureConditionDTL FK: ADPPlanID emaADPPlanInstallmentDTL FK: ADPPlanID | PK: ADPPlanInstallmentID emaADPPlanInstallmentRuleDTL FK: ADPPlanInstallmentID | PK: ADPPlanInstallmentRuleID emaADPPlanInstallmentRuleValueDTL FK: ADPPlanInstallmentRuleID | PK: RuleValueID emaADPPlanInstallmentRuleValueFormulaDTL FK: ADPPlanInstallmentRuleValueID admMasterDataValueDTL Reference / Lookup HDR Table DTL (linked to HDR) Rule Chain DTL Value Chain DTL Reference/Lookup FK Relationship Lookup Ref

Transaction Flow Diagram

START – User clicks Save Validate HDR fields Validation error? No Yes Show error / Stop Insert emaADPPlanHDR Insert emaADPPlanRuleDTL Early closure enabled? No Yes Insert EarlyClosureDTL Insert ChannelAccessDTL Insert InstallmentDTL Insert InstallmentRuleDTL Insert RuleValueDTL Rule = Advanced Formula? No Yes Insert FormulaDTL Set ApprovalStatus = Pending END – Record Saved Legend: Start / End Decision HDR / Status DTL insert Rule chain Value chain Error Main flow Error branch (Yes) Optional branch & rejoin

4. Reference / Lookup Tables

The following reference tables are used by the Advance Plan form, derived from FK references in the ER structure and dropdown fields in the UI design.

Table NameUsed For
admMasterDataValueDTLAll single-selection dropdowns: Plan Type, Customer Deposit Type, Plan Structure Type, Maturity Payout Calculation Method, Collection Window Type, Installment Rule Type, Installment Progression Type, Calculation Type, Operator, Commission Trigger Event, Enrollment Limit, Action Type, Closure Eligibility Basis, Comparison Operator, Comparison Connector, Formula Component Type, Approval Status
From_MasterDataValueID_Day (via admMasterDataValueDTL)From Day dropdown in Collection Window Rule (day values 1–30)
To_MasterDataValueID_Day (via admMasterDataValueDTL)To Day dropdown in Collection Window Rule (day values 1–30)

5. Form Controls & Functionalities

5.1 Header Level Fields

Active  (Toggle)

Description:

Controls the active/inactive status of the Advance Plan record.

Control Properties:
  • Default Value: Checked (True)
  • User Entry: User can Toggle On/Off
  • Mandatory: No
Behavior:
  • Toggled On (True): Record is Active and available for use in enrollment and collection transactions.
  • Toggled Off (False): Record is Inactive and no longer available for new transactions.
  • Not restricted by Roles and Rights Configuration — available to all users.
Saved in & as:
  • emaADPPlanHDR → Active (bit)

Plan Type  (Single Selection Dropdown)

Description:

Defines the category of the Advance Plan.

Control Properties:
  • Default Value: —
  • Data Source: admMasterDataValueDTL
  • Filter Condition:
    • Active = True, listed from MasterDataValueID
    • MasterDataCategory = ADPPlanType
  • User Entry: Selection from dropdown
  • Mandatory: Yes
  • Options:
    • Value-Based Plan — Plan where installment amounts are defined in monetary value.
    • Weight-Based Plan — Plan where installment contributions are defined by metal weight.
    • Customer Deposit Plan — Plan where the customer makes a deposit against a purchase commitment.
Behavior:
  • If Customer Deposit Plan → Customer Deposit Type field becomes visible and mandatory.
  • If Customer Deposit Plan → Plan Structure Type is forced to "Installment-Based" and Total No. of Installments is forced to 1.
  • If Value-Based Plan or Weight-Based Plan and Plan Structure Type = Open Contribution → Installment Rule Type is restricted to "Fully Flexible" or "Flexible with Limits".
Saved in & as:
  • emaADPPlanHDR → MasterDataValueID_ADPPlanType

Name  (Textbox)

Description:

Full name of the Advance Plan.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input by user
  • Mandatory: Yes
  • Allowed Characters: Alphanumeric
Saved in & as:
  • emaADPPlanHDR → Name (nvarchar(max))

Short Name  (Textbox)

Description:

Abbreviated name used for display in grids and reports.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input by user
  • Mandatory: Yes
  • Allowed Characters: Alphanumeric
Saved in & as:
  • emaADPPlanHDR → ShortName (nvarchar(max))

Customer Deposit Type  (Single Selection Dropdown)

Description:

Specifies the type of customer deposit for Customer Deposit Plan.

Control Properties:
  • Default Value: —
  • Data Source: admMasterDataValueDTL
  • Filter Condition:
    • Active = True, listed from MasterDataValueID
    • MasterDataCategory = ADPPlanCustomerDepositType
  • User Entry: Selection from dropdown
  • Mandatory: Yes (when Plan Type = Customer Deposit Plan)
  • Options:
    • Metal Deposit — Customer deposits in metal weight units.
    • Amount Deposit — Customer deposits in monetary amount.
Behavior:
  • Visible only when Plan Type = Customer Deposit Plan.
  • If Metal Deposit → Rate Fixing Allowed and Partial Rate Fixing Allowed checkboxes become enabled for selection.
Saved in & as:
  • emaADPPlanHDR → MasterDataValueID_ADPPlanCustomerDepositType

Rotation No  (Textbox)

Description:

Rotation number identifier for the plan.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input by user
  • Mandatory: No (Confirm with team)
  • Allowed Characters: Alphanumeric
Saved in & as:
  • emaADPPlanHDR → RotationNo (int)

Plan Structure Type  (Single Selection Dropdown)

Description:

Defines whether the plan is installment-based with fixed terms or allows open contributions.

Control Properties:
  • Default Value: —
  • Data Source: admMasterDataValueDTL
  • Filter Condition:
    • Active = True, listed from MasterDataValueID
    • MasterDataCategory = ADPPlanStructureType
  • User Entry: Selection from dropdown
  • Mandatory: Yes
  • Options:
    • Installment-Based — Plan has a fixed number of installment terms.
    • Open Contribution — Plan allows flexible, unscheduled contributions.
Behavior:
  • If Customer Deposit Plan → forced to "Installment-Based" (read-only).
  • If Open Contribution → Total No. of Installments field is disabled.
  • If Open Contribution and Plan Type = Value-Based or Weight-Based → Installment Rule Type restricted to "Fully Flexible" or "Flexible with Limits".
Saved in & as:
  • emaADPPlanHDR → MasterDataValueID_ADPPlanStructureType

Total No. of Installments  (Textbox)

Description:

Specifies the total number of installment terms in the plan.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input by user
  • Mandatory: Yes (when Plan Structure Type = Installment-Based)
  • Allowed Characters: Numeric (integer)
Behavior:
  • Disabled when Plan Structure Type = Open Contribution.
  • If Customer Deposit Plan → forced to 1 (read-only).
  • Drives the number of installment rows generated in the Installment Setup section.
Saved in & as:
  • emaADPPlanHDR → TotalInstallmentCount (int)

Maturity Period (Days)  (Textbox)

Description:

Defines the maturity duration of the plan in number of days.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input by user
  • Mandatory: Yes
  • Allowed Characters: Numeric (integer)
Saved in & as:
  • emaADPPlanHDR → MaturityPeriodInDays (int)

Lucky Draw Applicable  (Checkbox)

Description:

Indicates whether the plan is eligible for lucky draw participation.

Control Properties:
  • Default Value: Unchecked (False)
  • User Entry: User can Check/Uncheck
  • Mandatory: No
Saved in & as:
  • emaADPPlanHDR → IsLuckyDrawApplicable (bit)

Enrollment Gift Applicable  (Checkbox)

Description:

Indicates whether an enrollment gift is offered under this plan.

Control Properties:
  • Default Value: Unchecked (False)
  • User Entry: User can Check/Uncheck
  • Mandatory: No
Saved in & as:
  • emaADPPlanHDR → HasEnrollmentGift (bit)

Allow Maturity Payout  (Checkbox)

Description:

Enables maturity payout for the plan on completion.

Control Properties:
  • Default Value: Unchecked (False)
  • User Entry: User can Check/Uncheck
  • Mandatory: No
Behavior:
  • Checked (True): Maturity Payout Calculation Method field becomes visible and mandatory.
  • Unchecked (False): Maturity Payout Calculation Method is hidden.
Saved in & as:
  • emaADPPlanHDR → AllowMaturityPayout (bit)

Maturity Payout Calculation Method  (Single Selection Dropdown)

Description:

Specifies how the maturity payout amount is calculated when the plan matures.

Control Properties:
  • Default Value: —
  • Data Source: admMasterDataValueDTL
  • Filter Condition:
    • Active = True, listed from MasterDataValueID
    • MasterDataCategory = MaturityPayoutCalculationMethod
  • User Entry: Selection from dropdown
  • Mandatory: Yes (when Allow Maturity Payout = Checked)
  • Options:
    • Principal Amount Only — Payout equals the total principal collected.
    • Principal and Bonus Amount — Payout includes principal plus accrued bonus.
    • Convert Weight to Amount — Payout converts accumulated metal weight to monetary value.
    • Based on Closing — Payout is calculated at the time of plan closing.
Behavior:
  • Visible only when Allow Maturity Payout = Checked.
Saved in & as:
  • emaADPPlanHDR → MasterDataValueID_MaturityPayoutCalculationMethod

Rate Fixing Allowed  (Checkbox)

Description:

Indicates whether rate fixing is allowed for this plan.

Control Properties:
  • Default Value: Unchecked (False)
  • User Entry: User can Check/Uncheck
  • Mandatory: No
Behavior:
  • Enabled only when Plan Type = Customer Deposit Plan and Customer Deposit Type = Metal Deposit.
  • Disabled otherwise.
  • Checked (True): Partial Rate Fixing Allowed checkbox becomes enabled.
  • Unchecked (False): Partial Rate Fixing Allowed is disabled and reset to False.
Saved in & as:
  • emaADPPlanHDR → IsRateFixingAllowed (bit)

Partial Rate Fixing Allowed  (Checkbox)

Description:

Indicates whether partial rate fixing is permitted on this plan.

Control Properties:
  • Default Value: Unchecked (False)
  • User Entry: User can Check/Uncheck
  • Mandatory: No
Behavior:
  • Enabled only when Rate Fixing Allowed = True.
  • Disabled otherwise.
Saved in & as:
  • emaADPPlanHDR → IsPartialRateFixingAllowed (bit)

5.2 Installment Discount Setup

Installment Discount Applicable  (Checkbox)

Description:

Enables the installment discount distribution configuration.

Control Properties:
  • Default Value: Unchecked (False)
  • User Entry: User can Check/Uncheck
  • Mandatory: No
Behavior:
  • Checked (True): Reveals Discount Installment Count field and Installment Discount Distribution popup.
  • Unchecked (False): Discount configuration section is hidden.
  • Enabled only when Plan Type = Value-Based Plan or Weight-Based Plan and Plan Structure Type = Installment-Based.
Saved in & as:
  • emaADPPlanHDR → DiscountInstallmentCount (int) — count stored here; per-installment discount % stored in emaADPPlanInstallmentDTL → DiscountPercentage

Discount Installment Count  (Textbox)

Description:

Defines how many installments' worth of value will be given as a discount to the customer out of the total installments. For example: Total Installments = 11, Per Installment Amount = 1000 — if Discount Installment Count = 2, the customer receives a discount equivalent to 2 installment values (2 × 1000 = 2000).

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input by user
  • Mandatory: Yes (when Installment Discount Applicable = Checked)
  • Allowed Characters: Numeric (integer)
Behavior:
  • Visible only when Installment Discount Applicable = Checked.
  • Value must be less than Total No. of Installments.
  • Drives the number of installment rows shown in the Installment Discount Distribution popup for percentage distribution.
Validation:

Entered value must be greater than 0 and less than Total No. of Installments.

Saved in & as:
  • emaADPPlanHDR → DiscountInstallmentCount (int)

Installment Discount Distribution  (Popup)

Description:

Opens a popup to assign discount percentages per installment term.

Control Properties:
  • User Entry: Manual click by user
  • Mandatory: No (click is optional; values within are mandatory if opened)
Behavior:
  • Opens popup listing installment rows (count = Discount Installment Count) with a checkbox and Discount Percentage textbox per row.
  • User selects which installments receive a discount and enters the discount percentage.
  • The total of all entered discount percentages must equal exactly 100%. For example: Installment 1 = 20%, Installment 2 = 30%, Installment 3 = 20%, Installment 4 = 30%.
  • Validation: If the sum of all Discount Percentage values does not equal 100%, the system displays an error — "Total discount percentage must equal 100%." and prevents submission.
  • On submit: IsDiscountApplied (bit) and DiscountPercentage (decimal 18,9) saved per installment row in emaADPPlanInstallmentDTL.

5.3 Early Plan Closure (Popup)

Allow Early Plan Closure  (Checkbox)

Description:

Enables early closure eligibility condition configuration for the plan.

Control Properties:
  • Default Value: Unchecked (False)
  • User Entry: User can Check/Uncheck
  • Mandatory: No
Behavior:
  • Checked (True): Reveals the early closure condition builder section.
  • Unchecked (False): Early closure section is hidden.
Saved in & as:
  • emaADPPlanHDR → AllowEarlyPlanClosure (bit)

Closure Eligibility Basis  (Single Selection Dropdown)

Description:

Specifies the basis on which early closure eligibility is evaluated.

Control Properties:
  • Default Value: —
  • Data Source: admMasterDataValueDTL
  • Filter Condition:
    • Active = True, listed from MasterDataValueID
    • MasterDataCategory = ADPClosureEligibilityBasis
  • User Entry: Selection from dropdown
  • Mandatory: Yes (within closure condition row)
  • Options:
    • Installment — Eligibility based on number of installments collected.
    • Amount — Eligibility based on total amount collected.
    • Days — Eligibility based on number of days elapsed since enrollment.
Saved in & as:
  • emaADPPlanEarlyClosureConditionDTL → MasterDataValueID_ADPClosureEligibilityBasis

Comparison Operator (Early Closure)  (Single Selection Dropdown)

Description:

Comparison operator applied to the closure eligibility condition.

Control Properties:
  • Default Value: —
  • Data Source: admMasterDataValueDTL
  • Filter Condition:
    • Active = True, listed from MasterDataValueID
    • MasterDataCategory = ComparisionOperator
  • User Entry: Selection from dropdown
  • Mandatory: Yes
  • Options: Equal To (=), Not Equal To (<>), Greater Than (>), Less Than (<), Greater Than or Equal To (>=), Less Than or Equal To (<=)
Saved in & as:
  • emaADPPlanEarlyClosureConditionDTL → MasterDataValueID_ComparisionOperator

Value (Early Closure Condition)  (Textbox)

Description:

The threshold value used in the closure eligibility comparison.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input by user
  • Mandatory: Yes
  • Allowed Characters: Numeric (decimal)
Saved in & as:
  • emaADPPlanEarlyClosureConditionDTL → Value (decimal 18,9)

Connector (Early Closure)  (Single Selection Dropdown)

Description:

Logical connector used to join multiple closure conditions.

Control Properties:
  • Default Value: —
  • Data Source: admMasterDataValueDTL
  • Filter Condition:
    • Active = True, listed from MasterDataValueID
    • MasterDataCategory = ComparisionConnector
  • User Entry: Selection from dropdown
  • Mandatory: Yes (for second condition onwards)
  • Options:
    • AND (&&) — Both conditions must be satisfied.
    • OR (||) — Either condition must be satisfied.
Saved in & as:
  • emaADPPlanEarlyClosureConditionDTL → MasterDataValueID_ComparisionConnector

Expression (Early Closure)  (Read-Only Textbox)

Description:

Auto-generated expression string representing all early closure conditions.

Control Properties:
  • Default Value: Empty
  • User Entry: Read-only; auto-generated by system
  • Mandatory: No
Saved in & as:
  • emaADPPlanHDR → EarlyPlanClosureConditionJsonFormat (nvarchar(max))
  • emaADPPlanHDR → EarlyPlanClosureConditionStringFormat (nvarchar(max))

+ Add Condition Button (Early Closure)  (Button)

Description:

Adds a new condition row to the early closure condition builder.

Control Properties:
  • User Entry: Manual click by user
  • Mandatory: No
Behavior:
  • On click: Appends a new condition row with Connector, Closure Eligibility Basis, Comparison Operator, and Value fields.
  • Updates the Expression field on each addition.
  • Each row saved as one record in emaADPPlanEarlyClosureConditionDTL with SortOrder.

5.4 Enrollment Limits

Enrollment Limit  (Single Selection Dropdown)

Description:

Defines whether total enrollment into the plan is capped or unlimited.

Control Properties:
  • Default Value: —
  • Data Source: admMasterDataValueDTL
  • Filter Condition:
    • Active = True, listed from MasterDataValueID
    • MasterDataCategory = ADPEnrollmentLimit
  • User Entry: Selection from dropdown
  • Mandatory: Yes
  • Options:
    • Unlimited — No cap on total enrollments.
    • Limited — Total enrollments are capped; requires Maximum Enrollment Count.
Behavior:
  • If Unlimited → Member Enrollment Limit textbox is hidden. No cap applied on enrollments.
  • If Limited → Member Enrollment Limit textbox becomes visible and mandatory. Enrollment is capped at the entered value.
Saved in & as:
  • emaADPPlanHDR → MasterDataValueID_ADPEnrollmentLimit

Member Enrollment Limit  (Textbox)

Description:

Maximum number of customers allowed to enroll in this plan.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input by user
  • Mandatory: Yes (when Enrollment Limit = Limited)
  • Allowed Characters: Numeric (integer)
Behavior:
  • Visible only when Enrollment Limit = Limited.
Saved in & as:
  • emaADPPlanHDR → MaximumEnrollmentCount (int)

5.5 Commission Setup

Commission Applicable  (Checkbox)

Description:

Enables commission configuration for the plan.

Control Properties:
  • Default Value: Unchecked (False)
  • User Entry: User can Check/Uncheck
  • Mandatory: No
Behavior:
  • Checked (True): Reveals Commission Calculation Method, Commission Trigger Event, Commission Value, and per-installment commission grid.
  • Unchecked (False): Commission section is hidden.
Saved in & as:
  • emaADPPlanHDR → IsCommissionApplicable (bit)

Commission Calculation Method  (Single Selection Dropdown)

Description:

Defines the method used to calculate commission.

Control Properties:
  • Default Value: —
  • Data Source: admMasterDataValueDTL
  • Filter Condition:
    • Active = True, listed from MasterDataValueID
    • MasterDataCategory = CalculationType
  • User Entry: Selection from dropdown
  • Mandatory: Yes (when Commission Applicable = Checked)
  • Options:
    • Amount — Commission is a fixed monetary amount.
    • Percentage — Commission is a percentage of the installment.
Saved in & as:
  • emaADPPlanHDR → Comission_MasterDataValueID_CalculationType

Commission Trigger Event  (Single Selection Dropdown)

Description:

Specifies the event that triggers commission calculation.

Control Properties:
  • Default Value: —
  • Data Source: admMasterDataValueDTL
  • Filter Condition:
    • Active = True, listed from MasterDataValueID
    • MasterDataCategory = ADPCommissionTriggerEvent
  • User Entry: Selection from dropdown
  • Mandatory: Yes (when Commission Applicable = Checked)
  • Options:
    • On Enrollment — Commission is triggered at the time the customer enrolls (joining month).
    • On Collection — Commission is triggered on total collection amount.
    • Per Installment — Commission is triggered per individual installment; shows per-installment commission grid.
Behavior:
  • If On Enrollment or On Collection → single Commission Value textbox is shown.
  • If Per Installment → single Commission Value textbox is hidden. Commission Value / Percentage grid becomes visible displaying rows equal to Total No. of Installments (one Commission Value/Percentage input per installment row).
Saved in & as:
  • emaADPPlanHDR → MasterDataValueID_ADPCommissionTriggerEvent

Commission Value  (Textbox)

Description:

The commission amount or percentage applied at the plan level (for On Enrollment / On Collection trigger).

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input by user
  • Mandatory: Yes (when Commission Trigger Event = On Enrollment or On Collection)
  • Allowed Characters: Numeric (decimal)
Behavior:
  • Visible when Commission Trigger Event = On Enrollment or On Collection.
  • Hidden when trigger = Per Installment (commission entered per installment in grid).
Saved in & as:
  • emaADPPlanHDR → CommissionValue (decimal 18,9)

5.6 Collection Window Rule (EmaADPPlanRuleDTL)

Collection Window Type  (Single Selection Dropdown)

Description:

Defines the type of collection window applied to the plan.

Control Properties:
  • Default Value: —
  • Data Source: admMasterDataValueDTL
  • Filter Condition:
    • Active = True, listed from MasterDataValueID
    • MasterDataCategory = ADPCollectionWindowType
  • User Entry: Selection from dropdown
  • Mandatory: Yes
  • Options:
    • Calendar Window — Collection allowed within specific calendar days of the month (From Day–To Day).
    • Relative Days Window — Collection allowed within relative days before/after due date.
    • Open Collection — Collection allowed at any time without window restriction.
Behavior:
  • If Calendar Window → From Day (D1) and To Day (D1) dropdowns visible.
  • If Relative Days Window → From Day and To Day textboxes visible (numeric days).
  • If Open Collection → window day fields are hidden.
Saved in & as:
  • emaADPPlanRuleDTL → MasterDataValueID_ADPCollectionWindowType

From Day (Calendar Window)  (Single Selection Dropdown)

Description:

Start day of the collection window (calendar day 1–30).

Control Properties:
  • Default Value: —
  • Data Source: admMasterDataValueDTL
  • Filter Condition:
    • Active = True, listed from MasterDataValueID (day values)
    • MasterDataCategory = Day
  • User Entry: Selection from dropdown
  • Mandatory: Yes (when Collection Window Type = Calendar Window)
Behavior:

Visible only when Collection Window Type = Calendar Window.

Saved in & as:
  • emaADPPlanRuleDTL → From_MasterDataValueID_Day

To Day (Calendar Window)  (Single Selection Dropdown)

Description:

End day of the collection window (calendar day 1–30).

Control Properties:
  • Default Value: —
  • Data Source: admMasterDataValueDTL
  • Filter Condition:
    • Active = True, listed from MasterDataValueID (day values)
    • MasterDataCategory = Day
  • User Entry: Selection from dropdown
  • Mandatory: Yes (when Collection Window Type = Calendar Window)
Behavior:

Visible only when Collection Window Type = Calendar Window.

Saved in & as:
  • emaADPPlanRuleDTL → To_MasterDataValueID_Day

From Day (Relative Days Window)  (Textbox)

Description:

Number of days before the due date from which collection is allowed.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input by user
  • Mandatory: Yes (when Collection Window Type = Relative Days Window)
  • Allowed Characters: Numeric (integer)
Behavior:

Visible only when Collection Window Type = Relative Days Window.

Saved in & as:
  • emaADPPlanRuleDTL → FromDays (int)

To Day (Relative Days Window)  (Textbox)

Description:

Number of days after the due date until which collection is allowed.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input by user
  • Mandatory: Yes (when Collection Window Type = Relative Days Window)
  • Allowed Characters: Numeric (integer)
Behavior:

Visible only when Collection Window Type = Relative Days Window.

Saved in & as:
  • emaADPPlanRuleDTL → ToDays (int)

Collection Cutoff Period (Days)  (Textbox)

Description:

Number of days after the collection window closes before the system marks the installment as missed.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input by user
  • Mandatory: No
  • Allowed Characters: Numeric (integer)
Saved in & as:
  • emaADPPlanRuleDTL → CollectionCutoffPeriodInDays (int)

Min Gap Between Installments (Days)  (Textbox)

Description:

Defines the minimum number of days that must elapse between two consecutive installment collections. For example, if set to 30, a customer cannot collect two installments within the same 30-day period — the second installment can only be collected after 30 days from the previous collection date.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input by user
  • Mandatory: No
  • Allowed Characters: Numeric (integer)
Saved in & as:
  • emaADPPlanRuleDTL → MinimumInstallmentGapInDays (int)

Auto Deactivate on Missed Collections  (Checkbox)

Description:

Automatically deactivates the enrollment if missed collection thresholds are exceeded.

Control Properties:
  • Default Value: Unchecked (False)
  • User Entry: User can Check/Uncheck
  • Mandatory: No
Behavior:
  • Checked (True): Reveals Max Missed Installments, Max Overdue Days, and Max Missed Collection Occurrences fields.
  • Unchecked (False): Those fields are hidden.
Saved in & as:
  • emaADPPlanRuleDTL → IsAutoDeactivateOnMissedCollection (bit)

Max Missed Installments  (Textbox)

Description:

Maximum number of consecutive missed installments before auto-deactivation.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input
  • Mandatory: Yes (when Auto Deactivate on Missed Collections = Checked)
  • Allowed Characters: Numeric (integer)
Saved in & as:
  • emaADPPlanRuleDTL → MaxMissedInstallmentCount (int)

Max Overdue Days  (Textbox)

Description:

Maximum number of overdue days before auto-deactivation is triggered.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input
  • Mandatory: Yes (when Auto Deactivate on Missed Collections = Checked)
  • Allowed Characters: Numeric (integer)
Saved in & as:
  • emaADPPlanRuleDTL → MaxOverdueDays (int)

Max Missed Collection Occurrences  (Textbox)

Description:

Maximum total occurrences of missed collections allowed across the plan lifetime.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input
  • Mandatory: Yes (when Auto Deactivate on Missed Collections = Checked)
  • Allowed Characters: Numeric (integer)
Saved in & as:
  • emaADPPlanRuleDTL → MaxMissedCollectionOccurrences (int)

Auto Deactivate Member  (Checkbox)

Description:

Automatically deactivates the member if the plan enrollment is deactivated due to missed collections.

Control Properties:
  • Default Value: Unchecked (False)
  • User Entry: User can Check/Uncheck
  • Mandatory: No
Behavior:
  • Checked (True): Reveals Member Auto Deactivation Period (Days) textbox.
  • Unchecked (False): That field is hidden.
Saved in & as:
  • emaADPPlanRuleDTL → IsAutoDeactivateMember (bit)

Member Auto Deactivation Period (Days)  (Textbox)

Description:

Grace period (in days) after which the member is auto-deactivated.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input
  • Mandatory: Yes (when Auto Deactivate Member = Checked)
  • Allowed Characters: Numeric (integer)
Saved in & as:
  • emaADPPlanRuleDTL → MemberAutoDeactivationPeriodInDays (int)

Allow Collection of Pending Installments  (Checkbox)

Description:

Allows collection of previously missed / pending installments.

Control Properties:
  • Default Value: Unchecked (False)
  • User Entry: User can Check/Uncheck
  • Mandatory: No
Behavior:
  • Checked (True): Reveals Max Pending Installments Allowed textbox.
Saved in & as:
  • emaADPPlanRuleDTL → IsPendingInstallmentCollectionAllowed (bit)

Max Pending Installments Allowed  (Textbox)

Description:

Maximum number of pending installments the system allows to be collected at once.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input
  • Mandatory: Yes (when Allow Collection of Pending Installments = Checked)
  • Allowed Characters: Numeric (integer)
Saved in & as:
  • emaADPPlanRuleDTL → MaxPendingInstallmentCollectionCount (int)

Allow Collection of Advance Installments  (Checkbox)

Description:

Allows customers to pay ahead of schedule (advance installments).

Control Properties:
  • Default Value: Unchecked (False)
  • User Entry: User can Check/Uncheck
  • Mandatory: No
Behavior:
  • Checked (True): Reveals Max Advance Installments Allowed textbox.
Saved in & as:
  • emaADPPlanRuleDTL → IsAdvanceInstallmentCollectionAllowed (bit)

Max Advance Installments Allowed  (Textbox)

Description:

Maximum number of installments a customer can pay in advance.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input
  • Mandatory: Yes (when Allow Collection of Advance Installments = Checked)
  • Allowed Characters: Numeric (integer)
Saved in & as:
  • emaADPPlanRuleDTL → MaxAdvanceInstallmentCollectionCount (int)

Allow Partial Installment Collection  (Checkbox)

Description:

Allows customers to make partial payments against an installment.

Control Properties:
  • Default Value: Unchecked (False)
  • User Entry: User can Check/Uncheck
  • Mandatory: No
Behavior:
  • Checked (True): Reveals Max Partial Payments Per Installment textbox.
Saved in & as:
  • emaADPPlanRuleDTL → IsPartialInstallmentCollectionAllowed (bit)

Max Partial Payments Per Installment  (Textbox)

Description:

Maximum number of partial payment transactions allowed per installment.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input
  • Mandatory: Yes (when Allow Partial Installment Collection = Checked)
  • Allowed Characters: Numeric (integer)
Saved in & as:
  • emaADPPlanRuleDTL → MaxPartialPaymentsPerInstallment (int)

5.7 Collection Channel Restrictions & Channel Access Control

Channel Access Control – Action Type Grid  (Checkbox Grid)

Description:

Grid showing action types (Enrollment, Collection, Closing) with Online and Offline blocking checkboxes to control which channels are allowed per action.

Control Properties:
  • Default Value: Unchecked (False) for each
  • User Entry: User can Check/Uncheck per action type
  • Mandatory: No
Behavior:
  • Three fixed rows are always displayed: Enrollment, Collection, and Closing.
  • If Online = Checked → that action type is blocked from being performed via online channel.
  • If Offline = Checked → that action type is blocked from being performed via offline channel.
  • Both Online and Offline can be checked simultaneously for the same action type.
Saved in & as:
  • emaADPPlanChannelAccessDTL → MasterDataValueID_ADPActionType, IsOnlineBlocked (bit), IsOfflineBlocked (bit) — one row per action type

Block Online / Block Offline (Per Installment)  (Checkbox Grid)

Description:

Inline grid showing each installment row with Block Online and Block Offline checkboxes to restrict which collection channel is available per installment.

Control Properties:
  • Default Value: Unchecked (False) for each
  • User Entry: User can Check/Uncheck per installment
  • Mandatory: No
Behavior:
  • Grid displays rows equal to Total No. of Installments.
  • If Block Online = Checked → collection for that installment is blocked via online channel.
  • If Block Offline = Checked → collection for that installment is blocked via offline channel.
  • Both Block Online and Block Offline can be checked simultaneously for the same installment.
Saved in & as:
  • emaADPPlanInstallmentDTL → IsOnlineCollectionBlocked (bit)
  • emaADPPlanInstallmentDTL → IsOfflineCollectionBlocked (bit)

5.8 Installment Rule Setup

Installment Rule Type  (Single Selection Dropdown)

Description:

Defines the rule type that governs acceptable installment amounts for this plan.

Control Properties:
  • Default Value: —
  • Data Source: admMasterDataValueDTL
  • Filter Condition:
    • Active = True, listed from MasterDataValueID
    • MasterDataCategory = ADPInstallmentRuleType
  • User Entry: Selection from dropdown
  • Mandatory: Yes
  • Options:
    • Fixed Selection — Customer selects from a predefined list of fixed amounts. Requires Amount input + Add button.
    • Ranged Selection — Customer enters any amount within a defined starting–ending range with a multiple-with constraint.
    • Predefined Term Amount — Each installment term has a specific preset amount.
    • Progressive Term Formula — Starting amount, ending amount, multiple-with, and per-installment progression rules (Progression Type, Calculation Type, Progressive Value).
    • Fully Flexible — No amount restriction; customer can enter any amount.
    • Flexible with Limits — Customer can enter any amount within a starting–ending range.
    • Advanced Formula — Amount computed using a formula expression built from components.
Behavior:
  • Each selected rule type reveals a specific sub-field configuration (see 5.8.1–5.8.7).
  • If Plan Type = Customer Deposit Plan → restricted to "Flexible with Limits".
  • If Plan Type = Value/Weight-Based and Plan Structure Type = Open Contribution → restricted to "Fully Flexible" or "Flexible with Limits".
Saved in & as:
  • emaADPPlanHDR → MasterDataValueID_ADPInstallmentRuleType
  • emaADPPlanInstallmentRuleDTL → MasterDataValueID_ADPInstallmentRuleType

5.8.1 Fixed Selection Sub-Fields

Amount (Fixed Selection)  (Textbox)

Description:

A fixed installment amount value the customer can select.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input
  • Mandatory: Yes
  • Allowed Characters: Numeric (decimal)
Behavior:

User enters an amount and clicks Add. Multiple amounts can be added to an inline list with a Remove (×) option. At least one amount is required.

Saved in & as:
  • emaADPPlanInstallmentRuleValueDTL → InstallmentAmount (decimal 18,9) — one row per added amount

5.8.2 Ranged Selection Sub-Fields

Starting Amount  (Textbox)

Description:

Minimum installment amount the customer can enter.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input
  • Mandatory: Yes
  • Allowed Characters: Numeric (decimal)
Saved in & as:
  • emaADPPlanInstallmentRuleValueDTL → StartingInstallmentAmount (decimal 18,9)

Ending Amount  (Textbox)

Description:

Maximum installment amount the customer can enter.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input
  • Mandatory: Yes
  • Allowed Characters: Numeric (decimal)
Saved in & as:
  • emaADPPlanInstallmentRuleValueDTL → EndingInstallmentAmount (decimal 18,9)

Multiple With  (Textbox)

Description:

Amount increment constraint — the entered amount must be a multiple of this value.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input
  • Mandatory: No (Confirm with team)
  • Allowed Characters: Numeric (decimal)
Saved in & as:
  • emaADPPlanInstallmentRuleValueDTL → MultipleWith (decimal 18,9)

5.8.3 Predefined Term Amount Sub-Fields

An inline grid is rendered with one row per installment (driven by Total No. of Installments). Each row shows: Installment No. | Amount (textbox).

Amount per Term  (Textbox per row)

Description:

Preset amount for each installment term.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input per row
  • Mandatory: Yes (for each row)
  • Allowed Characters: Numeric (decimal)
Saved in & as:
  • emaADPPlanInstallmentRuleValueDTL → InstallmentAmount (decimal 18,9) — one record per term, each linked to its own emaADPPlanInstallmentRuleDTL record

5.8.4 Progressive Term Formula Sub-Fields

Header fields (Starting Amount, Ending Amount, Multiple With) plus an inline grid for installments 2 onwards showing Progression Type, Calculation Type, and Progressive Value per row.

Starting Amount  (Textbox)

Description:

The installment amount for the first term and the base amount from which progression is calculated.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input by user
  • Mandatory: Yes
  • Allowed Characters: Numeric (decimal)
Saved in & as:
  • emaADPPlanInstallmentRuleValueDTL → StartingInstallmentAmount (decimal 18,9)

Ending Amount  (Textbox)

Description:

The maximum installment amount the progression can reach.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input by user
  • Mandatory: Yes
  • Allowed Characters: Numeric (decimal)
Saved in & as:
  • emaADPPlanInstallmentRuleValueDTL → EndingInstallmentAmount (decimal 18,9)

Multiple With  (Textbox)

Description:

Amount increment constraint — the progressive installment amount must be a multiple of this value.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input by user
  • Mandatory: No
  • Allowed Characters: Numeric (decimal)
Saved in & as:
  • emaADPPlanInstallmentRuleValueDTL → MultipleWith (decimal 18,9)

Progression Type  (Single Selection Dropdown per row)

Description:

Defines how the installment amount progresses from one term to the next.

Control Properties:
  • Default Value: —
  • Data Source: admMasterDataValueDTL
  • Filter Condition:
    • Active = True, listed from MasterDataValueID
    • MasterDataCategory = ADPInstallmentProgressionType
  • User Entry: Selection from dropdown
  • Mandatory: Yes
  • Options:
    • Increase — Amount increases each term.
    • Decrease — Amount decreases each term.
    • Same as Previous Installment — Amount remains unchanged from the previous term.
    • Formula Expression — Opens formula builder popup (see 5.8.7).
Saved in & as:
  • emaADPPlanInstallmentRuleValueDTL → MasterDataValueID_ADPInstallmentProgressionType

Calculation Type (Progressive)  (Single Selection Dropdown per row)

Description:

Method by which the progression value is applied to calculate the next installment amount.

Control Properties:
  • Default Value: —
  • Data Source: admMasterDataValueDTL
  • Filter Condition:
    • MasterDataCategory = CalculationType
  • User Entry: Selection from dropdown
  • Mandatory: Yes (when Progression Type = Increase or Decrease)
  • Options: Amount, Percentage
Saved in & as:
  • emaADPPlanInstallmentRuleValueDTL → MasterDataValueID_CalculationType

Progressive Value  (Textbox per row)

Description:

The numeric amount or percentage used in the progression calculation.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input
  • Mandatory: Yes (when Progression Type = Increase or Decrease)
  • Allowed Characters: Numeric (decimal)
Saved in & as:
  • emaADPPlanInstallmentRuleValueDTL → ProgressionValue (decimal 18,9)

5.8.5 Fully Flexible Sub-Fields

No amount constraints or input fields. Section is visible only when Installment Rule Type = Fully Flexible.

5.8.6 Flexible with Limits Sub-Fields

Section is visible only when Installment Rule Type = Flexible with Limits. Customer can enter any amount within the defined starting–ending range.

Starting Amount  (Textbox)

Description:

Minimum installment amount the customer can enter.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input by user
  • Mandatory: Yes
  • Allowed Characters: Numeric (decimal)
Validation:

Must be greater than 0 and less than Ending Amount.

Saved in & as:
  • emaADPPlanInstallmentRuleValueDTL → StartingInstallmentAmount (decimal 18,9)

Ending Amount  (Textbox)

Description:

Maximum installment amount the customer can enter.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input by user
  • Mandatory: Yes
  • Allowed Characters: Numeric (decimal)
Validation:

Must be greater than Starting Amount.

Saved in & as:
  • emaADPPlanInstallmentRuleValueDTL → EndingInstallmentAmount (decimal 18,9)

5.8.7 Advanced Formula Sub-Fields

Section is visible only when Installment Rule Type = Advanced Formula. Displays an inline grid with one row per installment (count = Total No. of Installments).

5.8.8 Formula Expression Popup Sub-Fields

This popup is triggered in two scenarios:

Component Type  (Single Selection Dropdown)

Description:

Defines what type of value the formula component represents.

Control Properties:
  • Default Value: —
  • Data Source: admMasterDataValueDTL
  • Filter Condition:
    • MasterDataCategory = ADPInstallmentFormulaComponentType
  • User Entry: Selection from dropdown
  • Mandatory: Yes
  • Options:
    • Installment — Component references a specific installment term number.
    • Static Value — Component is a fixed numeric value.
Behavior:
  • If Installment → Installment dropdown (select term no.) becomes visible.
  • If Static Value → Value textbox becomes visible.
Saved in & as:
  • emaADPPlanInstallmentRuleValueFormulaDTL → MasterDataValueID_ADPInstallmentFormulaComponentType

Installment (Formula)  (Single Selection Dropdown)

Description:

Selects the installment term number to reference in the formula.

Control Properties:
  • Default Value: —
  • Data Source: emaADPPlanInstallmentDTL (current plan)
  • Filter Condition:
    • Active installment terms for the current plan
  • User Entry: Selection from dropdown
  • Mandatory: Yes (when Component Type = Installment)
Behavior:

Visible only when Component Type = Installment.

Saved in & as:
  • emaADPPlanInstallmentRuleValueFormulaDTL → MasterDataValueID_ADPInstallmentID (uniqueidentifier)

Value (Formula Static)  (Textbox)

Description:

Static numeric value used as a formula component.

Control Properties:
  • Default Value: Empty
  • User Entry: Manual input
  • Mandatory: Yes (when Component Type = Static Value)
  • Allowed Characters: Numeric (decimal)
Behavior:

Visible only when Component Type = Static Value.

Saved in & as:
  • emaADPPlanInstallmentRuleValueFormulaDTL → StaticValue (decimal 18,9)

Operator (Formula)  (Single Selection Dropdown)

Description:

Arithmetic operator connecting two formula components.

Control Properties:
  • Default Value: —
  • Data Source: admMasterDataValueDTL
  • Filter Condition:
    • MasterDataCategory = Operator
  • User Entry: Selection from dropdown
  • Mandatory: Yes (for second component onwards)
  • Options: Add (+), Minus (-), Multiply (*), Divide (/)
Saved in & as:
  • emaADPPlanInstallmentRuleValueFormulaDTL → MasterDataValueID_Operator

Expression (Formula)  (Read-Only Textbox)

Description:

Auto-generated string representation of the formula expression.

Control Properties:
  • Default Value: Empty
  • User Entry: Read-only; auto-generated by system
  • Mandatory: No
Saved in & as:
  • emaADPPlanInstallmentRuleValueDTL → FormulaExpressionJsonFormat (nvarchar(max))
  • emaADPPlanInstallmentRuleValueDTL → FormulaExpressionStringFormat (nvarchar(max))

5.9 Form Action Buttons

Save  (Button)

Description:

Validates and saves the Advance Plan record.

Control Properties:
  • User Entry: Manual click by user
  • Mandatory: Yes
Behavior:
  • Validates all mandatory header and DTL fields.
  • On success: Inserts HDR, all DTL records, sets ApprovalStatus = Pending.
  • On failure: Displays inline validation errors.

Clear  (Button)

Description:

Resets the form to its default empty state.

Control Properties:
  • User Entry: Manual click by user
  • Mandatory: No
Behavior:
  • Clears all field values and resets the form to default state without saving.

6. Table View

6.1 Column List

#Column HeaderSource FieldRemarks
1Plan TypeMasterDataValueID_ADPPlanTypeDisplay lookup value
2NameName
3Short NameShortName
4Plan Structure TypeMasterDataValueID_ADPPlanStructureTypeDisplay lookup value
5Total InstallmentsTotalInstallmentCount
6Maturity Period (Days)MaturityPeriodInDays
7Installment Rule TypeMasterDataValueID_ADPInstallmentRuleTypeDisplay lookup value
8Approval StatusMasterDataValueID_ApprovalStatusDisplay lookup value
9ActiveActiveYes / No
10ActionsAdd, Edit, Delete, Export, Export All

6.2 Add Button

6.3 Edit Button

Edit Scenario 1 — No Linked Transactions (e.g. No Member Enrollments)

Condition:

No active member enrollments or transactions linked to this plan.

Behavior:

All plan fields are fully editable. No restrictions apply. Complete plan configuration including Plan Type, Plan Structure Type, Total No. of Installments, Installment Rule Type, and all DTL records can be modified.

Edit Scenario 2 — Linked Transactions Exist (e.g. Members Enrolled)

Condition:

At least one active member enrollment or transaction is linked to this plan.

Behavior:

Only the following fields are editable. All other fields are read-only.

Editable Fields:
  • Name — Fully editable.
  • Short Name — Fully editable.
  • Maturity Period (Days) — Editable only if Allow Days Increase is permitted (increase only; cannot reduce).
  • Enrollment Gift Applicable — Fully editable (checkbox).
  • Rate Fixing Allowed — Fully editable (checkbox).
  • Partial Rate Fixing Allowed — Fully editable (checkbox; subject to Rate Fixing Allowed = True).
  • Allow Maturity Payout — Fully editable (checkbox).
  • Maturity Payout Calculation Method — Editable when Allow Maturity Payout = Checked.
  • Discount Installment Count — Increase only; cannot reduce below current value.
  • Installment Discount Distribution — Installment selection and discount percentage editable; increase only.
  • Allow Early Plan Closure — Fully editable (checkbox and condition builder).
  • Enrollment Limit — Fully editable (dropdown).
  • Member Enrollment Limit — Increase only; cannot reduce below current value.
  • Commission Applicable — Fully editable (checkbox).
  • Commission Calculation Method — Editable when Commission Applicable = Checked.
  • Commission Trigger Event — Editable when Commission Applicable = Checked.
  • Commission Value — Editable when Commission Applicable = Checked.
  • Channel Access Controls — Online/Offline blocking per action type fully editable.
  • Collection Channel Restrictions — Block Online/Block Offline per installment fully editable.
  • Collection Window / Days — Collection Window Type, From Day, To Day editable.
  • Collection Cutoff Period (Days) — Fully editable.
  • Min Gap Between Installments (Days) — Fully editable.
  • Auto Deactivate on Missed Collections — Checkbox editable. If enabled:
    • Max Missed Installments — Editable.
    • Max Overdue Days — Editable.
    • Max Missed Collection Occurrences — Editable.
  • Auto Deactivate Member — Checkbox editable. If enabled:
    • Member Auto Deactivation Period (Days) — Editable.
  • Allow Collection of Pending Installments — Checkbox editable. If enabled:
    • Max Pending Installments Allowed — Editable.
  • Allow Collection of Advance Installments — Checkbox editable. If enabled:
    • Max Advance Installments Allowed — Editable.
  • Allow Partial Installment Collection — Checkbox editable. If enabled:
    • Max Partial Payments Per Installment — Editable.
  • Installment Rule Type Values — Rule Type itself is read-only (not changeable). Only the rule values are editable with the following constraints:
    • Fixed Selection — New amount values can be added only; existing values cannot be removed.
    • Ending Amount — Increase only; cannot reduce below current value.
    • Multiple With — Increase only; cannot reduce below current value.
  • Installment Rule Type = Advanced Formula — Table values (Progression Type, Calculation Type, Progressive Value) are editable per installment row based on the selected Installment Type.

6.4 Delete Button

6.5 Export Button

6.6 Export All Button

7. Functional Specifications

7.1 Save Behavior (Add Mode)

On Save, the system executes the following insert sequence:

  1. Insert emaADPPlanHDR → sets ApprovalStatus = Pending
  2. Insert emaADPPlanRuleDTL (collection window rule)
  3. If AllowEarlyPlanClosure = True → Insert emaADPPlanEarlyClosureConditionDTL (one row per condition)
  4. Insert emaADPPlanChannelAccessDTL (one row per action type: Enrollment, Collection, Closing)
  5. Insert emaADPPlanInstallmentDTL (one row per installment term)
  6. Insert emaADPPlanInstallmentRuleDTL (one row per installment, linked to InstallmentDTL)
  7. Insert emaADPPlanInstallmentRuleValueDTL (one or more rows per rule, depending on rule type)
  8. If Rule Type = Advanced Formula → Insert emaADPPlanInstallmentRuleValueFormulaDTL (one row per formula component)

7.2 Edit Save Behavior

7.3 Common Validations

7.4.1 emaADPPlanHDR — Value on Save

ColumnValue on Save
ADPPlanIDNew GUID (system generated)
NameUser input
ShortNameUser input
MasterDataValueID_ADPPlanTypeSelected Plan Type ID
MasterDataValueID_ADPPlanCustomerDepositTypeSelected value or NULL
MetalIDSelected metal
RotationNoUser input or NULL
MasterDataValueID_ADPPlanStructureTypeSelected Structure Type ID
TotalInstallmentCountUser input or 1 (Customer Deposit Plan)
MaturityPeriodInDaysUser input
IsLuckyDrawApplicableChecked = 1, Unchecked = 0
HasEnrollmentGiftChecked = 1, Unchecked = 0
AllowEarlyPlanClosureChecked = 1, Unchecked = 0
EarlyPlanClosureConditionJsonFormatAuto-generated JSON string or NULL
EarlyPlanClosureConditionStringFormatAuto-generated string or NULL
IsRateFixingAllowedChecked = 1, Unchecked = 0
IsPartialRateFixingAllowedChecked = 1, Unchecked = 0
AllowMaturityPayoutChecked = 1, Unchecked = 0
MasterDataValueID_MaturityPayoutCalculationMethodSelected value or NULL
DiscountInstallmentCountUser input or NULL
IsCommissionApplicableChecked = 1, Unchecked = 0
Comission_MasterDataValueID_CalculationTypeSelected value or NULL
MasterDataValueID_ADPCommissionTriggerEventSelected value or NULL
CommissionValueUser input or NULL
MasterDataValueID_ADPEnrollmentLimitSelected value
MaximumEnrollmentCountUser input or NULL
MasterDataValueID_ADPInstallmentRuleTypeSelected Rule Type ID
Active1 (default)
MasterDataValueID_ApprovalStatusPending

7.4.2 emaADPPlanRuleDTL — Value on Save

One row per plan.

ColumnValue on Save
ADPPlanRuleIDNew GUID
ADPPlanIDFK → emaADPPlanHDR.ADPPlanID
MasterDataValueID_ADPCollectionWindowTypeSelected Window Type ID
FromDaysUser input or NULL
ToDaysUser input or NULL
From_MasterDataValueID_DaySelected day value or NULL
To_MasterDataValueID_DaySelected day value or NULL
MinimumInstallmentGapInDaysUser input or NULL
CollectionCutoffPeriodInDaysUser input or NULL
IsAutoDeactivateOnMissedCollectionChecked = 1, else 0
MaxMissedInstallmentCountUser input or NULL
MaxOverdueDaysUser input or NULL
MaxMissedCollectionOccurrencesUser input or NULL
IsAutoDeactivateMemberChecked = 1, else 0
MemberAutoDeactivationPeriodInDaysUser input or NULL
IsPendingInstallmentCollectionAllowedChecked = 1, else 0
MaxPendingInstallmentCollectionCountUser input or NULL
IsAdvanceInstallmentCollectionAllowedChecked = 1, else 0
MaxAdvanceInstallmentCollectionCountUser input or NULL
IsPartialInstallmentCollectionAllowedChecked = 1, else 0
MaxPartialPaymentsPerInstallmentUser input or NULL

7.4.3 emaADPPlanEarlyClosureConditionDTL — Value on Save

One row per condition. Saved only when AllowEarlyPlanClosure = True.

ColumnValue on Save
ADPPlanEarlyClosureConditionIDNew GUID
ADPPlanIDFK → emaADPPlanHDR.ADPPlanID
MasterDataValueID_ADPClosureEligibilityBasisSelected Basis ID
MasterDataValueID_ComparisionOperatorSelected Operator ID
ValueUser input
MasterDataValueID_ComparisionConnectorSelected Connector or NULL (first row)
SortOrderSequential integer (1, 2, 3…)

7.4.4 emaADPPlanChannelAccessDTL — Value on Save

One row per action type (3 rows: Enrollment, Collection, Closing).

ColumnValue on Save
ADPPlanChannelAccessIDNew GUID
ADPPlanIDFK → emaADPPlanHDR.ADPPlanID
MasterDataValueID_ADPActionTypeEnrollment / Collection / Closing ID
IsOnlineBlockedChecked = 1, else 0
IsOfflineBlockedChecked = 1, else 0

7.4.5 emaADPPlanInstallmentDTL — Value on Save

One row per installment term (count = TotalInstallmentCount; or 1 row with TermNo = NULL for Open Contribution).

ColumnValue on Save
ADPPlanInstallmentIDNew GUID
ADPPlanIDFK → emaADPPlanHDR.ADPPlanID
TermNameSystem generated — Installment-1, Installment-2, Installment-3… (based on TermNo)
TermNoSequential integer (1, 2, 3…) or NULL for Open Contribution
SortOrderSequential integer
IsDiscountApplied1 if discount assigned, else 0
IsInstallmentDiscountApplicable1 if discount selected in popup, else 0
DiscountPercentageUser input from discount popup or NULL
CommissionValueUser input (Per Installment trigger) or NULL
IsOnlineCollectionBlockedChecked = 1, else 0
IsOfflineCollectionBlockedChecked = 1, else 0
ADPPlanInstallmentRuleIDFK → emaADPPlanInstallmentRuleDTL.ADPPlanInstallmentRuleID

7.4.6 emaADPPlanInstallmentRuleDTL — Value on Save

One row per installment (for Predefined Term Amount / Progressive Term Formula) or one shared row (for Fixed Selection, Ranged, Fully Flexible, Flexible with Limits, Advanced Formula).

ColumnValue on Save
ADPPlanInstallmentRuleIDNew GUID
MasterDataValueID_ADPInstallmentRuleTypeSelected Rule Type ID

7.4.7 emaADPPlanInstallmentRuleValueDTL — Value on Save

Rows depend on rule type. Refer to per-rule-type data structure below.

ColumnValue on Save
ADPPlanInstallmentRuleValueIDNew GUID
ADPPlanInstallmentRuleIDFK → emaADPPlanInstallmentRuleDTL
MasterDataValueID_ADPInstallmentRuleTypeSame as rule type
InstallmentAmountUser input (Fixed Selection / Predefined Term Amount) or NULL
StartingInstallmentAmountUser input (Ranged / Flexible with Limits / Progressive) or NULL
EndingInstallmentAmountUser input (Ranged / Flexible with Limits / Progressive) or NULL
MultipleWithUser input or NULL
MasterDataValueID_ADPInstallmentProgressionTypeSelected Progression Type or NULL
MasterDataValueID_CalculationTypeSelected Calculation Type or NULL
ProgressionValueUser input or NULL
FormulaExpressionJsonFormatAuto-generated or NULL
FormulaExpressionStringFormatAuto-generated or NULL

7.4.8 emaADPPlanInstallmentRuleValueFormulaDTL — Value on Save

One row per formula component. Saved only when Rule Type = Advanced Formula or Progression Type = Formula Expression.

ColumnValue on Save
ADPPlanInstallmentRuleValueFormulaIDNew GUID
ADPPlanInstallmentRuleValueIDFK → emaADPPlanInstallmentRuleValueDTL
MasterDataValueID_ADPInstallmentFormulaComponentTypeSelected Component Type ID
MasterDataValueID_ADPInstallmentIDSelected Installment Term ID or NULL
TermNoReferenced term number or NULL
StaticValueUser input or NULL
MasterDataValueID_OperatorSelected Operator ID or NULL (first component)
SortOrderSequential integer (1, 2, 3…)