@opengis/bi 1.0.13 → 1.0.14

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 (50) hide show
  1. package/README.md +2 -4
  2. package/config.js +5 -5
  3. package/dist/bi.js +1 -1
  4. package/dist/bi.umd.cjs +116 -130
  5. package/dist/{import-file-1T7kpSzt.js → import-file-DUp3rsNI.js} +11132 -10748
  6. package/dist/{map-component-mixin-BLM9iEWA.js → map-component-mixin-CGM0P5ub.js} +1135 -1134
  7. package/dist/style.css +1 -1
  8. package/dist/{vs-calendar-WiK1hcHS.js → vs-calendar-cOoinEwc.js} +33 -30
  9. package/dist/vs-funnel-bar-kLkPoIhJ.js +105 -0
  10. package/dist/vs-heatmap-3XAVGTSo.js +98 -0
  11. package/dist/vs-map-B1tr6V5_.js +74 -0
  12. package/dist/{vs-map-cluster-Dfe9INqE.js → vs-map-cluster-BWJPx7wE.js} +28 -25
  13. package/dist/vs-number-CrU7LmkV.js +48 -0
  14. package/dist/{vs-text-DcrAdQ40.js → vs-text-DRPx3aID.js} +2 -1
  15. package/package.json +37 -12
  16. package/plugin.js +4 -4
  17. package/server/migrations/bi.sql +66 -0
  18. package/server/plugins/docs.js +36 -35
  19. package/server/plugins/hook.js +72 -69
  20. package/server/plugins/vite.js +22 -8
  21. package/server/routes/dashboard/controllers/dashboard.delete.js +5 -3
  22. package/server/routes/dashboard/controllers/dashboard.js +66 -32
  23. package/server/routes/dashboard/controllers/dashboard.list.js +2 -5
  24. package/server/routes/dashboard/controllers/utils/yaml.js +1 -2
  25. package/server/routes/dashboard/index.mjs +5 -4
  26. package/server/routes/data/controllers/data.js +94 -34
  27. package/server/routes/data/controllers/util/chartSQL.js +24 -10
  28. package/server/routes/data/controllers/util/normalizeData.js +51 -29
  29. package/server/routes/data/index.mjs +1 -3
  30. package/server/routes/db/controllers/dbTablePreview.js +63 -0
  31. package/server/routes/db/controllers/dbTables.js +36 -0
  32. package/server/routes/db/index.mjs +17 -0
  33. package/server/routes/edit/controllers/dashboard.add.js +6 -5
  34. package/server/routes/edit/controllers/dashboard.edit.js +16 -9
  35. package/server/routes/edit/controllers/widget.add.js +43 -19
  36. package/server/routes/edit/controllers/widget.del.js +13 -6
  37. package/server/routes/edit/controllers/widget.edit.js +34 -13
  38. package/server/routes/edit/index.mjs +14 -10
  39. package/server/routes/map/controllers/cluster.js +89 -60
  40. package/server/routes/map/controllers/clusterVtile.js +154 -84
  41. package/server/routes/map/controllers/geojson.js +48 -22
  42. package/server/routes/map/controllers/map.js +51 -51
  43. package/server/routes/map/controllers/vtile.js +61 -40
  44. package/server/routes/map/index.mjs +1 -1
  45. package/server/utils/getWidget.js +67 -40
  46. package/utils.js +5 -4
  47. package/dist/vs-funnel-bar-CpPbYZ0_.js +0 -92
  48. package/dist/vs-heatmap-BG4eIROH.js +0 -83
  49. package/dist/vs-map-BRk6Fmks.js +0 -66
  50. package/dist/vs-number-CJq-vi95.js +0 -39
package/README.md CHANGED
@@ -7,9 +7,10 @@ BI (Business Intelligence) - поняття, яке поєднує в собі
7
7
 
8
8
  ## Короткий опис
9
9
 
10
- Підсистема для створення інтерактивних графічних представлень ключової інформації, яка відображається у вигляді віджетів та графіків.
10
+ Підсистема для створення інтерактивних графічних представлень ключової інформації, яка відображається у вигляді віджетів та графіків.
11
11
 
12
12
  Модуль містить реєстри:
13
+
13
14
  - Панель управління (Dashboard)
14
15
  - Набір даних (Dataset)
15
16
 
@@ -21,7 +22,6 @@ BI (Business Intelligence) - поняття, яке поєднує в собі
21
22
 
22
23
  ![Інтерфейс](/assets/image/interface.png)
23
24
 
24
-
25
25
  ## Встновлення
26
26
 
27
27
  ```bash
@@ -38,13 +38,11 @@ fastify.register(import('@opengis/bi'), config);
38
38
 
39
39
  - Підсистема «Аналітичний модуль» Червоноградської міської ради.
40
40
 
41
-
42
41
  ## Документація
43
42
 
44
43
  [BI - Аналітичний модуль](https://docs.softpro.ua/bi/#bi)
45
44
  [apidocs/bi](https://apidocs.softpro.ua/bi/api/).
46
45
 
47
-
48
46
  ## License
49
47
 
50
48
  Copyright © SOFTPRO. Усі права захищено.
package/config.js CHANGED
@@ -1,9 +1,9 @@
1
- import fs from 'fs';
1
+ import { existsSync, readFileSync } from 'fs';
2
2
 
3
- import { readFile } from 'fs/promises';
4
-
5
- const fileName = ['/data/local/config.json', 'config.json'].find(el => (fs.existsSync(el) ? el : null));
6
- const config = fileName ? await readFile(fileName).then(el => JSON.parse(el)) : {};
3
+ const fileName = ['/data/local/config.json', 'config.json'].find((el) =>
4
+ existsSync(el) ? el : null
5
+ );
6
+ const config = fileName ? JSON.parse(readFileSync(fileName), '{}') : {};
7
7
 
8
8
  Object.assign(config, {
9
9
  allTemplates: config?.allTemplates || {},
package/dist/bi.js CHANGED
@@ -1,4 +1,4 @@
1
- import { l as f } from "./import-file-1T7kpSzt.js";
1
+ import { l as f } from "./import-file-DUp3rsNI.js";
2
2
  export {
3
3
  f as default
4
4
  };