@opengis/gis 0.1.82 → 0.2.1

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/dist/index.css +1 -1
  2. package/dist/index.js +6794 -6952
  3. package/dist/index.umd.cjs +50 -56
  4. package/module/cls.json +2 -1
  5. package/module/gis/form/gis.maps.form.json +2 -2
  6. package/module/gis/form/gis.registers.form.json +8 -199
  7. package/module/gis/form/gis.services.form.json +11 -200
  8. package/module/gis/table/gis.group_list.table.json +36 -0
  9. package/module/gis/table/gis.maps.table.json +5 -7
  10. package/module/gis/table/gis.ogc_service.table.json +14 -3
  11. package/module/gis/table/gis.registers.table.json +2 -3
  12. package/module/gis/table/gis.services.table.json +19 -6
  13. package/module/test/cls/doc_status.json +31 -31
  14. package/module/test/cls/ts.temp_status.json +18 -0
  15. package/module/test/cls/ts.temp_structure.ts_class.json +50 -0
  16. package/module/test/cls/ts.temp_type.json +10 -0
  17. package/module/test/layer/bp.json +60 -0
  18. package/module/test/map/address4.json +2 -42
  19. package/module/test/map/bp_myo.json +41 -0
  20. package/module/test/map/main.json +44 -0
  21. package/module/test/map/mbd.json +24 -176
  22. package/module/test/map/ts.json +20 -129
  23. package/module/test/select/address_id.json +3 -0
  24. package/module/test/select/address_id.sql +8 -0
  25. package/module/test/select/core.user_uid.sql +1 -1
  26. package/module/test/table/data_bp_myo.bp.table.json +123 -0
  27. package/package.json +61 -61
  28. package/server/migrations/ogc.sql +107 -0
  29. package/server/migrations/widgets.sql +21 -0
  30. package/server/routes/gis/index.mjs +18 -2
  31. package/server/routes/gis/ogc/map.info.point.js +120 -0
  32. package/server/routes/gis/registers/funcs/classifiers.js +6 -3
  33. package/server/routes/gis/registers/funcs/handleRegistryRequest.js +15 -22
  34. package/server/routes/gis/registers/gis.registry.js +3 -2
  35. package/server/routes/gis/services/add.service.js +5 -5
  36. package/server/routes/gis/services/get.services.col.js +19 -11
  37. package/server/routes/gis/services/get.services.js +29 -14
  38. package/server/routes/gis/services/legend.auto.js +78 -0
  39. package/server/routes/map/controllers/layerList.js +14 -2
  40. package/server/routes/map/controllers/mapFeatures.js +11 -2
  41. package/server/routes/map/controllers/mapFormat.js +14 -18
  42. package/server/routes/map/controllers/vtile.js +1 -1
  43. package/server/routes/map/index.mjs +36 -17
  44. package/server/routes/map/maps/add.map.js +42 -0
  45. package/server/routes/map/maps/del.map.js +19 -0
  46. package/server/routes/map/maps/get.map.js +67 -0
  47. package/server/routes/map/vtile1.js +42 -6
  48. package/server/routes/map/widgets/add.widget.js +39 -0
  49. package/server/routes/map/widgets/del.widget.js +23 -0
  50. package/server/routes/map/widgets/get.widget.js +41 -0
