@likewatt/models 1.0.61 → 1.0.62
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/dist/core/Scenario.d.ts +20 -0
- package/dist/core/Scenario.js +74 -1
- package/package.json +1 -1
package/dist/core/Scenario.d.ts
CHANGED
|
@@ -46,6 +46,19 @@ export declare const DemandMultiplierSlotSchema: MSchema<DemandMultiplierSlot, i
|
|
|
46
46
|
} & {
|
|
47
47
|
__v: number;
|
|
48
48
|
}>;
|
|
49
|
+
export declare class DistributionKey {
|
|
50
|
+
type: string;
|
|
51
|
+
values: (string | number)[];
|
|
52
|
+
}
|
|
53
|
+
export declare const DistributionKeySchema: MSchema<DistributionKey, import("mongoose").Model<DistributionKey, any, any, any, Document<unknown, any, DistributionKey, any, {}> & DistributionKey & {
|
|
54
|
+
_id: Types.ObjectId;
|
|
55
|
+
} & {
|
|
56
|
+
__v: number;
|
|
57
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, DistributionKey, Document<unknown, {}, import("mongoose").FlatRecord<DistributionKey>, {}, import("mongoose").ResolveSchemaOptions<import("mongoose").DefaultSchemaOptions>> & import("mongoose").FlatRecord<DistributionKey> & {
|
|
58
|
+
_id: Types.ObjectId;
|
|
59
|
+
} & {
|
|
60
|
+
__v: number;
|
|
61
|
+
}>;
|
|
49
62
|
export declare class RateOfGrowth {
|
|
50
63
|
id: string;
|
|
51
64
|
rate: number;
|
|
@@ -94,9 +107,16 @@ export declare const ConfigScenarioSchema: MSchema<ConfigScenario, import("mongo
|
|
|
94
107
|
__v: number;
|
|
95
108
|
}>;
|
|
96
109
|
export declare class ConfigSite {
|
|
110
|
+
ACI?: boolean;
|
|
97
111
|
consumptionReference?: string;
|
|
112
|
+
counterNumber?: number;
|
|
113
|
+
demandMultiplier?: number;
|
|
98
114
|
demandMultiplierSlots?: DemandMultiplierSlot[];
|
|
115
|
+
demandMultiplierUnit?: string;
|
|
116
|
+
distributionKey?: DistributionKey[];
|
|
117
|
+
priorityStage?: number;
|
|
99
118
|
rateOfGrowth?: RateOfGrowth[];
|
|
119
|
+
settings: Record<string, unknown>;
|
|
100
120
|
}
|
|
101
121
|
export declare const ConfigSiteSchema: MSchema<ConfigSite, import("mongoose").Model<ConfigSite, any, any, any, Document<unknown, any, ConfigSite, any, {}> & ConfigSite & {
|
|
102
122
|
_id: Types.ObjectId;
|
package/dist/core/Scenario.js
CHANGED
|
@@ -9,7 +9,7 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.ScenarioSchema = exports.Scenario = exports.ConfigSiteSchema = exports.ConfigSite = exports.ConfigScenarioSchema = exports.ConfigScenario = exports.TechnologySchema = exports.Technology = exports.RateOfGrowthSchema = exports.RateOfGrowth = exports.DemandMultiplierSlotSchema = exports.DemandMultiplierSlot = exports.MonthSchema = exports.Month = exports.ObjectiveSchema = exports.Objective = void 0;
|
|
12
|
+
exports.ScenarioSchema = exports.Scenario = exports.ConfigSiteSchema = exports.ConfigSite = exports.ConfigScenarioSchema = exports.ConfigScenario = exports.TechnologySchema = exports.Technology = exports.RateOfGrowthSchema = exports.RateOfGrowth = exports.DistributionKeySchema = exports.DistributionKey = exports.DemandMultiplierSlotSchema = exports.DemandMultiplierSlot = exports.MonthSchema = exports.Month = exports.ObjectiveSchema = exports.Objective = void 0;
|
|
13
13
|
const mongoose_1 = require("@nestjs/mongoose");
|
|
14
14
|
const mongoose_2 = require("mongoose");
|
|
15
15
|
const swagger_1 = require("@nestjs/swagger");
|
|
@@ -125,6 +125,25 @@ exports.DemandMultiplierSlot = DemandMultiplierSlot = __decorate([
|
|
|
125
125
|
(0, mongoose_1.Schema)({ _id: false })
|
|
126
126
|
], DemandMultiplierSlot);
|
|
127
127
|
exports.DemandMultiplierSlotSchema = mongoose_1.SchemaFactory.createForClass(DemandMultiplierSlot);
|
|
128
|
+
let DistributionKey = class DistributionKey {
|
|
129
|
+
};
|
|
130
|
+
exports.DistributionKey = DistributionKey;
|
|
131
|
+
__decorate([
|
|
132
|
+
(0, swagger_1.ApiProperty)({ example: 'prorata' }),
|
|
133
|
+
(0, mongoose_1.Prop)({ required: false }),
|
|
134
|
+
(0, class_validator_1.IsString)(),
|
|
135
|
+
__metadata("design:type", String)
|
|
136
|
+
], DistributionKey.prototype, "type", void 0);
|
|
137
|
+
__decorate([
|
|
138
|
+
(0, swagger_1.ApiProperty)({ example: [] }),
|
|
139
|
+
(0, mongoose_1.Prop)({ required: false }),
|
|
140
|
+
(0, class_validator_1.IsArray)(),
|
|
141
|
+
__metadata("design:type", Array)
|
|
142
|
+
], DistributionKey.prototype, "values", void 0);
|
|
143
|
+
exports.DistributionKey = DistributionKey = __decorate([
|
|
144
|
+
(0, mongoose_1.Schema)({ _id: false })
|
|
145
|
+
], DistributionKey);
|
|
146
|
+
exports.DistributionKeySchema = mongoose_1.SchemaFactory.createForClass(DistributionKey);
|
|
128
147
|
let RateOfGrowth = class RateOfGrowth {
|
|
129
148
|
};
|
|
130
149
|
exports.RateOfGrowth = RateOfGrowth;
|
|
@@ -245,6 +264,13 @@ exports.ConfigScenarioSchema = mongoose_1.SchemaFactory.createForClass(ConfigSce
|
|
|
245
264
|
let ConfigSite = class ConfigSite {
|
|
246
265
|
};
|
|
247
266
|
exports.ConfigSite = ConfigSite;
|
|
267
|
+
__decorate([
|
|
268
|
+
(0, swagger_1.ApiPropertyOptional)({ example: true }),
|
|
269
|
+
(0, mongoose_1.Prop)(),
|
|
270
|
+
(0, class_validator_1.IsOptional)(),
|
|
271
|
+
(0, class_validator_1.IsBoolean)(),
|
|
272
|
+
__metadata("design:type", Boolean)
|
|
273
|
+
], ConfigSite.prototype, "ACI", void 0);
|
|
248
274
|
__decorate([
|
|
249
275
|
(0, swagger_1.ApiProperty)({ example: 'REFERENCE', required: false }),
|
|
250
276
|
(0, mongoose_1.Prop)({ required: false }),
|
|
@@ -252,6 +278,20 @@ __decorate([
|
|
|
252
278
|
(0, class_validator_1.IsString)(),
|
|
253
279
|
__metadata("design:type", String)
|
|
254
280
|
], ConfigSite.prototype, "consumptionReference", void 0);
|
|
281
|
+
__decorate([
|
|
282
|
+
(0, swagger_1.ApiPropertyOptional)({ example: 1 }),
|
|
283
|
+
(0, mongoose_1.Prop)(),
|
|
284
|
+
(0, class_validator_1.IsOptional)(),
|
|
285
|
+
(0, class_validator_1.IsNumber)(),
|
|
286
|
+
__metadata("design:type", Number)
|
|
287
|
+
], ConfigSite.prototype, "counterNumber", void 0);
|
|
288
|
+
__decorate([
|
|
289
|
+
(0, swagger_1.ApiPropertyOptional)({ example: 1 }),
|
|
290
|
+
(0, mongoose_1.Prop)(),
|
|
291
|
+
(0, class_validator_1.IsOptional)(),
|
|
292
|
+
(0, class_validator_1.IsNumber)(),
|
|
293
|
+
__metadata("design:type", Number)
|
|
294
|
+
], ConfigSite.prototype, "demandMultiplier", void 0);
|
|
255
295
|
__decorate([
|
|
256
296
|
(0, swagger_1.ApiProperty)({ type: [DemandMultiplierSlot], required: false }),
|
|
257
297
|
(0, mongoose_1.Prop)({
|
|
@@ -263,6 +303,31 @@ __decorate([
|
|
|
263
303
|
(0, class_validator_1.IsArray)(),
|
|
264
304
|
__metadata("design:type", Array)
|
|
265
305
|
], ConfigSite.prototype, "demandMultiplierSlots", void 0);
|
|
306
|
+
__decorate([
|
|
307
|
+
(0, swagger_1.ApiProperty)({ example: 'POWER', required: false }),
|
|
308
|
+
(0, mongoose_1.Prop)({ required: false }),
|
|
309
|
+
(0, class_validator_1.IsOptional)(),
|
|
310
|
+
(0, class_validator_1.IsString)(),
|
|
311
|
+
__metadata("design:type", String)
|
|
312
|
+
], ConfigSite.prototype, "demandMultiplierUnit", void 0);
|
|
313
|
+
__decorate([
|
|
314
|
+
(0, swagger_1.ApiProperty)({ type: [DistributionKey], required: false }),
|
|
315
|
+
(0, mongoose_1.Prop)({
|
|
316
|
+
type: [exports.DistributionKeySchema],
|
|
317
|
+
required: false,
|
|
318
|
+
default: undefined,
|
|
319
|
+
}),
|
|
320
|
+
(0, class_validator_1.IsOptional)(),
|
|
321
|
+
(0, class_validator_1.IsArray)(),
|
|
322
|
+
__metadata("design:type", Array)
|
|
323
|
+
], ConfigSite.prototype, "distributionKey", void 0);
|
|
324
|
+
__decorate([
|
|
325
|
+
(0, swagger_1.ApiPropertyOptional)({ example: 1 }),
|
|
326
|
+
(0, mongoose_1.Prop)(),
|
|
327
|
+
(0, class_validator_1.IsOptional)(),
|
|
328
|
+
(0, class_validator_1.IsNumber)(),
|
|
329
|
+
__metadata("design:type", Number)
|
|
330
|
+
], ConfigSite.prototype, "priorityStage", void 0);
|
|
266
331
|
__decorate([
|
|
267
332
|
(0, swagger_1.ApiProperty)({ type: [RateOfGrowth], required: false }),
|
|
268
333
|
(0, mongoose_1.Prop)({
|
|
@@ -274,6 +339,14 @@ __decorate([
|
|
|
274
339
|
(0, class_validator_1.IsArray)(),
|
|
275
340
|
__metadata("design:type", Array)
|
|
276
341
|
], ConfigSite.prototype, "rateOfGrowth", void 0);
|
|
342
|
+
__decorate([
|
|
343
|
+
(0, swagger_1.ApiProperty)({
|
|
344
|
+
example: { power: 100, orientation: 'south', tilt: 30 },
|
|
345
|
+
}),
|
|
346
|
+
(0, mongoose_1.Prop)({ type: mongoose_2.Schema.Types.Mixed, required: true }),
|
|
347
|
+
(0, class_validator_1.IsObject)(),
|
|
348
|
+
__metadata("design:type", Object)
|
|
349
|
+
], ConfigSite.prototype, "settings", void 0);
|
|
277
350
|
exports.ConfigSite = ConfigSite = __decorate([
|
|
278
351
|
(0, mongoose_1.Schema)({ _id: false })
|
|
279
352
|
], ConfigSite);
|