@dhyasama/totem-models 11.67.0 → 11.70.0

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/Financials.js CHANGED
@@ -86,7 +86,6 @@ module.exports = function(mongoose, config) {
86
86
  form: [{
87
87
  name: { type: String, trim: true },
88
88
  type: { type: String, enum: [null, 'header', 'block', 'document', 'metric', 'question'] },
89
- actual: { type: Boolean, default: false },
90
89
  budget: { type: Boolean, default: false },
91
90
  forecast: { type: Boolean, default: false },
92
91
  required: { type: Boolean, default: false }
@@ -103,6 +102,7 @@ module.exports = function(mongoose, config) {
103
102
  name: { type: String, trim: true },
104
103
  actual: { type: Number },
105
104
  budget: { type: Number },
105
+ forecast: { type: Number },
106
106
  breakdown: { type: Schema.Types.Mixed }
107
107
  }],
108
108
 
@@ -338,6 +338,7 @@ module.exports = function(mongoose, config) {
338
338
  console.log('Upserting metric name:', metric.name);
339
339
  console.log('Upserting metric actual:', metric.actual);
340
340
  console.log('Upserting metric budget:', metric.budget);
341
+ console.log('Upserting metric forecast:', metric.forecast);
341
342
  console.log('Upserting metric breakdown:', metric.breakdown);
342
343
 
343
344
  // Check if the metric exists and update it
@@ -351,6 +352,7 @@ module.exports = function(mongoose, config) {
351
352
  $set: {
352
353
  'snapshots.$.metrics.$[metric].actual': metric.actual,
353
354
  'snapshots.$.metrics.$[metric].budget': metric.budget,
355
+ 'snapshots.$.metrics.$[metric].forecast': metric.forecast,
354
356
  'snapshots.$.metrics.$[metric].breakdown': metric.breakdown,
355
357
  }
356
358
  },
@@ -320,7 +320,6 @@ module.exports = function(mongoose, config) {
320
320
  _id: false,
321
321
  name: { type: String, trim: true },
322
322
  type: { type: String, enum: [null, 'header', 'block', 'document', 'metric', 'question'] },
323
- actual: { type: Boolean, default: false },
324
323
  budget: { type: Boolean, default: false },
325
324
  forecast: { type: Boolean, default: false },
326
325
  required: { type: Boolean, default: false }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dhyasama/totem-models",
3
- "version": "11.67.0",
3
+ "version": "11.70.0",
4
4
  "author": "Jason Reynolds",
5
5
  "license": "UNLICENSED",
6
6
  "description": "Models for Totem platform",