@likewatt/models 1.0.30 → 1.0.31

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.
@@ -18,7 +18,8 @@ import { ScenarioParams } from './internal/scenario-params';
18
18
  import { StationParams } from './internal/station-params';
19
19
  import { ThermalStorageParams } from './internal/thermal-storage-params';
20
20
  import { OptimizationParams } from './internal/optimization-params';
21
- export declare enum FinancingType {
21
+ import { FinancingType } from './internal/financing-type';
22
+ export declare enum FinancingTypeEnum {
22
23
  INVESTMENT = "Investissement",
23
24
  LEASING = "Location",
24
25
  PPA = "PPA"
@@ -60,7 +61,7 @@ export declare class ScenarioDefaultValue {
60
61
  paramsStockageThermal: ThermalStorageParams;
61
62
  paramsStation: StationParams;
62
63
  paramsScenario: ScenarioParams;
63
- financingType?: FinancingType;
64
+ financingType: FinancingType;
64
65
  scenarioConfigSite?: {
65
66
  rateOfGrowth: RateOfGrowth[];
66
67
  demandMultiplierSlots: Array<{
@@ -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.ScenarioDefaultValueSchema = exports.ScenarioDefaultValue = exports.ConsumptionReference = exports.UseCase = exports.TrackerType = exports.FinancingType = void 0;
12
+ exports.ScenarioDefaultValueSchema = exports.ScenarioDefaultValue = exports.ConsumptionReference = exports.UseCase = exports.TrackerType = exports.FinancingTypeEnum = void 0;
13
13
  const mongoose_1 = require("@nestjs/mongoose");
14
14
  const swagger_1 = require("@nestjs/swagger");
15
15
  const mongoose_2 = require("mongoose");
@@ -32,13 +32,14 @@ const scenario_params_1 = require("./internal/scenario-params");
32
32
  const station_params_1 = require("./internal/station-params");
33
33
  const thermal_storage_params_1 = require("./internal/thermal-storage-params");
34
34
  const optimization_params_1 = require("./internal/optimization-params");
35
+ const financing_type_1 = require("./internal/financing-type");
35
36
  // Enums
36
- var FinancingType;
37
- (function (FinancingType) {
38
- FinancingType["INVESTMENT"] = "Investissement";
39
- FinancingType["LEASING"] = "Location";
40
- FinancingType["PPA"] = "PPA";
41
- })(FinancingType || (exports.FinancingType = FinancingType = {}));
37
+ var FinancingTypeEnum;
38
+ (function (FinancingTypeEnum) {
39
+ FinancingTypeEnum["INVESTMENT"] = "Investissement";
40
+ FinancingTypeEnum["LEASING"] = "Location";
41
+ FinancingTypeEnum["PPA"] = "PPA";
42
+ })(FinancingTypeEnum || (exports.FinancingTypeEnum = FinancingTypeEnum = {}));
42
43
  var TrackerType;
43
44
  (function (TrackerType) {
44
45
  TrackerType["OFF"] = "OFF";
@@ -176,11 +177,9 @@ __decorate([
176
177
  __metadata("design:type", scenario_params_1.ScenarioParams)
177
178
  ], ScenarioDefaultValue.prototype, "paramsScenario", void 0);
178
179
  __decorate([
179
- (0, swagger_1.ApiProperty)({ enum: FinancingType }),
180
- (0, mongoose_1.Prop)({ type: String, enum: FinancingType, required: true }),
181
- (0, class_validator_1.IsOptional)(),
182
- (0, class_validator_1.IsEnum)(FinancingType),
183
- __metadata("design:type", String)
180
+ (0, swagger_1.ApiProperty)({ type: financing_type_1.FinancingType }),
181
+ (0, mongoose_1.Prop)({ type: financing_type_1.FinancingType, required: true }),
182
+ __metadata("design:type", financing_type_1.FinancingType)
184
183
  ], ScenarioDefaultValue.prototype, "financingType", void 0);
185
184
  __decorate([
186
185
  (0, swagger_1.ApiPropertyOptional)(),
@@ -0,0 +1,15 @@
1
+ import { FinancingTypeEnum } from '../ScenarioDefaultValue';
2
+ export declare class FinancingType {
3
+ INVESTMENT: FinancingTypeEnum.INVESTMENT;
4
+ LEASING: FinancingTypeEnum.LEASING;
5
+ PPA: FinancingTypeEnum.PPA;
6
+ }
7
+ export declare const FinancingTypeSchema: import("mongoose").Schema<FinancingType, import("mongoose").Model<FinancingType, any, any, any, import("mongoose").Document<unknown, any, FinancingType, any> & FinancingType & {
8
+ _id: import("mongoose").Types.ObjectId;
9
+ } & {
10
+ __v: number;
11
+ }, any>, {}, {}, {}, {}, import("mongoose").DefaultSchemaOptions, FinancingType, import("mongoose").Document<unknown, {}, import("mongoose").FlatRecord<FinancingType>, {}> & import("mongoose").FlatRecord<FinancingType> & {
12
+ _id: import("mongoose").Types.ObjectId;
13
+ } & {
14
+ __v: number;
15
+ }>;
@@ -0,0 +1,41 @@
1
+ "use strict";
2
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
6
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
7
+ };
8
+ var __metadata = (this && this.__metadata) || function (k, v) {
9
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.FinancingTypeSchema = exports.FinancingType = void 0;
13
+ const mongoose_1 = require("@nestjs/mongoose");
14
+ const swagger_1 = require("@nestjs/swagger");
15
+ const class_validator_1 = require("class-validator");
16
+ const ScenarioDefaultValue_1 = require("../ScenarioDefaultValue");
17
+ let FinancingType = class FinancingType {
18
+ };
19
+ exports.FinancingType = FinancingType;
20
+ __decorate([
21
+ (0, swagger_1.ApiProperty)(),
22
+ (0, mongoose_1.Prop)({ required: true }),
23
+ (0, class_validator_1.IsString)(),
24
+ __metadata("design:type", String)
25
+ ], FinancingType.prototype, "INVESTMENT", void 0);
26
+ __decorate([
27
+ (0, swagger_1.ApiProperty)(),
28
+ (0, mongoose_1.Prop)({ required: true }),
29
+ (0, class_validator_1.IsString)(),
30
+ __metadata("design:type", String)
31
+ ], FinancingType.prototype, "LEASING", void 0);
32
+ __decorate([
33
+ (0, swagger_1.ApiProperty)(),
34
+ (0, mongoose_1.Prop)({ required: true }),
35
+ (0, class_validator_1.IsString)(),
36
+ __metadata("design:type", String)
37
+ ], FinancingType.prototype, "PPA", void 0);
38
+ exports.FinancingType = FinancingType = __decorate([
39
+ (0, mongoose_1.Schema)({ _id: false })
40
+ ], FinancingType);
41
+ exports.FinancingTypeSchema = mongoose_1.SchemaFactory.createForClass(FinancingType);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@likewatt/models",
3
- "version": "1.0.30",
3
+ "version": "1.0.31",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "scripts": {