From 61b1bef805dbc4bc03feeff0f6b6f45c8608c2ff Mon Sep 17 00:00:00 2001 From: AbleKSaju <126228406+AbleKSaju@users.noreply.github.com> Date: Mon, 12 Jan 2026 10:12:02 +0530 Subject: [PATCH] fix: add sublabel in loyalty program --- schemas/app/CollectionRulesItems.json | 5 +++-- schemas/app/LoyaltyProgram.json | 3 ++- schemas/types.ts | 1 + src/components/Controls/Base.vue | 3 +++ src/components/Controls/Table.vue | 3 ++- 5 files changed, 11 insertions(+), 4 deletions(-) diff --git a/schemas/app/CollectionRulesItems.json b/schemas/app/CollectionRulesItems.json index 6ae4c5c9..803e3c5f 100644 --- a/schemas/app/CollectionRulesItems.json +++ b/schemas/app/CollectionRulesItems.json @@ -10,8 +10,9 @@ }, { "fieldname": "collectionFactor", - "label": "Collection Factor (=1 LP)", - "fieldtype": "Float" + "label": "Collection Factor", + "fieldtype": "Float", + "sub_label": "Sale 100→ 100 (1), 50 (0.5)" }, { "fieldname": "minimumTotalSpent", diff --git a/schemas/app/LoyaltyProgram.json b/schemas/app/LoyaltyProgram.json index a53e5eca..5c5c1c71 100644 --- a/schemas/app/LoyaltyProgram.json +++ b/schemas/app/LoyaltyProgram.json @@ -43,7 +43,8 @@ "label": "Conversion Factor", "fieldtype": "Float", "default": 1, - "required": true + "required": true, + "sub_label": "100 Points → 100 (Factor 1), 50 (Factor 0.5)" }, { "fieldname": "expiryDuration", diff --git a/schemas/types.ts b/schemas/types.ts index 4fbbb9b5..daa65952 100644 --- a/schemas/types.ts +++ b/schemas/types.ts @@ -69,6 +69,7 @@ export interface BaseField { tab?: string; // UI Facing config, for grouping by tabs abstract?: string; // Used to mark the location of a field in an Abstract schema isCustom?: boolean; // Whether the field is a custom field + sub_label?: string; filters?: Record; getOptions?: () => Promise<{ label: string; value: string }[]>; } diff --git a/src/components/Controls/Base.vue b/src/components/Controls/Base.vue index 461a4014..caa8f7de 100644 --- a/src/components/Controls/Base.vue +++ b/src/components/Controls/Base.vue @@ -23,6 +23,9 @@ @input="(e) => !isReadOnly && $emit('input', e)" /> +
+ {{ df?.sub_label }} +