@likewatt/models 1.0.40 → 1.0.41
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
CHANGED
|
@@ -16,12 +16,25 @@ export declare const ObjectiveSchema: MSchema<Objective, import("mongoose").Mode
|
|
|
16
16
|
} & {
|
|
17
17
|
__v: number;
|
|
18
18
|
}>;
|
|
19
|
+
export declare class Month {
|
|
20
|
+
month: number;
|
|
21
|
+
year?: number;
|
|
22
|
+
}
|
|
23
|
+
export declare const MonthSchema: MSchema<Month, import("mongoose").Model<Month, any, any, any, Document<unknown, any, Month, any> & Month & {
|
|
24
|
+
_id: Types.ObjectId;
|
|
25
|
+
} & {
|
|
26
|
+
__v: number;
|
|
27
|
+
}, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, Month, Document<unknown, {}, import("mongoose").FlatRecord<Month>, {}> & import("mongoose").FlatRecord<Month> & {
|
|
28
|
+
_id: Types.ObjectId;
|
|
29
|
+
} & {
|
|
30
|
+
__v: number;
|
|
31
|
+
}>;
|
|
19
32
|
export declare class DemandMultiplierSlot {
|
|
20
33
|
days: number[];
|
|
21
34
|
demandMultiplier?: number;
|
|
22
35
|
endHour?: number;
|
|
23
|
-
id:
|
|
24
|
-
months
|
|
36
|
+
id: string;
|
|
37
|
+
months?: Month[];
|
|
25
38
|
startHour?: number;
|
|
26
39
|
}
|
|
27
40
|
export declare const DemandMultiplierSlotSchema: MSchema<DemandMultiplierSlot, import("mongoose").Model<DemandMultiplierSlot, any, any, any, Document<unknown, any, DemandMultiplierSlot, any> & DemandMultiplierSlot & {
|
|
@@ -34,7 +47,7 @@ export declare const DemandMultiplierSlotSchema: MSchema<DemandMultiplierSlot, i
|
|
|
34
47
|
__v: number;
|
|
35
48
|
}>;
|
|
36
49
|
export declare class RateOfGrowth {
|
|
37
|
-
id:
|
|
50
|
+
id: string;
|
|
38
51
|
rate: number;
|
|
39
52
|
year?: number;
|
|
40
53
|
}
|
|
@@ -81,7 +94,7 @@ export declare const ConfigScenarioSchema: MSchema<ConfigScenario, import("mongo
|
|
|
81
94
|
__v: number;
|
|
82
95
|
}>;
|
|
83
96
|
export declare class ConfigSite {
|
|
84
|
-
|
|
97
|
+
consumptionReference: string;
|
|
85
98
|
demandMultiplierSlots: DemandMultiplierSlot[];
|
|
86
99
|
rateOfGrowth: RateOfGrowth[];
|
|
87
100
|
}
|
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.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.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");
|
|
@@ -59,11 +59,31 @@ exports.Objective = Objective = __decorate([
|
|
|
59
59
|
(0, mongoose_1.Schema)({ _id: false })
|
|
60
60
|
], Objective);
|
|
61
61
|
exports.ObjectiveSchema = mongoose_1.SchemaFactory.createForClass(Objective);
|
|
62
|
+
let Month = class Month {
|
|
63
|
+
};
|
|
64
|
+
exports.Month = Month;
|
|
65
|
+
__decorate([
|
|
66
|
+
(0, swagger_1.ApiProperty)({ example: 1 }),
|
|
67
|
+
(0, mongoose_1.Prop)({ required: true }),
|
|
68
|
+
(0, class_validator_1.IsNumber)(),
|
|
69
|
+
__metadata("design:type", Number)
|
|
70
|
+
], Month.prototype, "month", void 0);
|
|
71
|
+
__decorate([
|
|
72
|
+
(0, swagger_1.ApiPropertyOptional)({ example: 2020 }),
|
|
73
|
+
(0, mongoose_1.Prop)(),
|
|
74
|
+
(0, class_validator_1.IsOptional)(),
|
|
75
|
+
(0, class_validator_1.IsNumber)(),
|
|
76
|
+
__metadata("design:type", Number)
|
|
77
|
+
], Month.prototype, "year", void 0);
|
|
78
|
+
exports.Month = Month = __decorate([
|
|
79
|
+
(0, mongoose_1.Schema)({ _id: false })
|
|
80
|
+
], Month);
|
|
81
|
+
exports.MonthSchema = mongoose_1.SchemaFactory.createForClass(Month);
|
|
62
82
|
let DemandMultiplierSlot = class DemandMultiplierSlot {
|
|
63
83
|
};
|
|
64
84
|
exports.DemandMultiplierSlot = DemandMultiplierSlot;
|
|
65
85
|
__decorate([
|
|
66
|
-
(0, swagger_1.ApiProperty)({ example: [1, 2, 3] }),
|
|
86
|
+
(0, swagger_1.ApiProperty)({ example: [1, 2, 3, 4, 5, 6, 7] }),
|
|
67
87
|
(0, mongoose_1.Prop)({ required: true }),
|
|
68
88
|
(0, class_validator_1.IsArray)(),
|
|
69
89
|
__metadata("design:type", Array)
|
|
@@ -85,14 +105,14 @@ __decorate([
|
|
|
85
105
|
__decorate([
|
|
86
106
|
(0, swagger_1.ApiProperty)({ example: 0 }),
|
|
87
107
|
(0, mongoose_1.Prop)({ required: true }),
|
|
88
|
-
(0, class_validator_1.
|
|
89
|
-
__metadata("design:type",
|
|
108
|
+
(0, class_validator_1.IsString)(),
|
|
109
|
+
__metadata("design:type", String)
|
|
90
110
|
], DemandMultiplierSlot.prototype, "id", void 0);
|
|
91
111
|
__decorate([
|
|
92
|
-
(0, swagger_1.ApiProperty)({
|
|
93
|
-
(0, mongoose_1.Prop)({ type:
|
|
94
|
-
(0, class_validator_1.
|
|
95
|
-
__metadata("design:type",
|
|
112
|
+
(0, swagger_1.ApiProperty)({ type: [Month] }),
|
|
113
|
+
(0, mongoose_1.Prop)({ type: [exports.MonthSchema], required: true }),
|
|
114
|
+
(0, class_validator_1.IsArray)(),
|
|
115
|
+
__metadata("design:type", Array)
|
|
96
116
|
], DemandMultiplierSlot.prototype, "months", void 0);
|
|
97
117
|
__decorate([
|
|
98
118
|
(0, swagger_1.ApiPropertyOptional)({ example: 1 }),
|
|
@@ -112,7 +132,7 @@ __decorate([
|
|
|
112
132
|
(0, swagger_1.ApiProperty)({ example: 0 }),
|
|
113
133
|
(0, mongoose_1.Prop)({ required: true }),
|
|
114
134
|
(0, class_validator_1.IsString)(),
|
|
115
|
-
__metadata("design:type",
|
|
135
|
+
__metadata("design:type", String)
|
|
116
136
|
], RateOfGrowth.prototype, "id", void 0);
|
|
117
137
|
__decorate([
|
|
118
138
|
(0, swagger_1.ApiProperty)({ example: 0 }),
|
|
@@ -225,11 +245,11 @@ let ConfigSite = class ConfigSite {
|
|
|
225
245
|
};
|
|
226
246
|
exports.ConfigSite = ConfigSite;
|
|
227
247
|
__decorate([
|
|
228
|
-
(0, swagger_1.ApiProperty)({ example: '
|
|
248
|
+
(0, swagger_1.ApiProperty)({ example: 'REFERENCE' }),
|
|
229
249
|
(0, mongoose_1.Prop)({ required: true }),
|
|
230
250
|
(0, class_validator_1.IsString)(),
|
|
231
251
|
__metadata("design:type", String)
|
|
232
|
-
], ConfigSite.prototype, "
|
|
252
|
+
], ConfigSite.prototype, "consumptionReference", void 0);
|
|
233
253
|
__decorate([
|
|
234
254
|
(0, swagger_1.ApiProperty)({ type: [DemandMultiplierSlot] }),
|
|
235
255
|
(0, mongoose_1.Prop)({ type: [exports.DemandMultiplierSlotSchema], required: true }),
|
|
@@ -323,7 +343,7 @@ __decorate([
|
|
|
323
343
|
__metadata("design:type", Number)
|
|
324
344
|
], Scenario.prototype, "optimizationYear", void 0);
|
|
325
345
|
__decorate([
|
|
326
|
-
(0, swagger_1.ApiPropertyOptional)({ example: [1
|
|
346
|
+
(0, swagger_1.ApiPropertyOptional)({ example: [1] }),
|
|
327
347
|
(0, mongoose_1.Prop)(),
|
|
328
348
|
(0, class_validator_1.IsOptional)(),
|
|
329
349
|
(0, class_validator_1.IsNumber)(),
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.UseCase = exports.TrackerType = exports.FinancingTypeEnum = exports.Profiles = exports.SiteType = void 0;
|
|
3
|
+
exports.Reference = exports.UseCase = exports.TrackerType = exports.FinancingTypeEnum = exports.Profiles = exports.SiteType = void 0;
|
|
4
4
|
var SiteType;
|
|
5
5
|
(function (SiteType) {
|
|
6
6
|
SiteType["CONSUMER"] = "CONSUMER";
|
|
@@ -36,3 +36,7 @@ var UseCase;
|
|
|
36
36
|
UseCase["AUTOCONSOMMATION"] = "AUTOCONSOMMATION";
|
|
37
37
|
UseCase["VENTE_TOTALE"] = "VENTE_TOTALE";
|
|
38
38
|
})(UseCase || (exports.UseCase = UseCase = {}));
|
|
39
|
+
var Reference;
|
|
40
|
+
(function (Reference) {
|
|
41
|
+
Reference["REFERENCE"] = "REFERENCE";
|
|
42
|
+
})(Reference || (exports.Reference = Reference = {}));
|