cloud-ide-model-schema 1.1.139 → 1.1.141
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/schema/core/core_dashboard_cards.d.ts +23 -0
- package/lib/schema/core/core_dashboard_cards.js +148 -0
- package/lib/schema/core/index.d.ts +4 -1
- package/lib/schema/core/index.js +3 -1
- package/lib/schema/fees/fee_payment.d.ts +23 -0
- package/lib/schema/fees/fee_payment.js +221 -0
- package/lib/schema/fees/fee_structure_item.js +12 -0
- package/lib/schema/fees/index.d.ts +1 -0
- package/lib/schema/fees/index.js +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import mongoose from "mongoose";
|
|
2
|
+
declare const CCoreDashboardCards: mongoose.Model<{
|
|
3
|
+
[x: string]: unknown;
|
|
4
|
+
}, {}, {}, {}, mongoose.Document<unknown, {}, {
|
|
5
|
+
[x: string]: unknown;
|
|
6
|
+
}, {}> & {
|
|
7
|
+
[x: string]: unknown;
|
|
8
|
+
} & Required<{
|
|
9
|
+
_id: unknown;
|
|
10
|
+
}> & {
|
|
11
|
+
__v: number;
|
|
12
|
+
}, mongoose.Schema<any, mongoose.Model<any, any, any, any, any, any>, {}, {}, {}, {}, mongoose.DefaultSchemaOptions, {
|
|
13
|
+
[x: string]: unknown;
|
|
14
|
+
}, mongoose.Document<unknown, {}, mongoose.FlatRecord<{
|
|
15
|
+
[x: string]: unknown;
|
|
16
|
+
}>, {}> & mongoose.FlatRecord<{
|
|
17
|
+
[x: string]: unknown;
|
|
18
|
+
}> & Required<{
|
|
19
|
+
_id: unknown;
|
|
20
|
+
}> & {
|
|
21
|
+
__v: number;
|
|
22
|
+
}>>;
|
|
23
|
+
export { CCoreDashboardCards };
|
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CCoreDashboardCards = void 0;
|
|
4
|
+
var mongoose_1 = require("mongoose");
|
|
5
|
+
/* SCHEMA START */
|
|
6
|
+
var core_dashboard_cards = new mongoose_1.Schema({
|
|
7
|
+
cdc_title: {
|
|
8
|
+
type: String,
|
|
9
|
+
required: true,
|
|
10
|
+
maxlength: 200,
|
|
11
|
+
trim: true,
|
|
12
|
+
comment: "Title of the dashboard card"
|
|
13
|
+
},
|
|
14
|
+
cdc_description: {
|
|
15
|
+
type: String,
|
|
16
|
+
maxlength: 500,
|
|
17
|
+
trim: true,
|
|
18
|
+
comment: "Description of the dashboard card"
|
|
19
|
+
},
|
|
20
|
+
cdc_type: {
|
|
21
|
+
type: String,
|
|
22
|
+
required: true,
|
|
23
|
+
maxlength: 50,
|
|
24
|
+
trim: true,
|
|
25
|
+
enum: ["stats", "chart", "table", "module-card", "activity-feed", "events", "custom"],
|
|
26
|
+
default: "custom",
|
|
27
|
+
comment: "Type of dashboard card (stats, chart, table, etc.)"
|
|
28
|
+
},
|
|
29
|
+
cdc_api_endpoint: {
|
|
30
|
+
type: String,
|
|
31
|
+
maxlength: 500,
|
|
32
|
+
trim: true,
|
|
33
|
+
comment: "API endpoint URL to fetch data for this card"
|
|
34
|
+
},
|
|
35
|
+
cdc_api_method: {
|
|
36
|
+
type: String,
|
|
37
|
+
maxlength: 10,
|
|
38
|
+
trim: true,
|
|
39
|
+
enum: ["GET", "POST", "PUT", "DELETE", "PATCH"],
|
|
40
|
+
default: "GET",
|
|
41
|
+
comment: "HTTP method for the API endpoint"
|
|
42
|
+
},
|
|
43
|
+
cdc_api_payload: {
|
|
44
|
+
type: mongoose_1.Schema.Types.Mixed,
|
|
45
|
+
comment: "Default payload/query parameters for the API call (stored as JSON)"
|
|
46
|
+
},
|
|
47
|
+
cdc_config: {
|
|
48
|
+
type: mongoose_1.Schema.Types.Mixed,
|
|
49
|
+
comment: "Card-specific configuration (layout, styling, display options, etc.)"
|
|
50
|
+
},
|
|
51
|
+
cdc_position: {
|
|
52
|
+
row: {
|
|
53
|
+
type: Number,
|
|
54
|
+
default: 1,
|
|
55
|
+
comment: "Row position in the grid"
|
|
56
|
+
},
|
|
57
|
+
col: {
|
|
58
|
+
type: Number,
|
|
59
|
+
default: 1,
|
|
60
|
+
comment: "Column position in the grid"
|
|
61
|
+
},
|
|
62
|
+
colspan: {
|
|
63
|
+
type: Number,
|
|
64
|
+
default: 1,
|
|
65
|
+
min: 1,
|
|
66
|
+
max: 12,
|
|
67
|
+
comment: "Number of columns this card spans"
|
|
68
|
+
},
|
|
69
|
+
rowspan: {
|
|
70
|
+
type: Number,
|
|
71
|
+
default: 1,
|
|
72
|
+
min: 1,
|
|
73
|
+
comment: "Number of rows this card spans"
|
|
74
|
+
}
|
|
75
|
+
},
|
|
76
|
+
cdc_icon: {
|
|
77
|
+
type: String,
|
|
78
|
+
maxlength: 100,
|
|
79
|
+
trim: true,
|
|
80
|
+
comment: "Icon name or identifier for the card"
|
|
81
|
+
},
|
|
82
|
+
cdc_color: {
|
|
83
|
+
type: String,
|
|
84
|
+
maxlength: 50,
|
|
85
|
+
trim: true,
|
|
86
|
+
comment: "Color theme for the card (hex code or color name)"
|
|
87
|
+
},
|
|
88
|
+
cdc_visible: {
|
|
89
|
+
type: Boolean,
|
|
90
|
+
default: true,
|
|
91
|
+
comment: "Whether the card is visible on the dashboard"
|
|
92
|
+
},
|
|
93
|
+
cdc_draggable: {
|
|
94
|
+
type: Boolean,
|
|
95
|
+
default: true,
|
|
96
|
+
comment: "Whether the card can be dragged and repositioned"
|
|
97
|
+
},
|
|
98
|
+
cdc_refresh_interval: {
|
|
99
|
+
type: Number,
|
|
100
|
+
default: 0,
|
|
101
|
+
comment: "Auto-refresh interval in seconds (0 = no auto-refresh)"
|
|
102
|
+
},
|
|
103
|
+
cdc_permissions: {
|
|
104
|
+
type: [String],
|
|
105
|
+
default: ["all"],
|
|
106
|
+
comment: "Array of role/permission identifiers that can view this card"
|
|
107
|
+
},
|
|
108
|
+
cdc_entity_id_syen: {
|
|
109
|
+
type: mongoose_1.default.Schema.Types.ObjectId,
|
|
110
|
+
ref: "core_system_entity",
|
|
111
|
+
comment: "Reference to core_system_entity (for multi-entity support)"
|
|
112
|
+
},
|
|
113
|
+
cdc_created_by_user: {
|
|
114
|
+
type: mongoose_1.default.Schema.Types.ObjectId,
|
|
115
|
+
ref: "auth_user_mst",
|
|
116
|
+
comment: "User who created this card"
|
|
117
|
+
},
|
|
118
|
+
cdc_modified_by_user: {
|
|
119
|
+
type: mongoose_1.default.Schema.Types.ObjectId,
|
|
120
|
+
ref: "auth_user_mst",
|
|
121
|
+
comment: "User who last modified this card"
|
|
122
|
+
},
|
|
123
|
+
cdc_created_date: {
|
|
124
|
+
type: Date,
|
|
125
|
+
default: Date.now,
|
|
126
|
+
comment: "Creation timestamp"
|
|
127
|
+
},
|
|
128
|
+
cdc_modified_date: {
|
|
129
|
+
type: Date,
|
|
130
|
+
default: Date.now,
|
|
131
|
+
comment: "Last modification timestamp"
|
|
132
|
+
},
|
|
133
|
+
cdc_isactive: {
|
|
134
|
+
type: Boolean,
|
|
135
|
+
default: true,
|
|
136
|
+
comment: "Active status of the card"
|
|
137
|
+
}
|
|
138
|
+
}, {
|
|
139
|
+
collection: 'core_dashboard_cards',
|
|
140
|
+
timestamps: false // We're using custom timestamp fields
|
|
141
|
+
});
|
|
142
|
+
// Indexes for performance
|
|
143
|
+
core_dashboard_cards.index({ cdc_entity_id_syen: 1 });
|
|
144
|
+
core_dashboard_cards.index({ cdc_visible: 1, cdc_isactive: 1 });
|
|
145
|
+
core_dashboard_cards.index({ cdc_created_date: -1 });
|
|
146
|
+
core_dashboard_cards.index({ cdc_position: 1 });
|
|
147
|
+
var CCoreDashboardCards = mongoose_1.default.model("core_dashboard_cards", core_dashboard_cards);
|
|
148
|
+
exports.CCoreDashboardCards = CCoreDashboardCards;
|
|
@@ -35,6 +35,7 @@ import { CCoreSchoolBoardAffiliation } from './core_school_board_affiliation';
|
|
|
35
35
|
import { CCoreEntityUdise } from './core_entity_udise';
|
|
36
36
|
import { CCoreBoardExamPattern } from './core_board_exam_pattern';
|
|
37
37
|
import { CCoreBoardGradeSystem } from './core_board_grade_system';
|
|
38
|
+
import { CCoreDashboardCards } from './core_dashboard_cards';
|
|
38
39
|
export * from './core_user_contact_addresses';
|
|
39
40
|
export * from './core_entity_access_pass_management';
|
|
40
41
|
export { CCoreSypg, CCoreSytm, CCoreSyme, CCoreSylog, CCoreSyen, CCoreSyco, CCoreFinancialConfig, CCoreSypin, CCoreSyptb, CCoreSypgr, CCoreSype, CCoreSygms, CCoreSygmt, CCoreSyenm, CCoreCyfm, CCoreSyctr, CCoreSynat,
|
|
@@ -77,4 +78,6 @@ CCoreBoardExamPattern,
|
|
|
77
78
|
/** Board Grade System schemas */
|
|
78
79
|
CCoreBoardGradeSystem,
|
|
79
80
|
/** User Type Mapping schemas */
|
|
80
|
-
CCoreUserTypeMapping
|
|
81
|
+
CCoreUserTypeMapping,
|
|
82
|
+
/** Dashboard Cards schemas */
|
|
83
|
+
CCoreDashboardCards };
|
package/lib/schema/core/index.js
CHANGED
|
@@ -14,7 +14,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
exports.CCoreUserTypeMapping = exports.CCoreBoardGradeSystem = exports.CCoreBoardExamPattern = exports.CCoreEntityUdise = exports.CCoreSchoolBoardAffiliation = exports.CCoreEducationBoard = exports.CCoreUserRoleExceptions = exports.CCoreUserRoleRights = exports.CCoreUserRole = exports.CCoreUserFamilyDetails = exports.CCoreUserDocuments = exports.CCoreSydept = exports.CCoreSydsgl = exports.CCoreSydsg = exports.CCoreSycr = exports.CCoreSypn = exports.CCoreSyoth = exports.CCoreSyupth = exports.CCoreSyth = exports.CCoreSylang = exports.CCoreSynat = exports.CCoreSyctr = exports.CCoreCyfm = exports.CCoreSyenm = exports.CCoreSygmt = exports.CCoreSygms = exports.CCoreSype = exports.CCoreSypgr = exports.CCoreSyptb = exports.CCoreSypin = exports.CCoreFinancialConfig = exports.CCoreSyco = exports.CCoreSyen = exports.CCoreSylog = exports.CCoreSyme = exports.CCoreSytm = exports.CCoreSypg = void 0;
|
|
17
|
+
exports.CCoreDashboardCards = exports.CCoreUserTypeMapping = exports.CCoreBoardGradeSystem = exports.CCoreBoardExamPattern = exports.CCoreEntityUdise = exports.CCoreSchoolBoardAffiliation = exports.CCoreEducationBoard = exports.CCoreUserRoleExceptions = exports.CCoreUserRoleRights = exports.CCoreUserRole = exports.CCoreUserFamilyDetails = exports.CCoreUserDocuments = exports.CCoreSydept = exports.CCoreSydsgl = exports.CCoreSydsg = exports.CCoreSycr = exports.CCoreSypn = exports.CCoreSyoth = exports.CCoreSyupth = exports.CCoreSyth = exports.CCoreSylang = exports.CCoreSynat = exports.CCoreSyctr = exports.CCoreCyfm = exports.CCoreSyenm = exports.CCoreSygmt = exports.CCoreSygms = exports.CCoreSype = exports.CCoreSypgr = exports.CCoreSyptb = exports.CCoreSypin = exports.CCoreFinancialConfig = exports.CCoreSyco = exports.CCoreSyen = exports.CCoreSylog = exports.CCoreSyme = exports.CCoreSytm = exports.CCoreSypg = void 0;
|
|
18
18
|
var core_system_pages_1 = require("./core_system_pages");
|
|
19
19
|
Object.defineProperty(exports, "CCoreSypg", { enumerable: true, get: function () { return core_system_pages_1.CCoreSypg; } });
|
|
20
20
|
var core_system_pages_theme_1 = require("./core_system_pages_theme");
|
|
@@ -89,5 +89,7 @@ var core_board_exam_pattern_1 = require("./core_board_exam_pattern");
|
|
|
89
89
|
Object.defineProperty(exports, "CCoreBoardExamPattern", { enumerable: true, get: function () { return core_board_exam_pattern_1.CCoreBoardExamPattern; } });
|
|
90
90
|
var core_board_grade_system_1 = require("./core_board_grade_system");
|
|
91
91
|
Object.defineProperty(exports, "CCoreBoardGradeSystem", { enumerable: true, get: function () { return core_board_grade_system_1.CCoreBoardGradeSystem; } });
|
|
92
|
+
var core_dashboard_cards_1 = require("./core_dashboard_cards");
|
|
93
|
+
Object.defineProperty(exports, "CCoreDashboardCards", { enumerable: true, get: function () { return core_dashboard_cards_1.CCoreDashboardCards; } });
|
|
92
94
|
__exportStar(require("./core_user_contact_addresses"), exports);
|
|
93
95
|
__exportStar(require("./core_entity_access_pass_management"), exports);
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import mongoose from "mongoose";
|
|
2
|
+
declare const CFeePayment: mongoose.Model<{
|
|
3
|
+
[x: string]: unknown;
|
|
4
|
+
}, {}, {}, {}, mongoose.Document<unknown, {}, {
|
|
5
|
+
[x: string]: unknown;
|
|
6
|
+
}, {}> & {
|
|
7
|
+
[x: string]: unknown;
|
|
8
|
+
} & Required<{
|
|
9
|
+
_id: unknown;
|
|
10
|
+
}> & {
|
|
11
|
+
__v: number;
|
|
12
|
+
}, mongoose.Schema<any, mongoose.Model<any, any, any, any, any, any>, {}, {}, {}, {}, mongoose.DefaultSchemaOptions, {
|
|
13
|
+
[x: string]: unknown;
|
|
14
|
+
}, mongoose.Document<unknown, {}, mongoose.FlatRecord<{
|
|
15
|
+
[x: string]: unknown;
|
|
16
|
+
}>, {}> & mongoose.FlatRecord<{
|
|
17
|
+
[x: string]: unknown;
|
|
18
|
+
}> & Required<{
|
|
19
|
+
_id: unknown;
|
|
20
|
+
}> & {
|
|
21
|
+
__v: number;
|
|
22
|
+
}>>;
|
|
23
|
+
export { CFeePayment };
|
|
@@ -0,0 +1,221 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CFeePayment = void 0;
|
|
4
|
+
var mongoose_1 = require("mongoose");
|
|
5
|
+
/**
|
|
6
|
+
* Fee Payment Schema
|
|
7
|
+
*
|
|
8
|
+
* Purpose: Payment records for student fees
|
|
9
|
+
* Used by: Fees, Accounts modules
|
|
10
|
+
*
|
|
11
|
+
* BUSINESS LOGIC:
|
|
12
|
+
* 1. Records all fee payments made by students
|
|
13
|
+
* 2. Supports multiple payment methods (Cash, Cheque, Online, etc.)
|
|
14
|
+
* 3. Links to fee assignments being paid
|
|
15
|
+
* 4. Tracks payment status and reconciliation
|
|
16
|
+
* 5. Generates receipts automatically
|
|
17
|
+
* 6. Supports partial payments
|
|
18
|
+
* 7. Integrates with payment gateways
|
|
19
|
+
*/
|
|
20
|
+
/* SCHEMA START */
|
|
21
|
+
var fee_payment = new mongoose_1.Schema({
|
|
22
|
+
feepay_receipt_number: {
|
|
23
|
+
type: String,
|
|
24
|
+
required: false,
|
|
25
|
+
unique: true,
|
|
26
|
+
sparse: true,
|
|
27
|
+
maxlength: 50,
|
|
28
|
+
trim: true,
|
|
29
|
+
comment: "Unique receipt number (auto-generated)"
|
|
30
|
+
},
|
|
31
|
+
feepay_student_id: {
|
|
32
|
+
type: String,
|
|
33
|
+
required: true,
|
|
34
|
+
comment: "Student ID (from admission form admap_student_id) - will be ObjectId when student schema exists"
|
|
35
|
+
},
|
|
36
|
+
feepay_academic_year_id_acayr: {
|
|
37
|
+
type: mongoose_1.default.Schema.Types.ObjectId,
|
|
38
|
+
ref: "aca_academic_year",
|
|
39
|
+
required: true,
|
|
40
|
+
comment: "Academic year"
|
|
41
|
+
},
|
|
42
|
+
feepay_entity_id_syen: {
|
|
43
|
+
type: mongoose_1.default.Schema.Types.ObjectId,
|
|
44
|
+
ref: "core_system_entity",
|
|
45
|
+
required: true,
|
|
46
|
+
comment: "Entity/Organization"
|
|
47
|
+
},
|
|
48
|
+
feepay_payment_date: {
|
|
49
|
+
type: Date,
|
|
50
|
+
required: true,
|
|
51
|
+
default: Date.now,
|
|
52
|
+
comment: "Payment date"
|
|
53
|
+
},
|
|
54
|
+
feepay_payment_mode: {
|
|
55
|
+
type: String,
|
|
56
|
+
required: true,
|
|
57
|
+
enum: ['CASH', 'CHEQUE', 'DD', 'ONLINE', 'CARD', 'UPI', 'NET_BANKING', 'BANK_TRANSFER', 'NEFT', 'RTGS', 'OTHER'],
|
|
58
|
+
comment: "Payment mode/method"
|
|
59
|
+
},
|
|
60
|
+
feepay_payment_reference: {
|
|
61
|
+
type: String,
|
|
62
|
+
maxlength: 100,
|
|
63
|
+
trim: true,
|
|
64
|
+
default: null,
|
|
65
|
+
comment: "Payment reference (cheque number, transaction ID, etc.)"
|
|
66
|
+
},
|
|
67
|
+
feepay_bank_name: {
|
|
68
|
+
type: String,
|
|
69
|
+
maxlength: 100,
|
|
70
|
+
trim: true,
|
|
71
|
+
default: null,
|
|
72
|
+
comment: "Bank name (if cheque/bank transfer)"
|
|
73
|
+
},
|
|
74
|
+
feepay_bank_branch_name: {
|
|
75
|
+
type: String,
|
|
76
|
+
maxlength: 100,
|
|
77
|
+
trim: true,
|
|
78
|
+
default: null,
|
|
79
|
+
comment: "Bank branch name (if cheque/bank transfer)"
|
|
80
|
+
},
|
|
81
|
+
feepay_bank_ifsc_code: {
|
|
82
|
+
type: String,
|
|
83
|
+
maxlength: 11,
|
|
84
|
+
trim: true,
|
|
85
|
+
default: null,
|
|
86
|
+
comment: "Bank IFSC code (if cheque/bank transfer)"
|
|
87
|
+
},
|
|
88
|
+
feepay_instrument_date: {
|
|
89
|
+
type: Date,
|
|
90
|
+
default: null,
|
|
91
|
+
comment: "Instrument date (cheque date, DD date, etc.)"
|
|
92
|
+
},
|
|
93
|
+
feepay_cheque_number: {
|
|
94
|
+
type: String,
|
|
95
|
+
maxlength: 50,
|
|
96
|
+
trim: true,
|
|
97
|
+
default: null,
|
|
98
|
+
comment: "Cheque number (if cheque payment)"
|
|
99
|
+
},
|
|
100
|
+
feepay_cheque_date: {
|
|
101
|
+
type: Date,
|
|
102
|
+
default: null,
|
|
103
|
+
comment: "Cheque date (if cheque payment)"
|
|
104
|
+
},
|
|
105
|
+
feepay_bank_account_number: {
|
|
106
|
+
type: String,
|
|
107
|
+
maxlength: 50,
|
|
108
|
+
trim: true,
|
|
109
|
+
default: null,
|
|
110
|
+
comment: "Bank account number (if bank transfer)"
|
|
111
|
+
},
|
|
112
|
+
feepay_transaction_reference: {
|
|
113
|
+
type: String,
|
|
114
|
+
maxlength: 100,
|
|
115
|
+
trim: true,
|
|
116
|
+
default: null,
|
|
117
|
+
comment: "Transaction reference number (for online payments)"
|
|
118
|
+
},
|
|
119
|
+
feepay_gateway_transaction_id: {
|
|
120
|
+
type: String,
|
|
121
|
+
maxlength: 100,
|
|
122
|
+
trim: true,
|
|
123
|
+
default: null,
|
|
124
|
+
comment: "Payment gateway transaction ID"
|
|
125
|
+
},
|
|
126
|
+
feepay_gateway_reference_id: {
|
|
127
|
+
type: String,
|
|
128
|
+
maxlength: 100,
|
|
129
|
+
trim: true,
|
|
130
|
+
default: null,
|
|
131
|
+
comment: "Payment gateway reference ID"
|
|
132
|
+
},
|
|
133
|
+
feepay_discount_percentage: {
|
|
134
|
+
type: Number,
|
|
135
|
+
default: 0,
|
|
136
|
+
min: 0,
|
|
137
|
+
max: 100,
|
|
138
|
+
comment: "Discount percentage applied"
|
|
139
|
+
},
|
|
140
|
+
feepay_discount_on: {
|
|
141
|
+
type: String,
|
|
142
|
+
enum: ['SUB_TOTAL', 'FEE_HEAD', 'TOTAL', 'INSTALLMENT'],
|
|
143
|
+
default: null,
|
|
144
|
+
comment: "Discount applied on: Sub Total, Fee Head, Total, or Installment"
|
|
145
|
+
},
|
|
146
|
+
feepay_discount_reason: {
|
|
147
|
+
type: String,
|
|
148
|
+
maxlength: 500,
|
|
149
|
+
trim: true,
|
|
150
|
+
default: null,
|
|
151
|
+
comment: "Reason for discount"
|
|
152
|
+
},
|
|
153
|
+
feepay_total_amount: {
|
|
154
|
+
type: Number,
|
|
155
|
+
required: true,
|
|
156
|
+
min: 0,
|
|
157
|
+
comment: "Total payment amount"
|
|
158
|
+
},
|
|
159
|
+
feepay_late_fee_amount: {
|
|
160
|
+
type: Number,
|
|
161
|
+
required: true,
|
|
162
|
+
default: 0,
|
|
163
|
+
min: 0,
|
|
164
|
+
comment: "Amount paid towards late fees"
|
|
165
|
+
},
|
|
166
|
+
feepay_discount_amount: {
|
|
167
|
+
type: Number,
|
|
168
|
+
required: true,
|
|
169
|
+
default: 0,
|
|
170
|
+
min: 0,
|
|
171
|
+
comment: "Discount amount applied"
|
|
172
|
+
},
|
|
173
|
+
feepay_remarks: {
|
|
174
|
+
type: String,
|
|
175
|
+
maxlength: 1000,
|
|
176
|
+
trim: true,
|
|
177
|
+
default: null,
|
|
178
|
+
comment: "Additional remarks/notes"
|
|
179
|
+
},
|
|
180
|
+
feepay_status: {
|
|
181
|
+
type: String,
|
|
182
|
+
required: true,
|
|
183
|
+
enum: ['SUCCESS', 'PENDING', 'FAILED', 'CANCELLED', 'REFUNDED'],
|
|
184
|
+
default: 'PENDING',
|
|
185
|
+
comment: "Payment status"
|
|
186
|
+
},
|
|
187
|
+
feepay_receipt_template_id_feert: {
|
|
188
|
+
type: mongoose_1.default.Schema.Types.ObjectId,
|
|
189
|
+
ref: "fee_receipt_templates",
|
|
190
|
+
default: null,
|
|
191
|
+
comment: "Receipt template used (if custom)"
|
|
192
|
+
},
|
|
193
|
+
feepay_created_by_user: {
|
|
194
|
+
type: mongoose_1.default.Schema.Types.ObjectId,
|
|
195
|
+
ref: "auth_user_mst",
|
|
196
|
+
required: false,
|
|
197
|
+
default: null,
|
|
198
|
+
comment: "User who created the payment"
|
|
199
|
+
},
|
|
200
|
+
feepay_isactive: {
|
|
201
|
+
type: Boolean,
|
|
202
|
+
default: true,
|
|
203
|
+
comment: "Active status flag"
|
|
204
|
+
}
|
|
205
|
+
}, {
|
|
206
|
+
collection: 'fee_payments',
|
|
207
|
+
timestamps: true // Adds created_at and updated_at
|
|
208
|
+
});
|
|
209
|
+
// Indexes for performance
|
|
210
|
+
fee_payment.index({ feepay_receipt_number: 1 }, { unique: true, sparse: true });
|
|
211
|
+
fee_payment.index({ feepay_student_id: 1, feepay_payment_date: -1 });
|
|
212
|
+
fee_payment.index({ feepay_payment_date: -1 });
|
|
213
|
+
fee_payment.index({ feepay_status: 1, feepay_payment_date: -1 });
|
|
214
|
+
fee_payment.index({ feepay_entity_id_syen: 1, feepay_academic_year_id_acayr: 1 });
|
|
215
|
+
fee_payment.index({ feepay_transaction_reference: 1 });
|
|
216
|
+
fee_payment.index({ feepay_gateway_transaction_id: 1 });
|
|
217
|
+
/* SCHEMA END */
|
|
218
|
+
// Note: Interface will be defined in cloud-ide-lms-model
|
|
219
|
+
// For now, export the schema model
|
|
220
|
+
var CFeePayment = mongoose_1.default.model("fee_payments", fee_payment);
|
|
221
|
+
exports.CFeePayment = CFeePayment;
|
|
@@ -36,6 +36,18 @@ var fee_structure_item = new mongoose_1.Schema({
|
|
|
36
36
|
trim: true,
|
|
37
37
|
comment: "Fee item description"
|
|
38
38
|
},
|
|
39
|
+
feesi_fee_type: {
|
|
40
|
+
type: String,
|
|
41
|
+
enum: ['ONE_TIME', 'RECURRING'],
|
|
42
|
+
default: 'ONE_TIME',
|
|
43
|
+
comment: "Fee type: One-time or Recurring"
|
|
44
|
+
},
|
|
45
|
+
feesi_payment_frequency: {
|
|
46
|
+
type: String,
|
|
47
|
+
enum: ['MONTHLY', 'QUARTERLY', 'SEMESTER', 'ANNUAL', 'ONE_TIME'],
|
|
48
|
+
default: 'ONE_TIME',
|
|
49
|
+
comment: "Payment frequency for recurring fees"
|
|
50
|
+
},
|
|
39
51
|
feesi_amount: {
|
|
40
52
|
type: Number,
|
|
41
53
|
required: true,
|
package/lib/schema/fees/index.js
CHANGED
|
@@ -18,3 +18,4 @@ __exportStar(require("./fee_assignment"), exports);
|
|
|
18
18
|
__exportStar(require("./fee_structure"), exports);
|
|
19
19
|
__exportStar(require("./fee_structure_item"), exports);
|
|
20
20
|
__exportStar(require("./fee_receipt_template"), exports);
|
|
21
|
+
__exportStar(require("./fee_payment"), exports);
|
package/package.json
CHANGED