@golemio/municipal-libraries 1.0.5-dev.568966813 → 1.1.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.
Files changed (147) hide show
  1. package/db/example/.config.json +3 -0
  2. package/db/example/00_truncate_tables.sql +7 -0
  3. package/db/example/01_libraries.sql +50 -0
  4. package/db/migrations/postgresql/.config.json +3 -0
  5. package/db/migrations/postgresql/20220916133717-init.js +53 -0
  6. package/db/migrations/postgresql/package.json +3 -0
  7. package/db/migrations/postgresql/sqls/20220916133717-init-down.sql +6 -0
  8. package/db/migrations/postgresql/sqls/20220916133717-init-up.sql +102 -0
  9. package/db/migrations/postgresql/sqls/package.json +3 -0
  10. package/dist/integration-engine/datasources/MunicipalLibrariesDataSource.d.ts +4 -0
  11. package/dist/integration-engine/datasources/MunicipalLibrariesDataSource.js +21 -0
  12. package/dist/integration-engine/datasources/MunicipalLibrariesDataSource.js.map +1 -0
  13. package/dist/integration-engine/datasources/index.d.ts +1 -0
  14. package/dist/integration-engine/datasources/index.js +19 -0
  15. package/dist/integration-engine/datasources/index.js.map +1 -0
  16. package/dist/integration-engine/index.d.ts +2 -3
  17. package/dist/integration-engine/index.js +5 -3
  18. package/dist/integration-engine/index.js.map +1 -1
  19. package/dist/integration-engine/repositories/DepartmentsRepository.d.ts +4 -0
  20. package/dist/integration-engine/repositories/DepartmentsRepository.js +19 -0
  21. package/dist/integration-engine/repositories/DepartmentsRepository.js.map +1 -0
  22. package/dist/integration-engine/repositories/LibraryDepartmentsRepository.d.ts +4 -0
  23. package/dist/integration-engine/repositories/LibraryDepartmentsRepository.js +19 -0
  24. package/dist/integration-engine/repositories/LibraryDepartmentsRepository.js.map +1 -0
  25. package/dist/integration-engine/repositories/LibraryServicesRepository.d.ts +4 -0
  26. package/dist/integration-engine/repositories/LibraryServicesRepository.js +19 -0
  27. package/dist/integration-engine/repositories/LibraryServicesRepository.js.map +1 -0
  28. package/dist/integration-engine/repositories/MunicipalLibrariesRepository.d.ts +16 -0
  29. package/dist/integration-engine/repositories/MunicipalLibrariesRepository.js +140 -0
  30. package/dist/integration-engine/repositories/MunicipalLibrariesRepository.js.map +1 -0
  31. package/dist/integration-engine/repositories/OpeningHoursRepository.d.ts +4 -0
  32. package/dist/integration-engine/repositories/OpeningHoursRepository.js +19 -0
  33. package/dist/integration-engine/repositories/OpeningHoursRepository.js.map +1 -0
  34. package/dist/integration-engine/repositories/ServicesRepository.d.ts +4 -0
  35. package/dist/integration-engine/repositories/ServicesRepository.js +19 -0
  36. package/dist/integration-engine/repositories/ServicesRepository.js.map +1 -0
  37. package/dist/integration-engine/repositories/index.d.ts +6 -0
  38. package/dist/integration-engine/repositories/index.js +24 -0
  39. package/dist/integration-engine/repositories/index.js.map +1 -0
  40. package/dist/integration-engine/transformations/MunicipalLibrariesTransformation.d.ts +32 -0
  41. package/dist/integration-engine/transformations/MunicipalLibrariesTransformation.js +72 -0
  42. package/dist/integration-engine/transformations/MunicipalLibrariesTransformation.js.map +1 -0
  43. package/dist/integration-engine/transformations/helpers/TransformationHelper.d.ts +19 -0
  44. package/dist/integration-engine/transformations/helpers/TransformationHelper.js +95 -0
  45. package/dist/integration-engine/transformations/helpers/TransformationHelper.js.map +1 -0
  46. package/dist/integration-engine/workers/MunicipalLibrariesWorker.d.ts +5 -0
  47. package/dist/integration-engine/workers/MunicipalLibrariesWorker.js +16 -0
  48. package/dist/integration-engine/workers/MunicipalLibrariesWorker.js.map +1 -0
  49. package/dist/integration-engine/workers/index.d.ts +2 -0
  50. package/dist/integration-engine/workers/index.js +6 -0
  51. package/dist/integration-engine/workers/index.js.map +1 -0
  52. package/dist/integration-engine/workers/schemas/UpdateDistrictSchema.d.ts +6 -0
  53. package/dist/integration-engine/workers/schemas/UpdateDistrictSchema.js +21 -0
  54. package/dist/integration-engine/workers/schemas/UpdateDistrictSchema.js.map +1 -0
  55. package/dist/integration-engine/workers/tasks/RefreshDataInDBTask.d.ts +10 -0
  56. package/dist/integration-engine/workers/tasks/RefreshDataInDBTask.js +41 -0
  57. package/dist/integration-engine/workers/tasks/RefreshDataInDBTask.js.map +1 -0
  58. package/dist/integration-engine/workers/tasks/UpdateDistrictsTask.d.ts +12 -0
  59. package/dist/integration-engine/workers/tasks/UpdateDistrictsTask.js +47 -0
  60. package/dist/integration-engine/workers/tasks/UpdateDistrictsTask.js.map +1 -0
  61. package/dist/integration-engine/workers/tasks/index.d.ts +2 -0
  62. package/dist/integration-engine/workers/tasks/index.js +20 -0
  63. package/dist/integration-engine/workers/tasks/index.js.map +1 -0
  64. package/dist/output-gateway/MunicipalLibrariesRouter.d.ts +8 -0
  65. package/dist/output-gateway/MunicipalLibrariesRouter.js +15 -0
  66. package/dist/output-gateway/MunicipalLibrariesRouter.js.map +1 -0
  67. package/dist/output-gateway/index.d.ts +2 -0
  68. package/dist/output-gateway/index.js +19 -0
  69. package/dist/output-gateway/index.js.map +1 -0
  70. package/dist/output-gateway/repositories/DepartmentsRepository.d.ts +6 -0
  71. package/dist/output-gateway/repositories/DepartmentsRepository.js +28 -0
  72. package/dist/output-gateway/repositories/DepartmentsRepository.js.map +1 -0
  73. package/dist/output-gateway/repositories/LibraryDepartmentsRepository.d.ts +6 -0
  74. package/dist/output-gateway/repositories/LibraryDepartmentsRepository.js +28 -0
  75. package/dist/output-gateway/repositories/LibraryDepartmentsRepository.js.map +1 -0
  76. package/dist/output-gateway/repositories/LibraryServicesRepository.d.ts +6 -0
  77. package/dist/output-gateway/repositories/LibraryServicesRepository.js +28 -0
  78. package/dist/output-gateway/repositories/LibraryServicesRepository.js.map +1 -0
  79. package/dist/output-gateway/repositories/MunicipalLibrariesRepository.d.ts +17 -0
  80. package/dist/output-gateway/repositories/MunicipalLibrariesRepository.js +164 -0
  81. package/dist/output-gateway/repositories/MunicipalLibrariesRepository.js.map +1 -0
  82. package/dist/output-gateway/repositories/OpeningHoursRepository.d.ts +6 -0
  83. package/dist/output-gateway/repositories/OpeningHoursRepository.js +28 -0
  84. package/dist/output-gateway/repositories/OpeningHoursRepository.js.map +1 -0
  85. package/dist/output-gateway/repositories/ServicesRepository.d.ts +6 -0
  86. package/dist/output-gateway/repositories/ServicesRepository.js +28 -0
  87. package/dist/output-gateway/repositories/ServicesRepository.js.map +1 -0
  88. package/dist/output-gateway/repositories/index.d.ts +6 -0
  89. package/dist/output-gateway/repositories/index.js +23 -0
  90. package/dist/output-gateway/repositories/index.js.map +1 -0
  91. package/dist/schema-definitions/Departments.d.ts +10 -0
  92. package/dist/schema-definitions/Departments.js +8 -0
  93. package/dist/schema-definitions/Departments.js.map +1 -0
  94. package/dist/schema-definitions/Libraries.d.ts +16 -0
  95. package/dist/schema-definitions/Libraries.js +8 -0
  96. package/dist/schema-definitions/Libraries.js.map +1 -0
  97. package/dist/schema-definitions/LibraryDepartments.d.ts +8 -0
  98. package/dist/schema-definitions/LibraryDepartments.js +8 -0
  99. package/dist/schema-definitions/LibraryDepartments.js.map +1 -0
  100. package/dist/schema-definitions/LibraryServices.d.ts +8 -0
  101. package/dist/schema-definitions/LibraryServices.js +8 -0
  102. package/dist/schema-definitions/LibraryServices.js.map +1 -0
  103. package/dist/schema-definitions/OpeningHours.d.ts +15 -0
  104. package/dist/schema-definitions/OpeningHours.js +8 -0
  105. package/dist/schema-definitions/OpeningHours.js.map +1 -0
  106. package/dist/schema-definitions/Services.d.ts +9 -0
  107. package/dist/schema-definitions/Services.js +8 -0
  108. package/dist/schema-definitions/Services.js.map +1 -0
  109. package/dist/schema-definitions/datasources/MunicipalLibrariesJsonSchema.d.ts +78 -0
  110. package/dist/schema-definitions/datasources/MunicipalLibrariesJsonSchema.js +209 -0
  111. package/dist/schema-definitions/datasources/MunicipalLibrariesJsonSchema.js.map +1 -0
  112. package/dist/schema-definitions/index.d.ts +1 -314
  113. package/dist/schema-definitions/index.js +19 -265
  114. package/dist/schema-definitions/index.js.map +1 -1
  115. package/dist/schema-definitions/models/DepartmentsModel.d.ts +12 -0
  116. package/dist/schema-definitions/models/DepartmentsModel.js +33 -0
  117. package/dist/schema-definitions/models/DepartmentsModel.js.map +1 -0
  118. package/dist/schema-definitions/models/LibrariesModel.d.ts +18 -0
  119. package/dist/schema-definitions/models/LibrariesModel.js +46 -0
  120. package/dist/schema-definitions/models/LibrariesModel.js.map +1 -0
  121. package/dist/schema-definitions/models/LibraryDepartmentsModel.d.ts +10 -0
  122. package/dist/schema-definitions/models/LibraryDepartmentsModel.js +30 -0
  123. package/dist/schema-definitions/models/LibraryDepartmentsModel.js.map +1 -0
  124. package/dist/schema-definitions/models/LibraryServicesModel.d.ts +10 -0
  125. package/dist/schema-definitions/models/LibraryServicesModel.js +30 -0
  126. package/dist/schema-definitions/models/LibraryServicesModel.js.map +1 -0
  127. package/dist/schema-definitions/models/OpeningHoursModel.d.ts +17 -0
  128. package/dist/schema-definitions/models/OpeningHoursModel.js +44 -0
  129. package/dist/schema-definitions/models/OpeningHoursModel.js.map +1 -0
  130. package/dist/schema-definitions/models/ServicesModel.d.ts +11 -0
  131. package/dist/schema-definitions/models/ServicesModel.js +31 -0
  132. package/dist/schema-definitions/models/ServicesModel.js.map +1 -0
  133. package/dist/schema-definitions/models/index.d.ts +6 -0
  134. package/dist/schema-definitions/models/index.js +24 -0
  135. package/dist/schema-definitions/models/index.js.map +1 -0
  136. package/package.json +64 -58
  137. package/db/example/mongo_data/dataplatform/municipallibraries.bson +0 -0
  138. package/db/example/mongo_data/dataplatform/municipallibraries.metadata.json +0 -1
  139. package/dist/integration-engine/MunicipalLibrariesTransformation.d.ts +0 -9
  140. package/dist/integration-engine/MunicipalLibrariesTransformation.js +0 -150
  141. package/dist/integration-engine/MunicipalLibrariesTransformation.js.map +0 -1
  142. package/dist/integration-engine/MunicipalLibrariesWorker.d.ts +0 -11
  143. package/dist/integration-engine/MunicipalLibrariesWorker.js +0 -105
  144. package/dist/integration-engine/MunicipalLibrariesWorker.js.map +0 -1
  145. package/dist/integration-engine/queueDefinitions.d.ts +0 -3
  146. package/dist/integration-engine/queueDefinitions.js +0 -36
  147. package/dist/integration-engine/queueDefinitions.js.map +0 -1
