diff --git a/deliver-front/vue/components.d.ts b/deliver-front/vue/components.d.ts index b01e80ab1990125954a2585cc6591362b932f3b5..5f64989f43abe0c287df0e6982bd687af5f6413e 100644 --- a/deliver-front/vue/components.d.ts +++ b/deliver-front/vue/components.d.ts @@ -8,14 +8,14 @@ export {} declare module 'vue' { export interface GlobalComponents { AAvatar: typeof import('ant-design-vue/es')['Avatar'] + ABadge: typeof import('ant-design-vue/es')['Badge'] ABreadcrumb: typeof import('ant-design-vue/es')['Breadcrumb'] AButton: typeof import('ant-design-vue/es')['Button'] ACard: typeof import('ant-design-vue/es')['Card'] ACardMeta: typeof import('ant-design-vue/es')['CardMeta'] - ACheckbox: typeof import('ant-design-vue/es')['Checkbox'] - ACheckboxGroup: typeof import('ant-design-vue/es')['CheckboxGroup'] ACol: typeof import('ant-design-vue/es')['Col'] - ADivider: typeof import('ant-design-vue/es')['Divider'] + AConfigProvider: typeof import('ant-design-vue/es')['ConfigProvider'] + ADropdown: typeof import('ant-design-vue/es')['Dropdown'] AForm: typeof import('ant-design-vue/es')['Form'] AFormItem: typeof import('ant-design-vue/es')['FormItem'] AInput: typeof import('ant-design-vue/es')['Input'] @@ -34,6 +34,7 @@ declare module 'vue' { ASelectOption: typeof import('ant-design-vue/es')['SelectOption'] AStatistic: typeof import('ant-design-vue/es')['Statistic'] ASubMenu: typeof import('ant-design-vue/es')['SubMenu'] + ASwitch: typeof import('ant-design-vue/es')['Switch'] ATable: typeof import('ant-design-vue/es')['Table'] ATooltip: typeof import('ant-design-vue/es')['Tooltip'] Echarts: typeof import('./src/components/Echarts/index.vue')['default'] diff --git a/deliver-front/vue/index.html b/deliver-front/vue/index.html index 03b053353ccef0d17aa84accaca54c2ef598455b..24ec9c73f5f5f07f8f9623e186f08c7834b94300 100644 --- a/deliver-front/vue/index.html +++ b/deliver-front/vue/index.html @@ -1,13 +1,72 @@ - - - - - Deliver - - -
- - - + + + + + + Deliver + + + + +
+
+
+
+
+
+
+
+ + + + \ No newline at end of file diff --git a/deliver-front/vue/package-lock.json b/deliver-front/vue/package-lock.json index 09274b13f7e658f9e2f509ca5cf26ff5202c1793..8544c01b00c3716d75a5741719d0975dbb3e73d8 100644 --- a/deliver-front/vue/package-lock.json +++ b/deliver-front/vue/package-lock.json @@ -11,12 +11,14 @@ "ant-design-vue": "^4.0.6", "axios": "^1.5.1", "echarts": "^5.4.3", + "nprogress": "^0.2.0", "pinia": "^2.1.7", "vue": "^3.3.4", "vue-router": "^4.2.5" }, "devDependencies": { "@types/node": "^20.8.7", + "@types/nprogress": "^0.2.3", "@typescript-eslint/eslint-plugin": "^6.8.0", "@vitejs/plugin-vue": "^4.2.3", "eslint": "^8.52.0", @@ -719,6 +721,12 @@ "undici-types": "~5.25.1" } }, + "node_modules/@types/nprogress": { + "version": "0.2.3", + "resolved": "https://registry.npmmirror.com/@types/nprogress/-/nprogress-0.2.3.tgz", + "integrity": "sha512-k7kRA033QNtC+gLc4VPlfnue58CM1iQLgn1IMAU8VPHGOj7oIHPp9UlhedEnD/Gl8evoCjwkZjlBORtZ3JByUA==", + "dev": true + }, "node_modules/@types/semver": { "version": "7.5.4", "resolved": "https://registry.npmmirror.com/@types/semver/-/semver-7.5.4.tgz", @@ -3354,6 +3362,11 @@ "node": ">=12" } }, + "node_modules/nprogress": { + "version": "0.2.0", + "resolved": "https://registry.npmmirror.com/nprogress/-/nprogress-0.2.0.tgz", + "integrity": "sha512-I19aIingLgR1fmhftnbWWO3dXc0hSxqHQHQb3H8m+K3TnEn/iSeTZZOyvKXWqQESMwuUVnatlCnZdLBZZt2VSA==" + }, "node_modules/nth-check": { "version": "2.1.1", "resolved": "https://registry.npmmirror.com/nth-check/-/nth-check-2.1.1.tgz", @@ -5130,6 +5143,12 @@ "undici-types": "~5.25.1" } }, + "@types/nprogress": { + "version": "0.2.3", + "resolved": "https://registry.npmmirror.com/@types/nprogress/-/nprogress-0.2.3.tgz", + "integrity": "sha512-k7kRA033QNtC+gLc4VPlfnue58CM1iQLgn1IMAU8VPHGOj7oIHPp9UlhedEnD/Gl8evoCjwkZjlBORtZ3JByUA==", + "dev": true + }, "@types/semver": { "version": "7.5.4", "resolved": "https://registry.npmmirror.com/@types/semver/-/semver-7.5.4.tgz", @@ -7228,6 +7247,11 @@ } } }, + "nprogress": { + "version": "0.2.0", + "resolved": "https://registry.npmmirror.com/nprogress/-/nprogress-0.2.0.tgz", + "integrity": "sha512-I19aIingLgR1fmhftnbWWO3dXc0hSxqHQHQb3H8m+K3TnEn/iSeTZZOyvKXWqQESMwuUVnatlCnZdLBZZt2VSA==" + }, "nth-check": { "version": "2.1.1", "resolved": "https://registry.npmmirror.com/nth-check/-/nth-check-2.1.1.tgz", diff --git a/deliver-front/vue/package.json b/deliver-front/vue/package.json index e561739f4be6e13833190843a23d2acafdea425f..bcde3b2b73cd186ffbb1cb15dd318b25694ae7eb 100644 --- a/deliver-front/vue/package.json +++ b/deliver-front/vue/package.json @@ -14,12 +14,14 @@ "ant-design-vue": "^4.0.6", "axios": "^1.5.1", "echarts": "^5.4.3", + "nprogress": "^0.2.0", "pinia": "^2.1.7", "vue": "^3.3.4", "vue-router": "^4.2.5" }, "devDependencies": { "@types/node": "^20.8.7", + "@types/nprogress": "^0.2.3", "@typescript-eslint/eslint-plugin": "^6.8.0", "@vitejs/plugin-vue": "^4.2.3", "eslint": "^8.52.0", diff --git a/deliver-front/vue/public/head.ico b/deliver-front/vue/public/head.ico deleted file mode 100644 index d30793792733f7d167180113d77f6161b335472c..0000000000000000000000000000000000000000 Binary files a/deliver-front/vue/public/head.ico and /dev/null differ diff --git a/deliver-front/vue/public/head.png b/deliver-front/vue/public/head.png deleted file mode 100644 index 62c0dacebee1ae650e70591519467f3820cc216c..0000000000000000000000000000000000000000 Binary files a/deliver-front/vue/public/head.png and /dev/null differ diff --git a/deliver-front/vue/public/logo.png b/deliver-front/vue/public/logo.png new file mode 100644 index 0000000000000000000000000000000000000000..fd2522311154beddd148c43defb17f0bb08451bc Binary files /dev/null and b/deliver-front/vue/public/logo.png differ diff --git a/deliver-front/vue/src/api/dashboard.ts b/deliver-front/vue/src/api/dashboard.ts index c7f963ed03e311fe55032268d3b7ed33e2de2372..cb7263ff287672541e6dbda20201d92e058c2e8c 100644 --- a/deliver-front/vue/src/api/dashboard.ts +++ b/deliver-front/vue/src/api/dashboard.ts @@ -1,15 +1,54 @@ import request from '@/utils/request' -// interface DashboardHeadData { -// numberOfMessagesToday: string -// numberOfPlatformFiles: string -// accumulatedTemplateOwnership: string -// numberOfApps: string -// } +export interface DashboardHeadData { + numberOfMessagesToday?: string + numberOfPlatformFiles?: string + accumulatedTemplateOwnership?: string + numberOfApps?: string +} + +type barDataPoint = [string, number, number] +interface pieDataPoint { + value: number + name: string +} + +export type messageDataSource = barDataPoint[] +export type templeteDataSource = pieDataPoint[] +export type channelDataSource = pieDataPoint[] +export type userDataSource = pieDataPoint[] -export async function getDashboardHeadData(): Promise { +export async function getDashboardHeadData(): Promise { return await request({ url: '/dashboard/getDashboardHeadData', method: 'post' }) } +export async function getMessageInfo(data: { dateSelect: number }): Promise { + return await request({ + url: '/dashboard/getMessageInfo', + method: 'post', + data + }) +} +export async function getTemplateInfo(data: { dateSelect: number }): Promise { + return await request({ + url: '/dashboard/getTemplateInfo', + method: 'post', + data + }) +} +export async function getAppInfo(data: { dateSelect: number }): Promise { + return await request({ + url: '/dashboard/getAppInfo', + method: 'post', + data + }) +} +export async function getPushUserInfo(data: { dateSelect: number }): Promise { + return await request({ + url: '/dashboard/getPushUserInfo', + method: 'post', + data + }) +} diff --git a/deliver-front/vue/src/api/message.ts b/deliver-front/vue/src/api/message.ts new file mode 100644 index 0000000000000000000000000000000000000000..97b965364bbe754f21695d49cbc4cb47f7639065 --- /dev/null +++ b/deliver-front/vue/src/api/message.ts @@ -0,0 +1,10 @@ +import request from '@/utils/request' +import type { searchMessage } from '@/views/Message/type' + +export async function getTemplatePages(data: searchMessage): Promise { + return await request({ + url: '/template/search', + method: 'post', + data + }) +} diff --git a/deliver-front/vue/src/components/Echarts/index.vue b/deliver-front/vue/src/components/Echarts/index.vue index 5e6f40914318f022a913ab99b2a92cb8891dbc33..e456c209fa26ffffe4830d216724488730c8aecd 100644 --- a/deliver-front/vue/src/components/Echarts/index.vue +++ b/deliver-front/vue/src/components/Echarts/index.vue @@ -1,8 +1,9 @@