lfra_db 1.0.3 → 1.0.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lfra_db",
3
- "version": "1.0.3",
3
+ "version": "1.0.4",
4
4
  "main": "index.js",
5
5
  "scripts": {
6
6
  "test": "echo \"Error: no test specified\" && exit 1"
@@ -18,14 +18,23 @@ const visitLogSchema = new mongoose.Schema({
18
18
  residentId: {
19
19
  type: mongoose.Schema.Types.ObjectId,
20
20
  },
21
- qrCode:{
22
- type:Boolean,
23
- required:false
21
+ userId: {
22
+ type: String,
23
+ required: false
24
+
25
+ },
26
+ qrCode: {
27
+ type: Boolean,
28
+ required: false
24
29
  },
25
30
  houseNumber: {
26
31
  type: String,
27
32
  required: false
28
33
  },
34
+ phoneNumber: {
35
+ type: String,
36
+ required: false
37
+ },
29
38
  startTime: {
30
39
  type: String, // Changed to Date for better handling of time
31
40
  required: true
@@ -34,26 +43,26 @@ const visitLogSchema = new mongoose.Schema({
34
43
  type: Date, // Changed to Date for better handling of time
35
44
  required: false
36
45
  },
37
- days:{
38
- type:Number,
39
- required:false
46
+ days: {
47
+ type: Number,
48
+ required: false
40
49
  },
41
- division:{
42
- type:String,
43
- required:false
50
+ division: {
51
+ type: String,
52
+ required: false
44
53
  },
45
- entryPoint:{
46
- type:String,
47
- required:false
54
+ entryPoint: {
55
+ type: String,
56
+ required: false
48
57
  },
49
- exitPoint:{
50
- type:String,
51
- required:false
58
+ exitPoint: {
59
+ type: String,
60
+ required: false
52
61
  },
53
62
  status: {
54
63
  type: String,
55
64
  required: true,
56
- enum: ['Visit Confirmation', 'Scheduled', 'Checked In','Checked Out', 'Cancelled'] // Define valid statuses
65
+ enum: ['Visit Confirmation', 'Scheduled', 'Checked In', 'Checked Out', 'Cancelled'] // Define valid statuses
57
66
  // Define valid statuses
58
67
  },
59
68
  vehicle: {
@@ -66,17 +75,17 @@ const visitLogSchema = new mongoose.Schema({
66
75
  type: Number,
67
76
  required: false
68
77
  },
69
- requestedBy:{
70
- type:mongoose.Schema.Types.ObjectId,
71
- ref:"User",
72
- required:false
78
+ requestedBy: {
79
+ type: mongoose.Schema.Types.ObjectId,
80
+ ref: "User",
81
+ required: false
73
82
  },
74
83
  facilityId: {
75
84
  type: mongoose.Schema.Types.ObjectId,
76
85
  ref: 'Facility',
77
86
  required: true // Ensures a facilityId is always provided
78
- }
79
- }, {
87
+ },
88
+
80
89
  timestamps: true // Automatically add createdAt and updatedAt fields
81
90
  });
82
91
 
@@ -33,8 +33,7 @@ const waitListSchema = new mongoose.Schema({
33
33
  type: mongoose.Schema.Types.ObjectId,
34
34
  ref: 'Facility',
35
35
  required: true // Ensures a facilityId is always provided
36
- },
37
-
36
+ }
38
37
  }, {
39
38
  timestamps: true // Automatically add createdAt and updatedAt fields
40
39
  });