diff --git a/package.json b/package.json index a891a236..b1629925 100644 --- a/package.json +++ b/package.json @@ -25,7 +25,7 @@ "event-source-polyfill": "^1.0.31", "global": "^4.4.0", "jetlinks-store": "^0.0.3", - "jetlinks-ui-components": "^1.0.5", + "jetlinks-ui-components": "1.0.5", "js-cookie": "^3.0.1", "less": "^4.1.3", "less-loader": "^11.1.0", @@ -64,6 +64,7 @@ "typescript": "^4.9.3", "vite": "^4.0.0", "vite-plugin-html": "^3.2.0", + "vite-plugin-progress": "^0.0.7", "vite-plugin-style-import": "^2.0.0", "vite-plugin-vue-setup-extend": "^0.4.0", "vue-tsc": "^1.0.11" diff --git a/plugin/jetlinks.ts b/plugin/jetlinks.ts index eac09e18..1144639d 100644 --- a/plugin/jetlinks.ts +++ b/plugin/jetlinks.ts @@ -337,9 +337,6 @@ export function JetlinksVueResolver(options: JetlinksVueResolverOptions = {}): a options.packageName = _isJetlinks ? 'jetlinks-ui-components' : 'ant-design-vue' const path = `${options.packageName}/${options.cjs ? 'lib' : 'es'}` const stylePath = getSideEffects(importName, options, _isAntd) - if (_isJetlinks) { - console.log(name, importName, stylePath) - } return { name: importName, from: path, diff --git a/plugin/optimize.ts b/plugin/optimize.ts index 75e6721b..b01707fe 100644 --- a/plugin/optimize.ts +++ b/plugin/optimize.ts @@ -43,7 +43,6 @@ export function optimizeDeps() { ] let concat = config.optimizeDeps.include.concat(components) config.optimizeDeps.include = Array.from(new Set(concat)) - console.log(config.optimizeDeps.include) } } } \ No newline at end of file diff --git a/public/ant-avicon.ico b/public/ant-avicon.ico deleted file mode 100644 index e2e93252..00000000 Binary files a/public/ant-avicon.ico and /dev/null differ diff --git a/public/images/access-config-disabled.png b/public/images/access-config-disabled.png deleted file mode 100644 index 37a41bc2..00000000 Binary files a/public/images/access-config-disabled.png and /dev/null differ diff --git a/public/images/access-config-enabled.png b/public/images/access-config-enabled.png deleted file mode 100644 index 00c403ed..00000000 Binary files a/public/images/access-config-enabled.png and /dev/null differ diff --git a/public/images/access/background.png b/public/images/access/background.png deleted file mode 100644 index fd06f7fa..00000000 Binary files a/public/images/access/background.png and /dev/null differ diff --git a/public/images/alarm/alarm-config.png b/public/images/alarm/alarm-config.png index a0413bb2..c043c5e5 100644 Binary files a/public/images/alarm/alarm-config.png and b/public/images/alarm/alarm-config.png differ diff --git a/public/images/alarm/background.png b/public/images/alarm/background.png deleted file mode 100644 index 93bbe8db..00000000 Binary files a/public/images/alarm/background.png and /dev/null differ diff --git a/public/images/alarm/device.png b/public/images/alarm/device.png index b9589a3b..3ccab0d1 100644 Binary files a/public/images/alarm/device.png and b/public/images/alarm/device.png differ diff --git a/public/images/alarm/log.png b/public/images/alarm/log.png index e793115c..c19fc87a 100644 Binary files a/public/images/alarm/log.png and b/public/images/alarm/log.png differ diff --git a/public/images/alarm/org.png b/public/images/alarm/org.png index 8b64f03d..c53a9e11 100644 Binary files a/public/images/alarm/org.png and b/public/images/alarm/org.png differ diff --git a/public/images/alarm/other.png b/public/images/alarm/other.png index c89782ee..4ebf4951 100644 Binary files a/public/images/alarm/other.png and b/public/images/alarm/other.png differ diff --git a/public/images/alarm/product.png b/public/images/alarm/product.png index 3841f3ba..bef80f4d 100644 Binary files a/public/images/alarm/product.png and b/public/images/alarm/product.png differ diff --git a/public/images/apply.png b/public/images/apply.png index 356612c9..2c92ab4c 100644 Binary files a/public/images/apply.png and b/public/images/apply.png differ diff --git a/public/images/avatar-1.png b/public/images/avatar-1.png deleted file mode 100644 index b3631a4b..00000000 Binary files a/public/images/avatar-1.png and /dev/null differ diff --git a/public/images/channel/1.png b/public/images/channel/1.png deleted file mode 100644 index 97c48155..00000000 Binary files a/public/images/channel/1.png and /dev/null differ diff --git a/public/images/channel/2.png b/public/images/channel/2.png deleted file mode 100644 index f4101662..00000000 Binary files a/public/images/channel/2.png and /dev/null differ diff --git a/public/images/channel/3.png b/public/images/channel/3.png deleted file mode 100644 index 706778db..00000000 Binary files a/public/images/channel/3.png and /dev/null differ diff --git a/public/images/channel/4.png b/public/images/channel/4.png deleted file mode 100644 index 361f71dc..00000000 Binary files a/public/images/channel/4.png and /dev/null differ diff --git a/public/images/channel/background.png b/public/images/channel/background.png deleted file mode 100644 index 37c0342b..00000000 Binary files a/public/images/channel/background.png and /dev/null differ diff --git a/public/images/channel/connect.png b/public/images/channel/connect.png deleted file mode 100644 index 0f83fd20..00000000 Binary files a/public/images/channel/connect.png and /dev/null differ diff --git a/public/images/channel/disconnect.png b/public/images/channel/disconnect.png deleted file mode 100644 index b81ec023..00000000 Binary files a/public/images/channel/disconnect.png and /dev/null differ diff --git a/public/images/device-access.png b/public/images/device-access.png index f2cd40be..67ae52b2 100644 Binary files a/public/images/device-access.png and b/public/images/device-access.png differ diff --git a/public/images/device-gateway.png b/public/images/device-gateway.png index 47e9e773..9f33b482 100644 Binary files a/public/images/device-gateway.png and b/public/images/device-gateway.png differ diff --git a/public/images/device-media.png b/public/images/device-media.png index cbfa989a..7cbed55f 100644 Binary files a/public/images/device-media.png and b/public/images/device-media.png differ diff --git a/public/images/device-product.png b/public/images/device-product.png index 8c56da7f..685a9860 100644 Binary files a/public/images/device-product.png and b/public/images/device-product.png differ diff --git a/public/images/device/device-number.png b/public/images/device/device-number.png index fc3de501..6079cfd7 100644 Binary files a/public/images/device/device-number.png and b/public/images/device/device-number.png differ diff --git a/public/images/device/device-number.svg b/public/images/device/device-number.svg new file mode 100644 index 00000000..93e138cf --- /dev/null +++ b/public/images/device/device-number.svg @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/images/device/device-product.png b/public/images/device/device-product.png index aca91db2..01d36145 100644 Binary files a/public/images/device/device-product.png and b/public/images/device/device-product.png differ diff --git a/public/images/device/device-product.svg b/public/images/device/device-product.svg new file mode 100644 index 00000000..0f5b7ccb --- /dev/null +++ b/public/images/device/device-product.svg @@ -0,0 +1,67 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/public/images/device/instance/device-card.png b/public/images/device/instance/device-card.png index 9a740af2..ec1891c1 100644 Binary files a/public/images/device/instance/device-card.png and b/public/images/device/instance/device-card.png differ diff --git a/public/images/dingding.png b/public/images/dingding.png deleted file mode 100644 index 91f854a9..00000000 Binary files a/public/images/dingding.png and /dev/null differ diff --git a/public/images/home/content.png b/public/images/home/content.png index ba957820..8c8364d3 100644 Binary files a/public/images/home/content.png and b/public/images/home/content.png differ diff --git a/public/images/home/content1.png b/public/images/home/content1.png deleted file mode 100644 index 0f377a21..00000000 Binary files a/public/images/home/content1.png and /dev/null differ diff --git a/public/images/home/home-1.png b/public/images/home/home-1.png deleted file mode 100644 index c37407b9..00000000 Binary files a/public/images/home/home-1.png and /dev/null differ diff --git a/public/images/home/home-2.png b/public/images/home/home-2.png deleted file mode 100644 index b57c0e26..00000000 Binary files a/public/images/home/home-2.png and /dev/null differ diff --git a/public/images/home/home-3.png b/public/images/home/home-3.png deleted file mode 100644 index 22bbf600..00000000 Binary files a/public/images/home/home-3.png and /dev/null differ diff --git a/public/images/home/top-bg.png b/public/images/home/top-bg.png deleted file mode 100644 index 5202b23a..00000000 Binary files a/public/images/home/top-bg.png and /dev/null differ diff --git a/public/images/iot-card/iot-card-bg.png b/public/images/iot-card/iot-card-bg.png index 7b47b0e0..a25a4847 100644 Binary files a/public/images/iot-card/iot-card-bg.png and b/public/images/iot-card/iot-card-bg.png differ diff --git a/public/images/login1.png b/public/images/login1.png deleted file mode 100644 index 4f2811e6..00000000 Binary files a/public/images/login1.png and /dev/null differ diff --git a/public/images/login2.png b/public/images/login2.png deleted file mode 100644 index 766dbf9f..00000000 Binary files a/public/images/login2.png and /dev/null differ diff --git a/public/images/network.png b/public/images/network.png index e8ec7206..f3d5104a 100644 Binary files a/public/images/network.png and b/public/images/network.png differ diff --git a/public/images/notice/dingtalk-background.png b/public/images/notice/dingtalk-background.png deleted file mode 100644 index 553e4338..00000000 Binary files a/public/images/notice/dingtalk-background.png and /dev/null differ diff --git a/public/images/notice/email-background.png b/public/images/notice/email-background.png deleted file mode 100644 index 1de906b0..00000000 Binary files a/public/images/notice/email-background.png and /dev/null differ diff --git a/public/images/notice/sms-background.png b/public/images/notice/sms-background.png deleted file mode 100644 index 9f9957b5..00000000 Binary files a/public/images/notice/sms-background.png and /dev/null differ diff --git a/public/images/notice/voice-background.png b/public/images/notice/voice-background.png deleted file mode 100644 index 0c0cb373..00000000 Binary files a/public/images/notice/voice-background.png and /dev/null differ diff --git a/public/images/notice/webhook-backgroud.png b/public/images/notice/webhook-backgroud.png deleted file mode 100644 index fcc64261..00000000 Binary files a/public/images/notice/webhook-backgroud.png and /dev/null differ diff --git a/public/images/notice/wechat-background.png b/public/images/notice/wechat-background.png deleted file mode 100644 index 9a45ed71..00000000 Binary files a/public/images/notice/wechat-background.png and /dev/null differ diff --git a/public/images/protocol.png b/public/images/protocol.png index 04f02408..6b9844f0 100644 Binary files a/public/images/protocol.png and b/public/images/protocol.png differ diff --git a/public/images/scene/scene-device.png b/public/images/scene/scene-device.png index e4fb1ef6..3ccab0d1 100644 Binary files a/public/images/scene/scene-device.png and b/public/images/scene/scene-device.png differ diff --git a/public/images/scene/scene-hand.png b/public/images/scene/scene-hand.png index 3571b390..d578ca1b 100644 Binary files a/public/images/scene/scene-hand.png and b/public/images/scene/scene-hand.png differ diff --git a/public/images/scene/scene-timer.png b/public/images/scene/scene-timer.png index 9dcea61c..aec34fbd 100644 Binary files a/public/images/scene/scene-timer.png and b/public/images/scene/scene-timer.png differ diff --git a/public/images/scene/trigger-type/device.png b/public/images/scene/trigger-type/device.png deleted file mode 100644 index 9a6cdd0b..00000000 Binary files a/public/images/scene/trigger-type/device.png and /dev/null differ diff --git a/public/images/scene/trigger-type/scene.png b/public/images/scene/trigger-type/scene.png index 1614ab41..99a69f0c 100644 Binary files a/public/images/scene/trigger-type/scene.png and b/public/images/scene/trigger-type/scene.png differ diff --git a/public/images/stream.png b/public/images/stream.png index 9847637c..652b4cea 100644 Binary files a/public/images/stream.png and b/public/images/stream.png differ diff --git a/public/pro_icon.svg b/public/pro_icon.svg deleted file mode 100644 index e075b78d..00000000 --- a/public/pro_icon.svg +++ /dev/null @@ -1,5 +0,0 @@ - - - - - \ No newline at end of file diff --git a/public/vite.svg b/public/vite.svg deleted file mode 100644 index e7b8dfb1..00000000 --- a/public/vite.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/src/api/account/center.ts b/src/api/account/center.ts index 2a6eacc7..8faebadd 100644 --- a/src/api/account/center.ts +++ b/src/api/account/center.ts @@ -1,4 +1,5 @@ import server from '@/utils/request' +import { BASE_API_PATH } from '@/utils/variable' export const getSsoBinds_api = (): any =>server.get(`/application/sso/me/bindings`) diff --git a/src/api/device/product.ts b/src/api/device/product.ts index d54283a8..4d34b3ba 100644 --- a/src/api/device/product.ts +++ b/src/api/device/product.ts @@ -187,6 +187,13 @@ export const getOperator = () => server.get('/property-calculate */ export const getStreamingAggType = () => server.get[]>('/dictionary/streaming-agg-type/items') +/** + * 根据指定的接入方式获取产品需要的配置信息 + * @pId 产品id + * @accessId 设备接入id + */ +export const getAccessConfig = (pId: string, accessId: string) => server.get(`/device-product/${pId}/${accessId}/config-metadata`) + export const getMetadataConfig = (params: { deviceId: string; metadata: { diff --git a/src/api/edge/device.ts b/src/api/edge/device.ts index ff2e4247..62bf77f7 100644 --- a/src/api/edge/device.ts +++ b/src/api/edge/device.ts @@ -4,6 +4,6 @@ export const restPassword = (id: string) => server.post(`/edge/operations/${id}/ export const _control = (deviceId: string) => server.get(`/edge/remote/${deviceId}/url`) -export const _stopControl = (deviceId: string) => server.get(`/edge/remote/${deviceId}/stop`, {}) +export const _stopControl = (deviceId: string) => server.post(`/edge/remote/${deviceId}/stop`) diff --git a/src/api/home.ts b/src/api/home.ts index a37c0f3d..c7d0805e 100644 --- a/src/api/home.ts +++ b/src/api/home.ts @@ -1,7 +1,7 @@ import server from '@/utils/request'; // 当前登录用户权限信息 -export const getMe_api = () => server.get(`/authorize/me`); +export const getMe_api = () => server.get<{ user: any, [key : string]: any }>(`/authorize/me`); // 设置登录用户选择的页面 export const setView_api = (data:object) => server.patch(`/user/settings/view/user`, data); // 当前登录用户选择的页面 diff --git a/src/api/login.ts b/src/api/login.ts index fd3eed95..b5511f80 100644 --- a/src/api/login.ts +++ b/src/api/login.ts @@ -10,7 +10,7 @@ export const config = () => server.get(`/authorize/captcha/config`) * 获取验证码图片 * @returns */ -export const code = () => server.get(`/authorize/captcha/image?width=130&height=30`) +export const code = () => server.get<{ base64: string, key: string }>(`/authorize/captcha/image?width=130&height=30`) /** * 登录 @@ -57,3 +57,7 @@ export const userDetail = () => server.get('/user/detail') * 退出登录 */ export const loginout_api = () => server.get('/user-token/reset') + +export const getOAuth2 = (params: any) => server.get('/oauth2/authorize', params) + +export const initApplication = (clientId: string | number) => server.get<{name: string}>(`/application/${clientId}/info`) diff --git a/src/components/CardBox/index.vue b/src/components/CardBox/index.vue index 5f612285..99a71da1 100644 --- a/src/components/CardBox/index.vue +++ b/src/components/CardBox/index.vue @@ -1,5 +1,5 @@ - diff --git a/src/views/account/Center/index.vue b/src/views/account/Center/index.vue index becf59e7..89d62d93 100644 --- a/src/views/account/Center/index.vue +++ b/src/views/account/Center/index.vue @@ -140,8 +140,10 @@