payservedb 3.3.2 → 3.3.4

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/index.js CHANGED
@@ -116,7 +116,8 @@ const models = {
116
116
  Handover:require('./src/models/handover'),
117
117
  Budget:require('./src/models/budget'),
118
118
  BudgetCategory:require('./src/models/budgetCategory'),
119
- Expense:require('./src/models/expense')
119
+ Expense:require('./src/models/expense'),
120
+ InvoiceSettings:require('./src/models/levy_invoice_settings')
120
121
 
121
122
 
122
123
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "payservedb",
3
- "version": "3.3.2",
3
+ "version": "3.3.4",
4
4
  "main": "index.js",
5
5
  "scripts": {
6
6
  "test": "echo \"Error: no test specified\" && exit 1"
@@ -0,0 +1,27 @@
1
+ const mongoose = require('mongoose');
2
+
3
+ const InvoiceSettingsSchema = new mongoose.Schema({
4
+ facilityId: {
5
+ type: mongoose.Schema.Types.ObjectId,
6
+ ref: 'Facility',
7
+ required: [true, 'Facility ID is required']
8
+ },
9
+ termsAndConditions: {
10
+ type: String,
11
+ default: 'Payment is due within 15 days'
12
+ },
13
+ bankName: {
14
+ type: String,
15
+ required: [true, 'Bank name is required']
16
+ },
17
+ accountNumber: {
18
+ type: String,
19
+ required: [true, 'Account number is required']
20
+ }
21
+ }, {
22
+ timestamps: true
23
+ });
24
+
25
+ const InvoiceSettings = mongoose.model('InvoiceSettings', InvoiceSettingsSchema);
26
+
27
+ module.exports = InvoiceSettings;