@golemio/energetics 1.12.2-dev.2727447026 → 1.12.2-dev.2740928370
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/db/example/00_clear_test_data.sql +0 -13
- package/db/migrations/postgresql/{20260730120000-enapo-om-detail-porsenna.js → 20260805090000-ppas-distribution-installation.js} +2 -8
- package/db/migrations/postgresql/sqls/20260805090000-ppas-distribution-installation-down.sql +86 -0
- package/db/migrations/postgresql/sqls/20260805090000-ppas-distribution-installation-up.sql +124 -0
- package/dist/integration-engine/enapo/datasources/ppas/distribution/PpasDistributionDatasource.js +2 -5
- package/dist/integration-engine/enapo/datasources/ppas/distribution/PpasDistributionDatasource.js.map +1 -1
- package/dist/integration-engine/enapo/ioc/Di.js +2 -0
- package/dist/integration-engine/enapo/ioc/Di.js.map +1 -1
- package/dist/integration-engine/enapo/ioc/EnapoWorkerContainerToken.d.ts +1 -0
- package/dist/integration-engine/enapo/ioc/EnapoWorkerContainerToken.js +1 -0
- package/dist/integration-engine/enapo/ioc/EnapoWorkerContainerToken.js.map +1 -1
- package/dist/integration-engine/enapo/repositories/ppas/PpasDistributionInvoiceInstallationRepository.d.ts +7 -0
- package/dist/integration-engine/enapo/repositories/ppas/PpasDistributionInvoiceInstallationRepository.js +36 -0
- package/dist/integration-engine/enapo/repositories/ppas/PpasDistributionInvoiceInstallationRepository.js.map +1 -0
- package/dist/integration-engine/enapo/transformations/ppas/PpasDistributionTransformation.d.ts +7 -0
- package/dist/integration-engine/enapo/transformations/ppas/PpasDistributionTransformation.js +133 -122
- package/dist/integration-engine/enapo/transformations/ppas/PpasDistributionTransformation.js.map +1 -1
- package/dist/integration-engine/enapo/workers/task/EnapoPpasDistributionTask.d.ts +3 -1
- package/dist/integration-engine/enapo/workers/task/EnapoPpasDistributionTask.js +10 -5
- package/dist/integration-engine/enapo/workers/task/EnapoPpasDistributionTask.js.map +1 -1
- package/dist/output-gateway/constants/Links.d.ts +0 -1
- package/dist/output-gateway/constants/Links.js +1 -2
- package/dist/output-gateway/constants/Links.js.map +1 -1
- package/dist/output-gateway/index.js +1 -8
- package/dist/output-gateway/index.js.map +1 -1
- package/dist/output-gateway/ioc/Di.js +1 -9
- package/dist/output-gateway/ioc/Di.js.map +1 -1
- package/dist/output-gateway/ioc/ModuleContainerToken.d.ts +0 -4
- package/dist/output-gateway/ioc/ModuleContainerToken.js +0 -4
- package/dist/output-gateway/ioc/ModuleContainerToken.js.map +1 -1
- package/dist/schema-definitions/datasources/enapo/ppas/distribution/IPpasDistributionInvoiceDetailInput.d.ts +10 -10
- package/dist/schema-definitions/datasources/enapo/ppas/distribution/IPpasDistributionInvoiceListInput.d.ts +1 -1
- package/dist/schema-definitions/datasources/enapo/ppas/distribution/PpasDistributionSchema.d.ts +1 -3
- package/dist/schema-definitions/datasources/enapo/ppas/distribution/PpasDistributionSchema.js +57 -72
- package/dist/schema-definitions/datasources/enapo/ppas/distribution/PpasDistributionSchema.js.map +1 -1
- package/dist/schema-definitions/models/enapo/ppas/PpasDistributionInvoiceDeviceModel.d.ts +9 -8
- package/dist/schema-definitions/models/enapo/ppas/PpasDistributionInvoiceDeviceModel.js +10 -8
- package/dist/schema-definitions/models/enapo/ppas/PpasDistributionInvoiceDeviceModel.js.map +1 -1
- package/dist/schema-definitions/models/enapo/ppas/PpasDistributionInvoiceInstallationModel.d.ts +26 -0
- package/dist/schema-definitions/models/enapo/ppas/PpasDistributionInvoiceInstallationModel.js +56 -0
- package/dist/schema-definitions/models/enapo/ppas/PpasDistributionInvoiceInstallationModel.js.map +1 -0
- package/dist/schema-definitions/models/enapo/ppas/PpasDistributionInvoiceModel.d.ts +1 -17
- package/dist/schema-definitions/models/enapo/ppas/PpasDistributionInvoiceModel.js +1 -33
- package/dist/schema-definitions/models/enapo/ppas/PpasDistributionInvoiceModel.js.map +1 -1
- package/dist/schema-definitions/models/enapo/ppas/PpasDistributionInvoicePriceModel.d.ts +2 -1
- package/dist/schema-definitions/models/enapo/ppas/PpasDistributionInvoicePriceModel.js +5 -3
- package/dist/schema-definitions/models/enapo/ppas/PpasDistributionInvoicePriceModel.js.map +1 -1
- package/dist/schema-definitions/models/enapo/ppas/interfaces/IPpasDistributionInvoice.d.ts +1 -17
- package/dist/schema-definitions/models/enapo/ppas/interfaces/IPpasDistributionInvoiceDevice.d.ts +9 -7
- package/dist/schema-definitions/models/enapo/ppas/interfaces/IPpasDistributionInvoiceInstallation.d.ts +20 -0
- package/dist/{output-gateway/models/interfaces/IEnoBuildingDetailView.js → schema-definitions/models/enapo/ppas/interfaces/IPpasDistributionInvoiceInstallation.js} +1 -1
- package/dist/schema-definitions/models/enapo/ppas/interfaces/IPpasDistributionInvoiceInstallation.js.map +1 -0
- package/dist/schema-definitions/models/enapo/ppas/interfaces/IPpasDistributionInvoicePrice.d.ts +3 -1
- package/dist/schema-definitions/models/eno/AddressModel.d.ts +1 -1
- package/dist/schema-definitions/models/eno/AddressModel.js +1 -1
- package/dist/schema-definitions/models/eno/AddressModel.js.map +1 -1
- package/dist/schema-definitions/models/eno/interfaces/IAddress.d.ts +1 -1
- package/docs/implementation_documentation.md +4 -41
- package/docs/openapi-output.yaml +1 -260
- package/package.json +1 -1
- package/db/example/06_eno.sql +0 -25
- package/db/example/07_enapo_om_detail.sql +0 -131
- package/db/migrations/postgresql/20260729100000-enapo-gid-mapping-om-detail.js +0 -53
- package/db/migrations/postgresql/sqls/20260729100000-enapo-gid-mapping-om-detail-down.sql +0 -3
- package/db/migrations/postgresql/sqls/20260729100000-enapo-gid-mapping-om-detail-up.sql +0 -179
- package/db/migrations/postgresql/sqls/20260730120000-enapo-om-detail-porsenna-down.sql +0 -132
- package/db/migrations/postgresql/sqls/20260730120000-enapo-om-detail-porsenna-up.sql +0 -287
- package/db/scripts/ded_gid_mapping_mock_import.sql +0 -48
- package/dist/output-gateway/controllers/v2/EnoBuildingsController.d.ts +0 -11
- package/dist/output-gateway/controllers/v2/EnoBuildingsController.js +0 -53
- package/dist/output-gateway/controllers/v2/EnoBuildingsController.js.map +0 -1
- package/dist/output-gateway/helpers/objectMappers.d.ts +0 -10
- package/dist/output-gateway/helpers/objectMappers.js +0 -37
- package/dist/output-gateway/helpers/objectMappers.js.map +0 -1
- package/dist/output-gateway/models/EnoBuildingDetailViewModel.d.ts +0 -35
- package/dist/output-gateway/models/EnoBuildingDetailViewModel.js +0 -43
- package/dist/output-gateway/models/EnoBuildingDetailViewModel.js.map +0 -1
- package/dist/output-gateway/models/EnoConsumptionPointViewModel.d.ts +0 -105
- package/dist/output-gateway/models/EnoConsumptionPointViewModel.js +0 -118
- package/dist/output-gateway/models/EnoConsumptionPointViewModel.js.map +0 -1
- package/dist/output-gateway/models/EnoPorsennaDeviceViewModel.d.ts +0 -27
- package/dist/output-gateway/models/EnoPorsennaDeviceViewModel.js +0 -41
- package/dist/output-gateway/models/EnoPorsennaDeviceViewModel.js.map +0 -1
- package/dist/output-gateway/models/interfaces/IEnoBuildingDetailView.d.ts +0 -30
- package/dist/output-gateway/models/interfaces/IEnoBuildingDetailView.js.map +0 -1
- package/dist/output-gateway/models/interfaces/IEnoConsumptionPointView.d.ts +0 -104
- package/dist/output-gateway/models/interfaces/IEnoConsumptionPointView.js +0 -3
- package/dist/output-gateway/models/interfaces/IEnoConsumptionPointView.js.map +0 -1
- package/dist/output-gateway/models/interfaces/IEnoPorsennaDeviceView.d.ts +0 -22
- package/dist/output-gateway/models/interfaces/IEnoPorsennaDeviceView.js +0 -3
- package/dist/output-gateway/models/interfaces/IEnoPorsennaDeviceView.js.map +0 -1
- package/dist/output-gateway/repositories/AbstractNumericParsingRepository.d.ts +0 -12
- package/dist/output-gateway/repositories/AbstractNumericParsingRepository.js +0 -41
- package/dist/output-gateway/repositories/AbstractNumericParsingRepository.js.map +0 -1
- package/dist/output-gateway/repositories/EnoBuildingAddressesRepository.d.ts +0 -8
- package/dist/output-gateway/repositories/EnoBuildingAddressesRepository.js +0 -62
- package/dist/output-gateway/repositories/EnoBuildingAddressesRepository.js.map +0 -1
- package/dist/output-gateway/repositories/EnoBuildingDetailRepository.d.ts +0 -18
- package/dist/output-gateway/repositories/EnoBuildingDetailRepository.js +0 -100
- package/dist/output-gateway/repositories/EnoBuildingDetailRepository.js.map +0 -1
- package/dist/output-gateway/repositories/EnoConsumptionPointsRepository.d.ts +0 -8
- package/dist/output-gateway/repositories/EnoConsumptionPointsRepository.js +0 -51
- package/dist/output-gateway/repositories/EnoConsumptionPointsRepository.js.map +0 -1
- package/dist/output-gateway/repositories/EnoPorsennaDevicesRepository.d.ts +0 -8
- package/dist/output-gateway/repositories/EnoPorsennaDevicesRepository.js +0 -51
- package/dist/output-gateway/repositories/EnoPorsennaDevicesRepository.js.map +0 -1
- package/dist/output-gateway/repositories/PorsennaConsumptionsRepository.d.ts +0 -8
- package/dist/output-gateway/repositories/PorsennaConsumptionsRepository.js +0 -52
- package/dist/output-gateway/repositories/PorsennaConsumptionsRepository.js.map +0 -1
- package/dist/output-gateway/repositories/PpasInvoiceChildRepository.d.ts +0 -13
- package/dist/output-gateway/repositories/PpasInvoiceChildRepository.js +0 -39
- package/dist/output-gateway/repositories/PpasInvoiceChildRepository.js.map +0 -1
- package/dist/output-gateway/repositories/interfaces/IEnoBuildingDetailAggregate.d.ts +0 -22
- package/dist/output-gateway/repositories/interfaces/IEnoBuildingDetailAggregate.js +0 -3
- package/dist/output-gateway/repositories/interfaces/IEnoBuildingDetailAggregate.js.map +0 -1
- package/dist/output-gateway/routers/interfaces/IEnoBuildingDetailResponse.d.ts +0 -106
- package/dist/output-gateway/routers/interfaces/IEnoBuildingDetailResponse.js +0 -3
- package/dist/output-gateway/routers/interfaces/IEnoBuildingDetailResponse.js.map +0 -1
- package/dist/output-gateway/routers/v2/V2EnoBuildingsRouter.d.ts +0 -9
- package/dist/output-gateway/routers/v2/V2EnoBuildingsRouter.js +0 -40
- package/dist/output-gateway/routers/v2/V2EnoBuildingsRouter.js.map +0 -1
- package/dist/output-gateway/transformations/EnoBuildingDetailTransformation.d.ts +0 -14
- package/dist/output-gateway/transformations/EnoBuildingDetailTransformation.js +0 -149
- package/dist/output-gateway/transformations/EnoBuildingDetailTransformation.js.map +0 -1
- package/dist/schema-definitions/models/enapo/EnapoGidMappingModel.d.ts +0 -17
- package/dist/schema-definitions/models/enapo/EnapoGidMappingModel.js +0 -63
- package/dist/schema-definitions/models/enapo/EnapoGidMappingModel.js.map +0 -1
- package/dist/schema-definitions/models/enapo/interfaces/IEnapoGidMapping.d.ts +0 -11
- package/dist/schema-definitions/models/enapo/interfaces/IEnapoGidMapping.js +0 -3
- package/dist/schema-definitions/models/enapo/interfaces/IEnapoGidMapping.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PpasDistributionInvoicePriceModel.js","sourceRoot":"","sources":["../../../../../src/schema-definitions/models/enapo/ppas/PpasDistributionInvoicePriceModel.ts"],"names":[],"mappings":";;;AAAA,mEAAwF;AAIxF,MAAa,iCACT,SAAQ,iBAAoC;;AADhD,
|
|
1
|
+
{"version":3,"file":"PpasDistributionInvoicePriceModel.js","sourceRoot":"","sources":["../../../../../src/schema-definitions/models/enapo/ppas/PpasDistributionInvoicePriceModel.ts"],"names":[],"mappings":";;;AAAA,mEAAwF;AAIxF,MAAa,iCACT,SAAQ,iBAAoC;;AADhD,8EAmEC;AA/DiB,4CAAU,GAAG,uCAAuC,CAAC;AAmBrD,gDAAc,GAAsF;IAC9G,UAAU,EAAE,EAAE,IAAI,EAAE,qBAAS,CAAC,MAAM,EAAE,UAAU,EAAE,IAAI,EAAE;IACxD,QAAQ,EAAE,EAAE,IAAI,EAAE,qBAAS,CAAC,MAAM,EAAE,UAAU,EAAE,IAAI,EAAE;IACtD,WAAW,EAAE,EAAE,IAAI,EAAE,qBAAS,CAAC,MAAM,EAAE,UAAU,EAAE,IAAI,EAAE;IACzD,SAAS,EAAE,EAAE,IAAI,EAAE,qBAAS,CAAC,QAAQ,EAAE,UAAU,EAAE,IAAI,EAAE;IACzD,OAAO,EAAE,EAAE,IAAI,EAAE,qBAAS,CAAC,QAAQ,EAAE,UAAU,EAAE,IAAI,EAAE;IACvD,IAAI,EAAE,EAAE,IAAI,EAAE,qBAAS,CAAC,MAAM,EAAE,UAAU,EAAE,IAAI,EAAE;IAClD,WAAW,EAAE,EAAE,IAAI,EAAE,qBAAS,CAAC,MAAM,EAAE;IACvC,WAAW,EAAE,EAAE,IAAI,EAAE,qBAAS,CAAC,MAAM,EAAE;IACvC,QAAQ,EAAE,EAAE,IAAI,EAAE,qBAAS,CAAC,OAAO,EAAE;IACrC,IAAI,EAAE,EAAE,IAAI,EAAE,qBAAS,CAAC,MAAM,EAAE;IAChC,UAAU,EAAE,EAAE,IAAI,EAAE,qBAAS,CAAC,OAAO,EAAE;IACvC,SAAS,EAAE,EAAE,IAAI,EAAE,qBAAS,CAAC,OAAO,EAAE;IACtC,WAAW,EAAE,EAAE,IAAI,EAAE,qBAAS,CAAC,OAAO,EAAE;IACxC,UAAU,EAAE,EAAE,IAAI,EAAE,qBAAS,CAAC,MAAM,EAAE,UAAU,EAAE,IAAI,EAAE;IACxD,QAAQ,EAAE,EAAE,IAAI,EAAE,qBAAS,CAAC,MAAM,EAAE;IACpC,QAAQ,EAAE,EAAE,IAAI,EAAE,qBAAS,CAAC,OAAO,EAAE;CACxC,CAAC;AAEY,4CAAU,GAAoD;IACxE,IAAI,EAAE,OAAO;IACb,KAAK,EAAE;QACH,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACR,UAAU,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YAC9B,QAAQ,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YAC5B,WAAW,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YAC/B,SAAS,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YAC7B,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YAC3B,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YACxB,WAAW,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YAC/B,WAAW,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YAC/B,QAAQ,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YAC5B,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YACxB,UAAU,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YAC9B,SAAS,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,EAAE;YAC5E,WAAW,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YAC/B,UAAU,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YAC9B,QAAQ,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YAC5B,QAAQ,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;SAC/B;QACD,QAAQ,EAAE,CAAC,YAAY,EAAE,UAAU,EAAE,aAAa,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,EAAE,YAAY,CAAC;KACpG;CACJ,CAAC"}
|
|
@@ -12,7 +12,7 @@ export interface IPpasDistributionInvoice {
|
|
|
12
12
|
customer_address_city_part: string;
|
|
13
13
|
customer_address_post_code: string;
|
|
14
14
|
customer_address_country: string;
|
|
15
|
-
customer_address_ruian_id: number;
|
|
15
|
+
customer_address_ruian_id: number | null;
|
|
16
16
|
facts_doc_date: string;
|
|
17
17
|
facts_net_date: string;
|
|
18
18
|
facts_billing_transaction: string;
|
|
@@ -21,20 +21,4 @@ export interface IPpasDistributionInvoice {
|
|
|
21
21
|
facts_price_brutto: number;
|
|
22
22
|
is_canceled?: boolean;
|
|
23
23
|
canceled_reason?: string;
|
|
24
|
-
eic: string;
|
|
25
|
-
place_id: string;
|
|
26
|
-
installations_billing_class: string;
|
|
27
|
-
installations_measurement_type: string;
|
|
28
|
-
installations_contract_contract_id: string | null;
|
|
29
|
-
installations_contract_move_in_date: string;
|
|
30
|
-
installations_contract_move_out_date: string;
|
|
31
|
-
installations_tdd_class: string;
|
|
32
|
-
installations_address_street: string;
|
|
33
|
-
installations_address_house_number: string | null;
|
|
34
|
-
installations_address_house_org_number: string | null;
|
|
35
|
-
installations_address_city: string;
|
|
36
|
-
installations_address_city_part: string;
|
|
37
|
-
installations_address_post_code: string;
|
|
38
|
-
installations_address_country: string;
|
|
39
|
-
installations_address_ruian_id: number;
|
|
40
24
|
}
|
package/dist/schema-definitions/models/enapo/ppas/interfaces/IPpasDistributionInvoiceDevice.d.ts
CHANGED
|
@@ -1,18 +1,20 @@
|
|
|
1
1
|
export interface IPpasDistributionInvoiceDevice {
|
|
2
2
|
device_serial_number: string;
|
|
3
3
|
invoice_id: string;
|
|
4
|
+
/** One invoice can bill several installations, so invoice_id alone no longer identifies a device. */
|
|
5
|
+
place_id: string;
|
|
4
6
|
date_from: string;
|
|
5
7
|
date_to: string;
|
|
6
8
|
reading_type: string;
|
|
7
9
|
type: string;
|
|
8
10
|
kind: string;
|
|
9
|
-
reading_from: number;
|
|
10
|
-
reading_to: number;
|
|
11
|
-
consumption: number;
|
|
11
|
+
reading_from: number | null;
|
|
12
|
+
reading_to: number | null;
|
|
13
|
+
consumption: number | null;
|
|
12
14
|
unit: string;
|
|
13
15
|
meter_reading_type: string | null;
|
|
14
|
-
gas_consumption_kwh: number;
|
|
15
|
-
volume_coefficient: number;
|
|
16
|
-
combustion_heat: number;
|
|
17
|
-
normometers_nm3: number;
|
|
16
|
+
gas_consumption_kwh: number | null;
|
|
17
|
+
volume_coefficient: number | null;
|
|
18
|
+
combustion_heat: number | null;
|
|
19
|
+
normometers_nm3: number | null;
|
|
18
20
|
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export interface IPpasDistributionInvoiceInstallation {
|
|
2
|
+
invoice_id: string;
|
|
3
|
+
customer_id: string;
|
|
4
|
+
place_id: string;
|
|
5
|
+
eic: string;
|
|
6
|
+
billing_class: string;
|
|
7
|
+
measurement_type: string;
|
|
8
|
+
contract_contract_id: string | null;
|
|
9
|
+
contract_move_in_date: string;
|
|
10
|
+
contract_move_out_date: string;
|
|
11
|
+
tdd_class: string;
|
|
12
|
+
address_street: string;
|
|
13
|
+
address_house_number: string | null;
|
|
14
|
+
address_house_org_number: string | null;
|
|
15
|
+
address_city: string;
|
|
16
|
+
address_city_part: string;
|
|
17
|
+
address_post_code: string;
|
|
18
|
+
address_country: string;
|
|
19
|
+
address_ruian_id: number | null;
|
|
20
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IPpasDistributionInvoiceInstallation.js","sourceRoot":"","sources":["../../../../../../src/schema-definitions/models/enapo/ppas/interfaces/IPpasDistributionInvoiceInstallation.ts"],"names":[],"mappings":""}
|
package/dist/schema-definitions/models/enapo/ppas/interfaces/IPpasDistributionInvoicePrice.d.ts
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
export interface IPpasDistributionInvoicePrice {
|
|
2
2
|
invoice_id: string;
|
|
3
|
+
/** Without it two installations on one invoice collide on the primary key and overwrite each other. */
|
|
4
|
+
place_id: string;
|
|
3
5
|
date_from: string;
|
|
4
6
|
date_to: string;
|
|
5
7
|
kind: string;
|
|
@@ -8,7 +10,7 @@ export interface IPpasDistributionInvoicePrice {
|
|
|
8
10
|
quantity: number;
|
|
9
11
|
unit: string;
|
|
10
12
|
unit_price: number;
|
|
11
|
-
time_slot: number;
|
|
13
|
+
time_slot: number | null;
|
|
12
14
|
price_netto: number;
|
|
13
15
|
currency: string;
|
|
14
16
|
tax_rate: number;
|
|
@@ -8,7 +8,7 @@ export declare class AddressModel extends Model<IAddress> implements IAddress {
|
|
|
8
8
|
poradi: number;
|
|
9
9
|
zdroj: string;
|
|
10
10
|
id: number;
|
|
11
|
-
popis: string
|
|
11
|
+
popis: string;
|
|
12
12
|
hlavni: boolean;
|
|
13
13
|
static attributeModel: ModelAttributes<AddressModel, IAddress>;
|
|
14
14
|
static jsonSchema: JSONSchemaType<IAddress[]>;
|
|
@@ -39,7 +39,7 @@ AddressModel.jsonSchema = {
|
|
|
39
39
|
poradi: { type: "number" },
|
|
40
40
|
zdroj: { type: "string" },
|
|
41
41
|
id: { type: "number" },
|
|
42
|
-
popis: {
|
|
42
|
+
popis: { type: "string" },
|
|
43
43
|
hlavni: { type: "boolean" },
|
|
44
44
|
},
|
|
45
45
|
required: ["gid", "gid_typ", "poradi", "zdroj"],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AddressModel.js","sourceRoot":"","sources":["../../../../src/schema-definitions/models/eno/AddressModel.ts"],"names":[],"mappings":";;;AACA,mEAAwF;AAGxF,MAAa,YAAa,SAAQ,iBAAe;;AAAjD,oCAmDC;AAlD0B,uBAAU,GAAG,YAAY,CAAC;AAUnC,2BAAc,GAA4C;IACpE,GAAG,EAAE;QACD,UAAU,EAAE,IAAI;QAChB,IAAI,EAAE,qBAAS,CAAC,IAAI;KACvB;IACD,OAAO,EAAE;QACL,UAAU,EAAE,IAAI;QAChB,IAAI,EAAE,qBAAS,CAAC,IAAI;KACvB;IACD,MAAM,EAAE;QACJ,UAAU,EAAE,IAAI;QAChB,IAAI,EAAE,qBAAS,CAAC,MAAM;KACzB;IACD,KAAK,EAAE;QACH,UAAU,EAAE,IAAI;QAChB,IAAI,EAAE,qBAAS,CAAC,IAAI;KACvB;IACD,EAAE,EAAE;QACA,IAAI,EAAE,qBAAS,CAAC,MAAM;KACzB;IACD,KAAK,EAAE,qBAAS,CAAC,IAAI;IACrB,MAAM,EAAE,qBAAS,CAAC,OAAO;CAC5B,CAAC;AAEY,uBAAU,GAA+B;IACnD,IAAI,EAAE,OAAO;IACb,KAAK,EAAE;QACH,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACR,GAAG,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YACvB,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YAC3B,MAAM,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YAC1B,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YACzB,EAAE,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YACtB,KAAK,EAAE,EAAE,
|
|
1
|
+
{"version":3,"file":"AddressModel.js","sourceRoot":"","sources":["../../../../src/schema-definitions/models/eno/AddressModel.ts"],"names":[],"mappings":";;;AACA,mEAAwF;AAGxF,MAAa,YAAa,SAAQ,iBAAe;;AAAjD,oCAmDC;AAlD0B,uBAAU,GAAG,YAAY,CAAC;AAUnC,2BAAc,GAA4C;IACpE,GAAG,EAAE;QACD,UAAU,EAAE,IAAI;QAChB,IAAI,EAAE,qBAAS,CAAC,IAAI;KACvB;IACD,OAAO,EAAE;QACL,UAAU,EAAE,IAAI;QAChB,IAAI,EAAE,qBAAS,CAAC,IAAI;KACvB;IACD,MAAM,EAAE;QACJ,UAAU,EAAE,IAAI;QAChB,IAAI,EAAE,qBAAS,CAAC,MAAM;KACzB;IACD,KAAK,EAAE;QACH,UAAU,EAAE,IAAI;QAChB,IAAI,EAAE,qBAAS,CAAC,IAAI;KACvB;IACD,EAAE,EAAE;QACA,IAAI,EAAE,qBAAS,CAAC,MAAM;KACzB;IACD,KAAK,EAAE,qBAAS,CAAC,IAAI;IACrB,MAAM,EAAE,qBAAS,CAAC,OAAO;CAC5B,CAAC;AAEY,uBAAU,GAA+B;IACnD,IAAI,EAAE,OAAO;IACb,KAAK,EAAE;QACH,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACR,GAAG,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YACvB,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YAC3B,MAAM,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YAC1B,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YACzB,EAAE,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YACtB,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YACzB,MAAM,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE;SAC9B;QACD,QAAQ,EAAE,CAAC,KAAK,EAAE,SAAS,EAAE,QAAQ,EAAE,OAAO,CAAC;KAClD;CACJ,CAAC"}
|
|
@@ -512,7 +512,7 @@ Task zpracovává zasílaná data o spotřebě elektřiny. Data jsou nám zasíl
|
|
|
512
512
|
- v případě, že se u measurementů vyskytnou dvě hodnoty ve stejném čase, tak se hodnoty sečtou viz [sumDuplicates](../src/integration-engine/commodity-providers/helper/PreMeasurementFilter.ts)
|
|
513
513
|
- device_serial_number is extracted from raw_data `meter_replaced` value
|
|
514
514
|
- default time for meter change is set to static value `10:00` Europe/Prague time
|
|
515
|
-
- If change occurs e.g. `"meter_replaced": "2025-06-19|54292510|55505332|2025-06-30|55505332|96933662"` measurements before 19.6.2025 will have serial number `54292510`
|
|
515
|
+
- If change occurs e.g. `"meter_replaced": "2025-06-19|54292510|55505332|2025-06-30|55505332|96933662"` measurements before 19.6.2025 will have serial number `54292510` measurements after `2025-06-19 10:00` will have serial number `55505332` and measurements after `2025-06-30 10:00` will have serial number `96933662`
|
|
516
516
|
- [DeviceSerialNumberExtractor](../src/integration-engine/enapo/transformations/pre/helpers/DeviceSerialNumberExtractor.ts)
|
|
517
517
|
- data modely
|
|
518
518
|
- [EnapoMeasurementsModel](../src/schema-definitions/models/enapo/EnapoMeasurementsModel.ts) tabulka `enapo_measurements`
|
|
@@ -691,6 +691,7 @@ Task stahuje fakturační data distribuce od PPAS včetně informací o fakturá
|
|
|
691
691
|
- parametry: `{ from?, to? }`
|
|
692
692
|
- `from` - datum od (formát YYYY-MM-DD), volitelné - výchozí: dnes - 3 dny
|
|
693
693
|
- `to` - datum do (formát YYYY-MM-DD), volitelné - výchozí: dnes
|
|
694
|
+
- zdrojové API povoluje rozsah maximálně 366 dní, delší rozsah vrací chybu 400 - pro dotažení historie je nutné poslat zprávu pro každý rok zvlášť
|
|
694
695
|
- validační schéma: [EnapoPpasDistributionParamsSchema](../src/integration-engine/enapo/workers/schema/EnapoPpasDistributionParamsSchema.ts)
|
|
695
696
|
- závislé fronty (do kterých jsou odesílány zprávy z metody workeru)
|
|
696
697
|
- žádné
|
|
@@ -705,6 +706,7 @@ Task stahuje fakturační data distribuce od PPAS včetně informací o fakturá
|
|
|
705
706
|
- Rozlišuje mezi standardní cenou STANDARD a korekcí CORRECTION
|
|
706
707
|
- data modely
|
|
707
708
|
- [PpasDistributionInvoiceModel](../src/schema-definitions/models/enapo/ppas/PpasDistributionInvoiceModel.ts) tabulka `ppas_distribution_invoice` - hlavičky faktur
|
|
709
|
+
- [PpasDistributionInvoiceInstallationModel](../src/schema-definitions/models/enapo/ppas/PpasDistributionInvoiceInstallationModel.ts) tabulka `enapo_ppas_distribution_installation` - odběrná místa faktury
|
|
708
710
|
- [PpasDistributionInvoiceDeviceModel](../src/schema-definitions/models/enapo/ppas/PpasDistributionInvoiceDeviceModel.ts) tabulka `ppas_distribution_invoice_device` - zařízení a odečty
|
|
709
711
|
- [PpasDistributionInvoicePriceModel](../src/schema-definitions/models/enapo/ppas/PpasDistributionInvoicePriceModel.ts) tabulka `ppas_distribution_invoice_price` - cenové položky
|
|
710
712
|
|
|
@@ -811,27 +813,12 @@ Task stahuje data o měřidlech a spotřebách z Porsenna API (e-Manazer).
|
|
|
811
813
|
- zdrojový soubor: [openapi-output.yaml](./openapi-output.yaml)
|
|
812
814
|
- rabin: https://rabin.golemio.cz/v2/docs/openapi/
|
|
813
815
|
- golem: https://api.golemio.cz/v2/docs/openapi/
|
|
814
|
-
- přístup je řízen pomocí interního parametru `accessLimit`, který
|
|
816
|
+
- přístup je řízen pomocí interního parametru `accessLimit`, který musí být vždy nastaven a omezen z permission proxy
|
|
815
817
|
- při obdržení dotazu na API se stáhnou povolené organizace z tabulky `access_limit` a omezí se podle toho dotazy do databáze
|
|
816
818
|
- pokud je `accessLimit` nastaven na `admin`, tak se vždy dotazuje na všechny organizace
|
|
817
|
-
- `accessLimit` vyžadují všechny endpointy nad původní datovou doménou OICT Energetika (tabulky `organizations*` a `consumption_energy_*`), kde jsou data vázaná na organizace; endpointy projektu ENAPO (aktuální oficiální zkratka **DeD** — v URL se používá `/ded/`, tabulky si ponechávají prefix `enapo_` / `eno_`) parametr nepoužívají vůbec — data nejsou vázaná na organizace a validace `checkErrors` (`checkExact`) parametr odmítne jako nedeklarovaný s HTTP 400
|
|
818
819
|
|
|
819
820
|
### API
|
|
820
821
|
|
|
821
|
-
Přehled endpointů a parametru `accessLimit`:
|
|
822
|
-
|
|
823
|
-
| Endpoint | Datová doména (tabulky) | `accessLimit` |
|
|
824
|
-
| --------------------------------------------- | ---------------------------------------- | ---------------------------------------------- |
|
|
825
|
-
| `/v2/energetics/buildings` | OICT Energetika (`consumption_energy_*`) | povinný |
|
|
826
|
-
| `/v2/energetics/buildings/:id` | OICT Energetika (`consumption_energy_*`) | povinný |
|
|
827
|
-
| `/v2/energetics/organizations` | OICT Energetika (`organizations*`) | povinný |
|
|
828
|
-
| `/v2/energetics/organizations/:id` | OICT Energetika (`organizations*`) | povinný |
|
|
829
|
-
| `/v2/energetics/devices` | OICT Energetika (`consumption_energy_*`) | povinný |
|
|
830
|
-
| `/v2/energetics/devices/:id` | OICT Energetika (`consumption_energy_*`) | povinný |
|
|
831
|
-
| `/v2/energetics/measurements` | OICT Energetika (`consumption_energy_*`) | povinný |
|
|
832
|
-
| `/v2/energetics/measurements/monthly-reading` | OICT Energetika (`consumption_energy_*`) | povinný |
|
|
833
|
-
| `/v2/energetics/ded/buildings/:gid` | DeD / ENAPO (`enapo_*`, `eno_*`) | nepoužívá se — parametr je odmítnut s HTTP 400 |
|
|
834
|
-
|
|
835
822
|
#### _/v2/energetics/buildings_
|
|
836
823
|
|
|
837
824
|
#### _/v2/energetics/buildings/:id_
|
|
@@ -863,27 +850,3 @@ Přehled endpointů a parametru `accessLimit`:
|
|
|
863
850
|
|
|
864
851
|
- zdrojové tabulky
|
|
865
852
|
- consumption_energy_measurements
|
|
866
|
-
|
|
867
|
-
#### _/v2/energetics/ded/buildings/:gid_
|
|
868
|
-
|
|
869
|
-
- detail budovy (ENO) s odběrnými místy (OM) a technickými parametry pro DeD
|
|
870
|
-
- přístup: bez `accessLimit` — endpoint čte výhradně tabulky ENAPO (`enapo_*`, `eno_*`), které nejsou vázané na organizace z domény OICT Energetika, takže se nefiltruje přes tabulku `access_limit`; parametr `accessLimit` (ani žádný jiný query parametr) endpoint nepřijímá a vrací pro něj 400
|
|
871
|
-
- zdrojové tabulky a pohledy
|
|
872
|
-
- `v_enapo_building_detail` — pohled nad `eno_budova` (dedup přes `zdroj` pomocí `DISTINCT ON (gid)`)
|
|
873
|
-
- `eno_adresa` — všechny adresy budovy (deduplikované podle `popis`)
|
|
874
|
-
- `v_enapo_building_consumption_points` — pohled nad `enapo_gid_mapping` obohacený o:
|
|
875
|
-
- `enapo_pre_metadata_history` — poslední měsíc metadat PRE (jen EAN / elektřina)
|
|
876
|
-
- `enapo_ppas_distribution_invoice` — poslední nestornovaná distribuční faktura (jen EIC / plyn, join přes `eic`)
|
|
877
|
-
- `enapo_ppas_commercial_invoice(_installations)` — poslední nestornovaná obchodní faktura (jen EIC / plyn, join přes `eic`)
|
|
878
|
-
- `UNION ALL` větev pro OM známá pouze z Porsenny (e-manažer): hlavní měřidla (`level = main`) z `enapo_porsenna_devices`, jejichž `identifier` není namapován na daný GID v `enapo_gid_mapping`; `commodity` z typu měřidla (v reálných datech existují pouze `electricity_meter` / `gasometer` / `heat_meter` / `water_meter`), `id_type` odvozen přímo z komodity (elektřina → ean, plyn → eic, teplo a voda → `om` — standardní identifikátor nemají), `link_source = 'porsenna'`, `is_active` z `disabled_at`
|
|
879
|
-
- `v_enapo_building_porsenna_devices` — měřidla Porsenny s budovou (`enapo_porsenna_devices` × `enapo_porsenna_buildings` přes `(source, building_id)`); slouží pro obohacení OM o blok `porsenna` (měřidlo + podružná měřidla + roční spotřeby z `enapo_porsenna_consumption`) a pro blok `energy_management` na úrovni budovy
|
|
880
|
-
- `enapo_ppas_distribution_invoice_device` / `_price`, `enapo_ppas_commercial_invoice_device` / `_price` — dotahované podle id faktury
|
|
881
|
-
- mapovací tabulka `enapo_gid_mapping`
|
|
882
|
-
- vlastní kontrakt modulu; aktuálně plněná mock daty (`link_source = 'mock'`)
|
|
883
|
-
- v budoucnu ji bude plnit synchronizační task z dbt výstupu datového týmu (`tmp.ded_gid_mapping`, `link_source = 'energobroker_kod_eno'`)
|
|
884
|
-
- sloupec `is_active` v pohledu je odvozený z `valid_to` (NULL nebo v budoucnu = aktivní); expirovaná mapování se vracejí s příznakem
|
|
885
|
-
- struktura odpovědi
|
|
886
|
-
- komoditně specifická data jsou vnořená pod klíči `electricity` / `gas` u každého OM; v odpovědi je pouze klíč odpovídající poli `commodity`, ostatní jsou zcela vynechány
|
|
887
|
-
- detail existuje, pokud pro GID máme jakákoli data — zná ho alespoň jeden zdroj (`eno_budova`, `eno_adresa`, `enapo_gid_mapping`, nebo Porsenna): pokud GID není v `eno_budova`, ale má adresy, namapovaná OM či měřidla, vrací se 200 s `building: null` a chybějící části jako `null` / prázdná pole (cca 29 % GIDů z mapování nemá záznam v ENO); 404 pouze pokud GID nezná žádný zdroj
|
|
888
|
-
- OM známé z obou zdrojů (mapování i Porsenna) je v odpovědi jednou — data Porsenny jsou vnořená jako blok `porsenna` v příslušném komoditním klíči; duplicitní záznamy nevznikají
|
|
889
|
-
- budoucí komodity (teplo, voda) se přidají jako nové klíče bez breaking change
|
package/docs/openapi-output.yaml
CHANGED
|
@@ -15,18 +15,7 @@ servers:
|
|
|
15
15
|
description: Main (production) server
|
|
16
16
|
tags:
|
|
17
17
|
- name: ⚡ Energetics (v2)
|
|
18
|
-
description:
|
|
19
|
-
💡 Organizations & measurement devices — the original OICT Energetika data domain
|
|
20
|
-
(`organizations*` and `consumption_energy_*` tables). All endpoints in this group are
|
|
21
|
-
organization-scoped and require the internal `accessLimit` query parameter, which is set
|
|
22
|
-
by the permission proxy (never by the client).
|
|
23
|
-
- name: 🗺️ Energetics DeD (v2)
|
|
24
|
-
description: >-
|
|
25
|
-
🏢 DeD — city-wide energy management overview for Prague buildings. A separate data
|
|
26
|
-
domain from ⚡ Energetics: ENO buildings, consumption points (OM), PRE/PPAS enrichment
|
|
27
|
-
and Porsenna e-manazer devices. Data is not organization-scoped, so these endpoints do
|
|
28
|
-
not use the `accessLimit` parameter at all — sending it (or any other unknown query
|
|
29
|
-
parameter) is rejected with HTTP 400.
|
|
18
|
+
description: 💡 Organizations & measurement devices
|
|
30
19
|
paths:
|
|
31
20
|
/v2/energetics/buildings:
|
|
32
21
|
get:
|
|
@@ -84,55 +73,6 @@ paths:
|
|
|
84
73
|
schema:
|
|
85
74
|
$ref: "#/components/schemas/EnergeticsBuildingFull"
|
|
86
75
|
|
|
87
|
-
/v2/energetics/ded/buildings/{gid}:
|
|
88
|
-
get:
|
|
89
|
-
tags:
|
|
90
|
-
- 🗺️ Energetics DeD (v2)
|
|
91
|
-
summary: ENO building detail with consumption points (OM) and technical parameters
|
|
92
|
-
description: >-
|
|
93
|
-
Returns the ENO building (eno_budova) identified by GID together with its addresses and all
|
|
94
|
-
consumption points mapped to it. Commodity-specific data is nested under the
|
|
95
|
-
`electricity`/`gas`/`heat`/`water` keys of each consumption point; only the key matching the
|
|
96
|
-
`commodity` field is present, the others are omitted entirely.
|
|
97
|
-
|
|
98
|
-
Consumption points come from two independent sources: the energobroker mapping (EAN/EIC,
|
|
99
|
-
enriched with PRE metadata and PPAS invoices) and Porsenna e-manazer devices
|
|
100
|
-
(`link_source: porsenna`) — heat and water meters, plus any EAN/EIC the mapping lacks.
|
|
101
|
-
An OM known to both sources is returned once, with the Porsenna data nested as a `porsenna`
|
|
102
|
-
sub-block (device, sub-meters, yearly consumption) inside its commodity block. Buildings
|
|
103
|
-
tracked in Porsenna also carry an `energy_management` summary.
|
|
104
|
-
|
|
105
|
-
The endpoint returns whatever data exists for the GID: if there is any building record,
|
|
106
|
-
address, or consumption point, the response is 200 with the missing parts as `null` or
|
|
107
|
-
empty arrays (e.g. `building: null` when only consumption points or addresses are known).
|
|
108
|
-
404 is returned only when no source holds any data for the GID.
|
|
109
|
-
parameters:
|
|
110
|
-
- in: path
|
|
111
|
-
name: gid
|
|
112
|
-
required: true
|
|
113
|
-
schema:
|
|
114
|
-
type: string
|
|
115
|
-
example: GID100
|
|
116
|
-
responses:
|
|
117
|
-
"200":
|
|
118
|
-
description: OK
|
|
119
|
-
headers:
|
|
120
|
-
Cache-Control:
|
|
121
|
-
description: Cache control directive for caching proxies
|
|
122
|
-
schema:
|
|
123
|
-
type: string
|
|
124
|
-
example: public, s-maxage=21600, stale-while-revalidate=60
|
|
125
|
-
content:
|
|
126
|
-
application/json:
|
|
127
|
-
schema:
|
|
128
|
-
$ref: "#/components/schemas/EnergeticsEnoBuildingDetail"
|
|
129
|
-
"401":
|
|
130
|
-
$ref: "#/components/responses/UnauthorizedError"
|
|
131
|
-
"404":
|
|
132
|
-
$ref: "#/components/responses/NotFoundError"
|
|
133
|
-
"500":
|
|
134
|
-
$ref: "#/components/responses/ServerError"
|
|
135
|
-
|
|
136
76
|
/v2/energetics/devices:
|
|
137
77
|
get:
|
|
138
78
|
tags:
|
|
@@ -505,205 +445,6 @@ components:
|
|
|
505
445
|
type: string
|
|
506
446
|
|
|
507
447
|
schemas:
|
|
508
|
-
EnergeticsEnoBuildingDetail:
|
|
509
|
-
type: object
|
|
510
|
-
properties:
|
|
511
|
-
gid:
|
|
512
|
-
type: string
|
|
513
|
-
example: GID100
|
|
514
|
-
building:
|
|
515
|
-
type: object
|
|
516
|
-
nullable: true
|
|
517
|
-
description: >-
|
|
518
|
-
All available eno_budova attributes (Czech identifiers mirror the upstream ENO source).
|
|
519
|
-
Null when the GID has no ENO building record and is known only through the
|
|
520
|
-
consumption-point mapping.
|
|
521
|
-
properties:
|
|
522
|
-
zdroj:
|
|
523
|
-
type: string
|
|
524
|
-
nullable: true
|
|
525
|
-
nazev:
|
|
526
|
-
type: string
|
|
527
|
-
nullable: true
|
|
528
|
-
oznaceni:
|
|
529
|
-
type: string
|
|
530
|
-
nullable: true
|
|
531
|
-
druh_vytapeni:
|
|
532
|
-
type: string
|
|
533
|
-
nullable: true
|
|
534
|
-
pripojka_elektro:
|
|
535
|
-
type: string
|
|
536
|
-
nullable: true
|
|
537
|
-
pripojka_voda:
|
|
538
|
-
type: string
|
|
539
|
-
nullable: true
|
|
540
|
-
pripojka_kanalizace:
|
|
541
|
-
type: string
|
|
542
|
-
nullable: true
|
|
543
|
-
additionalProperties: true
|
|
544
|
-
addresses:
|
|
545
|
-
type: array
|
|
546
|
-
items:
|
|
547
|
-
type: object
|
|
548
|
-
properties:
|
|
549
|
-
popis:
|
|
550
|
-
type: string
|
|
551
|
-
nullable: true
|
|
552
|
-
hlavni:
|
|
553
|
-
type: boolean
|
|
554
|
-
nullable: true
|
|
555
|
-
poradi:
|
|
556
|
-
type: number
|
|
557
|
-
energy_management:
|
|
558
|
-
type: object
|
|
559
|
-
nullable: true
|
|
560
|
-
description: Porsenna (e-manazer) tracking summary; null when the building is not tracked there
|
|
561
|
-
properties:
|
|
562
|
-
source:
|
|
563
|
-
type: string
|
|
564
|
-
example: porsenna_p7
|
|
565
|
-
building_name:
|
|
566
|
-
type: string
|
|
567
|
-
nullable: true
|
|
568
|
-
address:
|
|
569
|
-
type: string
|
|
570
|
-
nullable: true
|
|
571
|
-
devices_total:
|
|
572
|
-
type: number
|
|
573
|
-
devices_active:
|
|
574
|
-
type: number
|
|
575
|
-
consumption_points:
|
|
576
|
-
type: array
|
|
577
|
-
items:
|
|
578
|
-
$ref: "#/components/schemas/EnergeticsEnoConsumptionPoint"
|
|
579
|
-
EnergeticsEnoPorsennaBlock:
|
|
580
|
-
type: object
|
|
581
|
-
description: Porsenna (e-manazer) device detail with sub-meters and yearly consumption aggregates
|
|
582
|
-
properties:
|
|
583
|
-
device:
|
|
584
|
-
type: object
|
|
585
|
-
additionalProperties: true
|
|
586
|
-
sub_devices:
|
|
587
|
-
type: array
|
|
588
|
-
items:
|
|
589
|
-
type: object
|
|
590
|
-
additionalProperties: true
|
|
591
|
-
yearly_consumption:
|
|
592
|
-
type: array
|
|
593
|
-
items:
|
|
594
|
-
type: object
|
|
595
|
-
properties:
|
|
596
|
-
period:
|
|
597
|
-
type: string
|
|
598
|
-
example: "2024"
|
|
599
|
-
value:
|
|
600
|
-
type: number
|
|
601
|
-
unit:
|
|
602
|
-
type: string
|
|
603
|
-
example: GJ
|
|
604
|
-
days_covered:
|
|
605
|
-
type: number
|
|
606
|
-
nullable: true
|
|
607
|
-
EnergeticsEnoConsumptionPoint:
|
|
608
|
-
type: object
|
|
609
|
-
properties:
|
|
610
|
-
place_id:
|
|
611
|
-
type: string
|
|
612
|
-
example: 27ZG100Z0000192O
|
|
613
|
-
id_type:
|
|
614
|
-
type: string
|
|
615
|
-
enum: [ean, eic, om]
|
|
616
|
-
commodity:
|
|
617
|
-
type: string
|
|
618
|
-
enum: [electricity, gas, heat, water]
|
|
619
|
-
is_first_gid:
|
|
620
|
-
type: boolean
|
|
621
|
-
is_active:
|
|
622
|
-
type: boolean
|
|
623
|
-
description: Derived from valid_to (null or in the future means the mapping is active)
|
|
624
|
-
link_source:
|
|
625
|
-
type: string
|
|
626
|
-
example: mock
|
|
627
|
-
valid_from:
|
|
628
|
-
type: string
|
|
629
|
-
format: date
|
|
630
|
-
nullable: true
|
|
631
|
-
valid_to:
|
|
632
|
-
type: string
|
|
633
|
-
format: date
|
|
634
|
-
nullable: true
|
|
635
|
-
address:
|
|
636
|
-
type: string
|
|
637
|
-
nullable: true
|
|
638
|
-
description: Consumption point address from the best available source
|
|
639
|
-
electricity:
|
|
640
|
-
type: object
|
|
641
|
-
description: Electricity-specific data (present only for commodity = electricity, omitted otherwise)
|
|
642
|
-
properties:
|
|
643
|
-
metadata:
|
|
644
|
-
type: object
|
|
645
|
-
nullable: true
|
|
646
|
-
description: Latest available month of PRE metadata for the EAN
|
|
647
|
-
additionalProperties: true
|
|
648
|
-
porsenna:
|
|
649
|
-
$ref: "#/components/schemas/EnergeticsEnoPorsennaBlock"
|
|
650
|
-
gas:
|
|
651
|
-
type: object
|
|
652
|
-
description: Gas-specific data (present only for commodity = gas, omitted otherwise)
|
|
653
|
-
properties:
|
|
654
|
-
porsenna:
|
|
655
|
-
$ref: "#/components/schemas/EnergeticsEnoPorsennaBlock"
|
|
656
|
-
distribution:
|
|
657
|
-
type: object
|
|
658
|
-
nullable: true
|
|
659
|
-
description: Latest non-canceled PPAS distribution invoice with its devices and prices
|
|
660
|
-
properties:
|
|
661
|
-
invoice:
|
|
662
|
-
type: object
|
|
663
|
-
additionalProperties: true
|
|
664
|
-
devices:
|
|
665
|
-
type: array
|
|
666
|
-
items:
|
|
667
|
-
type: object
|
|
668
|
-
additionalProperties: true
|
|
669
|
-
prices:
|
|
670
|
-
type: array
|
|
671
|
-
items:
|
|
672
|
-
type: object
|
|
673
|
-
additionalProperties: true
|
|
674
|
-
commercial:
|
|
675
|
-
type: object
|
|
676
|
-
nullable: true
|
|
677
|
-
description: Latest non-canceled PPAS commercial invoice with its installation, devices and prices
|
|
678
|
-
properties:
|
|
679
|
-
invoice:
|
|
680
|
-
type: object
|
|
681
|
-
additionalProperties: true
|
|
682
|
-
installation:
|
|
683
|
-
type: object
|
|
684
|
-
additionalProperties: true
|
|
685
|
-
devices:
|
|
686
|
-
type: array
|
|
687
|
-
items:
|
|
688
|
-
type: object
|
|
689
|
-
additionalProperties: true
|
|
690
|
-
prices:
|
|
691
|
-
type: array
|
|
692
|
-
items:
|
|
693
|
-
type: object
|
|
694
|
-
additionalProperties: true
|
|
695
|
-
heat:
|
|
696
|
-
type: object
|
|
697
|
-
description: Heat-specific data (present only for commodity = heat, omitted otherwise; Porsenna-sourced)
|
|
698
|
-
properties:
|
|
699
|
-
porsenna:
|
|
700
|
-
$ref: "#/components/schemas/EnergeticsEnoPorsennaBlock"
|
|
701
|
-
water:
|
|
702
|
-
type: object
|
|
703
|
-
description: Water-specific data (present only for commodity = water, omitted otherwise; Porsenna-sourced)
|
|
704
|
-
properties:
|
|
705
|
-
porsenna:
|
|
706
|
-
$ref: "#/components/schemas/EnergeticsEnoPorsennaBlock"
|
|
707
448
|
EnergeticsBuildingShort:
|
|
708
449
|
type: object
|
|
709
450
|
properties:
|
package/package.json
CHANGED
package/db/example/06_eno.sql
DELETED
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
INSERT INTO eno_budova (gid, zdroj, nazev, oznaceni, druh_vytapeni, pripojka_elektro, pripojka_voda, pripojka_kanalizace,
|
|
2
|
-
budova_rozdelena_byt_nebyt, celkova_plocha_budova, zastavena_plocha, obestaveny_prostor,
|
|
3
|
-
pocet_byt, pocet_nebyt_budova, pocet_nadzem_podlazi, pocet_podzem_podlazi, pocet_podkrovi, vytah,
|
|
4
|
-
czcc, id_cuzk, id_objekt, kod_vyuziti, nazev_vyuziti, kod_ochrana, nazev_ochrana, platnost_od) VALUES
|
|
5
|
-
('GID100', 'mhmp', 'ZŠ Testovací', 'ZŠT', 'ústřední dálkové', 'ano', 'ano', 'ano',
|
|
6
|
-
'ne', 1200.5, 450.0, 5200.0,
|
|
7
|
-
0, 12, 3, 1, 0, true,
|
|
8
|
-
112, 100000001, 1001, '7', 'budova pro vzdělávání', NULL, NULL, '2020-01-01'),
|
|
9
|
-
('GID100', 'stat', 'ZŠ Testovací (stat)', 'ZŠT', 'ústřední dálkové', 'ano', 'ano', 'ano',
|
|
10
|
-
'ne', 1200.5, 450.0, 5200.0,
|
|
11
|
-
0, 12, 3, 1, 0, true,
|
|
12
|
-
112, 100000001, 1001, '7', 'budova pro vzdělávání', NULL, NULL, '2020-01-01'),
|
|
13
|
-
('GID200', 'mhmp', 'MŠ Vedlejší', 'MŠV', 'plynová kotelna', 'ano', 'ano', 'ne',
|
|
14
|
-
'ne', 480.0, 220.0, 1600.0,
|
|
15
|
-
0, 5, 2, 0, 1, false,
|
|
16
|
-
112, 100000002, 1002, '7', 'budova pro vzdělávání', NULL, NULL, '2021-06-15');
|
|
17
|
-
|
|
18
|
-
INSERT INTO eno_adresa (gid, gid_typ, poradi, zdroj, id, popis, hlavni) VALUES
|
|
19
|
-
('GID100', 'budova', 1, 'mhmp', 501, 'Testovací 123/4, 100 00 Praha 10', true),
|
|
20
|
-
('GID100', 'budova', 2, 'mhmp', 502, 'Testovací 125/6, 100 00 Praha 10', false),
|
|
21
|
-
('GID100', 'budova', 1, 'stat', 501, 'Testovací 123/4, 100 00 Praha 10', true),
|
|
22
|
-
('GID100', 'budova', 3, 'mhmp', 504, NULL, false),
|
|
23
|
-
('GID100', 'budova', 4, 'mhmp', 505, NULL, false),
|
|
24
|
-
('GID200', 'budova', 1, 'mhmp', 503, 'Vedlejší 7, 100 00 Praha 10', true),
|
|
25
|
-
('GIDADDR1', 'stavba', 1, 'mhmp', 506, 'Stavební 9, 100 00 Praha 10', true);
|