vhp-mongo-models 1.6.1 → 1.6.3

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.
@@ -6,7 +6,7 @@ module.exports = [
6
6
  ...aticket,
7
7
  status: { type: String, default: 'active' },
8
8
  documents: { type: Array, default: [] },
9
- approval:{type:String,default:'NOT'}, // NOT | SENT | APPROVED
9
+ approval:{type:String,default:'WORKING'}, // WORKING | SENT | APPROVED
10
10
  approvalCode:{type:String,default:''}
11
- }
11
+ },{minimize:false}
12
12
  ]
@@ -1,17 +1,17 @@
1
1
  const { Schema } = require('mongoose')
2
2
 
3
- let ticketInvoice = new Schema({
3
+ let ticketInvoice = {
4
4
  total:{type:Number,default:0},
5
5
  pricelevel:{type:String,default:''}
6
- })
6
+ }
7
7
 
8
- let repairEstimate = new Schema({
8
+ let repairEstimate = {
9
9
  time:{type:Number,default:0}, //time to complete all repairs
10
10
  revenuePerEstimate:{type:Number,default:0},
11
11
  revenuePer:{type:Number,default:0}
12
- })
12
+ }
13
13
 
14
- let ticketFinal = new Schema({
14
+ let ticketFinal = {
15
15
  showReplacement:{type:Boolean,default:false},
16
16
  summary:{type:Object,default:{}}, //a static version of the presentation
17
17
  conform:{type:Object,default:{}},
@@ -26,7 +26,34 @@ let ticketFinal = new Schema({
26
26
  repairEstimate:repairEstimate, //was ticketTime
27
27
  timelog:{type:Object,default:{}},
28
28
  officeSubmit:{type:String,default:''},
29
- completedBy:{type:Array,default:[]} //change to string, and tag with the lead who completed
30
- })
29
+ completedBy:{type:Array,default:[]} //change to string, lcoaland tag with the lead who completed
30
+ }
31
31
 
32
- module.exports = ticketFinal
32
+ module.exports = ticketFinal
33
+
34
+ /*
35
+ summary = {
36
+ approved:{
37
+ name:{type:String,default:''},
38
+ signature:{type:String,default:''}
39
+ }
40
+ total:{
41
+ mprice:{type:Number,default:0},
42
+ rprice:{type:Number,default:0},
43
+ msavings:{type:Number,default:0},
44
+ rsavings:{type:Number,default:0}
45
+ }
46
+ repairs:{
47
+ <sitem.id>:[{
48
+ repair:{
49
+ task:{type:String,default:''}
50
+ appr:{type:String,default:''} // YES | NO | RETURNFOR
51
+ }
52
+ pricing:{
53
+ <pl1>:{type:Number,default:0},
54
+ <pl2>:{type:Number,default:0}
55
+ }
56
+ }]
57
+ }
58
+ }
59
+ */
@@ -21,6 +21,14 @@ const ticketFinal = require('./final.js')
21
21
  ]
22
22
  */
23
23
 
24
+ /*
25
+ sitems = [{
26
+ id:{type:String,default:''}
27
+ descr:{type:String,default:''}
28
+ needReplace:{type:Boolean:default:false}
29
+ }]
30
+ */
31
+
24
32
  module.exports = {
25
33
  id: { type: String, default: '' },
26
34
  ref: { type: Object, default: {} },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vhp-mongo-models",
3
- "version": "1.6.1",
3
+ "version": "1.6.3",
4
4
  "productName": "VHP Mongo Models",
5
5
  "description": "Mongo Models library to setup Mongoose Schemas",
6
6
  "author": "VHPim",