@@ -1,273 +1,27 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.MunicipalLibraries = void 0;
4
- const mongoose_1 = require("@golemio/core/dist/shared/mongoose");
5
- // MSO = Mongoose SchemaObject
6
- const datasourceJsonSchema = {
7
- // reusable definitions
8
- definitions: {
9
- denniOteviraciDoba: {
10
- type: "object",
11
- anyOf: [
12
- {
13
- required: ["rano"],
14
- },
15
- {
16
- required: ["odpoledne"],
17
- },
18
- ],
19
- additionalProperties: false,
20
- properties: {
21
- rano: {
22
- type: "object",
23
- required: ["od", "do"],
24
- additionalProperties: false,
25
- properties: {
26
- od: { type: "string" },
27
- do: { type: "string" },
28
- },
29
- },
30
- odpoledne: {
31
- type: "object",
32
- required: ["od", "do"],
33
- additionalProperties: false,
34
- properties: {
35
- od: { type: "string" },
36
- do: { type: "string" },
37
- },
38
- },
39
- },
40
- },
41
- oteviraciDoba: {
42
- type: "object",
43
- required: ["nazev", "defaultni"],
44
- additionalProperties: false,
45
- properties: {
46
- nazev: { type: "string" },
47
- defaultni: { type: "string" },
48
- platnost: {
49
- type: "object",
50
- required: ["od", "do"],
51
- additionalProperties: false,
52
- properties: {
53
- od: { type: "string" },
54
- do: { type: "string" },
55
- },
56
- },
57
- pondeli: {
58
- oneOf: [{ type: "string" }, { $ref: "#/definitions/denniOteviraciDoba" }],
59
- },
60
- utery: {
61
- oneOf: [{ type: "string" }, { $ref: "#/definitions/denniOteviraciDoba" }],
62
- },
63
- streda: {
64
- oneOf: [{ type: "string" }, { $ref: "#/definitions/denniOteviraciDoba" }],
65
- },
66
- ctvrtek: {
67
- oneOf: [{ type: "string" }, { $ref: "#/definitions/denniOteviraciDoba" }],
68
- },
69
- patek: {
70
- oneOf: [{ type: "string" }, { $ref: "#/definitions/denniOteviraciDoba" }],
71
- },
72
- sobota: {
73
- oneOf: [{ type: "string" }, { $ref: "#/definitions/denniOteviraciDoba" }],
74
- },
75
- nedele: {
76
- oneOf: [{ type: "string" }, { $ref: "#/definitions/denniOteviraciDoba" }],
77
- },
78
- },
79
- },
80
- oddeleni: {
81
- type: "object",
82
- required: ["id", "nazev"],
83
- additionalProperties: false,
84
- properties: {
85
- id: { type: "string" },
86
- nazev: { type: "string" },
87
- typ: { type: "string" },
88
- url: { type: "string" },
89
- },
90
- },
91
- sluzba: {
92
- type: "object",
93
- required: ["id", "nazev", "popis"],
94
- additionalProperties: false,
95
- properties: {
96
- id: { type: "string" },
97
- nazev: { type: "string" },
98
- popis: { type: "string" },
99
- },
100
- },
101
- },
102
- type: "array",
103
- additionalItems: false,
104
- items: {
105
- type: "object",
106
- required: ["nazev", "cislo", "id", "knoddel", "nadrazena", "adresa", "oteviracidoby", "sluzby", "oddeleni", "kontakt"],
107
- additionalProperties: false,
108
- properties: {
109
- nazev: { type: "string" },
110
- cislo: { type: "string" },
111
- id: { type: "string" },
112
- knoddel: { type: "string" },
113
- nadrazena: { type: "string" },
114
- adresa: {
115
- type: "object",
116
- required: ["ulice", "cislo", "mesto", "psc", "gps", "url"],
117
- additionalProperties: false,
118
- properties: {
119
- ulice: { type: "string" },
120
- cislo: { type: "string" },
121
- mesto: { type: "string" },
122
- psc: { type: "string" },
123
- gps: { type: "string" },
124
- url: { type: "string" },
125
- },
126
- },
127
- oteviracidoby: {
128
- type: "object",
129
- required: ["oteviracidoba"],
130
- additionalProperties: false,
131
- properties: {
132
- oteviracidoba: {
133
- oneOf: [
134
- {
135
- type: "array",
136
- additionalItems: false,
137
- items: {
138
- $ref: "#/definitions/oteviraciDoba",
139
- },
140
- },
141
- {
142
- $ref: "#/definitions/oteviraciDoba",
143
- },
144
- ],
145
- },
146
- },
147
- },
148
- sluzby: {
149
- oneOf: [
150
- {
151
- type: "object",
152
- required: ["sluzba"],
153
- additionalProperties: false,
154
- properties: {
155
- sluzba: {
156
- oneOf: [
157
- {
158
- type: "array",
159
- additionalItems: false,
160
- items: {
161
- $ref: "#/definitions/sluzba",
162
- },
163
- },
164
- {
165
- $ref: "#/definitions/sluzba",
166
- },
167
- ],
168
- },
169
- },
170
- },
171
- {
172
- type: "string",
173
- },
174
- ],
175
- },
176
- oddeleni: {
177
- oneOf: [
178
- {
179
- type: "object",
180
- required: ["oddeleni"],
181
- additionalProperties: false,
182
- properties: {
183
- oddeleni: {
184
- oneOf: [
185
- {
186
- type: "array",
187
- additionalItems: false,
188
- items: {
189
- $ref: "#/definitions/oddeleni",
190
- },
191
- },
192
- {
193
- $ref: "#/definitions/oddeleni",
194
- },
195
- ],
196
- },
197
- },
198
- },
199
- {
200
- type: "string",
201
- },
202
- ],
203
- },
204
- kontakt: {
205
- type: "object",
206
- required: ["telefon", "email"],
207
- additionalProperties: false,
208
- properties: {
209
- telefon: { type: "string" },
210
- email: { type: "string" },
211
- },
212
- },
213
- },
214
- },
215
- };
216
- const outputMSO = {
217
- geometry: {
218
- coordinates: { type: Array },
219
- type: { type: String },
220
- },
221
- properties: {
222
- address: {
223
- address_country: { type: String },
224
- address_formatted: { type: String },
225
- address_locality: { type: String },
226
- address_region: { type: String },
227
- postal_code: { type: String },
228
- street_address: { type: String },
229
- },
230
- district: { type: String },
231
- email: { type: String, required: true },
232
- id: { type: Number, required: true },
233
- name: { type: String, required: true },
234
- opening_hours: [
235
- new mongoose_1.Schema({
236
- closes: { type: String },
237
- day_of_week: { type: String },
238
- description: { type: String },
239
- is_default: { type: Boolean },
240
- opens: { type: String },
241
- valid_from: { type: String },
242
- valid_through: { type: String },
243
- }, { _id: false }),
244
- ],
245
- sections_and_departments: [
246
- new mongoose_1.Schema({
247
- id: { type: String },
248
- name: { type: String },
249
- type: { type: String },
250
- url: { type: String },
251
- }, { _id: false }),
252
- ],
253
- services: [
254
- new mongoose_1.Schema({
255
- description: { type: String },
256
- id: { type: Number },
257
- name: { type: String },
258
- }, { _id: false }),
259
- ],
260
- telephone: { type: String, required: true },
261
- updated_at: { type: Number, required: true },
262
- web: { type: String, required: true },
263
- },
264
- type: { type: String, required: true },
265
- };
4
+ const MunicipalLibrariesJsonSchema_1 = require("./datasources/MunicipalLibrariesJsonSchema");
5
+ const Libraries_1 = require("./Libraries");
6
+ const Services_1 = require("./Services");
7
+ const Departments_1 = require("./Departments");
8
+ const OpeningHours_1 = require("./OpeningHours");
9
+ const LibraryServices_1 = require("./LibraryServices");
10
+ const LibraryDepartments_1 = require("./LibraryDepartments");
266
11
  const forExport = {
267
- datasourceJsonSchema,
268
- mongoCollectionName: "municipallibraries",
269
12
  name: "MunicipalLibraries",
270
- outputMongooseSchemaObject: outputMSO,
13
+ pgSchema: "municipal_libraries",
14
+ datasources: {
15
+ municipalLibrariesDatasource: MunicipalLibrariesJsonSchema_1.municipalLibrariesDatasource,
16
+ },
17
+ definitions: {
18
+ municipalLibraries: Libraries_1.municipalLibraries,
19
+ municipalLibraryServices: Services_1.municipalLibraryServices,
20
+ municipalLibrariesLibraryServices: LibraryServices_1.municipalLibrariesLibraryServices,
21
+ municipalLibraryDepartments: Departments_1.municipalLibraryDepartments,
22
+ municipalLibrariesLibraryDepartments: LibraryDepartments_1.municipalLibrariesLibraryDepartments,
23
+ municipalLibraryOpeningHours: OpeningHours_1.municipalLibraryOpeningHours,
24
+ },
271
25
  };
