Merge branch 'dev' of github.com:jetlinks/jetlinks-ui-vue into dev
This commit is contained in:
commit
7f321213a8
|
@ -10,7 +10,6 @@
|
|||
"dependencies": {
|
||||
"@vitejs/plugin-vue-jsx": "^3.0.0",
|
||||
"@vuemap/vue-amap": "^1.1.20",
|
||||
"@vueuse/core": "^9.10.0",
|
||||
"ant-design-vue": "^3.2.15",
|
||||
"axios": "^1.2.1",
|
||||
"echarts": "^5.4.1",
|
||||
|
@ -1485,7 +1484,7 @@
|
|||
},
|
||||
"node_modules/@types/linkify-it": {
|
||||
"version": "3.0.2",
|
||||
"resolved": "https://registry.npmjs.org/@types/linkify-it/-/linkify-it-3.0.2.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/@types/linkify-it/-/linkify-it-3.0.2.tgz",
|
||||
"integrity": "sha512-HZQYqbiFVWufzCwexrvh694SOim8z2d+xJl5UNamcvQFejLY/2YUtzXHYi3cHdI7PMlS8ejH2slRAOJQ32aNbA==",
|
||||
"peer": true
|
||||
},
|
||||
|
@ -1506,7 +1505,7 @@
|
|||
},
|
||||
"node_modules/@types/markdown-it": {
|
||||
"version": "12.2.3",
|
||||
"resolved": "https://registry.npmjs.org/@types/markdown-it/-/markdown-it-12.2.3.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/@types/markdown-it/-/markdown-it-12.2.3.tgz",
|
||||
"integrity": "sha512-GKMHFfv3458yYy+v/N8gjufHO6MSZKCOXpZc5GXIWWy8uldwfmPn98vp81gZ5f9SVw8YYBctgfJ22a2d7AOMeQ==",
|
||||
"peer": true,
|
||||
"dependencies": {
|
||||
|
@ -1516,7 +1515,7 @@
|
|||
},
|
||||
"node_modules/@types/mdurl": {
|
||||
"version": "1.0.2",
|
||||
"resolved": "https://registry.npmjs.org/@types/mdurl/-/mdurl-1.0.2.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/@types/mdurl/-/mdurl-1.0.2.tgz",
|
||||
"integrity": "sha512-eC4U9MlIcu2q0KQmXszyn5Akca/0jrQmwDRgpAMJai7qBWq4amIQhZyNau4VYGtCeALvW1/NtjzJJ567aZxfKA==",
|
||||
"peer": true
|
||||
},
|
||||
|
@ -1556,11 +1555,6 @@
|
|||
"@types/webxr": "*"
|
||||
}
|
||||
},
|
||||
"node_modules/@types/web-bluetooth": {
|
||||
"version": "0.0.16",
|
||||
"resolved": "https://registry.npmjs.org/@types/web-bluetooth/-/web-bluetooth-0.0.16.tgz",
|
||||
"integrity": "sha512-oh8q2Zc32S6gd/j50GowEjKLoOVOwHP/bWVjKJInBwQqdOYMdPrf1oVlelTlyfFK3CKxL1uahMDAr+vy8T7yMQ=="
|
||||
},
|
||||
"node_modules/@types/webxr": {
|
||||
"version": "0.5.0",
|
||||
"resolved": "https://registry.npmjs.org/@types/webxr/-/webxr-0.5.0.tgz",
|
||||
|
@ -1852,39 +1846,6 @@
|
|||
"vue": "^3.2.0"
|
||||
}
|
||||
},
|
||||
"node_modules/@vueuse/core": {
|
||||
"version": "9.10.0",
|
||||
"resolved": "https://registry.npmjs.org/@vueuse/core/-/core-9.10.0.tgz",
|
||||
"integrity": "sha512-CxMewME07qeuzuT/AOIQGv0EhhDoojniqU6pC3F8m5VC76L47UT18DcX88kWlP3I7d3qMJ4u/PD8iSRsy3bmNA==",
|
||||
"dependencies": {
|
||||
"@types/web-bluetooth": "^0.0.16",
|
||||
"@vueuse/metadata": "9.10.0",
|
||||
"@vueuse/shared": "9.10.0",
|
||||
"vue-demi": "*"
|
||||
},
|
||||
"funding": {
|
||||
"url": "https://github.com/sponsors/antfu"
|
||||
}
|
||||
},
|
||||
"node_modules/@vueuse/metadata": {
|
||||
"version": "9.10.0",
|
||||
"resolved": "https://registry.npmjs.org/@vueuse/metadata/-/metadata-9.10.0.tgz",
|
||||
"integrity": "sha512-G5VZhgTCapzU9rv0Iq2HBrVOSGzOKb+OE668NxhXNcTjUjwYxULkEhAw70FtRLMZc+hxcFAzDZlKYA0xcwNMuw==",
|
||||
"funding": {
|
||||
"url": "https://github.com/sponsors/antfu"
|
||||
}
|
||||
},
|
||||
"node_modules/@vueuse/shared": {
|
||||
"version": "9.10.0",
|
||||
"resolved": "https://registry.npmjs.org/@vueuse/shared/-/shared-9.10.0.tgz",
|
||||
"integrity": "sha512-vakHJ2ZRklAzqmcVBL38RS7BxdBA4+5poG9NsSyqJxrt9kz0zX3P5CXMy0Hm6LFbZXUgvKdqAS3pUH1zX/5qTQ==",
|
||||
"dependencies": {
|
||||
"vue-demi": "*"
|
||||
},
|
||||
"funding": {
|
||||
"url": "https://github.com/sponsors/antfu"
|
||||
}
|
||||
},
|
||||
"node_modules/3d-tiles-renderer": {
|
||||
"version": "0.3.16",
|
||||
"resolved": "https://registry.npmjs.org/3d-tiles-renderer/-/3d-tiles-renderer-0.3.16.tgz",
|
||||
|
@ -3946,7 +3907,7 @@
|
|||
},
|
||||
"node_modules/highlight.js": {
|
||||
"version": "11.7.0",
|
||||
"resolved": "https://registry.npmjs.org/highlight.js/-/highlight.js-11.7.0.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/highlight.js/-/highlight.js-11.7.0.tgz",
|
||||
"integrity": "sha512-1rRqesRFhMO/PRF+G86evnyJkCgaZFOI+Z6kdj15TA18funfoqJXvgPCLSf0SWq3SRfg1j3HlDs8o4s3EGq1oQ==",
|
||||
"engines": {
|
||||
"node": ">=12.0.0"
|
||||
|
@ -5536,7 +5497,7 @@
|
|||
},
|
||||
"node_modules/linkify-it": {
|
||||
"version": "3.0.3",
|
||||
"resolved": "https://registry.npmjs.org/linkify-it/-/linkify-it-3.0.3.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/linkify-it/-/linkify-it-3.0.3.tgz",
|
||||
"integrity": "sha512-ynTsyrFSdE5oZ/O9GEf00kPngmOfVwazR5GKDq6EYfhlpFug3J2zybX56a2PRRpc9P+FuSoGNAwjlbDs9jJBPQ==",
|
||||
"dependencies": {
|
||||
"uc.micro": "^1.0.1"
|
||||
|
@ -5820,7 +5781,7 @@
|
|||
},
|
||||
"node_modules/lodash.flow": {
|
||||
"version": "3.5.0",
|
||||
"resolved": "https://registry.npmjs.org/lodash.flow/-/lodash.flow-3.5.0.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/lodash.flow/-/lodash.flow-3.5.0.tgz",
|
||||
"integrity": "sha512-ff3BX/tSioo+XojX4MOsOMhJw0nZoUEF011LX8g8d3gvjVbxd89cCio4BCXronjxcTUIJUoqKEUA+n4CqvvRPw=="
|
||||
},
|
||||
"node_modules/lodash.isfunction": {
|
||||
|
@ -6036,7 +5997,7 @@
|
|||
},
|
||||
"node_modules/markdown-it": {
|
||||
"version": "12.3.2",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it/-/markdown-it-12.3.2.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it/-/markdown-it-12.3.2.tgz",
|
||||
"integrity": "sha512-TchMembfxfNVpHkbtriWltGWc+m3xszaRD0CZup7GFFhzIgQqxIfn3eGj1yZpfuflzPvfkt611B2Q/Bsk1YnGg==",
|
||||
"dependencies": {
|
||||
"argparse": "^2.0.1",
|
||||
|
@ -6051,12 +6012,12 @@
|
|||
},
|
||||
"node_modules/markdown-it-abbr": {
|
||||
"version": "1.0.4",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-abbr/-/markdown-it-abbr-1.0.4.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-abbr/-/markdown-it-abbr-1.0.4.tgz",
|
||||
"integrity": "sha512-ZeA4Z4SaBbYysZap5iZcxKmlPL6bYA8grqhzJIHB1ikn7njnzaP8uwbtuXc4YXD5LicI4/2Xmc0VwmSiFV04gg=="
|
||||
},
|
||||
"node_modules/markdown-it-anchor": {
|
||||
"version": "8.6.6",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-anchor/-/markdown-it-anchor-8.6.6.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-anchor/-/markdown-it-anchor-8.6.6.tgz",
|
||||
"integrity": "sha512-jRW30YGywD2ESXDc+l17AiritL0uVaSnWsb26f+68qaW9zgbIIr1f4v2Nsvc0+s0Z2N3uX6t/yAw7BwCQ1wMsA==",
|
||||
"peerDependencies": {
|
||||
"@types/markdown-it": "*",
|
||||
|
@ -6065,22 +6026,22 @@
|
|||
},
|
||||
"node_modules/markdown-it-deflist": {
|
||||
"version": "2.1.0",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-deflist/-/markdown-it-deflist-2.1.0.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-deflist/-/markdown-it-deflist-2.1.0.tgz",
|
||||
"integrity": "sha512-3OuqoRUlSxJiuQYu0cWTLHNhhq2xtoSFqsZK8plANg91+RJQU1ziQ6lA2LzmFAEes18uPBsHZpcX6We5l76Nzg=="
|
||||
},
|
||||
"node_modules/markdown-it-emoji": {
|
||||
"version": "2.0.2",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-emoji/-/markdown-it-emoji-2.0.2.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-emoji/-/markdown-it-emoji-2.0.2.tgz",
|
||||
"integrity": "sha512-zLftSaNrKuYl0kR5zm4gxXjHaOI3FAOEaloKmRA5hijmJZvSjmxcokOLlzycb/HXlUFWzXqpIEoyEMCE4i9MvQ=="
|
||||
},
|
||||
"node_modules/markdown-it-footnote": {
|
||||
"version": "3.0.3",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-footnote/-/markdown-it-footnote-3.0.3.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-footnote/-/markdown-it-footnote-3.0.3.tgz",
|
||||
"integrity": "sha512-YZMSuCGVZAjzKMn+xqIco9d1cLGxbELHZ9do/TSYVzraooV8ypsppKNmUJ0fVH5ljkCInQAtFpm8Rb3eXSrt5w=="
|
||||
},
|
||||
"node_modules/markdown-it-highlightjs": {
|
||||
"version": "3.6.0",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-highlightjs/-/markdown-it-highlightjs-3.6.0.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-highlightjs/-/markdown-it-highlightjs-3.6.0.tgz",
|
||||
"integrity": "sha512-ex+Lq3cVkprh0GpGwFyc53A/rqY6GGzopPCG1xMsf8Ya3XtGC8Uw9tChN1rWbpyDae7tBBhVHVcMM29h4Btamw==",
|
||||
"dependencies": {
|
||||
"highlight.js": "^11.3.1",
|
||||
|
@ -6089,45 +6050,42 @@
|
|||
},
|
||||
"node_modules/markdown-it-ins": {
|
||||
"version": "3.0.1",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-ins/-/markdown-it-ins-3.0.1.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-ins/-/markdown-it-ins-3.0.1.tgz",
|
||||
"integrity": "sha512-32SSfZqSzqyAmmQ4SHvhxbFqSzPDqsZgMHDwxqPzp+v+t8RsmqsBZRG+RfRQskJko9PfKC2/oxyOs4Yg/CfiRw=="
|
||||
},
|
||||
"node_modules/markdown-it-mark": {
|
||||
"version": "3.0.1",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-mark/-/markdown-it-mark-3.0.1.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-mark/-/markdown-it-mark-3.0.1.tgz",
|
||||
"integrity": "sha512-HyxjAu6BRsdt6Xcv6TKVQnkz/E70TdGXEFHRYBGLncRE9lBFwDNLVtFojKxjJWgJ+5XxUwLaHXy+2sGBbDn+4A=="
|
||||
},
|
||||
"node_modules/markdown-it-sub": {
|
||||
"version": "1.0.0",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-sub/-/markdown-it-sub-1.0.0.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-sub/-/markdown-it-sub-1.0.0.tgz",
|
||||
"integrity": "sha512-z2Rm/LzEE1wzwTSDrI+FlPEveAAbgdAdPhdWarq/ZGJrGW/uCQbKAnhoCsE4hAbc3SEym26+W2z/VQB0cQiA9Q=="
|
||||
},
|
||||
"node_modules/markdown-it-sup": {
|
||||
"version": "1.0.0",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-sup/-/markdown-it-sup-1.0.0.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-sup/-/markdown-it-sup-1.0.0.tgz",
|
||||
"integrity": "sha512-E32m0nV9iyhRR7CrhnzL5msqic7rL1juWre6TQNxsnApg7Uf+F97JOKxUijg5YwXz86lZ0mqfOnutoryyNdntQ=="
|
||||
},
|
||||
"node_modules/markdown-it-task-lists": {
|
||||
"version": "2.1.1",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-task-lists/-/markdown-it-task-lists-2.1.1.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-task-lists/-/markdown-it-task-lists-2.1.1.tgz",
|
||||
"integrity": "sha512-TxFAc76Jnhb2OUu+n3yz9RMu4CwGfaT788br6HhEDlvWfdeJcLUsxk1Hgw2yJio0OXsxv7pyIPmvECY7bMbluA=="
|
||||
},
|
||||
"node_modules/markdown-it-toc-done-right": {
|
||||
"version": "4.2.0",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-toc-done-right/-/markdown-it-toc-done-right-4.2.0.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-toc-done-right/-/markdown-it-toc-done-right-4.2.0.tgz",
|
||||
"integrity": "sha512-UB/IbzjWazwTlNAX0pvWNlJS8NKsOQ4syrXZQ/C72j+jirrsjVRT627lCaylrKJFBQWfRsPmIVQie8x38DEhAQ=="
|
||||
},
|
||||
"node_modules/markdown-it/node_modules/entities": {
|
||||
"version": "2.1.0",
|
||||
"resolved": "https://registry.npmjs.org/entities/-/entities-2.1.0.tgz",
|
||||
"integrity": "sha512-hCx1oky9PFrJ611mf0ifBLBRW8lUUVRlFolb5gWRfIELabBlbp9xZvrqZLZAs+NxFnbfQoeGd8wDkygjg7U85w==",
|
||||
"funding": {
|
||||
"url": "https://github.com/fb55/entities?sponsor=1"
|
||||
}
|
||||
"resolved": "https://registry.npmmirror.com/entities/-/entities-2.1.0.tgz",
|
||||
"integrity": "sha512-hCx1oky9PFrJ611mf0ifBLBRW8lUUVRlFolb5gWRfIELabBlbp9xZvrqZLZAs+NxFnbfQoeGd8wDkygjg7U85w=="
|
||||
},
|
||||
"node_modules/mdurl": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmjs.org/mdurl/-/mdurl-1.0.1.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/mdurl/-/mdurl-1.0.1.tgz",
|
||||
"integrity": "sha512-/sKlQJCBYVY9Ers9hqzKou4H6V5UWc/M59TH2dvkt+84itfnq7uFOMLpOiOS4ujvHP4etln18fmIxA5R5fll0g=="
|
||||
},
|
||||
"node_modules/meow": {
|
||||
|
@ -8123,7 +8081,7 @@
|
|||
},
|
||||
"node_modules/uc.micro": {
|
||||
"version": "1.0.6",
|
||||
"resolved": "https://registry.npmjs.org/uc.micro/-/uc.micro-1.0.6.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/uc.micro/-/uc.micro-1.0.6.tgz",
|
||||
"integrity": "sha512-8Y75pvTYkLJW2hWQHXxoqRgV7qb9B+9vFEtidML+7koHUFapnVJAZ6cKs+Qjz5Aw3aZWHMC6u0wJE3At+nSGwA=="
|
||||
},
|
||||
"node_modules/ufo": {
|
||||
|
@ -8684,7 +8642,7 @@
|
|||
},
|
||||
"node_modules/vue3-markdown-it": {
|
||||
"version": "1.0.10",
|
||||
"resolved": "https://registry.npmjs.org/vue3-markdown-it/-/vue3-markdown-it-1.0.10.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/vue3-markdown-it/-/vue3-markdown-it-1.0.10.tgz",
|
||||
"integrity": "sha512-mTvHu0zl7jrh7ojgaZ+tTpCLiS4CVg4bTgTu4KGhw/cRRY5YgIG8QgFAPu6kCzSW6Znc9a52Beb6hFvF4hSMkQ==",
|
||||
"dependencies": {
|
||||
"markdown-it": "^12.3.2",
|
||||
|
@ -9971,7 +9929,7 @@
|
|||
},
|
||||
"@types/linkify-it": {
|
||||
"version": "3.0.2",
|
||||
"resolved": "https://registry.npmjs.org/@types/linkify-it/-/linkify-it-3.0.2.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/@types/linkify-it/-/linkify-it-3.0.2.tgz",
|
||||
"integrity": "sha512-HZQYqbiFVWufzCwexrvh694SOim8z2d+xJl5UNamcvQFejLY/2YUtzXHYi3cHdI7PMlS8ejH2slRAOJQ32aNbA==",
|
||||
"peer": true
|
||||
},
|
||||
|
@ -9992,7 +9950,7 @@
|
|||
},
|
||||
"@types/markdown-it": {
|
||||
"version": "12.2.3",
|
||||
"resolved": "https://registry.npmjs.org/@types/markdown-it/-/markdown-it-12.2.3.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/@types/markdown-it/-/markdown-it-12.2.3.tgz",
|
||||
"integrity": "sha512-GKMHFfv3458yYy+v/N8gjufHO6MSZKCOXpZc5GXIWWy8uldwfmPn98vp81gZ5f9SVw8YYBctgfJ22a2d7AOMeQ==",
|
||||
"peer": true,
|
||||
"requires": {
|
||||
|
@ -10002,7 +9960,7 @@
|
|||
},
|
||||
"@types/mdurl": {
|
||||
"version": "1.0.2",
|
||||
"resolved": "https://registry.npmjs.org/@types/mdurl/-/mdurl-1.0.2.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/@types/mdurl/-/mdurl-1.0.2.tgz",
|
||||
"integrity": "sha512-eC4U9MlIcu2q0KQmXszyn5Akca/0jrQmwDRgpAMJai7qBWq4amIQhZyNau4VYGtCeALvW1/NtjzJJ567aZxfKA==",
|
||||
"peer": true
|
||||
},
|
||||
|
@ -10041,11 +9999,6 @@
|
|||
"@types/webxr": "*"
|
||||
}
|
||||
},
|
||||
"@types/web-bluetooth": {
|
||||
"version": "0.0.16",
|
||||
"resolved": "https://registry.npmjs.org/@types/web-bluetooth/-/web-bluetooth-0.0.16.tgz",
|
||||
"integrity": "sha512-oh8q2Zc32S6gd/j50GowEjKLoOVOwHP/bWVjKJInBwQqdOYMdPrf1oVlelTlyfFK3CKxL1uahMDAr+vy8T7yMQ=="
|
||||
},
|
||||
"@types/webxr": {
|
||||
"version": "0.5.0",
|
||||
"resolved": "https://registry.npmjs.org/@types/webxr/-/webxr-0.5.0.tgz",
|
||||
|
@ -10307,30 +10260,6 @@
|
|||
"uppercamelcase": "^1.1.0"
|
||||
}
|
||||
},
|
||||
"@vueuse/core": {
|
||||
"version": "9.10.0",
|
||||
"resolved": "https://registry.npmjs.org/@vueuse/core/-/core-9.10.0.tgz",
|
||||
"integrity": "sha512-CxMewME07qeuzuT/AOIQGv0EhhDoojniqU6pC3F8m5VC76L47UT18DcX88kWlP3I7d3qMJ4u/PD8iSRsy3bmNA==",
|
||||
"requires": {
|
||||
"@types/web-bluetooth": "^0.0.16",
|
||||
"@vueuse/metadata": "9.10.0",
|
||||
"@vueuse/shared": "9.10.0",
|
||||
"vue-demi": "*"
|
||||
}
|
||||
},
|
||||
"@vueuse/metadata": {
|
||||
"version": "9.10.0",
|
||||
"resolved": "https://registry.npmjs.org/@vueuse/metadata/-/metadata-9.10.0.tgz",
|
||||
"integrity": "sha512-G5VZhgTCapzU9rv0Iq2HBrVOSGzOKb+OE668NxhXNcTjUjwYxULkEhAw70FtRLMZc+hxcFAzDZlKYA0xcwNMuw=="
|
||||
},
|
||||
"@vueuse/shared": {
|
||||
"version": "9.10.0",
|
||||
"resolved": "https://registry.npmjs.org/@vueuse/shared/-/shared-9.10.0.tgz",
|
||||
"integrity": "sha512-vakHJ2ZRklAzqmcVBL38RS7BxdBA4+5poG9NsSyqJxrt9kz0zX3P5CXMy0Hm6LFbZXUgvKdqAS3pUH1zX/5qTQ==",
|
||||
"requires": {
|
||||
"vue-demi": "*"
|
||||
}
|
||||
},
|
||||
"3d-tiles-renderer": {
|
||||
"version": "0.3.16",
|
||||
"resolved": "https://registry.npmjs.org/3d-tiles-renderer/-/3d-tiles-renderer-0.3.16.tgz",
|
||||
|
@ -11997,7 +11926,7 @@
|
|||
},
|
||||
"highlight.js": {
|
||||
"version": "11.7.0",
|
||||
"resolved": "https://registry.npmjs.org/highlight.js/-/highlight.js-11.7.0.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/highlight.js/-/highlight.js-11.7.0.tgz",
|
||||
"integrity": "sha512-1rRqesRFhMO/PRF+G86evnyJkCgaZFOI+Z6kdj15TA18funfoqJXvgPCLSf0SWq3SRfg1j3HlDs8o4s3EGq1oQ=="
|
||||
},
|
||||
"homedir-polyfill": {
|
||||
|
@ -13236,7 +13165,7 @@
|
|||
},
|
||||
"linkify-it": {
|
||||
"version": "3.0.3",
|
||||
"resolved": "https://registry.npmjs.org/linkify-it/-/linkify-it-3.0.3.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/linkify-it/-/linkify-it-3.0.3.tgz",
|
||||
"integrity": "sha512-ynTsyrFSdE5oZ/O9GEf00kPngmOfVwazR5GKDq6EYfhlpFug3J2zybX56a2PRRpc9P+FuSoGNAwjlbDs9jJBPQ==",
|
||||
"requires": {
|
||||
"uc.micro": "^1.0.1"
|
||||
|
@ -13451,7 +13380,7 @@
|
|||
},
|
||||
"lodash.flow": {
|
||||
"version": "3.5.0",
|
||||
"resolved": "https://registry.npmjs.org/lodash.flow/-/lodash.flow-3.5.0.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/lodash.flow/-/lodash.flow-3.5.0.tgz",
|
||||
"integrity": "sha512-ff3BX/tSioo+XojX4MOsOMhJw0nZoUEF011LX8g8d3gvjVbxd89cCio4BCXronjxcTUIJUoqKEUA+n4CqvvRPw=="
|
||||
},
|
||||
"lodash.isfunction": {
|
||||
|
@ -13636,7 +13565,7 @@
|
|||
},
|
||||
"markdown-it": {
|
||||
"version": "12.3.2",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it/-/markdown-it-12.3.2.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it/-/markdown-it-12.3.2.tgz",
|
||||
"integrity": "sha512-TchMembfxfNVpHkbtriWltGWc+m3xszaRD0CZup7GFFhzIgQqxIfn3eGj1yZpfuflzPvfkt611B2Q/Bsk1YnGg==",
|
||||
"requires": {
|
||||
"argparse": "^2.0.1",
|
||||
|
@ -13648,40 +13577,40 @@
|
|||
"dependencies": {
|
||||
"entities": {
|
||||
"version": "2.1.0",
|
||||
"resolved": "https://registry.npmjs.org/entities/-/entities-2.1.0.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/entities/-/entities-2.1.0.tgz",
|
||||
"integrity": "sha512-hCx1oky9PFrJ611mf0ifBLBRW8lUUVRlFolb5gWRfIELabBlbp9xZvrqZLZAs+NxFnbfQoeGd8wDkygjg7U85w=="
|
||||
}
|
||||
}
|
||||
},
|
||||
"markdown-it-abbr": {
|
||||
"version": "1.0.4",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-abbr/-/markdown-it-abbr-1.0.4.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-abbr/-/markdown-it-abbr-1.0.4.tgz",
|
||||
"integrity": "sha512-ZeA4Z4SaBbYysZap5iZcxKmlPL6bYA8grqhzJIHB1ikn7njnzaP8uwbtuXc4YXD5LicI4/2Xmc0VwmSiFV04gg=="
|
||||
},
|
||||
"markdown-it-anchor": {
|
||||
"version": "8.6.6",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-anchor/-/markdown-it-anchor-8.6.6.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-anchor/-/markdown-it-anchor-8.6.6.tgz",
|
||||
"integrity": "sha512-jRW30YGywD2ESXDc+l17AiritL0uVaSnWsb26f+68qaW9zgbIIr1f4v2Nsvc0+s0Z2N3uX6t/yAw7BwCQ1wMsA==",
|
||||
"requires": {}
|
||||
},
|
||||
"markdown-it-deflist": {
|
||||
"version": "2.1.0",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-deflist/-/markdown-it-deflist-2.1.0.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-deflist/-/markdown-it-deflist-2.1.0.tgz",
|
||||
"integrity": "sha512-3OuqoRUlSxJiuQYu0cWTLHNhhq2xtoSFqsZK8plANg91+RJQU1ziQ6lA2LzmFAEes18uPBsHZpcX6We5l76Nzg=="
|
||||
},
|
||||
"markdown-it-emoji": {
|
||||
"version": "2.0.2",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-emoji/-/markdown-it-emoji-2.0.2.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-emoji/-/markdown-it-emoji-2.0.2.tgz",
|
||||
"integrity": "sha512-zLftSaNrKuYl0kR5zm4gxXjHaOI3FAOEaloKmRA5hijmJZvSjmxcokOLlzycb/HXlUFWzXqpIEoyEMCE4i9MvQ=="
|
||||
},
|
||||
"markdown-it-footnote": {
|
||||
"version": "3.0.3",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-footnote/-/markdown-it-footnote-3.0.3.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-footnote/-/markdown-it-footnote-3.0.3.tgz",
|
||||
"integrity": "sha512-YZMSuCGVZAjzKMn+xqIco9d1cLGxbELHZ9do/TSYVzraooV8ypsppKNmUJ0fVH5ljkCInQAtFpm8Rb3eXSrt5w=="
|
||||
},
|
||||
"markdown-it-highlightjs": {
|
||||
"version": "3.6.0",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-highlightjs/-/markdown-it-highlightjs-3.6.0.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-highlightjs/-/markdown-it-highlightjs-3.6.0.tgz",
|
||||
"integrity": "sha512-ex+Lq3cVkprh0GpGwFyc53A/rqY6GGzopPCG1xMsf8Ya3XtGC8Uw9tChN1rWbpyDae7tBBhVHVcMM29h4Btamw==",
|
||||
"requires": {
|
||||
"highlight.js": "^11.3.1",
|
||||
|
@ -13690,37 +13619,37 @@
|
|||
},
|
||||
"markdown-it-ins": {
|
||||
"version": "3.0.1",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-ins/-/markdown-it-ins-3.0.1.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-ins/-/markdown-it-ins-3.0.1.tgz",
|
||||
"integrity": "sha512-32SSfZqSzqyAmmQ4SHvhxbFqSzPDqsZgMHDwxqPzp+v+t8RsmqsBZRG+RfRQskJko9PfKC2/oxyOs4Yg/CfiRw=="
|
||||
},
|
||||
"markdown-it-mark": {
|
||||
"version": "3.0.1",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-mark/-/markdown-it-mark-3.0.1.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-mark/-/markdown-it-mark-3.0.1.tgz",
|
||||
"integrity": "sha512-HyxjAu6BRsdt6Xcv6TKVQnkz/E70TdGXEFHRYBGLncRE9lBFwDNLVtFojKxjJWgJ+5XxUwLaHXy+2sGBbDn+4A=="
|
||||
},
|
||||
"markdown-it-sub": {
|
||||
"version": "1.0.0",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-sub/-/markdown-it-sub-1.0.0.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-sub/-/markdown-it-sub-1.0.0.tgz",
|
||||
"integrity": "sha512-z2Rm/LzEE1wzwTSDrI+FlPEveAAbgdAdPhdWarq/ZGJrGW/uCQbKAnhoCsE4hAbc3SEym26+W2z/VQB0cQiA9Q=="
|
||||
},
|
||||
"markdown-it-sup": {
|
||||
"version": "1.0.0",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-sup/-/markdown-it-sup-1.0.0.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-sup/-/markdown-it-sup-1.0.0.tgz",
|
||||
"integrity": "sha512-E32m0nV9iyhRR7CrhnzL5msqic7rL1juWre6TQNxsnApg7Uf+F97JOKxUijg5YwXz86lZ0mqfOnutoryyNdntQ=="
|
||||
},
|
||||
"markdown-it-task-lists": {
|
||||
"version": "2.1.1",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-task-lists/-/markdown-it-task-lists-2.1.1.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-task-lists/-/markdown-it-task-lists-2.1.1.tgz",
|
||||
"integrity": "sha512-TxFAc76Jnhb2OUu+n3yz9RMu4CwGfaT788br6HhEDlvWfdeJcLUsxk1Hgw2yJio0OXsxv7pyIPmvECY7bMbluA=="
|
||||
},
|
||||
"markdown-it-toc-done-right": {
|
||||
"version": "4.2.0",
|
||||
"resolved": "https://registry.npmjs.org/markdown-it-toc-done-right/-/markdown-it-toc-done-right-4.2.0.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/markdown-it-toc-done-right/-/markdown-it-toc-done-right-4.2.0.tgz",
|
||||
"integrity": "sha512-UB/IbzjWazwTlNAX0pvWNlJS8NKsOQ4syrXZQ/C72j+jirrsjVRT627lCaylrKJFBQWfRsPmIVQie8x38DEhAQ=="
|
||||
},
|
||||
"mdurl": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmjs.org/mdurl/-/mdurl-1.0.1.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/mdurl/-/mdurl-1.0.1.tgz",
|
||||
"integrity": "sha512-/sKlQJCBYVY9Ers9hqzKou4H6V5UWc/M59TH2dvkt+84itfnq7uFOMLpOiOS4ujvHP4etln18fmIxA5R5fll0g=="
|
||||
},
|
||||
"meow": {
|
||||
|
@ -15296,7 +15225,7 @@
|
|||
},
|
||||
"uc.micro": {
|
||||
"version": "1.0.6",
|
||||
"resolved": "https://registry.npmjs.org/uc.micro/-/uc.micro-1.0.6.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/uc.micro/-/uc.micro-1.0.6.tgz",
|
||||
"integrity": "sha512-8Y75pvTYkLJW2hWQHXxoqRgV7qb9B+9vFEtidML+7koHUFapnVJAZ6cKs+Qjz5Aw3aZWHMC6u0wJE3At+nSGwA=="
|
||||
},
|
||||
"ufo": {
|
||||
|
@ -15718,7 +15647,7 @@
|
|||
},
|
||||
"vue3-markdown-it": {
|
||||
"version": "1.0.10",
|
||||
"resolved": "https://registry.npmjs.org/vue3-markdown-it/-/vue3-markdown-it-1.0.10.tgz",
|
||||
"resolved": "https://registry.npmmirror.com/vue3-markdown-it/-/vue3-markdown-it-1.0.10.tgz",
|
||||
"integrity": "sha512-mTvHu0zl7jrh7ojgaZ+tTpCLiS4CVg4bTgTu4KGhw/cRRY5YgIG8QgFAPu6kCzSW6Znc9a52Beb6hFvF4hSMkQ==",
|
||||
"requires": {
|
||||
"markdown-it": "^12.3.2",
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -17,7 +17,6 @@ export interface formState {
|
|||
basePath: string; // 系统后台访问的URL
|
||||
logo: string; // 系统logo
|
||||
icon: string; // 浏览器页签
|
||||
rulesFrom: Record<string, Rule[]>;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -18,15 +18,15 @@
|
|||
</template>
|
||||
<a-form
|
||||
layout="vertical"
|
||||
ref="formBasicRef"
|
||||
:rules="rulesFrom"
|
||||
:model="form"
|
||||
ref="formBasicRef"
|
||||
>
|
||||
<a-row :span="24" :gutter="24">
|
||||
<a-col :span="10">
|
||||
<a-form-item
|
||||
label="系统名称"
|
||||
name="title"
|
||||
v-bind="validateInfos.title"
|
||||
>
|
||||
<a-input
|
||||
v-model:value="form.title"
|
||||
|
@ -37,6 +37,9 @@
|
|||
<a-form-item
|
||||
label="主题色"
|
||||
name="headerTheme"
|
||||
v-bind="
|
||||
validateInfos.headerTheme
|
||||
"
|
||||
>
|
||||
<a-select
|
||||
v-model:value="
|
||||
|
@ -74,7 +77,10 @@
|
|||
placeholder="请输入高德API Key"
|
||||
/>
|
||||
</a-form-item>
|
||||
<a-form-item>
|
||||
<a-form-item
|
||||
name="basePath"
|
||||
v-bind="validateInfos.basePath"
|
||||
>
|
||||
<template #label>
|
||||
<span>base-path</span>
|
||||
<a-tooltip
|
||||
|
@ -721,7 +727,11 @@
|
|||
type="primary"
|
||||
class="btn-style"
|
||||
@click="submitData"
|
||||
:loading="isSucessBasic || isSucessInit || isSucessRole"
|
||||
:loading="
|
||||
isSucessBasic === 2 ||
|
||||
isSucessInit === 2 ||
|
||||
isSucessRole === 2
|
||||
"
|
||||
>确定</a-button
|
||||
>
|
||||
</div>
|
||||
|
@ -742,7 +752,6 @@ import type {
|
|||
FormInstance,
|
||||
UploadChangeParam,
|
||||
UploadProps,
|
||||
Form,
|
||||
} from 'ant-design-vue';
|
||||
import { modalState, formState, logoState } from './data/interface';
|
||||
import BaseMenu from './data/baseMenu';
|
||||
|
@ -761,48 +770,56 @@ import {
|
|||
saveDevice,
|
||||
changeDeploy,
|
||||
deployDevice,
|
||||
saveInit,
|
||||
} from '@/api/initHome';
|
||||
import { BASE_API_PATH, TOKEN_KEY } from '@/utils/variable';
|
||||
import { LocalStore } from '@/utils/comm';
|
||||
import { message } from 'ant-design-vue';
|
||||
import { Form } from 'ant-design-vue';
|
||||
import { ValidateErrorEntity } from 'ant-design-vue/es/form/interface';
|
||||
const formRef = ref();
|
||||
const menuRef = ref();
|
||||
const formBasicRef = ref();
|
||||
const useForm = Form.useForm;
|
||||
/**
|
||||
* 表单数据
|
||||
*/
|
||||
const form = reactive<formState>({
|
||||
const form = ref<formState>({
|
||||
title: '',
|
||||
headerTheme: 'light',
|
||||
apikey: '',
|
||||
basePath: `${window.location.origin}/api`,
|
||||
logo: '',
|
||||
icon: '',
|
||||
rulesFrom: {
|
||||
title: [
|
||||
{
|
||||
required: true,
|
||||
message: '请选择本地地址',
|
||||
trigger: 'blur',
|
||||
},
|
||||
],
|
||||
headerTheme: [
|
||||
{
|
||||
required: true,
|
||||
message: '请选择主题色',
|
||||
trigger: 'blur',
|
||||
},
|
||||
],
|
||||
basePath: [
|
||||
{
|
||||
required: true,
|
||||
message: '请输入base-path',
|
||||
trigger: 'blur',
|
||||
},
|
||||
],
|
||||
},
|
||||
});
|
||||
const { rulesFrom } = toRefs(form);
|
||||
|
||||
const rulesFrom = ref({
|
||||
title: [
|
||||
{
|
||||
required: true,
|
||||
message: '请输入系统名称',
|
||||
trigger: 'blur',
|
||||
},
|
||||
],
|
||||
headerTheme: [
|
||||
{
|
||||
required: true,
|
||||
message: '请选择主题色',
|
||||
trigger: 'blur',
|
||||
},
|
||||
],
|
||||
basePath: [
|
||||
{
|
||||
required: true,
|
||||
message: '请输入base-path',
|
||||
trigger: 'blur',
|
||||
},
|
||||
],
|
||||
});
|
||||
const { resetFields, validate, validateInfos } = useForm(
|
||||
form.value,
|
||||
rulesFrom.value,
|
||||
);
|
||||
/**
|
||||
* 校验官网地址
|
||||
*/
|
||||
|
@ -871,6 +888,10 @@ const rulesModle = ref({
|
|||
],
|
||||
});
|
||||
|
||||
// const { resetFields, validate, validateInfos } = useForm(
|
||||
// modalForm.value,
|
||||
// rulesModle.value,
|
||||
// );
|
||||
/**
|
||||
* 默认打开第一个初始菜单
|
||||
*/
|
||||
|
@ -928,7 +949,7 @@ const logoData = reactive<logoState>({
|
|||
* logo格式校验
|
||||
*/
|
||||
beforeLogoUpload: (file) => {
|
||||
const isType = logoData.imageTypes.includes(file.type);
|
||||
const isType: any = logoData.imageTypes.includes(file.type);
|
||||
if (!isType) {
|
||||
message.error(`请上传.jpg.png.jfif.pjp.pjpeg.jpeg格式的图片`);
|
||||
return false;
|
||||
|
@ -1033,58 +1054,58 @@ const {
|
|||
* 提交基础表单
|
||||
*/
|
||||
const basicData = reactive({
|
||||
isSucessBasic: false,
|
||||
isSucessBasic: 0,
|
||||
/**
|
||||
* 提交基础表单数据
|
||||
*/
|
||||
saveBasicInfo: async () => {
|
||||
// return new Promise(async (resolve) => {
|
||||
const vaild = await formBasicRef.value.validate();
|
||||
console.log(vaild, 'vaild ');
|
||||
if (vaild) {
|
||||
const item = [
|
||||
{
|
||||
scope: 'front',
|
||||
properties: {
|
||||
...form,
|
||||
apikey: '',
|
||||
'base-path': '',
|
||||
validate()
|
||||
.then(async () => {
|
||||
const item = [
|
||||
{
|
||||
scope: 'front',
|
||||
properties: {
|
||||
...form,
|
||||
apikey: '',
|
||||
'base-path': '',
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
scope: 'amap',
|
||||
properties: {
|
||||
api: form.apikey,
|
||||
{
|
||||
scope: 'amap',
|
||||
properties: {
|
||||
api: form.apikey,
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
scope: 'paths',
|
||||
properties: {
|
||||
'base-path': form.basePath,
|
||||
{
|
||||
scope: 'paths',
|
||||
properties: {
|
||||
'base-path': form.basePath,
|
||||
},
|
||||
},
|
||||
},
|
||||
];
|
||||
const res = await save(item);
|
||||
if (res.status === 200) {
|
||||
const ico: any = document.querySelector('link[rel="icon"]');
|
||||
if (ico !== null) {
|
||||
ico.href = form.icon;
|
||||
];
|
||||
const res = await save(item);
|
||||
if (res.status === 200) {
|
||||
const ico: any = document.querySelector('link[rel="icon"]');
|
||||
if (ico !== null) {
|
||||
ico.href = form.icon;
|
||||
}
|
||||
basicData.isSucessBasic = 3;
|
||||
} else {
|
||||
basicData.isSucessBasic = 2;
|
||||
}
|
||||
} else {
|
||||
basicData.isSucessBasic = true;
|
||||
}
|
||||
} else {
|
||||
basicData.isSucessBasic = true;
|
||||
}
|
||||
// });
|
||||
})
|
||||
.catch((error: ValidateErrorEntity<formState>) => {
|
||||
basicData.isSucessBasic = 2;
|
||||
});
|
||||
},
|
||||
});
|
||||
const { isSucessBasic } = toRefs(basicData);
|
||||
|
||||
/**
|
||||
* 提交角色数据
|
||||
*/
|
||||
const roleData = reactive({
|
||||
isSucessRole: false,
|
||||
isSucessRole: 0,
|
||||
/**
|
||||
* 根据菜单找角色
|
||||
*/
|
||||
|
@ -1158,7 +1179,7 @@ const roleData = reactive({
|
|||
}
|
||||
} else if (index === keys.value.length - 1) {
|
||||
resolve(Count === keys.value.length);
|
||||
roleData.isSucessRole = true;
|
||||
roleData.isSucessRole = 2;
|
||||
}
|
||||
});
|
||||
});
|
||||
|
@ -1222,7 +1243,7 @@ const { count } = toRefs(menuDatas);
|
|||
* 提交初始化数据
|
||||
*/
|
||||
const initialization = reactive({
|
||||
isSucessInit: false,
|
||||
isSucessInit: 0,
|
||||
optionPorts: [],
|
||||
/**
|
||||
* 查询端口数据
|
||||
|
@ -1244,74 +1265,74 @@ const initialization = reactive({
|
|||
*/
|
||||
|
||||
saveCurrentData: async () => {
|
||||
// return new Promise(async (resolve) => {
|
||||
const valid = await formRef.value.validate();
|
||||
console.log(valid, 'valid');
|
||||
// if (valid) {
|
||||
// try {
|
||||
// // 新增网络组件
|
||||
// const network = await saveNetwork({
|
||||
// type: 'MQTT_SERVER',
|
||||
// shareCluster: true,
|
||||
// name: 'MQTT网络组件',
|
||||
// configuration: {
|
||||
// host: '0.0.0.0',
|
||||
// secure: false,
|
||||
// port: modalForm.port,
|
||||
// publicHost: modalForm.publicHost,
|
||||
// publicPort: modalForm.publicPort,
|
||||
// },
|
||||
// });
|
||||
// // 保存协议
|
||||
// const protocol = await saveProtocol();
|
||||
// let protocolItem: any = undefined;
|
||||
// if (protocol.status === 200) {
|
||||
// const proid = await getProtocol();
|
||||
// if (proid.status === 200) {
|
||||
// protocolItem = (proid?.result || []).find(
|
||||
// (it: any) => it.name === 'JetLinks官方协议',
|
||||
// );
|
||||
// }
|
||||
// }
|
||||
// // 新增设备接入网关
|
||||
// const accessConfig = await saveAccessConfig({
|
||||
// name: 'MQTT类型设备接入网关',
|
||||
// provider: 'mqtt-server-gateway',
|
||||
// protocol: protocolItem?.id,
|
||||
// transport: 'MQTT',
|
||||
// channel: 'network',
|
||||
// channelId: network?.result?.id,
|
||||
// });
|
||||
// // 新增产品
|
||||
// const product = await saveProduct({
|
||||
// name: 'MQTT产品',
|
||||
// messageProtocol: protocolItem?.id,
|
||||
// protocolName: protocolItem?.name,
|
||||
// transportProtocol: 'MQTT',
|
||||
// deviceType: 'device',
|
||||
// accessId: accessConfig.result?.id,
|
||||
// accessName: accessConfig.result?.name,
|
||||
// accessProvider: 'mqtt-server-gateway',
|
||||
// });
|
||||
// // 新增设备
|
||||
// const device = await saveDevice({
|
||||
// name: 'MQTT设备',
|
||||
// productId: product?.result?.id,
|
||||
// productName: product?.result?.name,
|
||||
// });
|
||||
// if (device.status === 200) {
|
||||
// changeDeploy(product.result.id);
|
||||
// deployDevice(device.result.id);
|
||||
// }
|
||||
|
||||
// flag.value = true;
|
||||
// visible.value = false;
|
||||
// } catch (e) {
|
||||
// initialization.isSucessInit = true;
|
||||
// // resolve(false);
|
||||
// }
|
||||
// }
|
||||
initialization.isSucessInit = true;
|
||||
formRef.value
|
||||
.validate()
|
||||
.then(async () => {
|
||||
try {
|
||||
// 新增网络组件
|
||||
const network = await saveNetwork({
|
||||
type: 'MQTT_SERVER',
|
||||
shareCluster: true,
|
||||
name: 'MQTT网络组件',
|
||||
configuration: {
|
||||
host: '0.0.0.0',
|
||||
secure: false,
|
||||
port: modalForm.port,
|
||||
publicHost: modalForm.publicHost,
|
||||
publicPort: modalForm.publicPort,
|
||||
},
|
||||
});
|
||||
// 保存协议
|
||||
const protocol = await saveProtocol();
|
||||
let protocolItem: any = undefined;
|
||||
if (protocol.status === 200) {
|
||||
const proid = await getProtocol();
|
||||
if (proid.status === 200) {
|
||||
protocolItem = (proid?.result || []).find(
|
||||
(it: any) => it.name === 'JetLinks官方协议',
|
||||
);
|
||||
}
|
||||
}
|
||||
// 新增设备接入网关
|
||||
const accessConfig = await saveAccessConfig({
|
||||
name: 'MQTT类型设备接入网关',
|
||||
provider: 'mqtt-server-gateway',
|
||||
protocol: protocolItem?.id,
|
||||
transport: 'MQTT',
|
||||
channel: 'network',
|
||||
channelId: network?.result?.id,
|
||||
});
|
||||
// 新增产品
|
||||
const product = await saveProduct({
|
||||
name: 'MQTT产品',
|
||||
messageProtocol: protocolItem?.id,
|
||||
protocolName: protocolItem?.name,
|
||||
transportProtocol: 'MQTT',
|
||||
deviceType: 'device',
|
||||
accessId: accessConfig.result?.id,
|
||||
accessName: accessConfig.result?.name,
|
||||
accessProvider: 'mqtt-server-gateway',
|
||||
});
|
||||
// 新增设备
|
||||
const device = await saveDevice({
|
||||
name: 'MQTT设备',
|
||||
productId: product?.result?.id,
|
||||
productName: product?.result?.name,
|
||||
});
|
||||
if (device.status === 200) {
|
||||
await changeDeploy(product.result.id);
|
||||
await deployDevice(device.result.id);
|
||||
}
|
||||
flag.value = true;
|
||||
visible.value = false;
|
||||
initialization.isSucessInit = 3;
|
||||
} catch (e) {
|
||||
initialization.isSucessInit = 2;
|
||||
}
|
||||
})
|
||||
.catch((error: ValidateErrorEntity<modalState>) => {
|
||||
initialization.isSucessInit = 2;
|
||||
});
|
||||
},
|
||||
});
|
||||
const { optionPorts, saveCurrentData, isSucessInit } = toRefs(initialization);
|
||||
|
@ -1321,13 +1342,33 @@ const { optionPorts, saveCurrentData, isSucessInit } = toRefs(initialization);
|
|||
*/
|
||||
menuDatas.getSystemPermissionData();
|
||||
initialization.getCurrentPort();
|
||||
/**
|
||||
* 跳转首页
|
||||
*/
|
||||
const jump = () => {
|
||||
window.location.href = '/';
|
||||
};
|
||||
/**
|
||||
* 提交所有数据
|
||||
*/
|
||||
const submitData = () => {
|
||||
initialization.saveCurrentData();
|
||||
roleData.addRoleData();
|
||||
const submitData = async () => {
|
||||
if (keys.value.length > 0) {
|
||||
roleData.addRoleData();
|
||||
}
|
||||
basicData.saveBasicInfo();
|
||||
// 当前数据是否成功提交
|
||||
if (
|
||||
basicData.isSucessBasic === 3 &&
|
||||
roleData.isSucessRole === 3 &&
|
||||
initialization.isSucessInit === 3
|
||||
) {
|
||||
message.success('保存成功');
|
||||
// 记录初始化数据,跳转首页
|
||||
const res = await saveInit();
|
||||
if (res.status === 200) {
|
||||
jump();
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
<style scoped lang="less">
|
||||
|
|
|
@ -9,8 +9,13 @@
|
|||
</div>
|
||||
<div v-else>
|
||||
<div v-if="!id"><a @click="goBack">返回</a></div>
|
||||
<AccessNetwork v-if="showType==='network'" :provider="provider" :data="data" />
|
||||
<Media v-if="showType==='media'" :provider="provider" :data="data" />
|
||||
<AccessNetwork
|
||||
v-if="showType === 'network'"
|
||||
:provider="provider"
|
||||
:data="data"
|
||||
/>
|
||||
<Media v-if="showType === 'media'" :provider="provider" />
|
||||
<Channel v-if="showType === 'channel'" :provider="provider" />
|
||||
</div>
|
||||
</a-card>
|
||||
</a-spin>
|
||||
|
@ -22,7 +27,7 @@ import AccessNetwork from '../components/Network.vue';
|
|||
import Provider from '../components/Provider/index.vue';
|
||||
import { getProviders, detail } from '@/api/link/accessConfig';
|
||||
import Media from '../components/Media/index.vue';
|
||||
|
||||
import Channel from '../components/Channel/index.vue';
|
||||
|
||||
// const router = useRouter();
|
||||
const route = useRoute();
|
||||
|
@ -34,14 +39,13 @@ const type = ref(false);
|
|||
const loading = ref(true);
|
||||
const provider = ref({});
|
||||
const data = ref({});
|
||||
const showType = ref('')
|
||||
const showType = ref('');
|
||||
|
||||
const goProviders = (param: object) => {
|
||||
showType.value = param.type
|
||||
const goProviders = (param: object) => {
|
||||
showType.value = param.type;
|
||||
provider.value = param;
|
||||
type.value = false;
|
||||
console.log(1123,showType.value,param);
|
||||
|
||||
console.log(1123, showType.value, param);
|
||||
};
|
||||
|
||||
const goBack = () => {
|
||||
|
@ -59,22 +63,22 @@ const queryProviders = async () => {
|
|||
const edge: any[] = [];
|
||||
resp.result.map((item) => {
|
||||
if (item.id === 'fixed-media' || item.id === 'gb28181-2016') {
|
||||
item.type='media'
|
||||
item.type = 'media';
|
||||
media.push(item);
|
||||
} else if (item.id === 'OneNet' || item.id === 'Ctwing') {
|
||||
item.type='cloud'
|
||||
item.type = 'cloud';
|
||||
cloud.push(item);
|
||||
} else if (item.id === 'modbus-tcp' || item.id === 'opc-ua') {
|
||||
item.type='channel'
|
||||
item.type = 'channel';
|
||||
channel.push(item);
|
||||
} else if (
|
||||
item.id === 'official-edge-gateway' ||
|
||||
item.id === 'edge-child-device'
|
||||
) {
|
||||
item.type='edge'
|
||||
item.type = 'edge';
|
||||
edge.push(item);
|
||||
} else {
|
||||
item.type='network'
|
||||
item.type = 'network';
|
||||
network.push(item);
|
||||
}
|
||||
});
|
||||
|
@ -114,7 +118,7 @@ const queryProviders = async () => {
|
|||
title: '官方接入',
|
||||
});
|
||||
}
|
||||
dataSource.value = list
|
||||
dataSource.value = list;
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
@ -0,0 +1,166 @@
|
|||
<template>
|
||||
<div class="container">
|
||||
<div v-if="type === 'channel'" class="card-last">
|
||||
<a-row :gutter="[24, 24]">
|
||||
<a-col :span="12">
|
||||
<title-component data="基本信息" />
|
||||
<div>
|
||||
<a-form
|
||||
:model="formState"
|
||||
name="basic"
|
||||
autocomplete="off"
|
||||
layout="vertical"
|
||||
@finish="onFinish"
|
||||
>
|
||||
<a-form-item
|
||||
label="名称"
|
||||
name="name"
|
||||
:rules="[
|
||||
{
|
||||
required: true,
|
||||
message: '请输入名称',
|
||||
trigger: 'blur',
|
||||
},
|
||||
{ max: 64, message: '最多可输入64个字符' },
|
||||
]"
|
||||
>
|
||||
<a-input
|
||||
placeholder="请输入名称"
|
||||
v-model:value="formState.name"
|
||||
/>
|
||||
</a-form-item>
|
||||
<a-form-item label="说明" name="description">
|
||||
<a-textarea
|
||||
placeholder="请输入说明"
|
||||
:rows="4"
|
||||
v-model:value="formState.description"
|
||||
show-count
|
||||
:maxlength="200"
|
||||
/>
|
||||
</a-form-item>
|
||||
<a-form-item>
|
||||
<a-button type="primary" html-type="submit"
|
||||
>保存</a-button
|
||||
>
|
||||
</a-form-item>
|
||||
</a-form>
|
||||
</div>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<div class="config-right">
|
||||
<div class="config-right-item">
|
||||
<title-component data="配置概览" />
|
||||
<div class="config-right-item-context">
|
||||
接入方式:{{ provider.name }}
|
||||
</div>
|
||||
<div class="config-right-item-context">
|
||||
{{ provider.description }}
|
||||
</div>
|
||||
<div class="config-right-item-context">
|
||||
消息协议:{{ provider.id }}
|
||||
</div>
|
||||
</div>
|
||||
<div class="config-right-item">
|
||||
<title-component data="设备接入指引" />
|
||||
<div class="config-right-item-context">
|
||||
1、配置{{ provider.name }}通道
|
||||
</div>
|
||||
<div class="config-right-item-context">
|
||||
2、创建{{ provider.name }}设备接入网关
|
||||
</div>
|
||||
<div class="config-right-item-context">
|
||||
3、创建产品,并选中接入方式为{{ provider.name }}
|
||||
</div>
|
||||
<div class="config-right-item-context">
|
||||
4、添加设备,单独为每一个设备进行数据点绑定
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup name="AccessMedia">
|
||||
import { message, Form } from 'ant-design-vue';
|
||||
import type { FormInstance } from 'ant-design-vue';
|
||||
import { update, save } from '@/api/link/accessConfig';
|
||||
|
||||
interface FormState {
|
||||
name: string;
|
||||
description: string;
|
||||
}
|
||||
const route = useRoute();
|
||||
const id = route.query.id;
|
||||
|
||||
const props = defineProps({
|
||||
provider: {
|
||||
type: Object,
|
||||
default: () => {},
|
||||
},
|
||||
});
|
||||
|
||||
const type = ref(props.provider.type);
|
||||
|
||||
const formState = reactive<FormState>({
|
||||
name: '',
|
||||
description: '',
|
||||
});
|
||||
const onFinish = async (values: any) => {
|
||||
const providerId = props.provider.id;
|
||||
const params = {
|
||||
...values,
|
||||
provider: providerId,
|
||||
protocol: providerId,
|
||||
transport: providerId === 'modbus-tcp' ? 'MODBUS_TCP' : 'OPC_UA',
|
||||
channel: providerId === 'modbus-tcp' ? 'modbus' : 'opc-ua',
|
||||
};
|
||||
const resp = !!id ? await update({ ...params, id }) : await save(params);
|
||||
if (resp.status === 200) {
|
||||
message.success('操作成功!');
|
||||
// if (params.get('save')) {
|
||||
// if ((window as any).onTabSaveSuccess) {
|
||||
// if (resp.result) {
|
||||
// (window as any).onTabSaveSuccess(resp.result);
|
||||
// setTimeout(() => window.close(), 300);
|
||||
// }
|
||||
// }
|
||||
// } else {
|
||||
history.back();
|
||||
// }
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.container {
|
||||
margin: 20px;
|
||||
}
|
||||
|
||||
.card-last {
|
||||
padding-right: 5px;
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
}
|
||||
.config-right {
|
||||
padding: 20px;
|
||||
color: rgba(0, 0, 0, 0.8);
|
||||
background: rgba(0, 0, 0, 0.04);
|
||||
|
||||
.config-right-item {
|
||||
margin-bottom: 10px;
|
||||
|
||||
.config-right-item-title {
|
||||
width: 100%;
|
||||
margin-bottom: 10px;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.config-right-item-context {
|
||||
margin: 5px 0;
|
||||
color: rgba(0, 0, 0, 0.8);
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
|
@ -539,10 +539,6 @@ const props = defineProps({
|
|||
type: Object,
|
||||
default: () => {},
|
||||
},
|
||||
data: {
|
||||
type: Object,
|
||||
default: () => {},
|
||||
},
|
||||
});
|
||||
|
||||
const route = useRoute();
|
||||
|
|
|
@ -24,7 +24,10 @@
|
|||
{ max: 64, message: '最多可输入64个字符' },
|
||||
]"
|
||||
>
|
||||
<a-input v-model:value="formState.name" />
|
||||
<a-input
|
||||
placeholder="请输入名称"
|
||||
v-model:value="formState.name"
|
||||
/>
|
||||
</a-form-item>
|
||||
<a-form-item label="说明" name="description">
|
||||
<a-textarea
|
||||
|
@ -68,8 +71,8 @@
|
|||
</a-col>
|
||||
</a-row>
|
||||
</div>
|
||||
<div v-else>
|
||||
<GB28181 :data="props.data" :provider="props.provider"></GB28181>
|
||||
<div v-else-if="channel === 'gb28181'">
|
||||
<GB28181 :provider="props.provider"></GB28181>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
@ -92,10 +95,6 @@ const props = defineProps({
|
|||
type: Object,
|
||||
default: () => {},
|
||||
},
|
||||
data: {
|
||||
type: Object,
|
||||
default: () => {},
|
||||
},
|
||||
});
|
||||
|
||||
const channel = ref(props.provider.channel);
|
||||
|
|
Loading…
Reference in New Issue