@@ -1,152 +1,43 @@
1
1
  {
2
2
  "history": true,
3
- "height": "calc(100vh - 65px)",
4
- "source_path": "ts.temp_structure",
3
+ "height": "calc(100vh - 65px)",
4
+ "center": [
5
+ 34.65450,
6
+ 48.51174
7
+ ],
8
+ "zoom": 11,
9
+ "layers": ["ed67980cd690"],
5
10
  "widgets": [
6
11
  {
7
12
  "type": "info",
8
13
  "position": "top-left",
9
14
  "config": {
10
15
  "title": "Тимчасові споруди",
11
- "content": "<p style='font-size: 14px; color: #34495E;'>Інформація про тимчасові споруди встановлені на території м. Кам'янське</p>",
12
- "goTo": [
13
- {
14
- "label": "Карта адресного реєстру",
15
- "url": "/map/addr"
16
- },
17
- {
18
- "label": "Карта БП/МУО",
19
- "url": "/map/bp_myo"
20
- },
21
- {
22
- "label": "Карта містобудівної документації",
23
- "url": "/map/mbd"
24
- },
25
- {
26
- "label": "Основна карта",
27
- "url": "/map/main"
28
- }
29
- ]
16
+ "content": "<p style='font-size: 14px; color: #34495E;'>Інформація про тимчасові споруди встановлені на території м. Кам'янське</p>"
30
17
  }
31
18
  },
32
19
  {
33
- "type": "attribute",
20
+ "type": "dataset",
34
21
  "position": "top-left",
35
22
  "config": {
36
- "layer": {
37
- "id": "temp_structure",
38
- "service": "vtile",
39
- "service_key": "ts",
40
- "map_key": "ts",
41
- "visible": true,
42
- "url": "/api/vtile/ts.temp_structure/ua/{z}/{x}/{y}.vmt",
43
- "style": {
44
- "type": "polygon",
45
- "attrType": "icon-by-attribute",
46
- "attribute": "temp_structure_status",
47
- "default_icon": "pin6-l-fa-question+4767e6.png",
48
- "icon_base_url": "https://data.softpro.ua/api-user/markerIcon/",
49
- "icon_size": 1,
50
- "iconZoom": 14,
51
- "pointZoom": 14,
52
- "icon_anchor": "bottom",
53
- "rules": [
54
- {
55
- "value": "1",
56
- "label": "Діючий",
57
- "color": "#28a745",
58
- "icon": "pin6-l-fa-check+28a745.png"
59
- },
60
- {
61
- "value": "2",
62
- "label": "Анульований",
63
- "color": "#dc3545",
64
- "icon": "pin6-l-fa-exclamation+dc3545.png"
65
- },
66
- {
67
- "value": "3",
68
- "label": "Призупинений",
69
- "color": "#ffc107",
70
- "icon": "pin6-l-ty-lock-closed-outline+ffc107.png"
71
- },
72
- {
73
- "value": "4",
74
- "label": "Завершився термін дії",
75
- "color": "purple",
76
- "icon": "pin6-l-fa-clock-o+800080.png"
77
- }
78
- ],
79
- "popup": {
80
- "mode": "html",
81
- "title": "<strong>Тимчасова споруда</strong>",
82
- "fields": [
83
- {
84
- "label": "Назва",
85
- "value": "name"
86
- },
87
- {
88
- "label": "Кадастровий номер ЗД",
89
- "value": "cad_num"
90
- },
91
- {
92
- "label": "Площа тимчасової споруди, м. кв.",
93
- "value": "area"
94
- }
95
- ]
96
- }
97
- }
98
- }
23
+ "layer":"ed67980cd690",
24
+ "attribute":"status"
99
25
  }
100
26
  },
101
- {
102
- "type": "card",
103
- "position": "top-right",
104
- "config": {
105
- "title": "Інформація про об'єкт"
106
- }
27
+ {
28
+ "type": "layers",
29
+ "visible":false
30
+ },
31
+ {
32
+ "type": "legend",
33
+ "position":"bottom-right"
107
34
  },
108
35
  {
109
36
  "type": "basemaps",
110
37
  "position": "bottom-left",
111
- "title": "Базові карти",
112
- "config": {
113
- "default": "voyager",
114
- "layers": [
115
- {
116
- "id": "voyager",
117
- "title": "Базова карта (voyager)",
118
- "url": "https://data.gki.com.ua/api-user/rtile/voyager/ua/{z}/{x}/{y}.png",
119
- "service": "raster",
120
- "map_key": "ts",
121
- "service_key": "ts",
122
- "attribution": "&copy; <a href='http://www.openstreetmap.org/copyright'>OpenStreetMap</a>, &copy; <a href='https://carto.com/attributions'>CARTO</a>",
123
- "image": "https://data.gki.com.ua/api-user/rtile/voyager/ua/12/2422/1400.png",
124
- "owner": "OSM",
125
- "basemap": true
126
- },
127
- {
128
- "id": "esri",
129
- "title": "ESRI Online Imagery(2022-2023)",
130
- "url": "https://server.arcgisonline.com/arcgis/rest/services/World_Imagery/MapServer/tile/{z}/{y}/{x}.png",
131
- "service": "raster",
132
- "image": "https://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/tile/7/47/69.png"
133
- }
134
- ]
135
- },
136
- "visible": true
137
- }
138
- ],
139
- "interactions": {
140
- "hover": {
141
- "enabled": true
142
- },
143
- "navigation": {
144
- "enabled": true
145
- },
146
- "click": {
147
- "enabled": true
38
+ "title": "Базові карти"
148
39
  }
149
- },
40
+ ],
150
41
  "tools": [
151
42
  "home",
152
43
  "geolocation",
@@ -0,0 +1,3 @@
1
+ {
2
+ "extra": true
3
+ }
@@ -0,0 +1,8 @@
1
+ SELECT addr_id,
2
+ coalesce(c.name , ' ') || ' ' || (select name from data_address.street where str_id=a.parent limit 1) ||
3
+ coalesce(', ' ||addr_num,'')
4
+ FROM data_address.address a
5
+ left join data_address.street b on a.parent=b.str_id
6
+ left join admin.cls c on c.parent='str_type' and c.code=b.type::text
7
+ order by
8
+ b.name
@@ -1 +1 @@
1
- select uid, coalesce(coalesce(sur_name,'')||coalesce(' '||user_name,'') ||coalesce(' '||father_name,''),login) as text from admin.users
1
+ select uid, coalesce(coalesce(sur_name,'')||coalesce(' '||user_name,'') ||coalesce(' '||father_name,''),login) as text from admin.users
@@ -0,0 +1,123 @@
1
+ {
2
+ "key": "bp_id",
3
+ "table": "data_bp_myo.bp",
4
+ "actions": [
5
+ "add",
6
+ "edit",
7
+ "del"
8
+ ],
9
+ "controls": [
10
+ "search",
11
+ "list",
12
+ "add"
13
+ ],
14
+ "access": "user",
15
+ "order": "cdate desc",
16
+ "meta": {
17
+ "title": "bp_code",
18
+ "search": "bp_code,bp_number,bp_reg_num,bp_issued_name,bp_customer_name,bp_object_name"
19
+ },
20
+ "title": "Будівельні паспорти",
21
+ "form": "data_bp_myo.bp.form",
22
+ "columns": [
23
+ {
24
+ "ua": "Реєстраційний номер МБК",
25
+ "name": "bp_number",
26
+ "width": 100,
27
+ "format": "text"
28
+ },
29
+ {
30
+ "ua": "Реєстраційний номер в ЄДЕССБ",
31
+ "meta": "title",
32
+ "name": "bp_code",
33
+ "hidden": true,
34
+ "format": "text"
35
+ },
36
+ {
37
+ "ua": "Реєстраційний номер",
38
+ "name": "bp_reg_num",
39
+ "width": 100,
40
+ "format": "text"
41
+ },
42
+ {
43
+ "ua": "Назва об’єкта будівництва",
44
+ "name": "bp_object_name",
45
+ "width": 300,
46
+ "format": "text"
47
+ },
48
+ {
49
+ "ua": "Адреса",
50
+ "name": "address",
51
+ "width": 300,
52
+ "format": "text"
53
+ },
54
+ {
55
+ "ua": "Вид будівництва",
56
+ "name": "bp_build_type",
57
+ "data": "bp_build_type",
58
+ "width": 150,
59
+ "format": "badge"
60
+ },
61
+ {
62
+ "ua": "Дата видачі",
63
+ "name": "bp_issued_date",
64
+ "width": 100,
65
+ "format": "date"
66
+ },
67
+ {
68
+ "ua": "Статус реєстрації",
69
+ "name": "bp_doc_status",
70
+ "data": "doc_status",
71
+ "width": 150,
72
+ "hidden": true,
73
+ "format": "badge"
74
+ },
75
+ {
76
+ "ua": "Назва органу, що видав",
77
+ "name": "bp_issued_name",
78
+ "width": 300,
79
+ "hidden": true,
80
+ "format": "text"
81
+ },
82
+ {
83
+ "ua": "Замовник",
84
+ "name": "bp_customer_name",
85
+ "width": 300,
86
+ "format": "text"
87
+ },
88
+ {
89
+ "ua": "Кадастрові номери",
90
+ "name": "land_number",
91
+ "format": "slot",
92
+ "hidden": true,
93
+ "slot": {
94
+ "content": "<p v-for=\"item in data?.land_number\">{{item}}</p>"
95
+ }
96
+ },
97
+ {
98
+ "ua": "Версія документу",
99
+ "name": "obj_version",
100
+ "format": "text",
101
+ "hidden": true
102
+ }
103
+ ],
104
+ "filterList": [
105
+ {
106
+ "ua": "Вид будівництва",
107
+ "name": "bp_build_type",
108
+ "data": "bp_build_type",
109
+ "type": "Check"
110
+ },
111
+ {
112
+ "ua": "Дата видачі",
113
+ "name": "bp_issued_date",
114
+ "type": "Date"
115
+ },
116
+ {
117
+ "ua": "Статус документа",
118
+ "name": "bp_doc_status",
119
+ "data": "doc_status",
120
+ "type": "Check"
121
+ }
122
+ ]
123
+ }
package/package.json CHANGED
@@ -1,61 +1,61 @@
1
- {
2
- "name": "@opengis/gis",
3
- "version": "0.1.82",
4
- "type": "module",
5
- "author": "Softpro",
6
- "main": "./dist/index.js",
7
- "files": [
8
- "dist/*",
9
- "module/*",
10
- "server/*",
11
- "plugin.js",
12
- "utils.js",
13
- "config.js",
14
- "README.md",
15
- "LICENSE"
16
- ],
17
- "scripts": {
18
- "patch": "npm version patch && git push && npm publish",
19
- "dev": "node server",
20
- "front": "vite dev",
21
- "build-lib": "vite build",
22
- "build:admin": "vite build admin",
23
- "build": "vite build",
24
- "preview": "vite preview",
25
- "prod": "NODE_ENV=production node server",
26
- "docs:install": "npm install --prefix ./docs",
27
- "docs:dev": "npm run --prefix ./docs docs:dev",
28
- "docs:build": "npm run --prefix ./docs docs:build",
29
- "docs:preview": "npm run --prefix ./docs docs:preview",
30
- "prepublishOnly": "npm run build"
31
- },
32
- "dependencies": {
33
- "@mapbox/sphericalmercator": "1.2.0",
34
- "carto": "0.16.3"
35
- },
36
- "peerDependencies": {
37
- "@opengis/fastify-table": "^2.0.13"
38
- },
39
- "resolutions": {
40
- "rollup": "4.30.0"
41
- },
42
- "devDependencies": {
43
- "yaml": "2.8.1",
44
- "@opengis/form": "^0.0.28",
45
- "@opengis/core": "^0.0.23",
46
- "@opengis/fastify-table": "^2.0.13",
47
- "@opengis/filter": "^0.1.7",
48
- "@vitejs/plugin-vue": "^5.2.3",
49
- "axios": "^1.11.0",
50
- "eslint": "8.49.0",
51
- "eslint-config-airbnb": "19.0.4",
52
- "lucide-vue-next": "^0.514.0",
53
- "sass-embedded": "1.86.3",
54
- "vite": "^6.3.5",
55
- "vue": "^3.5.13",
56
- "vue-router": "4.5.1",
57
- "vuedraggable": "^4.1.0",
58
- "typescript": "^5.9.2",
59
- "@opengis/table": "^0.0.27"
60
- }
61
- }
1
+ {
2
+ "name": "@opengis/gis",
3
+ "version": "0.2.1",
4
+ "type": "module",
5
+ "author": "Softpro",
6
+ "main": "./dist/index.js",
7
+ "files": [
8
+ "dist/*",
9
+ "module/*",
10
+ "server/*",
11
+ "plugin.js",
12
+ "utils.js",
13
+ "config.js",
14
+ "README.md",
15
+ "LICENSE"
16
+ ],
17
+ "scripts": {
18
+ "start1": "bun server",
19
+ "patch": "npm version patch && git push && npm publish",
20
+ "dev": "bun --hot server",
21
+ "front": "vite dev",
22
+ "build-lib": "vite build",
23
+ "build:admin": "vite build admin",
24
+ "build": "vite build",
25
+ "preview": "vite preview",
26
+ "prod": "NODE_ENV=production node server",
27
+ "docs:install": "npm install --prefix ./docs",
28
+ "docs:dev": "npm run --prefix ./docs docs:dev",
29
+ "docs:build": "npm run --prefix ./docs docs:build",
30
+ "docs:preview": "npm run --prefix ./docs docs:preview",
31
+ "prepublishOnly": "npm run build"
32
+ },
33
+ "dependencies": {
34
+ "@mapbox/sphericalmercator": "1.2.0",
35
+ "carto": "0.16.3"
36
+ },
37
+ "peerDependencies": {
38
+ "@opengis/fastify-table": "^2.0.23"
39
+ },
40
+ "resolutions": {
41
+ "rollup": "4.30.0"
42
+ },
43
+ "devDependencies": {
44
+ "@opengis/core": "^0.0.23",
45
+ "@opengis/fastify-table": "^2.0.23",
46
+ "@opengis/filter": "^0.1.7",
47
+ "@opengis/form": "^0.0.42",
48
+ "@opengis/table": "^0.0.27",
49
+ "@vitejs/plugin-vue": "^5.2.3",
50
+ "axios": "^1.11.0",
51
+ "eslint": "8.49.0",
52
+ "eslint-config-airbnb": "19.0.4",
53
+ "lucide-vue-next": "^0.514.0",
54
+ "sass-embedded": "1.86.3",
55
+ "typescript": "^5.9.2",
56
+ "vite": "^6.3.5",
57
+ "vue": "^3.5.13",
58
+ "vue-router": "4.5.1",
59
+ "vuedraggable": "^4.1.0"
60
+ }
61
+ }
@@ -0,0 +1,107 @@
1
+ CREATE TABLE if not exists gis.ogc_service
2
+ (
3
+ ogc_service_id text NOT NULL DEFAULT admin.next_id(),
4
+ name text, -- Назва
5
+ service text, -- TMS/WMS/WFS
6
+ url text, -- Шлях
7
+ enabled boolean, -- Опис
8
+ geom geometry, -- Баунд
9
+ updated_by text,
10
+ updated_at timestamp without time zone,
11
+ created_at timestamp without time zone DEFAULT date_trunc('minutes'::text, now()),
12
+ created_by text,
13
+ group_id text, -- Ідентифікатор групи
14
+ ispublic boolean DEFAULT false, -- Чи є сервіс публічним
15
+ service_id text DEFAULT admin.next_id(), -- ID
16
+ srid text, -- srid
17
+ info text,
18
+ scheme text, -- Схема
19
+ category text, -- Категорія
20
+ attribution text, -- Атрибуція
21
+ editor_id text,
22
+ editor_date timestamp without time zone,
23
+ cdate timestamp without time zone DEFAULT date_trunc('minutes'::text, now()),
24
+ uid text,
25
+ files json,
26
+ access_level text DEFAULT 'public'::text, -- Рівень доступу (public, user, admin)
27
+ sub_layers text, -- Під шари (Для WMS)
28
+ isadmin boolean DEFAULT false, -- Ознака доступу лише для адмін частини порталу
29
+ user_group_id text, -- Група користувачів
30
+ url_list text[], -- URL List
31
+ table_name text, -- Таблиця на клік (інтерактивний шар)
32
+ setting json, -- Додаткові налаштування
33
+ CONSTRAINT ogc_service_pkey PRIMARY KEY (ogc_service_id),
34
+ CONSTRAINT gis_ogc_service_group_id_fkey FOREIGN KEY (group_id)
35
+ REFERENCES gis.group_list (group_id) MATCH SIMPLE
36
+ ON UPDATE NO ACTION ON DELETE NO ACTION
37
+ );
38
+
39
+ COMMENT ON TABLE gis.ogc_service IS 'Сервіси';
40
+
41
+ COMMENT ON COLUMN gis.ogc_service.name IS 'Назва';
42
+ COMMENT ON COLUMN gis.ogc_service.service IS 'TMS/WMS/WFS';
43
+ COMMENT ON COLUMN gis.ogc_service.url IS 'Шлях';
44
+ COMMENT ON COLUMN gis.ogc_service.enabled IS 'Опис';
45
+ COMMENT ON COLUMN gis.ogc_service.geom IS 'Баунд';
46
+ COMMENT ON COLUMN gis.ogc_service.group_id IS 'Ідентифікатор групи';
47
+ COMMENT ON COLUMN gis.ogc_service.ispublic IS 'Чи є сервіс публічним';
48
+ COMMENT ON COLUMN gis.ogc_service.service_id IS 'ID';
49
+ COMMENT ON COLUMN gis.ogc_service.srid IS 'srid';
50
+ COMMENT ON COLUMN gis.ogc_service.scheme IS 'Схема';
51
+ COMMENT ON COLUMN gis.ogc_service.category IS 'Категорія';
52
+ COMMENT ON COLUMN gis.ogc_service.attribution IS 'Атрибуція';
53
+ COMMENT ON COLUMN gis.ogc_service.access_level IS 'Рівень доступу (public, user, admin)';
54
+ COMMENT ON COLUMN gis.ogc_service.sub_layers IS 'Під шари (Для WMS)';
55
+ COMMENT ON COLUMN gis.ogc_service.isadmin IS 'Ознака доступу лише для адмін частини порталу';
56
+ COMMENT ON COLUMN gis.ogc_service.user_group_id IS 'Група користувачів';
57
+ COMMENT ON COLUMN gis.ogc_service.url_list IS 'URL List';
58
+ COMMENT ON COLUMN gis.ogc_service.table_name IS 'Таблиця на клік (інтерактивний шар)';
59
+ COMMENT ON COLUMN gis.ogc_service.setting IS 'Додаткові налаштування';
60
+
61
+ CREATE INDEX if not exists gis_ogc_service_category_trgm_idx
62
+ ON gis.ogc_service
63
+ USING gin
64
+ (category COLLATE pg_catalog."default" gin_trgm_ops);
65
+
66
+ CREATE INDEX if not exists gis_ogc_service_enabled_btree_idx
67
+ ON gis.ogc_service
68
+ USING btree
69
+ (enabled);
70
+
71
+ CREATE INDEX if not exists gis_ogc_service_isadmin_btree_idx
72
+ ON gis.ogc_service
73
+ USING btree
74
+ (ispublic);
75
+
76
+ CREATE INDEX if not exists gis_ogc_service_ispublic_btree_idx
77
+ ON gis.ogc_service
78
+ USING btree
79
+ (ispublic);
80
+
81
+ CREATE INDEX if not exists gis_ogc_service_name_gin_idx
82
+ ON gis.ogc_service
83
+ USING gin
84
+ (name COLLATE pg_catalog."default" gin_trgm_ops);
85
+
86
+ CREATE INDEX if not exists gis_ogc_service_name_gin_idx_lower
87
+ ON gis.ogc_service
88
+ USING gin
89
+ (lower(name) COLLATE pg_catalog."default" gin_trgm_ops);
90
+
91
+ CREATE INDEX if not exists gis_ogc_service_name_trgm_idx
92
+ ON gis.ogc_service
93
+ USING gin
94
+ (name COLLATE pg_catalog."default" gin_trgm_ops);
95
+
96
+ CREATE INDEX if not exists gis_ogc_service_service_btree_idx
97
+ ON gis.ogc_service
98
+ USING btree
99
+ (service COLLATE pg_catalog."default");
100
+
101
+ CREATE INDEX if not exists gis_ogc_service_srid_btree_idx
102
+ ON gis.ogc_service
103
+ USING btree
104
+ (srid COLLATE pg_catalog."default");
105
+
106
+ alter table gis.ogc_service add column if not exists html text;
107
+ comment on column gis.ogc_service.html is 'HTML картки';
@@ -0,0 +1,21 @@
1
+ create schema if not exists gis;
2
+
3
+ CREATE TABLE if not exists gis.widgets
4
+ (
5
+ widget_id text NOT NULL DEFAULT next_id(),
6
+ map_id text NOT NULL,
7
+ name text,
8
+ type text NOT NULL,
9
+ title text,
10
+ position text,
11
+ config jsonb,
12
+ created_by text NOT NULL,
13
+ updated_by text,
14
+ updated_at timestamp without time zone,
15
+ created_at timestamp without time zone NOT NULL DEFAULT now(),
16
+ CONSTRAINT widgets_pkey PRIMARY KEY (widget_id),
17
+ CONSTRAINT widgets_map_id_fkey FOREIGN KEY (map_id)
18
+ REFERENCES gis.maps (map_id)
19
+ );
20
+
21
+ COMMENT ON TABLE gis.widgets IS 'Map widgets';
@@ -1,5 +1,3 @@
1
- import fp from 'fastify-plugin';
2
-
3
1
  import insertColumns from './registers/insert.columns.js';
4
2
  import insertFilters from './registers/insert.filters.js';
5
3
  import metadataXML from './metadata/metadataXML.js';
@@ -15,6 +13,21 @@ import addService from './services/add.service.js';
15
13
  import addGisRegistry from './registers/add.registry.js';
16
14
  import deleteGisRegistry from './registers/del.registry.js';
17
15
  import getServicesCol from './services/get.services.col.js';
16
+ import legendAuto from './services/legend.auto.js';
17
+ import mapInfoPoint from './ogc/map.info.point.js';
18
+
19
+ const mapInfoPointSchema = {
20
+ querystring: {
21
+ type: 'object',
22
+ properties: {
23
+ x: { type: 'number' },
24
+ y: { type: 'number' },
25
+ layers: { type: 'string' },
26
+ index: { type: 'number', minimum: 0 }
27
+ },
28
+ required: ['x', 'y', 'layers']
29
+ }
30
+ };
18
31
 
19
32
  async function route(app) {
20
33
  app.put('/insert-columns/:token', insertColumns);
@@ -38,6 +51,9 @@ async function route(app) {
38
51
  app.post('/gis-service/:id?', { config: { policy: ['public'] } }, addService);
39
52
  app.put('/gis-service/:id', { config: { policy: ['public'] } }, addService);
40
53
  app.delete('/gis-service/:id', { config: { policy: ['public'] } }, deleteService);
54
+ app.get('/legend-auto/:id', { config: { policy: ['public'] } }, legendAuto);
55
+
56
+ app.get('/map-info-point', { config: { policy: ['public'] }, schema: mapInfoPointSchema }, mapInfoPoint);
41
57
  }
42
58
 
43
59
  export default route;