272
26
  exports.MunicipalLibraries = forExport;
273
27
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/schema-definitions/index.ts"],"names":[],"mappings":";;;AAAA,iEAA8E;AAE9E,8BAA8B;AAE9B,MAAM,oBAAoB,GAAG;IACzB,uBAAuB;IACvB,WAAW,EAAE;QACT,kBAAkB,EAAE;YAChB,IAAI,EAAE,QAAQ;YACd,KAAK,EAAE;gBACH;oBACI,QAAQ,EAAE,CAAC,MAAM,CAAC;iBACrB;gBACD;oBACI,QAAQ,EAAE,CAAC,WAAW,CAAC;iBAC1B;aACJ;YACD,oBAAoB,EAAE,KAAK;YAC3B,UAAU,EAAE;gBACR,IAAI,EAAE;oB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CAA+D;AAC/D,iDAAiE;AACjE,uDAAyE;AACzE,6DAA+E;AAE/E,MAAM,SAAS,GAAQ;IACnB,IAAI,EAAE,oBAAoB;IAC1B,QAAQ,EAAE,qBAAqB;IAC/B,WAAW,EAAE;QACT,4BAA4B,EAA5B,2DAA4B;KAC/B;IACD,WAAW,EAAE;QACT,kBAAkB,EAAlB,8BAAkB;QAClB,wBAAwB,EAAxB,mCAAwB;QACxB,iCAAiC,EAAjC,mDAAiC;QACjC,2BAA2B,EAA3B,yCAA2B;QAC3B,oCAAoC,EAApC,yDAAoC;QACpC,4BAA4B,EAA5B,2CAA4B;KAC/B;CACJ,CAAC;AAEoB,uCAAkB"}
@@ -0,0 +1,12 @@
1
+ import { JSONSchemaType } from "@golemio/core/dist/shared/ajv";
2
+ import { Model, ModelAttributes } from "@golemio/core/dist/shared/sequelize";
3
+ import { IDepartments } from "../Departments";
4
+ export declare class DepartmentsModel extends Model<IDepartments> implements IDepartments {
5
+ id: string;
6
+ name: string;
7
+ type: string | null;
8
+ url: string | null;
9
+ static attributeModel: ModelAttributes<DepartmentsModel, IDepartments>;
10
+ static updateAttributes: (keyof IDepartments)[];
11
+ static jsonSchema: JSONSchemaType<IDepartments[]>;
12
+ }
@@ -0,0 +1,33 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.DepartmentsModel = void 0;
4
+ const sequelize_1 = require("@golemio/core/dist/shared/sequelize");
5
+ class DepartmentsModel extends sequelize_1.Model {
6
+ }
7
+ exports.DepartmentsModel = DepartmentsModel;
8
+ DepartmentsModel.attributeModel = {
9
+ id: {
10
+ type: sequelize_1.DataTypes.STRING(50),
11
+ primaryKey: true,
12
+ },
13
+ name: sequelize_1.DataTypes.STRING(255),
14
+ type: sequelize_1.DataTypes.STRING(255),
15
+ url: sequelize_1.DataTypes.STRING(255),
16
+ };
17
+ DepartmentsModel.updateAttributes = Object.keys(DepartmentsModel.attributeModel)
18
+ .filter((att) => att !== "id")
19
+ .concat("updated_at");
20
+ DepartmentsModel.jsonSchema = {
21
+ type: "array",
22
+ items: {
23
+ type: "object",
24
+ properties: {
25
+ id: { type: "string" },
26
+ name: { type: "string" },
27
+ type: { oneOf: [{ type: "string" }, { type: "null", nullable: true }] },
28
+ url: { oneOf: [{ type: "string" }, { type: "null", nullable: true }] },
29
+ },
30
+ required: ["id", "name"],
31
+ },
32
+ };
33
+ //# sourceMappingURL=DepartmentsModel.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DepartmentsModel.js","sourceRoot":"","sources":["../../../src/schema-definitions/models/DepartmentsModel.ts"],"names":[],"mappings":";;;AACA,mEAAwF;AAGxF,MAAa,gBAAiB,SAAQ,iBAAmB;;AAAzD,4CAiCC;AA3BiB,+BAAc,GAAoD;IAC5E,EAAE,EAAE;QACA,IAAI,EAAE,qBAAS,CAAC,MAAM,CAAC,EAAE,CAAC;QAC1B,UAAU,EAAE,IAAI;KACnB;IACD,IAAI,EAAE,qBAAS,CAAC,MAAM,CAAC,GAAG,CAAC;IAC3B,IAAI,EAAE,qBAAS,CAAC,MAAM,CAAC,GAAG,CAAC;IAC3B,GAAG,EAAE,qBAAS,CAAC,MAAM,CAAC,GAAG,CAAC;CAC7B,CAAC;AAEY,iCAAgB,GAAG,MAAM,CAAC,IAAI,CAAC,gBAAgB,CAAC,cAAc,CAAC;KACxE,MAAM,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,KAAK,IAAI,CAAC;KAC7B,MAAM,CAAC,YAAY,CAA8B,CAAC;AAEzC,2BAAU,GAAmC;IACvD,IAAI,EAAE,OAAO;IACb,KAAK,EAAE;QACH,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACR,EAAE,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YACtB,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YACxB,IAAI,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,EAAE;YACvE,GAAG,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,EAAE;SACzE;QACD,QAAQ,EAAE,CAAC,IAAI,EAAE,MAAM,CAAC;KAC3B;CACJ,CAAC"}
@@ -0,0 +1,18 @@
1
+ import { Point } from "@golemio/core/dist/shared/geojson";
2
+ import { JSONSchemaType } from "@golemio/core/dist/shared/ajv";
3
+ import { Model, ModelAttributes } from "@golemio/core/dist/shared/sequelize";
4
+ import { IPostalAddress } from "@golemio/core/dist/integration-engine";
5
+ import { ILibraries } from "../Libraries";
6
+ export declare class LibrariesModel extends Model<ILibraries> implements ILibraries {
7
+ id: number;
8
+ name: string;
9
+ geometry: Point;
10
+ address: IPostalAddress;
11
+ district: string | null;
12
+ web: string;
13
+ email: string;
14
+ telephone: string;
15
+ static attributeModel: ModelAttributes<LibrariesModel, ILibraries>;
16
+ static updateAttributes: (keyof ILibraries)[];
17
+ static jsonSchema: JSONSchemaType<ILibraries[]>;
18
+ }
@@ -0,0 +1,46 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.LibrariesModel = void 0;
4
+ const sequelize_1 = require("@golemio/core/dist/shared/sequelize");
5
+ const schema_definitions_1 = require("@golemio/core/dist/schema-definitions");
6
+ class LibrariesModel extends sequelize_1.Model {
7
+ }
8
+ exports.LibrariesModel = LibrariesModel;
9
+ LibrariesModel.attributeModel = {
10
+ id: {
11
+ type: sequelize_1.DataTypes.INTEGER,
12
+ primaryKey: true,
13
+ },
14
+ name: sequelize_1.DataTypes.STRING(255),
15
+ geometry: sequelize_1.DataTypes.GEOMETRY,
16
+ address: sequelize_1.DataTypes.JSON,
17
+ email: sequelize_1.DataTypes.STRING(255),
18
+ telephone: sequelize_1.DataTypes.STRING(255),
19
+ web: sequelize_1.DataTypes.STRING(255),
20
+ district: sequelize_1.DataTypes.STRING(255),
21
+ };
22
+ LibrariesModel.updateAttributes = Object.keys(LibrariesModel.attributeModel)
23
+ .filter((att) => att !== "id")
24
+ .concat("updated_at");
25
+ LibrariesModel.jsonSchema = {
26
+ type: "array",
27
+ items: {
28
+ type: "object",
29
+ properties: {
30
+ id: { type: "integer" },
31
+ name: { type: "string" },
32
+ geometry: { $ref: "#/definitions/geometry" },
33
+ address: { type: "object" },
34
+ email: { type: "string" },
35
+ telephone: { type: "string" },
36
+ web: { type: "string" },
37
+ district: { oneOf: [{ type: "string" }, { type: "null", nullable: true }] },
38
+ },
39
+ required: ["id", "name"],
40
+ },
41
+ definitions: {
42
+ // @ts-expect-error
43
+ geometry: schema_definitions_1.SharedSchemaProvider.Geometry,
44
+ },
45
+ };
46
+ //# sourceMappingURL=LibrariesModel.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LibrariesModel.js","sourceRoot":"","sources":["../../../src/schema-definitions/models/LibrariesModel.ts"],"names":[],"mappings":";;;AAEA,mEAAwF;AACxF,8EAA6E;AAI7E,MAAa,cAAe,SAAQ,iBAAiB;;AAArD,wCAiDC;AAvCiB,6BAAc,GAAgD;IACxE,EAAE,EAAE;QACA,IAAI,EAAE,qBAAS,CAAC,OAAO;QACvB,UAAU,EAAE,IAAI;KACnB;IACD,IAAI,EAAE,qBAAS,CAAC,MAAM,CAAC,GAAG,CAAC;IAC3B,QAAQ,EAAE,qBAAS,CAAC,QAAQ;IAC5B,OAAO,EAAE,qBAAS,CAAC,IAAI;IACvB,KAAK,EAAE,qBAAS,CAAC,MAAM,CAAC,GAAG,CAAC;IAC5B,SAAS,EAAE,qBAAS,CAAC,MAAM,CAAC,GAAG,CAAC;IAChC,GAAG,EAAE,qBAAS,CAAC,MAAM,CAAC,GAAG,CAAC;IAC1B,QAAQ,EAAE,qBAAS,CAAC,MAAM,CAAC,GAAG,CAAC;CAClC,CAAC;AAEY,+BAAgB,GAAG,MAAM,CAAC,IAAI,CAAC,cAAc,CAAC,cAAc,CAAC;KACtE,MAAM,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,KAAK,IAAI,CAAC;KAC7B,MAAM,CAAC,YAAY,CAA4B,CAAC;AAEvC,yBAAU,GAAiC;IACrD,IAAI,EAAE,OAAO;IACb,KAAK,EAAE;QACH,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACR,EAAE,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE;YACvB,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YACxB,QAAQ,EAAE,EAAE,IAAI,EAAE,wBAAwB,EAAE;YAC5C,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YAC3B,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YACzB,SAAS,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YAC7B,GAAG,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YACvB,QAAQ,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,EAAE;SAC9E;QACD,QAAQ,EAAE,CAAC,IAAI,EAAE,MAAM,CAAC;KAC3B;IACD,WAAW,EAAE;QACT,mBAAmB;QACnB,QAAQ,EAAE,yCAAoB,CAAC,QAAQ;KAC1C;CACJ,CAAC"}
@@ -0,0 +1,10 @@
1
+ import { JSONSchemaType } from "@golemio/core/dist/shared/ajv";
2
+ import { Model, ModelAttributes } from "@golemio/core/dist/shared/sequelize";
3
+ import { ILibraryDepartments } from "../LibraryDepartments";
4
+ export declare class LibraryDepartmentsModel extends Model<ILibraryDepartments> implements ILibraryDepartments {
5
+ library_id: number;
6
+ department_id: string;
7
+ static attributeModel: ModelAttributes<LibraryDepartmentsModel, ILibraryDepartments>;
8
+ static updateAttributes: (keyof ILibraryDepartments)[];
9
+ static jsonSchema: JSONSchemaType<ILibraryDepartments[]>;
10
+ }
@@ -0,0 +1,30 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.LibraryDepartmentsModel = void 0;
4
+ const sequelize_1 = require("@golemio/core/dist/shared/sequelize");
5
+ class LibraryDepartmentsModel extends sequelize_1.Model {
6
+ }
7
+ exports.LibraryDepartmentsModel = LibraryDepartmentsModel;
8
+ LibraryDepartmentsModel.attributeModel = {
9
+ library_id: {
10
+ type: sequelize_1.DataTypes.INTEGER,
11
+ primaryKey: true,
12
+ },
13
+ department_id: {
14
+ type: sequelize_1.DataTypes.STRING(50),
15
+ primaryKey: true,
16
+ },
17
+ };
18
+ LibraryDepartmentsModel.updateAttributes = ["updated_at"];
19
+ LibraryDepartmentsModel.jsonSchema = {
20
+ type: "array",
21
+ items: {
22
+ type: "object",
23
+ properties: {
24
+ library_id: { type: "integer" },
25
+ department_id: { type: "string" },
26
+ },
27
+ required: ["library_id", "department_id"],
28
+ },
29
+ };
30
+ //# sourceMappingURL=LibraryDepartmentsModel.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LibraryDepartmentsModel.js","sourceRoot":"","sources":["../../../src/schema-definitions/models/LibraryDepartmentsModel.ts"],"names":[],"mappings":";;;AACA,mEAAwF;AAGxF,MAAa,uBAAwB,SAAQ,iBAA0B;;AAAvE,0DA4BC;AAxBiB,sCAAc,GAAkE;IAC1F,UAAU,EAAE;QACR,IAAI,EAAE,qBAAS,CAAC,OAAO;QACvB,UAAU,EAAE,IAAI;KACnB;IACD,aAAa,EAAE;QACX,IAAI,EAAE,qBAAS,CAAC,MAAM,CAAC,EAAE,CAAC;QAC1B,UAAU,EAAE,IAAI;KACnB;CACJ,CAAC;AAEY,wCAAgB,GAAG,CAAC,YAAyC,CAAC,CAAC;AAE/D,kCAAU,GAA0C;IAC9D,IAAI,EAAE,OAAO;IACb,KAAK,EAAE;QACH,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACR,UAAU,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE;YAC/B,aAAa,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;SACpC;QACD,QAAQ,EAAE,CAAC,YAAY,EAAE,eAAe,CAAC;KAC5C;CACJ,CAAC"}
@@ -0,0 +1,10 @@
1
+ import { JSONSchemaType } from "@golemio/core/dist/shared/ajv";
2
+ import { Model, ModelAttributes } from "@golemio/core/dist/shared/sequelize";
3
+ import { ILibraryServices } from "../LibraryServices";
4
+ export declare class LibraryServicesModel extends Model<ILibraryServices> implements ILibraryServices {
5
+ library_id: number;
6
+ service_id: number;
7
+ static attributeModel: ModelAttributes<LibraryServicesModel, ILibraryServices>;
8
+ static updateAttributes: (keyof ILibraryServices)[];
9
+ static jsonSchema: JSONSchemaType<ILibraryServices[]>;
10
+ }
@@ -0,0 +1,30 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.LibraryServicesModel = void 0;
4
+ const sequelize_1 = require("@golemio/core/dist/shared/sequelize");
5
+ class LibraryServicesModel extends sequelize_1.Model {
6
+ }
7
+ exports.LibraryServicesModel = LibraryServicesModel;
8
+ LibraryServicesModel.attributeModel = {
9
+ library_id: {
10
+ type: sequelize_1.DataTypes.INTEGER,
11
+ primaryKey: true,
12
+ },
13
+ service_id: {
14
+ type: sequelize_1.DataTypes.INTEGER,
15
+ primaryKey: true,
16
+ },
17
+ };
18
+ LibraryServicesModel.updateAttributes = ["updated_at"];
19
+ LibraryServicesModel.jsonSchema = {
20
+ type: "array",
21
+ items: {
22
+ type: "object",
23
+ properties: {
24
+ library_id: { type: "integer" },
25
+ service_id: { type: "integer" },
26
+ },
27
+ required: ["library_id", "service_id"],
28
+ },
29
+ };
30
+ //# sourceMappingURL=LibraryServicesModel.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LibraryServicesModel.js","sourceRoot":"","sources":["../../../src/schema-definitions/models/LibraryServicesModel.ts"],"names":[],"mappings":";;;AACA,mEAAwF;AAGxF,MAAa,oBAAqB,SAAQ,iBAAuB;;AAAjE,oDA4BC;AAxBiB,mCAAc,GAA4D;IACpF,UAAU,EAAE;QACR,IAAI,EAAE,qBAAS,CAAC,OAAO;QACvB,UAAU,EAAE,IAAI;KACnB;IACD,UAAU,EAAE;QACR,IAAI,EAAE,qBAAS,CAAC,OAAO;QACvB,UAAU,EAAE,IAAI;KACnB;CACJ,CAAC;AAEY,qCAAgB,GAAG,CAAC,YAAsC,CAAC,CAAC;AAE5D,+BAAU,GAAuC;IAC3D,IAAI,EAAE,OAAO;IACb,KAAK,EAAE;QACH,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACR,UAAU,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE;YAC/B,UAAU,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE;SAClC;QACD,QAAQ,EAAE,CAAC,YAAY,EAAE,YAAY,CAAC;KACzC;CACJ,CAAC"}
@@ -0,0 +1,17 @@
1
+ import { JSONSchemaType } from "@golemio/core/dist/shared/ajv";
2
+ import { Model, ModelAttributes } from "@golemio/core/dist/shared/sequelize";
3
+ import { IOpeningHours } from "../OpeningHours";
4
+ export declare class OpeningHoursModel extends Model<IOpeningHours> implements IOpeningHours {
5
+ id: number;
6
+ library_id: number;
7
+ day_of_week: string;
8
+ opens: string;
9
+ closes: string;
10
+ description: string;
11
+ is_default: boolean;
12
+ valid_from: string | null;
13
+ valid_through: string | null;
14
+ static attributeModel: ModelAttributes<OpeningHoursModel, IOpeningHours>;
15
+ static updateAttributes: (keyof IOpeningHours)[];
16
+ static jsonSchema: JSONSchemaType<IOpeningHours[]>;
17
+ }
@@ -0,0 +1,44 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.OpeningHoursModel = void 0;
4
+ const sequelize_1 = require("@golemio/core/dist/shared/sequelize");
5
+ class OpeningHoursModel extends sequelize_1.Model {
6
+ }
7
+ exports.OpeningHoursModel = OpeningHoursModel;
8
+ OpeningHoursModel.attributeModel = {
9
+ id: {
10
+ type: sequelize_1.DataTypes.INTEGER,
11
+ primaryKey: true,
12
+ autoIncrement: true,
13
+ },
14
+ library_id: sequelize_1.DataTypes.INTEGER,
15
+ day_of_week: sequelize_1.DataTypes.STRING(255),
16
+ opens: sequelize_1.DataTypes.STRING(255),
17
+ closes: sequelize_1.DataTypes.STRING(255),
18
+ description: sequelize_1.DataTypes.STRING(255),
19
+ is_default: sequelize_1.DataTypes.BOOLEAN,
20
+ valid_from: sequelize_1.DataTypes.DATE,
21
+ valid_through: sequelize_1.DataTypes.DATE,
22
+ };
23
+ OpeningHoursModel.updateAttributes = Object.keys(OpeningHoursModel.attributeModel)
24
+ .filter((att) => att !== "id")
25
+ .concat("updated_at");
26
+ OpeningHoursModel.jsonSchema = {
27
+ type: "array",
28
+ items: {
29
+ type: "object",
30
+ properties: {
31
+ id: { type: "integer" },
32
+ library_id: { type: "integer" },
33
+ day_of_week: { type: "string" },
34
+ opens: { type: "string" },
35
+ closes: { type: "string" },
36
+ description: { type: "string" },
37
+ is_default: { type: "boolean" },
38
+ valid_from: { oneOf: [{ type: "string" }, { type: "null", nullable: true }] },
39
+ valid_through: { oneOf: [{ type: "string" }, { type: "null", nullable: true }] },
40
+ },
41
+ required: ["library_id", "day_of_week", "opens", "closes", "description", "is_default"],
42
+ },
43
+ };
44
+ //# sourceMappingURL=OpeningHoursModel.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"OpeningHoursModel.js","sourceRoot":"","sources":["../../../src/schema-definitions/models/OpeningHoursModel.ts"],"names":[],"mappings":";;;AACA,mEAAwF;AAGxF,MAAa,iBAAkB,SAAQ,iBAAoB;;AAA3D,8CAiDC;AAtCiB,gCAAc,GAAsD;IAC9E,EAAE,EAAE;QACA,IAAI,EAAE,qBAAS,CAAC,OAAO;QACvB,UAAU,EAAE,IAAI;QAChB,aAAa,EAAE,IAAI;KACtB;IACD,UAAU,EAAE,qBAAS,CAA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AAE,MAAM,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,EAAE;SACnF;QACD,QAAQ,EAAE,CAAC,YAAY,EAAE,aAAa,EAAE,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,YAAY,CAAC;KAC1F;CACJ,CAAC"}
@@ -0,0 +1,11 @@
1
+ import { JSONSchemaType } from "@golemio/core/dist/shared/ajv";
2
+ import { Model, ModelAttributes } from "@golemio/core/dist/shared/sequelize";
3
+ import { IServices } from "../Services";
4
+ export declare class ServicesModel extends Model<IServices> implements IServices {
5
+ id: number;
6
+ name: string;
7
+ description: string | null;
8
+ static attributeModel: ModelAttributes<ServicesModel, IServices>;
9
+ static updateAttributes: (keyof IServices)[];
10
+ static jsonSchema: JSONSchemaType<IServices[]>;
11
+ }
@@ -0,0 +1,31 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ServicesModel = void 0;
4
+ const sequelize_1 = require("@golemio/core/dist/shared/sequelize");
5
+ class ServicesModel extends sequelize_1.Model {
6
+ }
7
+ exports.ServicesModel = ServicesModel;
8
+ ServicesModel.attributeModel = {
9
+ id: {
10
+ type: sequelize_1.DataTypes.INTEGER,
11
+ primaryKey: true,
12
+ },
13
+ name: sequelize_1.DataTypes.STRING(255),
14
+ description: sequelize_1.DataTypes.TEXT,
15
+ };
16
+ ServicesModel.updateAttributes = Object.keys(ServicesModel.attributeModel)
17
+ .filter((att) => att !== "id")
18
+ .concat("updated_at");
19
+ ServicesModel.jsonSchema = {
20
+ type: "array",
21
+ items: {
22
+ type: "object",
23
+ properties: {
24
+ id: { type: "integer" },
25
+ name: { type: "string" },
26
+ description: { oneOf: [{ type: "string" }, { type: "null", nullable: true }] },
27
+ },
28
+ required: ["id", "name", "description"],
29
+ },
30
+ };
31
+ //# sourceMappingURL=ServicesModel.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ServicesModel.js","sourceRoot":"","sources":["../../../src/schema-definitions/models/ServicesModel.ts"],"names":[],"mappings":";;;AACA,mEAAwF;AAGxF,MAAa,aAAc,SAAQ,iBAAgB;;AAAnD,sCA8BC;AAzBiB,4BAAc,GAA8C;IACtE,EAAE,EAAE;QACA,IAAI,EAAE,qBAAS,CAAC,OAAO;QACvB,UAAU,EAAE,IAAI;KACnB;IACD,IAAI,EAAE,qBAAS,CAAC,MAAM,CAAC,GAAG,CAAC;IAC3B,WAAW,EAAE,qBAAS,CAAC,IAAI;CAC9B,CAAC;AAEY,8BAAgB,GAAG,MAAM,CAAC,IAAI,CAAC,aAAa,CAAC,cAAc,CAAC;KACrE,MAAM,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,KAAK,IAAI,CAAC;KAC7B,MAAM,CAAC,YAAY,CAA2B,CAAC;AAEtC,wBAAU,GAAgC;IACpD,IAAI,EAAE,OAAO;IACb,KAAK,EAAE;QACH,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACR,EAAE,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE;YACvB,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;YACxB,WAAW,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,EAAE;SACjF;QACD,QAAQ,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,aAAa,CAAC;KAC1C;CACJ,CAAC"}
@@ -0,0 +1,6 @@
1
+ export * from "./LibrariesModel";
2
+ export * from "./ServicesModel";
3
+ export * from "./DepartmentsModel";
4
+ export * from "./OpeningHoursModel";
5
+ export * from "./LibraryServicesModel";
6
+ export * from "./LibraryDepartmentsModel";