* fix/0707-ch: (296 commits) clear 修改 list fix: test 修改 修改跳转问题 fix:修改评分查询错误 fix: bug修复 fix:商家回复 fix:商家回复 fix:修改接口地址 修改后管评论 pref:去掉回复功能 fix: 查询参数问题 fix:详情页不显示 fix: 切换更新详情 fat:评价详情 评价详情 fix:修改生产配置 fix:修改生产配置 ...main
@ -0,0 +1,18 @@
|
||||
module.exports = {
|
||||
extends: ['@commitlint/config-conventional'],
|
||||
rules: {
|
||||
'type-enum': [
|
||||
2,
|
||||
'always',
|
||||
// 新增、修复、文档、不影响逻辑的代码格式、重构、测试、回滚、编译、合并、优化、配置、其他
|
||||
['feat', 'fix', 'doc', 'style', 'refactor', 'test', 'revert', 'build', 'merge', 'perf', 'conf', 'chore'],
|
||||
],
|
||||
'type-case': [0],
|
||||
'type-empty': [0],
|
||||
'scope-empty': [0],
|
||||
'scope-case': [0],
|
||||
'subject-full-stop': [0, 'never'],
|
||||
'subject-case': [0, 'never'],
|
||||
'header-max-length': [0, 'always', 72],
|
||||
},
|
||||
};
|
@ -1,2 +1,5 @@
|
||||
VITE_BASE_URL=/api
|
||||
VITE_REQUEST_TIMEOUT=20000
|
||||
VITE_SOCKET_URL=wss://k8s-horse-gateway.mashibing.cn/ws
|
||||
#VITE_SOCKET_URL=ws://192.168.10.93:8090/ws
|
||||
VITE_REQUEST_TIMEOUT=5000
|
||||
VITE_BROWSER_URL = https://k8s-shop-pc.mashibing.cn
|
@ -1,2 +0,0 @@
|
||||
VITE_BASE_URL=https://gateway.mashibing.cn
|
||||
VITE_REQUEST_TIMEOUT=20000
|
@ -1,2 +1,4 @@
|
||||
VITE_BASE_URL=https://gateway.mashibing.com
|
||||
VITE_BASE_URL=https://you-gateway.mashibing.com
|
||||
VITE_SOCKET_URL=wss://you-gateway.mashibing.com/ws
|
||||
VITE_REQUEST_TIMEOUT=20000
|
||||
VITE_BROWSER_URL = https://you.mashibing.com
|
||||
|
@ -1,2 +1,4 @@
|
||||
VITE_BASE_URL=https://gateway-test.mashibing.cn
|
||||
VITE_BASE_URL=https://k8s-horse-gateway.mashibing.cn/
|
||||
VITE_SOCKET_URL=wss://k8s-horse-gateway.mashibing.cn/ws
|
||||
VITE_REQUEST_TIMEOUT=20000
|
||||
VITE_BROWSER_URL = https://k8s-shop-pc.mashibing.cn
|
||||
|
@ -0,0 +1,8 @@
|
||||
src/assets
|
||||
src/icons
|
||||
public
|
||||
dist
|
||||
node_modules
|
||||
src/utils/msb-im.js
|
||||
src/utils/poto-req.js
|
||||
src/utils/proto-rsp.js
|
@ -1,8 +1,8 @@
|
||||
.idea
|
||||
.DS_Store
|
||||
.eslintcache
|
||||
node_modules
|
||||
dist
|
||||
*.local
|
||||
.history
|
||||
src/.eslintrc.json
|
||||
src/components.d.ts
|
||||
src/auto-imports.d.ts
|
||||
|
@ -0,0 +1,4 @@
|
||||
#!/bin/sh
|
||||
. "$(dirname "$0")/_/husky.sh"
|
||||
|
||||
npx commitlint --edit $1
|
@ -0,0 +1,4 @@
|
||||
#!/bin/sh
|
||||
. "$(dirname "$0")/_/husky.sh"
|
||||
|
||||
npx lint-staged
|
@ -0,0 +1,3 @@
|
||||
module.exports = {
|
||||
'*.{jsx,js,vue,tsx,ts}': ['eslint --cache --fix --max-warnings=0'],
|
||||
};
|
@ -1,3 +1,14 @@
|
||||
{
|
||||
"recommendations": ["johnsoncodehk.volar", "dbaeumer.vscode-eslint", "esbenp.prettier-vscode"]
|
||||
"recommendations": [
|
||||
"ms-ceintl.vscode-language-pack-zh-hans",
|
||||
"eamodio.gitlens",
|
||||
"formulahendry.auto-close-tag",
|
||||
"formulahendry.auto-rename-tag",
|
||||
"ecmel.vscode-html-css",
|
||||
"abusaidm.html-snippets",
|
||||
"octref.vetur",
|
||||
"dbaeumer.vscode-eslint",
|
||||
"esbenp.prettier-vscode",
|
||||
"Vue.volar"
|
||||
]
|
||||
}
|
||||
|
@ -0,0 +1,37 @@
|
||||
{
|
||||
"nuxt.isNuxtApp": false,
|
||||
"js/ts.implicitProjectConfig.checkJs": true,
|
||||
"js/ts.implicitProjectConfig.strictNullChecks": true,
|
||||
"git.autofetch": true,
|
||||
"javascript.updateImportsOnFileMove.enabled": "always",
|
||||
"typescript.updateImportsOnFileMove.enabled": "always",
|
||||
"editor.formatOnSave": true,
|
||||
"editor.codeActionsOnSave": {
|
||||
"source.fixAll": true,
|
||||
"source.organizeImports": true
|
||||
},
|
||||
"[vue]": {
|
||||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||
},
|
||||
"[json]": {
|
||||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||
},
|
||||
"[javascript]": {
|
||||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||
},
|
||||
"[jsx]": {
|
||||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||
},
|
||||
"[jsonc]": {
|
||||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||
},
|
||||
"[html]": {
|
||||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
||||
},
|
||||
"vetur.format.defaultFormatter.html": "prettier",
|
||||
"eslint.enable": true,
|
||||
"eslint.format.enable": true,
|
||||
"eslint.lintTask.enable": true,
|
||||
"eslint.run": "onType",
|
||||
"eslint.validate": ["javascript", "javascriptreact", "typescript", "typescriptreact", "html", "vue"]
|
||||
}
|
@ -1,3 +1,4 @@
|
||||
FROM nginx
|
||||
COPY dist /usr/share/nginx/html
|
||||
EXPOSE 80
|
||||
COPY nginx.conf /etc/nginx/conf.d/default.conf
|
||||
EXPOSE 80
|
||||
|
@ -1,58 +1,54 @@
|
||||
kind: Deployment
|
||||
apiVersion: apps/v1
|
||||
metadata:
|
||||
labels:
|
||||
app: $IMAGES
|
||||
name: $IMAGES
|
||||
namespace: yanxuan
|
||||
spec:
|
||||
progressDeadlineSeconds: 600
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: $IMAGES
|
||||
strategy:
|
||||
type: RollingUpdate
|
||||
rollingUpdate:
|
||||
maxUnavailable: 25%
|
||||
maxSurge: 25%
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
labels:
|
||||
app: $IMAGES
|
||||
spec:
|
||||
imagePullSecrets:
|
||||
- name: aliyun-docker-hub
|
||||
containers:
|
||||
- image: '$REGISTRY/$DOCKERHUB_NAMESPACE/$IMAGES:$BUILD_NUMBER'
|
||||
name: app
|
||||
ports:
|
||||
- containerPort: $JAR_PORD
|
||||
protocol: TCP
|
||||
resources:
|
||||
limits:
|
||||
cpu: '0.5'
|
||||
memory: 500Mi
|
||||
terminationMessagePath: /dev/termination-log
|
||||
terminationMessagePolicy: File
|
||||
dnsPolicy: ClusterFirst
|
||||
restartPolicy: Always
|
||||
terminationGracePeriodSeconds: 30
|
||||
name: $IMAGES
|
||||
namespace: yanxuan
|
||||
spec:
|
||||
progressDeadlineSeconds: 600
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
app: $IMAGES
|
||||
strategy:
|
||||
type: RollingUpdate
|
||||
rollingUpdate:
|
||||
maxUnavailable: 25%
|
||||
maxSurge: 25%
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: $IMAGES
|
||||
spec:
|
||||
imagePullSecrets:
|
||||
- name: aliyun-docker-hub
|
||||
containers:
|
||||
- image: '$REGISTRY/$DOCKERHUB_NAMESPACE/$IMAGES:$BUILD_NUMBER'
|
||||
name: app
|
||||
ports:
|
||||
- containerPort: $JAR_PORD
|
||||
protocol: TCP
|
||||
resources:
|
||||
limits:
|
||||
cpu: '0.5'
|
||||
memory: 500Mi
|
||||
terminationMessagePath: /dev/termination-log
|
||||
terminationMessagePolicy: File
|
||||
dnsPolicy: ClusterFirst
|
||||
restartPolicy: Always
|
||||
terminationGracePeriodSeconds: 30
|
||||
---
|
||||
kind: Service
|
||||
apiVersion: v1
|
||||
metadata:
|
||||
labels:
|
||||
app: $IMAGES
|
||||
name: $IMAGES
|
||||
namespace: yanxuan
|
||||
name: $IMAGES
|
||||
namespace: yanxuan
|
||||
spec:
|
||||
ports:
|
||||
- name: http
|
||||
port: 80
|
||||
protocol: TCP
|
||||
targetPort: http
|
||||
selector:
|
||||
app: $IMAGES
|
||||
sessionAffinity: None
|
||||
type: ClusterIP
|
||||
ports:
|
||||
- port: 80
|
||||
protocol: TCP
|
||||
targetPort: 80
|
||||
selector:
|
||||
app: $IMAGES
|
||||
type: ClusterIP
|
||||
|
@ -1,43 +1,66 @@
|
||||
{
|
||||
"name": "msb-shop-admin",
|
||||
"author": {
|
||||
"name": "向文可",
|
||||
"email": "1041367524@qq.com"
|
||||
},
|
||||
"private": true,
|
||||
"version": "0.0.1",
|
||||
"scripts": {
|
||||
"dev": "vite",
|
||||
"build:test": "vite build --mode test",
|
||||
"build:preview": "vite build --mode preview",
|
||||
"build:prod": "vite build --mode prod",
|
||||
"preview": "vite preview"
|
||||
},
|
||||
"dependencies": {
|
||||
"@element-plus/icons": "^0.0.11",
|
||||
"axios": "^0.26.1",
|
||||
"dayjs": "^1.11.0",
|
||||
"element-plus": "^2.1.2",
|
||||
"lodash": "^4.17.21",
|
||||
"qs": "^6.10.3",
|
||||
"sortablejs": "^1.14.0",
|
||||
"vue": "^3.2.25",
|
||||
"vue-router": "^4.0.14",
|
||||
"vuex": "^4.0.2"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@originjs/vite-plugin-global-style": "^1.0.2",
|
||||
"@types/node": "^17.0.21",
|
||||
"@vitejs/plugin-legacy": "^1.7.1",
|
||||
"@vitejs/plugin-vue": "^2.2.0",
|
||||
"@vitejs/plugin-vue-jsx": "^1.3.8",
|
||||
"consola": "^2.15.3",
|
||||
"less": "^4.1.2",
|
||||
"unplugin-auto-import": "^0.6.4",
|
||||
"unplugin-vue-components": "^0.18.0",
|
||||
"vite": "^2.8.0",
|
||||
"vite-plugin-remove-console": "^0.0.6",
|
||||
"vite-plugin-style-import": "^2.0.0",
|
||||
"vite-plugin-svg-icons": "^2.0.1"
|
||||
}
|
||||
"name": "msb-shop-admin",
|
||||
"author": {
|
||||
"name": "向文可",
|
||||
"email": "1041367524@qq.com"
|
||||
},
|
||||
"private": true,
|
||||
"version": "0.0.1",
|
||||
"scripts": {
|
||||
"dev": "vite",
|
||||
"build:test": "vite build --mode test",
|
||||
"build:beta": "vite build --mode beta",
|
||||
"build:prod": "vite build --mode prod",
|
||||
"preview": "vite preview",
|
||||
"prepare": "husky install",
|
||||
"lint": "eslint src/**/*.{vue,js,jsx} --fix"
|
||||
},
|
||||
"dependencies": {
|
||||
"@element-plus/icons": "^0.0.11",
|
||||
"@vueup/vue-quill": "^1.0.0-beta.8",
|
||||
"axios": "^0.26.1",
|
||||
"china-area-data": "^5.0.1",
|
||||
"dayjs": "^1.11.0",
|
||||
"echarts": "^5.3.2",
|
||||
"element-plus": "2.1.7",
|
||||
"lodash": "^4.17.21",
|
||||
"qs": "^6.10.3",
|
||||
"quill-image-uploader": "^1.2.2",
|
||||
"sortablejs": "^1.14.0",
|
||||
"vue": "3.2.25",
|
||||
"vue-router": "^4.0.14",
|
||||
"vuex": "^4.0.2",
|
||||
"vuex-persistedstate": "^4.1.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@commitlint/cli": "^13.2.1",
|
||||
"@commitlint/config-conventional": "^13.2.0",
|
||||
"@nabla/vite-plugin-eslint": "^1.4.0",
|
||||
"@originjs/vite-plugin-global-style": "^1.0.2",
|
||||
"@types/node": "^17.0.21",
|
||||
"@vitejs/plugin-legacy": "^1.7.1",
|
||||
"@vitejs/plugin-vue": "^2.2.0",
|
||||
"@vitejs/plugin-vue-jsx": "^1.3.8",
|
||||
"airbnb": "^0.0.2",
|
||||
"consola": "^2.15.3",
|
||||
"eslint": "^8.11.0",
|
||||
"eslint-config-prettier": "^8.5.0",
|
||||
"eslint-plugin-prettier": "^4.0.0",
|
||||
"eslint-plugin-vue": "^8.5.0",
|
||||
"husky": "^7.0.4",
|
||||
"less": "^4.1.2",
|
||||
"lint-staged": "^12.3.7",
|
||||
"prettier": "^2.6.0",
|
||||
"unplugin-auto-import": "^0.6.4",
|
||||
"unplugin-vue-components": "^0.18.0",
|
||||
"vite": "^2.8.0",
|
||||
"vite-plugin-remove-console": "^0.0.6",
|
||||
"vite-svg-loader": "^3.1.2"
|
||||
},
|
||||
"lint-staged": {
|
||||
"src/**/*.{jsx,tsx,ts,js,vue}": [
|
||||
"prettier --write",
|
||||
"eslint --fix"
|
||||
]
|
||||
}
|
||||
}
|
||||
|
Before Width: | Height: | Size: 4.2 KiB After Width: | Height: | Size: 9.4 KiB |
@ -0,0 +1,86 @@
|
||||
/*
|
||||
* @Author: xwk
|
||||
* @Date: 2022-05-24 17:00:26
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-06-13 14:26:53
|
||||
* @Description: file content
|
||||
*/
|
||||
import request from '@/utils/request.js';
|
||||
export const login = (params) => {
|
||||
return request({
|
||||
url: '/im/waiter/getWaiterConnectTicket',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const searchService = (id) => {
|
||||
return request({
|
||||
url: '/im/admin/waiter/findAllWaiter/' + id,
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const searchSession = (params) => {
|
||||
return request({
|
||||
url: '/im/admin/waiter/findWaiterSessions',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const searchMessage = (params) => {
|
||||
return request({
|
||||
url: '/im/admin/waiter/findSessionMessage',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const searchSummary = (params) => {
|
||||
return request({
|
||||
url: '/im/admin/waiter/waiterStatistics',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
/**
|
||||
* 获取链接凭证
|
||||
*/
|
||||
export const getCustomeServiceTicket = () => {
|
||||
return request({
|
||||
url: '/mall/im/admin/ticket',
|
||||
method: 'get',
|
||||
params: {
|
||||
ticketType: 'CONNECT_TICKET',
|
||||
},
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* 获取当前客服
|
||||
*/
|
||||
export const getCustomerService = () => {
|
||||
return request({
|
||||
url: '/mall/im/admin/waiterUser/getWaiterByUserId',
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
/**
|
||||
* 获取可转移客服列表
|
||||
* @param {*} params
|
||||
*/
|
||||
export const customerServiceList = (params) => {
|
||||
return request({
|
||||
url: '/mall/im/admin/waiter',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
/**
|
||||
* 转移客服
|
||||
* @param {*} params
|
||||
*/
|
||||
export const transferCustomerService = (data) => {
|
||||
return request({
|
||||
url: '/mall/im/admin/waiter/transfer',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
@ -0,0 +1,36 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: '/mall/im/admin/waiterUser',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const detail = (userId) => {
|
||||
return request({
|
||||
url: '/mall/im/admin/waiterUser/getWaiterByUserId',
|
||||
method: 'get',
|
||||
params: { userId },
|
||||
});
|
||||
};
|
||||
export const create = (data) => {
|
||||
return request({
|
||||
url: '/mall/im/admin/waiterUser',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const update = (data) => {
|
||||
return request({
|
||||
url: '/mall/im/admin/waiterUser',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const remove = (ids) => {
|
||||
return request({
|
||||
url: '/mall/im/admin/waiterUser',
|
||||
method: 'delete',
|
||||
data: { ids },
|
||||
});
|
||||
};
|
@ -0,0 +1,14 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = () => {
|
||||
return request({
|
||||
url: '/mall/base/orderConfig/getOrderConfig',
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const update = (data) => {
|
||||
return request({
|
||||
url: '/mall/base/orderConfig/saveOrUpdate',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
@ -0,0 +1,45 @@
|
||||
import request from '@/utils/request';
|
||||
// OSS签名
|
||||
export function sign(serviceName, configId) {
|
||||
return request({
|
||||
url: '/oss/oss/generateOssSignature',
|
||||
method: 'POST',
|
||||
data: {
|
||||
serviceName,
|
||||
configId,
|
||||
},
|
||||
});
|
||||
// console.info(serviceName, configId);
|
||||
// return {
|
||||
// accessId: 'LTAI4GHRNb5Xn2w5NeHVbR4c',
|
||||
// policy: 'eyJleHBpcmF0aW9uIjoiMjAyMi0wNC0xNVQyMDowODoyNi4zMTlaIiwiY29uZGl0aW9ucyI6W1siY29udGVudC1sZW5ndGgtcmFuZ2UiLDAsMTA0ODU3NjAwMF0sWyJzdGFydHMtd2l0aCIsIiRrZXkiLCJ0ZXN0LyJdXX0=',
|
||||
// signature: 'okaB3sNp3vzyfM0S3ypudaUAZ+0=',
|
||||
// dir: 'test/',
|
||||
// host: 'https://msb-edu-dev.oss-cn-beijing.aliyuncs.com',
|
||||
// expire: '1650053306',
|
||||
// };
|
||||
}
|
||||
// 上传文件
|
||||
export async function upload(serviceName, configId, file, cancelToken) {
|
||||
let oss = await sign(serviceName, configId);
|
||||
let data = new FormData();
|
||||
let arr = file.name.split('/');
|
||||
arr[arr.length - 1] = encodeURIComponent(arr[arr.length - 1]);
|
||||
data.append('name', arr.join('/'));
|
||||
data.append('key', `${oss.dir}${'${filename}'}`);
|
||||
data.append('policy', oss.policy);
|
||||
data.append('OSSAccessKeyId', oss.accessId);
|
||||
data.append('Signature', oss.signature);
|
||||
data.append('success_action_status', 200);
|
||||
data.append('file', file);
|
||||
return request({
|
||||
url: oss.host,
|
||||
method: 'POST',
|
||||
data,
|
||||
headers: {
|
||||
oss: true,
|
||||
},
|
||||
timeout: 0,
|
||||
cancelToken,
|
||||
});
|
||||
}
|
@ -0,0 +1,36 @@
|
||||
/*
|
||||
* @Author: ch
|
||||
* @Date: 2022-06-15 17:55:43
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-06-24 09:44:44
|
||||
* @Description: file content
|
||||
*/
|
||||
import request from '@/utils/request.js';
|
||||
//获取评论列表
|
||||
export const commentList = (params) =>
|
||||
request({
|
||||
url: '/mall/comment/admin/comment',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
// 获取评价详情
|
||||
export const commentDetail = ({ id }) =>
|
||||
request({
|
||||
url: `/mall/comment/admin/comment/getCommentDetail/${id}`,
|
||||
method: 'get',
|
||||
});
|
||||
|
||||
//评论
|
||||
export const commentAdd = (data) =>
|
||||
request({
|
||||
url: '/mall/comment/admin/merchantComment',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
// 更新评价显示状态
|
||||
export const updateCommentShow = (data) =>
|
||||
request({
|
||||
url: '/mall/comment/admin/comment',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
@ -0,0 +1,99 @@
|
||||
import request from '@/utils/request.js';
|
||||
// 获取头部数据 今日访客 今日订单 今日销售额 近七天销售额
|
||||
export const summary = () => {
|
||||
return request({
|
||||
url: '/mall/base/frontPage/getHeaderData',
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
// 获取待处理事务数据
|
||||
export const order = () => {
|
||||
return request({
|
||||
url: '/mall/base/frontPage/getWaitHandleAffairs',
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
|
||||
// 获取商品总览数据
|
||||
export const product = () => {
|
||||
return request({
|
||||
url: '/mall/base/frontPage/getProductOverview',
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
// 获取用户总览数据
|
||||
export const customer = () => {
|
||||
return request({
|
||||
url: '/mall/base/frontPage/getUserOverviewData',
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
|
||||
// 获取订单数量同比增长数据
|
||||
export const orderInfo = () => {
|
||||
return request({
|
||||
url: '/mall/base/frontPage/getOrderTotal',
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
// 获取订单统计数据
|
||||
export const orderSummary = (params) => {
|
||||
return request({
|
||||
url: '/mall/base/frontPage/listOrderStatistics',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
// 获取今日订单统计数据
|
||||
export const orderToday = () => {
|
||||
return request({
|
||||
url: '/mall/base/frontPage/listTodayOrderStatistics',
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
|
||||
// 获取访客数量同比增长数据
|
||||
export const customerInfo = () => {
|
||||
return request({
|
||||
url: '/mall/base/frontPage/getVisitorTotal',
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
// 获取访客统计数据
|
||||
export const customerSummary = (params) => {
|
||||
return request({
|
||||
url: '/mall/base/frontPage/listVisitorStatistics',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
// 获取今日访客统计数据
|
||||
export const customerToday = () => {
|
||||
return request({
|
||||
url: '/mall/base/frontPage/listTodayVisitorStatistics',
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
|
||||
// 获取销售额同比增长数据
|
||||
export const moneyInfo = () => {
|
||||
return request({
|
||||
url: '/mall/base/frontPage/getSalesTotal',
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
// 获取销售额统计数据
|
||||
export const moneySummary = (params) => {
|
||||
return request({
|
||||
url: '/mall/base/frontPage/listSalesStatistics',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
// 获取今日销售额统计数据
|
||||
export const moneyToday = () => {
|
||||
return request({
|
||||
url: '/mall/base/frontPage/listTodaySalesStatistics',
|
||||
method: 'get',
|
||||
});
|
||||
};
|
@ -0,0 +1,106 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const online = (params) => {
|
||||
return request({
|
||||
url: '/im/admin/count/online',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const hours = (params) => {
|
||||
return request({
|
||||
url: '/im/admin/count/hoursMessage',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const days = (params) => {
|
||||
return request({
|
||||
url: '/im/admin/count/daysMessage',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const searchSystem = (params) => {
|
||||
return request({
|
||||
url: '/im/admin/thirdSystem',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const createSystem = (data) => {
|
||||
return request({
|
||||
url: '/im/admin/thirdSystem',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const updateSystem = (data) => {
|
||||
return request({
|
||||
url: '/im/admin/thirdSystem',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const removeSystem = (data) => {
|
||||
return request({
|
||||
url: '/im/admin/thirdSystem',
|
||||
method: 'delete',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const searchStore = (params) => {
|
||||
return request({
|
||||
url: '/im/admin/storeConfig',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const createStore = (data) => {
|
||||
return request({
|
||||
url: '/im/admin/storeConfig',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const updateStore = (data) => {
|
||||
return request({
|
||||
url: '/im/admin/storeConfig',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const removeStore = (data) => {
|
||||
return request({
|
||||
url: '/im/admin/storeConfig',
|
||||
method: 'delete',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const searchWaiter = (params) => {
|
||||
return request({
|
||||
url: '/im/admin/waiter',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const createWaiter = (data) => {
|
||||
return request({
|
||||
url: '/im/admin/waiter',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const updateWaiter = (data) => {
|
||||
return request({
|
||||
url: '/im/admin/waiter',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const removeWaiter = (data) => {
|
||||
return request({
|
||||
url: '/im/admin/waiter',
|
||||
method: 'delete',
|
||||
data,
|
||||
});
|
||||
};
|
@ -0,0 +1,48 @@
|
||||
/*
|
||||
* @Author: ch
|
||||
* @Date: 2022-06-01 11:03:18
|
||||
* @LastEditors: ch
|
||||
* @LastEditTime: 2022-06-01 14:16:14
|
||||
* @Description: file content
|
||||
*/
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: '/mall/marketing/advertisement',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const detail = (id) => {
|
||||
return request({
|
||||
url: '/mall/marketing/advertisement/' + id,
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const create = (data) => {
|
||||
return request({
|
||||
url: '/mall/marketing/advertisement',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const update = (data) => {
|
||||
return request({
|
||||
url: '/mall/marketing/advertisement/' + data.id,
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const sort = (data) => {
|
||||
return request({
|
||||
url: '/mall/marketing/advertisement/updateSort',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const remove = (id) => {
|
||||
return request({
|
||||
url: `/mall/marketing/advertisement?id=${id}`,
|
||||
method: 'delete',
|
||||
});
|
||||
};
|
@ -0,0 +1,42 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: '/mall/marketing/activity',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const detail = (id) => {
|
||||
return request({
|
||||
url: '/mall/marketing/activity/' + id,
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const create = (data) => {
|
||||
return request({
|
||||
url: '/mall/marketing/activity',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const update = (data) => {
|
||||
return request({
|
||||
url: '/mall/marketing/activity/' + data.id,
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const online = (params) => {
|
||||
return request({
|
||||
url: '/mall/marketing/activity/online/' + params.id,
|
||||
method: 'put',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const remove = (idList) => {
|
||||
return request({
|
||||
url: '/mall/marketing/activity',
|
||||
method: 'delete',
|
||||
params: { idList },
|
||||
});
|
||||
};
|
@ -0,0 +1,38 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: '/mall/marketing/activityProduct',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const create = (data) => {
|
||||
return request({
|
||||
url: '/mall/marketing/activityProduct',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const remove = (idList) => {
|
||||
return request({
|
||||
url: '/mall/marketing/activityProduct',
|
||||
method: 'delete',
|
||||
params: { idList },
|
||||
});
|
||||
};
|
||||
|
||||
export const searchSkus = (activityProductId) => {
|
||||
return request({
|
||||
url: '/mall/marketing/activityProductSku',
|
||||
method: 'get',
|
||||
params: { activityProductId },
|
||||
});
|
||||
};
|
||||
|
||||
export const saveSkus = (data) => {
|
||||
return request({
|
||||
url: '/mall/marketing/activityProductSku',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
@ -0,0 +1,36 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: '/mall/marketing/activityTime',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const create = (data) => {
|
||||
return request({
|
||||
url: '/mall/marketing/activityTime',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const update = (data) => {
|
||||
return request({
|
||||
url: '/mall/marketing/activityTime/' + data.id,
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const enable = (params) => {
|
||||
return request({
|
||||
url: '/mall/marketing/activityTime/enable/' + params.id,
|
||||
method: 'put',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const remove = (idList) => {
|
||||
return request({
|
||||
url: '/mall/marketing/activityTime',
|
||||
method: 'delete',
|
||||
params: { idList },
|
||||
});
|
||||
};
|
@ -0,0 +1,29 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: '/mall/marketing/productRecommended',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const create = (data) => {
|
||||
return request({
|
||||
url: '/mall/marketing/productRecommended',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const enable = (data) => {
|
||||
return request({
|
||||
url: '/mall/marketing/productRecommended',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const remove = (idList) => {
|
||||
return request({
|
||||
url: '/mall/marketing/productRecommended',
|
||||
method: 'delete',
|
||||
params: { idList },
|
||||
});
|
||||
};
|
@ -0,0 +1,77 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: '/uc/department/tree',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const searchEmployee = (params) => {
|
||||
return request({
|
||||
url: '/uc/employee/department',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const transferEmployee = (data) => {
|
||||
return request({
|
||||
url: '/uc/employee/employee',
|
||||
method: 'put',
|
||||
params: data,
|
||||
});
|
||||
};
|
||||
export const children = (params) => {
|
||||
return request({
|
||||
url: '/uc/department/child',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const detail = (id) => {
|
||||
return request({
|
||||
url: '/uc/department/' + id,
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const create = (data) => {
|
||||
return request({
|
||||
url: '/uc/department',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const update = (data) => {
|
||||
return request({
|
||||
url: '/uc/department/' + data.id,
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const remove = (idList) => {
|
||||
return request({
|
||||
url: '/uc/department',
|
||||
method: 'delete',
|
||||
params: { idList },
|
||||
});
|
||||
};
|
||||
export const searchRole = (params) => {
|
||||
return request({
|
||||
url: '/uc/role/department',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const addRole = (data) => {
|
||||
return request({
|
||||
url: '/uc/department/role',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const delRole = (data) => {
|
||||
return request({
|
||||
url: '/uc/department/role',
|
||||
method: 'delete',
|
||||
data,
|
||||
});
|
||||
};
|
@ -0,0 +1,62 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: '/uc/employee',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const detail = (id) => {
|
||||
return request({
|
||||
url: '/uc/employee/' + id,
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const searchPermission = (id) => {
|
||||
return request({
|
||||
url: '/uc/employee/role/' + id,
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const savePermission = (id, data) => {
|
||||
return request({
|
||||
url: '/uc/employee/role/' + id,
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const create = (data) => {
|
||||
return request({
|
||||
url: '/uc/employee',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const update = (data) => {
|
||||
return request({
|
||||
url: '/uc/employee',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const remove = (idList) => {
|
||||
return request({
|
||||
url: '/uc/employee',
|
||||
method: 'delete',
|
||||
params: { idList },
|
||||
});
|
||||
};
|
||||
export const enable = (params) => {
|
||||
return request({
|
||||
url: '/uc/employee/enable',
|
||||
method: 'put',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const reset = (employeeId) => {
|
||||
return request({
|
||||
url: '/uc/employee/password',
|
||||
method: 'put',
|
||||
params: { employeeId },
|
||||
});
|
||||
};
|
@ -0,0 +1,42 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: '/uc/permission',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const searchFree = () => {
|
||||
return request({
|
||||
url: '/uc/permission/NotDistribution',
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const assign = (params) => {
|
||||
return request({
|
||||
url: '/uc/permission/menu',
|
||||
method: 'put',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const create = (data) => {
|
||||
return request({
|
||||
url: '/uc/permission',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const update = (data) => {
|
||||
return request({
|
||||
url: '/uc/permission/' + data.id,
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const remove = (idList) => {
|
||||
return request({
|
||||
url: '/uc/permission',
|
||||
method: 'delete',
|
||||
params: { idList },
|
||||
});
|
||||
};
|
@ -0,0 +1,29 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: '/uc/menu/tree',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const create = (data) => {
|
||||
return request({
|
||||
url: '/uc/menu',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const update = (data) => {
|
||||
return request({
|
||||
url: '/uc/menu/' + data.id,
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const remove = (idList) => {
|
||||
return request({
|
||||
url: '/uc/menu',
|
||||
method: 'delete',
|
||||
params: { idList },
|
||||
});
|
||||
};
|
@ -0,0 +1,42 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: '/uc/role',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const detail = (id) => {
|
||||
return request({
|
||||
url: '/uc/role/' + id,
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const create = (data) => {
|
||||
return request({
|
||||
url: '/uc/role',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const update = (data) => {
|
||||
return request({
|
||||
url: '/uc/role/' + data.id,
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const updateMenu = (data) => {
|
||||
return request({
|
||||
url: '/uc/role/menu',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const remove = (idList) => {
|
||||
return request({
|
||||
url: '/uc/role',
|
||||
method: 'delete',
|
||||
params: { idList },
|
||||
});
|
||||
};
|
@ -0,0 +1,8 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: '/uc/system',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
@ -0,0 +1,42 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/productCategory',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const create = (data) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/productCategory',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const update = (data) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/productCategory/' + data.id,
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const remove = (params) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/productCategory',
|
||||
method: 'delete',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const sort = (data) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/productCategory/updateSort',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const transform = (data) => {
|
||||
return request({
|
||||
url: `/mall/product/admin/productCategory/transfer/${data.sourceId}/${data.targetId}`,
|
||||
method: 'put',
|
||||
});
|
||||
};
|
@ -0,0 +1,107 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/tradeOrder/page',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const exportAll = (params) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/tradeOrder/page',
|
||||
method: 'get',
|
||||
params: {
|
||||
...params,
|
||||
export: true,
|
||||
},
|
||||
headers: {
|
||||
download: true,
|
||||
},
|
||||
});
|
||||
};
|
||||
export const detail = (id) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/tradeOrder/' + id,
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const shipList = (orderIds) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/tradeOrder/listDeliveryOrder',
|
||||
method: 'get',
|
||||
params: { orderIds },
|
||||
});
|
||||
};
|
||||
export const logistics = (id) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/tradeOrder/logistics/' + id,
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const summary = () => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/tradeOrder/statistics',
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const updateFees = (data) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/tradeOrder/updateAmount',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const updateAddress = (data) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/tradeOrder/updateRecipient',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const cancel = (data) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/tradeOrder/cancel',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const close = (data) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/tradeOrder/close',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const searchShip = () => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/tradeOrder/logisticsCompany',
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const send = (data) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/tradeOrder/delivery',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const sendVirtual = (data) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/tradeOrder/virtualDelivery/' + data,
|
||||
method: 'put',
|
||||
});
|
||||
};
|
||||
export const sendVirtualAll = (data) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/tradeOrder/batchVirtualDelivery',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const sendAll = (data) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/tradeOrder/batchDelivery',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
@ -0,0 +1,126 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/product/page',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const detail = (id) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/product/' + id,
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const create = (data) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/product',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const update = (data) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/product/' + data.id,
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const enable = (data) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/product/enable/' + data.id,
|
||||
method: 'put',
|
||||
params: { isEnable: data.isEnable },
|
||||
});
|
||||
};
|
||||
export const remove = (params) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/product',
|
||||
method: 'delete',
|
||||
params,
|
||||
});
|
||||
};
|
||||
|
||||
export const searchSkus = (id) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/productSku/list/' + id,
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const createSkus = (id, data) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/productSku/' + id,
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const createAndClearSkus = (id, data) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/productSku/deleteAllAndAdd/' + id,
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
|
||||
export const searchAttrs = (id) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/productAttributeGroup/' + id,
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const createAttrs = (data) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/productAttributeGroup',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const updateAttrs = (data) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/productAttributeGroup/' + data.id,
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const updateAttrsSort = (data) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/productAttributeGroup/updateSort',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const removeAttrs = (params) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/productAttributeGroup',
|
||||
method: 'delete',
|
||||
params,
|
||||
});
|
||||
};
|
||||
|
||||
export const searchAttrsValue = (id) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/productAttribute/list/' + id,
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const createAttrsValue = (data) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/productAttribute',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const updateAttrsValue = (data) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/productAttribute/' + data.id,
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const removeAttrsValue = (params) => {
|
||||
return request({
|
||||
url: '/mall/product/admin/productAttribute',
|
||||
method: 'delete',
|
||||
params,
|
||||
});
|
||||
};
|
@ -0,0 +1,88 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/refundOrder/page',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const exportAll = (params) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/refundOrder/page',
|
||||
method: 'get',
|
||||
params: {
|
||||
...params,
|
||||
export: true,
|
||||
},
|
||||
headers: {
|
||||
download: true,
|
||||
},
|
||||
});
|
||||
};
|
||||
export const refundDetail = (id) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/refundOrder/refundInfo/' + id,
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const returnDetail = (id) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/refundOrder/returnInfo/' + id,
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const logistics = (id) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/refundOrder/logistics/' + id,
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const summary = () => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/refundOrder/statistics',
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
|
||||
export const resolveReceive = (data) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/refundOrder/agreeReceiving',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const rejectReceive = (data) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/refundOrder/disagreeReceiving',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const resolveRefund = (data) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/refundOrder/agreeRefund',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const rejectRefund = (data) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/refundOrder/disagreeRefund',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const resolveReturn = (data) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/refundOrder/agreeReturn',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const rejectReturn = (data) => {
|
||||
return request({
|
||||
url: '/mall/trade/admin/refundOrder/disagreeReturn',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
@ -0,0 +1,35 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: '/search/admin/searchConfig',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const detail = (id) => {
|
||||
return request({
|
||||
url: '/search/admin/searchConfig/' + id,
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const create = (data) => {
|
||||
return request({
|
||||
url: '/search/admin/searchConfig',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const update = (data) => {
|
||||
return request({
|
||||
url: '/search/admin/searchConfig',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const remove = (id) => {
|
||||
return request({
|
||||
url: '/search/admin/searchConfig',
|
||||
method: 'delete',
|
||||
params: { id },
|
||||
});
|
||||
};
|
@ -0,0 +1,35 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: '/search/admin/systemConfig',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const detail = (id) => {
|
||||
return request({
|
||||
url: '/search/admin/systemConfig/' + id,
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const create = (data) => {
|
||||
return request({
|
||||
url: '/search/admin/systemConfig',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const update = (data) => {
|
||||
return request({
|
||||
url: '/search/admin/systemConfig',
|
||||
method: 'put',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const remove = (id) => {
|
||||
return request({
|
||||
url: '/search/admin/systemConfig',
|
||||
method: 'delete',
|
||||
params: { id },
|
||||
});
|
||||
};
|
@ -0,0 +1,15 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: 'uc/admin/user/page',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const enable = (params) => {
|
||||
return request({
|
||||
url: 'uc/admin/user/enable',
|
||||
method: 'put',
|
||||
params,
|
||||
});
|
||||
};
|
@ -0,0 +1,28 @@
|
||||
import request from '@/utils/request.js';
|
||||
export const search = (params) => {
|
||||
return request({
|
||||
url: '/mall/marketing/appMessagePush',
|
||||
method: 'get',
|
||||
params,
|
||||
});
|
||||
};
|
||||
export const detail = (id) => {
|
||||
return request({
|
||||
url: '/mall/marketing/appMessagePush' + id,
|
||||
method: 'get',
|
||||
});
|
||||
};
|
||||
export const create = (data) => {
|
||||
return request({
|
||||
url: '/mall/marketing/appMessagePush',
|
||||
method: 'post',
|
||||
data,
|
||||
});
|
||||
};
|
||||
export const remove = (idList) => {
|
||||
return request({
|
||||
url: '/mall/marketing/appMessagePush',
|
||||
method: 'delete',
|
||||
params: { idList },
|
||||
});
|
||||
};
|
@ -1,40 +0,0 @@
|
||||
const mock = (data) =>
|
||||
new Promise((resolve) => {
|
||||
setTimeout(() => {
|
||||
resolve(data);
|
||||
}, Math.random() * 1500 + 500);
|
||||
});
|
||||
export const findUserList = (data) => {
|
||||
return mock({
|
||||
content: [
|
||||
{
|
||||
id: 1,
|
||||
username: 'user001',
|
||||
nickname: '张三',
|
||||
sex: 1,
|
||||
avatar: 'https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fup.enterdesk.com%2Fedpic%2Ffd%2Ff1%2Fda%2Ffdf1dacb8ff0b8f13ed29bcbee42f328.jpeg&refer=http%3A%2F%2Fup.enterdesk.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=auto?sec=1650201540&t=ba213738d8f11e79302fab71602856f2',
|
||||
loginTime: Date.now(),
|
||||
enabled: true,
|
||||
},
|
||||
{
|
||||
id: 2,
|
||||
username: 'user003',
|
||||
nickname: '李四',
|
||||
sex: 0,
|
||||
avatar: 'https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fup.enterdesk.com%2Fedpic%2Ffd%2Ff1%2Fda%2Ffdf1dacb8ff0b8f13ed29bcbee42f328.jpeg&refer=http%3A%2F%2Fup.enterdesk.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=auto?sec=1650201540&t=ba213738d8f11e79302fab71602856f2',
|
||||
loginTime: Date.now(),
|
||||
enabled: true,
|
||||
},
|
||||
{
|
||||
id: 3,
|
||||
username: 'user003',
|
||||
nickname: '王五',
|
||||
sex: 1,
|
||||
avatar: 'https://gimg2.baidu.com/image_search/src=http%3A%2F%2Fup.enterdesk.com%2Fedpic%2Ffd%2Ff1%2Fda%2Ffdf1dacb8ff0b8f13ed29bcbee42f328.jpeg&refer=http%3A%2F%2Fup.enterdesk.com&app=2002&size=f9999,10000&q=a80&n=0&g=0n&fmt=auto?sec=1650201540&t=ba213738d8f11e79302fab71602856f2',
|
||||
loginTime: Date.now(),
|
||||
enabled: false,
|
||||
},
|
||||
],
|
||||
totalElements: 3,
|
||||
});
|
||||
};
|
Before Width: | Height: | Size: 323 KiB |
After Width: | Height: | Size: 10 KiB |
After Width: | Height: | Size: 322 B |
After Width: | Height: | Size: 2.1 KiB |
After Width: | Height: | Size: 2.7 KiB |
After Width: | Height: | Size: 1.9 KiB |
After Width: | Height: | Size: 2.1 KiB |
After Width: | Height: | Size: 2.0 KiB |
After Width: | Height: | Size: 9.0 KiB |
After Width: | Height: | Size: 9.6 KiB |
After Width: | Height: | Size: 9.2 KiB |
After Width: | Height: | Size: 300 B |
After Width: | Height: | Size: 971 KiB |
Before Width: | Height: | Size: 9.0 KiB |
@ -0,0 +1,47 @@
|
||||
<template>
|
||||
<component :is="render" />
|
||||
</template>
|
||||
<script setup lang="jsx">
|
||||
import data from 'china-area-data';
|
||||
import ElCascader from './extra/ElCascader.vue';
|
||||
const props = defineProps({
|
||||
props: {
|
||||
type: Object,
|
||||
default: () => {
|
||||
return {
|
||||
expandTrigger: 'hover',
|
||||
};
|
||||
},
|
||||
},
|
||||
info: {
|
||||
type: Array,
|
||||
default: () => [],
|
||||
},
|
||||
});
|
||||
const attrs = useAttrs();
|
||||
const slots = useSlots();
|
||||
const emits = defineEmits(['update:info']);
|
||||
const convert = (obj) =>
|
||||
obj
|
||||
? Object.entries(obj).map((entry) => {
|
||||
return { label: entry[1], value: entry[0], children: convert(data[entry[0]]) };
|
||||
})
|
||||
: [];
|
||||
const options = convert(data[86]);
|
||||
const handleInfo = (code) => {
|
||||
let province = data[86],
|
||||
city = data[code[0]],
|
||||
area = data[code[1]];
|
||||
let res = [province?.[code[0]], city?.[code[1]], area?.[code[2]]];
|
||||
return res;
|
||||
};
|
||||
watch(
|
||||
() => attrs.modelValue,
|
||||
(value) => {
|
||||
emits('update:info', handleInfo(value));
|
||||
},
|
||||
{ immediate: true, deep: true }
|
||||
);
|
||||
const render = () => <ElCascader {...{ ...props, options }} {...attrs} v-slots={slots} />;
|
||||
</script>
|
||||
<style lang="less" scoped></style>
|
@ -0,0 +1,177 @@
|
||||
<template>
|
||||
<component :is="render" />
|
||||
</template>
|
||||
<script lang="jsx">
|
||||
export default defineComponent({
|
||||
inheritAttrs: false,
|
||||
});
|
||||
</script>
|
||||
<script setup lang="jsx">
|
||||
import { upload } from '@/api/file';
|
||||
import { Quill, QuillEditor } from '@vueup/vue-quill';
|
||||
import '@vueup/vue-quill/dist/vue-quill.snow.css';
|
||||
import ImageUploader from 'quill-image-uploader';
|
||||
Quill.register('modules/imageUploader', ImageUploader);
|
||||
|
||||
const props = defineProps({
|
||||
configId: {
|
||||
type: String,
|
||||
default: 'product',
|
||||
},
|
||||
serviceName: {
|
||||
type: String,
|
||||
default: 'mall-product',
|
||||
},
|
||||
readonly: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
preview: {
|
||||
type: [Boolean, String],
|
||||
default: 'app',
|
||||
},
|
||||
});
|
||||
const attrs = useAttrs();
|
||||
const emits = defineEmits(['update:modelValue', 'change']);
|
||||
const editor = ref(null);
|
||||
const options = {
|
||||
bounds: '.el-editor',
|
||||
debug: 'error',
|
||||
modules: {
|
||||
toolbar: [
|
||||
['bold', 'italic', 'underline', 'strike'],
|
||||
['blockquote', 'code-block'],
|
||||
['link', 'image'],
|
||||
[{ header: 1 }, { header: 2 }],
|
||||
[{ list: 'ordered' }, { list: 'bullet' }],
|
||||
[{ script: 'sub' }, { script: 'super' }],
|
||||
[{ indent: '-1' }, { indent: '+1' }],
|
||||
[{ direction: 'rtl' }],
|
||||
[{ size: ['small', false, 'large', 'huge'] }],
|
||||
[{ header: [1, 2, 3, 4, 5, 6, false] }],
|
||||
[{ color: [] }, { background: [] }],
|
||||
[{ font: [] }],
|
||||
[{ align: [] }],
|
||||
['clean'],
|
||||
],
|
||||
imageUploader: {
|
||||
upload: async (file) => {
|
||||
let res = await upload(props.serviceName, props.configId, file);
|
||||
if (!res) {
|
||||
throw new Error('上传失败');
|
||||
}
|
||||
return res;
|
||||
},
|
||||
},
|
||||
},
|
||||
placeholder: '请输入内容...',
|
||||
readOnly: props.readonly,
|
||||
theme: 'snow',
|
||||
};
|
||||
const content = ref(null);
|
||||
watch(
|
||||
() => content,
|
||||
(value, old) => {
|
||||
emits('update:modelValue', unref(value));
|
||||
emits('change', unref(value), unref(old));
|
||||
},
|
||||
{ deep: true }
|
||||
);
|
||||
const handleReady = () => {
|
||||
unref(editor)?.setHTML(attrs.modelValue || '');
|
||||
};
|
||||
watch(
|
||||
() => attrs.modelValue,
|
||||
(value) => {
|
||||
if (value !== unref(content)) {
|
||||
handleReady();
|
||||
}
|
||||
},
|
||||
{ immediate: true }
|
||||
);
|
||||
const handleUpdateContent = () => {
|
||||
content.value = unref(editor).getHTML();
|
||||
};
|
||||
|
||||
const preview = ref(props.preview === false ? false : typeof props.preview === 'string' ? props.preview : 'app');
|
||||
const handlePreview = (mode) => {
|
||||
preview.value = mode;
|
||||
};
|
||||
|
||||
const render = () => (
|
||||
<div class="el-editor">
|
||||
<div class="editor">
|
||||
<QuillEditor
|
||||
ref={editor}
|
||||
options={options}
|
||||
{...attrs}
|
||||
content={unref(content)}
|
||||
on={{
|
||||
'update:content': handleUpdateContent,
|
||||
ready: handleReady,
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
{unref(preview) ? (
|
||||
<div class={{ preview: true, ['--' + unref(preview)]: true, 'ql-snow': true }}>
|
||||
<h3 class="header">
|
||||
<div
|
||||
class={{ btn: true, active: unref(preview) === 'app' }}
|
||||
onClick={() => handlePreview('app')}
|
||||
>
|
||||
APP预览
|
||||
</div>
|
||||
<div class={{ btn: true, active: unref(preview) === 'pc' }} onClick={() => handlePreview('pc')}>
|
||||
PC预览
|
||||
</div>
|
||||
</h3>
|
||||
<div class="content ql-editor" v-html={unref(content)}></div>
|
||||
</div>
|
||||
) : (
|
||||
''
|
||||
)}
|
||||
</div>
|
||||
);
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.el-editor {
|
||||
width: 100%;
|
||||
height: 480px;
|
||||
display: flex;
|
||||
:deep(.editor) {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
flex: 1;
|
||||
}
|
||||
:deep(.preview) {
|
||||
height: 100%;
|
||||
margin-left: 20px;
|
||||
border: 1px solid #d1d5db;
|
||||
&.--app {
|
||||
width: 375px;
|
||||
}
|
||||
&.--pc {
|
||||
width: 640px;
|
||||
}
|
||||
.header {
|
||||
padding: 10px;
|
||||
border-bottom: 1px solid #d1d5db;
|
||||
display: flex;
|
||||
.btn {
|
||||
color: #d1d5db;
|
||||
cursor: pointer;
|
||||
&.active {
|
||||
color: #000;
|
||||
}
|
||||
+ .btn {
|
||||
margin-left: 10px;
|
||||
}
|
||||
}
|
||||
}
|
||||
.content {
|
||||
padding: 10px;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
@ -0,0 +1,162 @@
|
||||
<template>
|
||||
<div class="upload-box">
|
||||
<el-upload
|
||||
v-bind="props"
|
||||
action="none"
|
||||
:before-upload="handleBeforeUpload"
|
||||
:class="{ max: imgList.length === props.limit }"
|
||||
:file-list="imgList"
|
||||
:http-request="handleUpload"
|
||||
list-type="text"
|
||||
:on-exceed="handleExceed"
|
||||
:on-remove="handleRemove"
|
||||
show-file-list
|
||||
>
|
||||
<el-button type="primary">
|
||||
<el-icon name="Plus" style="top: 0" />
|
||||
<span>上传文件</span>
|
||||
</el-button>
|
||||
</el-upload>
|
||||
<div class="el-upload__tip">支持小于 {{ fmtSize }} 的 文件</div>
|
||||
</div>
|
||||
</template>
|
||||
<script setup lang="jsx">
|
||||
import { upload } from '@/api/file';
|
||||
import { ElMessage } from '@/plugins/element-plus';
|
||||
import 'element-plus/es/components/image/style/css';
|
||||
const props = defineProps({
|
||||
configId: {
|
||||
type: String,
|
||||
required: true,
|
||||
},
|
||||
serviceName: {
|
||||
type: String,
|
||||
default: 'mall-product',
|
||||
},
|
||||
drag: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
multiple: {
|
||||
type: Boolean,
|
||||
defualt: false,
|
||||
},
|
||||
disabled: {
|
||||
type: Boolean,
|
||||
defualt: false,
|
||||
},
|
||||
limit: {
|
||||
type: Number,
|
||||
default: 1,
|
||||
},
|
||||
size: {
|
||||
type: Number,
|
||||
default: 1024 * 1024 * 20,
|
||||
},
|
||||
accept: {
|
||||
type: String,
|
||||
default: '*/*',
|
||||
},
|
||||
loading: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
});
|
||||
const emits = defineEmits(['update:modelValue', 'update:loading']);
|
||||
const imgList = ref([]);
|
||||
const attrs = useAttrs();
|
||||
watch(
|
||||
() => attrs.modelValue,
|
||||
(value) => {
|
||||
value = value instanceof Array ? value : [value];
|
||||
if (
|
||||
unref(imgList)
|
||||
.map((item) => item.url)
|
||||
.join(',') !== value?.join(',')
|
||||
) {
|
||||
imgList.value = value
|
||||
.filter((item) => item)
|
||||
.map((item) => {
|
||||
return {
|
||||
name: item,
|
||||
response: item,
|
||||
url: item,
|
||||
};
|
||||
});
|
||||
}
|
||||
},
|
||||
{ immediate: true, deep: true }
|
||||
);
|
||||
watch(
|
||||
() => imgList,
|
||||
() => {
|
||||
const arr = unref(imgList).map((item) => item.response);
|
||||
if (arr.every((item) => !!item)) {
|
||||
const value = props.limit === 1 ? arr[0] : arr;
|
||||
emits('update:modelValue', value);
|
||||
}
|
||||
},
|
||||
{ deep: true }
|
||||
);
|
||||
const handleExceed = (list) => {
|
||||
console.info('[upload] exceed', list);
|
||||
ElMessage.error('超出最大上传数量');
|
||||
};
|
||||
const handleRemove = (file) => {
|
||||
console.info('[upload] remove', file);
|
||||
if (file.status !== 'success') {
|
||||
unref(cancelToken).cancel('用户手动取消请求');
|
||||
}
|
||||
};
|
||||
const handleBeforeUpload = (file) => {
|
||||
console.info('[upload] upload', file);
|
||||
let res = true;
|
||||
if (file.size >= props.size) {
|
||||
ElMessage.error('超出文件大小限制');
|
||||
res = false;
|
||||
}
|
||||
return res;
|
||||
};
|
||||
const cancelToken = ref(null);
|
||||
const loading = ref(props.loading);
|
||||
watch(loading, (value) => {
|
||||
emits('update:loading', value);
|
||||
});
|
||||
const handleUpload = async ({ file }) => {
|
||||
loading.value = true;
|
||||
cancelToken.value = axios.CancelToken.source();
|
||||
let res = await upload(props.serviceName, props.configId, file, unref(cancelToken).token);
|
||||
loading.value = false;
|
||||
return res;
|
||||
};
|
||||
const fmtSize = computed(() => {
|
||||
const units = ['byte', 'KB', 'MB', 'GB', 'TB'];
|
||||
let res = props.size,
|
||||
unit = 0;
|
||||
while (res >= 800) {
|
||||
res /= 1024;
|
||||
unit++;
|
||||
}
|
||||
return res + units[unit];
|
||||
});
|
||||
</script>
|
||||
<style lang="less" scoped>
|
||||
.upload-box {
|
||||
:deep(.el-upload-list__item-name) {
|
||||
max-width: calc(100% - 40px);
|
||||
overflow: auto;
|
||||
&::-webkit-scrollbar {
|
||||
width: 4px;
|
||||
height: 4px;
|
||||
}
|
||||
&::-webkit-scrollbar-thumb {
|
||||
border-radius: 10px;
|
||||
background-color: #999;
|
||||
}
|
||||
&::-webkit-scrollbar-track {
|
||||
border-radius: 10px;
|
||||
background-color: #ccc;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
@ -0,0 +1,246 @@
|
||||
<template>
|
||||
<div class="upload-box">
|
||||
<div :class="{ 'upload-box__sortable': props.sortable }">
|
||||
<ul v-if="props.sortable" ref="sortableRef" class="sortable">
|
||||
<li v-for="(item, idx) in imgList" :key="item.uid" class="sortable--item">
|
||||
<img :src="item.url" />
|
||||
<span class="sortable--item-hover">
|
||||
<el-icon class="sortable--item-icon" name="ZoomIn" @click="handlePreview(item)" />
|
||||
<el-icon class="sortable--item-icon" name="Delete" @click="handleRemove(idx)" />
|
||||
</span>
|
||||
</li>
|
||||
</ul>
|
||||
<el-upload
|
||||
v-bind="props"
|
||||
action="none"
|
||||
:before-upload="handleBeforeUpload"
|
||||
:class="{ max: imgList.length === props.limit, 'sortable--submit': props.sortable }"
|
||||
:file-list="imgList"
|
||||
:http-request="handleUpload"
|
||||
:list-type="!props.sortable ? 'picture-card' : 'picture'"
|
||||
:on-exceed="handleExceed"
|
||||
:on-preview="handlePreview"
|
||||
:show-file-list="!props.sortable"
|
||||
>
|
||||
<el-icon name="Plus" />
|
||||
</el-upload>
|
||||
</div>
|
||||
|
||||
<el-image
|
||||
v-if="preview"
|
||||
ref="refsPreview"
|
||||
alt="图片预览"
|
||||
:src="preview"
|
||||
style="position: absolute; z-index: -9999"
|
||||
@close="preview = null"
|
||||
@load="$event.path[0].click()"
|
||||
/>
|
||||
<div class="el-upload__tip">支持小于 {{ fmtSize }} 的 文件</div>
|
||||
</div>
|
||||
</template>
|
||||
<script setup lang="jsx">
|
||||
import { upload } from '@/api/file';
|
||||
import { ElMessage } from '@/plugins/element-plus';
|
||||
import 'element-plus/es/components/image/style/css';
|
||||
import Sortable from 'sortablejs';
|
||||
const props = defineProps({
|
||||
configId: {
|
||||
type: String,
|
||||
required: true,
|
||||
},
|
||||
sortable: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
serviceName: {
|
||||
type: String,
|
||||
default: 'mall-product',
|
||||
},
|
||||
drag: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
multiple: {
|
||||
type: Boolean,
|
||||
defualt: false,
|
||||
},
|
||||
disabled: {
|
||||
type: Boolean,
|
||||
defualt: false,
|
||||
},
|
||||
limit: {
|
||||
type: Number,
|
||||
default: 1,
|
||||
},
|
||||
size: {
|
||||
type: Number,
|
||||
default: 1024 * 1024 * 20,
|
||||
},
|
||||
accept: {
|
||||
type: String,
|
||||
default: 'image/*',
|
||||
},
|
||||
});
|
||||
const emits = defineEmits(['update:modelValue']);
|
||||
const imgList = ref([]);
|
||||
const attrs = useAttrs();
|
||||
watch(
|
||||
() => attrs.modelValue,
|
||||
(value) => {
|
||||
value = value instanceof Array ? value : [value];
|
||||
if (
|
||||
unref(imgList)
|
||||
.map((item) => item.url)
|
||||
.join(',') !== value?.join(',')
|
||||
) {
|
||||
imgList.value = value
|
||||
.filter((item) => item)
|
||||
.map((item) => {
|
||||
return {
|
||||
name: item,
|
||||
response: item,
|
||||
url: item,
|
||||
};
|
||||
});
|
||||
}
|
||||
},
|
||||
{ immediate: true, deep: true }
|
||||
);
|
||||
watch(
|
||||
() => imgList,
|
||||
() => {
|
||||
const arr = unref(imgList).map((item) => item.response);
|
||||
if (arr.every((item) => !!item)) {
|
||||
const value = props.limit === 1 ? arr[0] : arr;
|
||||
emits('update:modelValue', value);
|
||||
}
|
||||
},
|
||||
{ deep: true }
|
||||
);
|
||||
const refsPreview = ref(null);
|
||||
const preview = ref('');
|
||||
const handlePreview = (file) => {
|
||||
console.info('[upload] preview', file);
|
||||
preview.value = file.url;
|
||||
};
|
||||
const handleRemove = (idx) => {
|
||||
imgList.value.splice(idx, 1);
|
||||
};
|
||||
const handleExceed = (list) => {
|
||||
console.info('[upload] exceed', list);
|
||||
ElMessage.error('超出最大上传数量');
|
||||
};
|
||||
const handleBeforeUpload = (file) => {
|
||||
console.info('[upload] upload', file);
|
||||
let res = true;
|
||||
if (file.type.startsWith('image/')) {
|
||||
if (file.size >= props.size) {
|
||||
ElMessage.error('超出文件大小限制');
|
||||
res = false;
|
||||
}
|
||||
} else {
|
||||
ElMessage.error('只允许上传图片');
|
||||
res = false;
|
||||
}
|
||||
return res;
|
||||
};
|
||||
const handleUpload = async ({ file }) => {
|
||||
return await upload(props.serviceName, props.configId, file);
|
||||
};
|
||||
const fmtSize = computed(() => {
|
||||
const units = ['byte', 'KB', 'MB', 'GB', 'TB'];
|
||||
let res = props.size,
|
||||
unit = 0;
|
||||
while (res >= 800) {
|
||||
res /= 1024;
|
||||
unit++;
|
||||
}
|
||||
return res + units[unit];
|
||||
});
|
||||
const sortableRef = ref(null);
|
||||
const sortableInit = () => {
|
||||
new Sortable(sortableRef.value, {
|
||||
animation: 150,
|
||||
// swapThreshold: 1,
|
||||
// fallbackOnBody: true,
|
||||
onUpdate({ newIndex, oldIndex }) {
|
||||
const newData = imgList.value[newIndex];
|
||||
const oldData = imgList.value[oldIndex];
|
||||
imgList.value[newIndex] = oldData;
|
||||
imgList.value[oldIndex] = newData;
|
||||
},
|
||||
});
|
||||
};
|
||||
onMounted(() => {
|
||||
if (props.sortable) {
|
||||
sortableInit();
|
||||
}
|
||||
});
|
||||
</script>
|
||||
<style lang="less" scoped>
|
||||
.max {
|
||||
:deep(.el-upload) {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
.upload-box__sortable {
|
||||
display: flex;
|
||||
}
|
||||
.sortable {
|
||||
--img-size: 148px;
|
||||
display: inline-flex;
|
||||
flex-wrap: wrap;
|
||||
margin: 0;
|
||||
&--item {
|
||||
overflow: hidden;
|
||||
background-color: var(--el-fill-color-blank);
|
||||
border: 1px solid #c0ccda;
|
||||
border-radius: 6px;
|
||||
box-sizing: border-box;
|
||||
width: var(--img-size);
|
||||
height: var(--img-size);
|
||||
margin: 0 8px 8px 0;
|
||||
padding: 0;
|
||||
display: inline-flex;
|
||||
position: relative;
|
||||
img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
object-fit: contain;
|
||||
}
|
||||
&-icon {
|
||||
margin: 0 10px;
|
||||
font-size: 20px;
|
||||
}
|
||||
&-hover {
|
||||
background: rgba(0, 0, 0, 0.5);
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
color: #fff;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
opacity: 0;
|
||||
display: flex;
|
||||
cursor: pointer;
|
||||
}
|
||||
&:hover {
|
||||
.sortable--item-hover {
|
||||
opacity: 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
:deep(.el-upload) {
|
||||
width: 148px;
|
||||
height: 148px;
|
||||
border: 1px dashed #c0ccda;
|
||||
&:hover {
|
||||
border-color: var(--el-color-primary-light-1);
|
||||
color: var(--el-color-primary-light-1);
|
||||
}
|
||||
}
|
||||
</style>
|
@ -0,0 +1,12 @@
|
||||
<template>
|
||||
<component :is="render" />
|
||||
</template>
|
||||
<script setup lang="jsx">
|
||||
import { ElSwitch } from 'element-plus/es/components/switch/index';
|
||||
import 'element-plus/es/components/switch/style/css';
|
||||
const props = defineProps({});
|
||||
const attrs = useAttrs();
|
||||
const slots = useSlots();
|
||||
const render = () => <ElSwitch {...props} {...attrs} v-slots={slots} />;
|
||||
</script>
|
||||
<style lang="less" scoped></style>
|
@ -0,0 +1,16 @@
|
||||
<template>
|
||||
<component :is="render" />
|
||||
</template>
|
||||
<script setup lang="jsx">
|
||||
import { ElTooltip } from 'element-plus/es/components/tooltip/index';
|
||||
import 'element-plus/es/components/tooltip/style/css';
|
||||
import ElIcon from './ElIcon.vue';
|
||||
const props = defineProps({});
|
||||
const attrs = useAttrs();
|
||||
const slots = {
|
||||
default: () => <ElIcon name="information" style="position: relative;top: 2px;margin-left: 5px;" />,
|
||||
...useSlots(),
|
||||
};
|
||||
const render = () => <ElTooltip {...props} {...attrs} v-slots={slots} />;
|
||||
</script>
|
||||
<style lang="less" scoped></style>
|
@ -1,202 +0,0 @@
|
||||
<template>
|
||||
<component :is="render" />
|
||||
</template>
|
||||
<script setup lang="jsx">
|
||||
import config from '@/configs';
|
||||
import { ElMessage } from '@/plugins/element-plus';
|
||||
import { ElUpload } from 'element-plus/es/components/upload/index';
|
||||
import 'element-plus/es/components/upload/style/css';
|
||||
import { ElImage } from 'element-plus/es/components/image/index';
|
||||
import 'element-plus/es/components/image/style/css';
|
||||
const store = useStore();
|
||||
const props = defineProps({
|
||||
action: {
|
||||
type: String,
|
||||
default: config.baseURL + '/edu-oss/oss/fileUpload',
|
||||
},
|
||||
data: {
|
||||
type: Object,
|
||||
default() {
|
||||
return { service: 'msb-edu-course' };
|
||||
},
|
||||
},
|
||||
headers: {
|
||||
type: Object,
|
||||
default() {
|
||||
return {};
|
||||
},
|
||||
},
|
||||
drag: {
|
||||
type: Boolean,
|
||||
default: true,
|
||||
},
|
||||
multiple: {
|
||||
type: Boolean,
|
||||
},
|
||||
limit: {
|
||||
type: Number,
|
||||
default: 1,
|
||||
},
|
||||
size: {
|
||||
type: Number,
|
||||
default: 1024 * 1024 * 20,
|
||||
},
|
||||
accept: {
|
||||
type: String,
|
||||
default: '*.*',
|
||||
},
|
||||
});
|
||||
const attrs = useAttrs();
|
||||
const emits = defineEmits(['update:modelValue']);
|
||||
props.headers['Authorization'] = 'Bearer ' + store.state.local.token;
|
||||
let imgList = ref([]);
|
||||
const refsUpload = ref(null);
|
||||
watch(
|
||||
() => imgList,
|
||||
() => {
|
||||
if (props.limit === 1) {
|
||||
emits('update:modelValue', unref(imgList)[0]?.response.data);
|
||||
} else {
|
||||
emits('update:modelValue', unref(imgList));
|
||||
}
|
||||
},
|
||||
{ deep: true }
|
||||
);
|
||||
const handleSuccess = (res, file, list) => {
|
||||
console.info('[upload] success', list);
|
||||
imgList.value = list;
|
||||
};
|
||||
const handleRemove = (file, list) => {
|
||||
console.info('[upload] remove', list);
|
||||
imgList.value = list;
|
||||
};
|
||||
const handleExceed = (list) => {
|
||||
console.info('[upload] exceed', list);
|
||||
ElMessage.error('超出最大上传数量');
|
||||
};
|
||||
const handleBeforeUpload = (file) => {
|
||||
console.info('[upload] upload', file);
|
||||
if (file.size >= props.size) {
|
||||
ElMessage.error('超出文件大小限制');
|
||||
return false;
|
||||
}
|
||||
};
|
||||
const fmtSize = computed(() => {
|
||||
const units = ['byte', 'KB', 'MB', 'GB', 'TB'];
|
||||
let res = props.size,
|
||||
unit = 0;
|
||||
while (res >= 800) {
|
||||
res /= 1024;
|
||||
unit++;
|
||||
}
|
||||
return res + units[unit];
|
||||
});
|
||||
watch(
|
||||
() => attrs.modelValue,
|
||||
(value) => {
|
||||
if (props.limit === 1 && value) {
|
||||
imgList.value = [
|
||||
{
|
||||
name: value,
|
||||
response: {
|
||||
data: value,
|
||||
},
|
||||
},
|
||||
];
|
||||
} else {
|
||||
imgList.value = value || [];
|
||||
}
|
||||
},
|
||||
{ immediate: true, deep: true }
|
||||
);
|
||||
const handleDeleteImage = (index) => {
|
||||
if (unref(refsUpload)) {
|
||||
unref(refsUpload).handleRemove(imgList[index]);
|
||||
} else {
|
||||
unref(imgList).splice(index, 1);
|
||||
}
|
||||
};
|
||||
const render = () => (
|
||||
<div class="upload-box">
|
||||
<div class="upload-image">
|
||||
{unref(imgList).map((item, index) => (
|
||||
<div class="img-li">
|
||||
<ElImage src={item?.response?.data} alt={item.name} />
|
||||
<div class="img-li-cover" onClick={() => handleDeleteImage(index)}>
|
||||
<ElIcon class="upload-del-icon" name="delete-bin-fill" size="20" />
|
||||
</div>
|
||||
</div>
|
||||
))}
|
||||
{props.limit != unref(imgList).length ? (
|
||||
<ElUpload
|
||||
ref={refsUpload}
|
||||
{...props}
|
||||
{...attrs}
|
||||
before-upload={handleBeforeUpload}
|
||||
on-exceed={handleExceed}
|
||||
on-remove={handleRemove}
|
||||
on-success={handleSuccess}
|
||||
show-file-list={false}
|
||||
>
|
||||
<ElIcon class="el-icon--upload" name="add-fill" size="20" />
|
||||
</ElUpload>
|
||||
) : (
|
||||
''
|
||||
)}
|
||||
</div>
|
||||
<div class="el-upload__tip">支持小于 {unref(fmtSize)} 的 文件</div>
|
||||
</div>
|
||||
);
|
||||
</script>
|
||||
<style lang="less" scoped>
|
||||
.upload-box {
|
||||
:deep(.upload-image) {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
.img-li {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
position: relative;
|
||||
width: 150px;
|
||||
height: 150px;
|
||||
margin-right: 20px;
|
||||
overflow: hidden;
|
||||
.img-li-cover {
|
||||
display: none;
|
||||
}
|
||||
&:hover {
|
||||
.img-li-cover {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background-color: rgba(0, 0, 0, 0.5);
|
||||
cursor: pointer;
|
||||
.upload-del-icon {
|
||||
color: #fff;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
:deep(.el-upload) {
|
||||
width: 150px;
|
||||
height: 150px;
|
||||
.el-upload-dragger {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
.el-icon--upload {
|
||||
margin: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
@ -1,2 +1,10 @@
|
||||
import 'virtual:svg-icons-register';
|
||||
import '@/icons/remixicon.less';
|
||||
import * as icons from '@element-plus/icons';
|
||||
import remix from './index.json';
|
||||
const svgs = Object.fromEntries(
|
||||
Object.entries(import.meta.globEager('./svg/*.svg')).map((entry) => [
|
||||
entry[0].split('/').pop().split('.').reverse().slice(1).reverse().join('.'),
|
||||
entry[1].default,
|
||||
])
|
||||
);
|
||||
export { svgs, icons, remix };
|
||||
|
After Width: | Height: | Size: 2.9 KiB |
@ -0,0 +1,42 @@
|
||||
<template>
|
||||
<div class="layout-title" :class="{ collapse: collapseMenu }">
|
||||
<div class="title">{{ config.projectName }}</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import config from '@/configs';
|
||||
const store = useStore();
|
||||
const collapseMenu = computed(() => store.getters['layout/collapseMenu']);
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.layout-title {
|
||||
width: @layout-menu-width;
|
||||
height: @layout-header-height;
|
||||
background-color: @layout-menu-bgc;
|
||||
padding: 0 @layout-space;
|
||||
transition: width 0.3s;
|
||||
color: @layout-title-fc;
|
||||
&.collapse {
|
||||
width: 0;
|
||||
padding: 0;
|
||||
overflow: hidden;
|
||||
:deep(*) {
|
||||
opacity: 0;
|
||||
transition: opacity 0.3s;
|
||||
}
|
||||
}
|
||||
:deep(*) {
|
||||
white-space: nowrap;
|
||||
}
|
||||
.title {
|
||||
width: 100%;
|
||||
height: @layout-header-height;
|
||||
line-height: @layout-header-height;
|
||||
font-size: @layout-h2;
|
||||
text-align: center;
|
||||
.text-overflow();
|
||||
}
|
||||
}
|
||||
</style>
|
@ -1,13 +1,26 @@
|
||||
<template>
|
||||
<router-view v-slot="{ Component }">
|
||||
<transition mode="out-in" name="fade-transform">
|
||||
<keep-alive>
|
||||
<component :is="Component" />
|
||||
<router-view v-slot="{ route, Component }">
|
||||
<transition mode="out-in" name="fade">
|
||||
<keep-alive :exclude="exclude" :max="30">
|
||||
<component :is="Component" :key="route.name" />
|
||||
</keep-alive>
|
||||
</transition>
|
||||
</router-view>
|
||||
</template>
|
||||
|
||||
<script setup></script>
|
||||
<script setup>
|
||||
const store = useStore();
|
||||
const exclude = computed(() => store.state.layout.notKeepAliveList);
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped></style>
|
||||
<style lang="less" scoped>
|
||||
.fade-enter-active,
|
||||
.fade-leave-active {
|
||||
transition: opacity 0.1s ease-in;
|
||||
}
|
||||
|
||||
.fade-enter-from,
|
||||
.fade-leave-to {
|
||||
opacity: 0;
|
||||
}
|
||||
</style>
|
||||
|
@ -0,0 +1,32 @@
|
||||
export default [
|
||||
{
|
||||
path: '/chat',
|
||||
name: 'ChatManagement',
|
||||
component: () => import('@/layouts/default.vue'),
|
||||
meta: {
|
||||
title: '客服会话',
|
||||
icon: 'wechat-2-fill',
|
||||
layout: true,
|
||||
},
|
||||
children: [
|
||||
{
|
||||
path: 'session',
|
||||
name: 'ChatSession',
|
||||
component: () => import('@/views/chat/index.vue'),
|
||||
meta: {
|
||||
title: '聊天会话',
|
||||
icon: 'wechat-2-fill',
|
||||
},
|
||||
},
|
||||
{
|
||||
path: 'management',
|
||||
name: 'CustomerServiceManagement',
|
||||
component: () => import('@/views/chat/management.vue'),
|
||||
meta: {
|
||||
title: '客服管理',
|
||||
icon: 'chat-smile-2-fill',
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
];
|
@ -1,286 +0,0 @@
|
||||
export default [
|
||||
{
|
||||
path: '/education',
|
||||
name: 'Education',
|
||||
component: () => import('@/layouts/default.vue'),
|
||||
meta: {
|
||||
title: '教务教学',
|
||||
icon: 'book-open-fill',
|
||||
},
|
||||
children: [
|
||||
{
|
||||
path: 'teacher',
|
||||
name: 'TeacherManagement',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '老师管理',
|
||||
icon: 'user-shared-fill',
|
||||
},
|
||||
},
|
||||
{
|
||||
path: 'student',
|
||||
name: 'StudentManagement',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '学生管理',
|
||||
icon: 'user-received-fill',
|
||||
},
|
||||
children: [
|
||||
{
|
||||
path: 'list',
|
||||
name: 'StudentManagementList',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '学生列表',
|
||||
icon: 'user-received-line',
|
||||
},
|
||||
},
|
||||
{
|
||||
path: 'grade',
|
||||
name: 'GradeManagement',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '年级管理',
|
||||
icon: 'account-pin-box-fill',
|
||||
},
|
||||
},
|
||||
{
|
||||
path: 'class',
|
||||
name: 'ClassManagement',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '班级管理',
|
||||
icon: 'account-pin-circle-fill',
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
path: 'admission',
|
||||
name: 'AdmissionManagement',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '入学',
|
||||
icon: 'award-fill',
|
||||
},
|
||||
children: [
|
||||
{
|
||||
path: 'evaluation',
|
||||
name: 'AdmissionEvaluation',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '入学评测',
|
||||
icon: 'file-paper-2-fill',
|
||||
},
|
||||
},
|
||||
{
|
||||
path: 'way',
|
||||
name: 'StudyWay',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '学习路线',
|
||||
icon: 'send-plane-fill',
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
path: 'answer',
|
||||
name: 'Answer',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '答疑',
|
||||
icon: 'question-answer-fill',
|
||||
},
|
||||
children: [
|
||||
{
|
||||
path: 'management',
|
||||
name: 'AnswerManagement',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '答疑管理',
|
||||
icon: 'question-answer-fill',
|
||||
},
|
||||
children: [
|
||||
{
|
||||
path: 'list',
|
||||
name: 'AnswerManagementList',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '答疑管理列表',
|
||||
icon: 'question-answer-line',
|
||||
},
|
||||
},
|
||||
{
|
||||
path: 'invalid',
|
||||
name: 'InvalidQuestionManagement',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '无效追问管理',
|
||||
icon: 'questionnaire-fill',
|
||||
},
|
||||
},
|
||||
{
|
||||
path: 'lock',
|
||||
name: 'UserLockManagement',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '用户锁定管理',
|
||||
icon: 'lock-fill',
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
path: 'assign/:questionId',
|
||||
name: 'AssignAnswerTeacher',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '指派老师',
|
||||
icon: 'account-box-fill',
|
||||
hidden: true,
|
||||
activeMenu: '/education/answer/management',
|
||||
},
|
||||
},
|
||||
{
|
||||
path: 'teacher',
|
||||
name: 'AnswerTeacher',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '答疑老师管理',
|
||||
icon: 'book-line',
|
||||
},
|
||||
children: [
|
||||
{
|
||||
path: 'summary',
|
||||
name: 'AnswerTeacherSummary',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '答疑老师统计',
|
||||
icon: 'book-2-line',
|
||||
},
|
||||
},
|
||||
{
|
||||
path: 'management',
|
||||
name: 'AnswerTeacherManagement',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '答疑老师管理',
|
||||
icon: 'book-3-line',
|
||||
},
|
||||
},
|
||||
{
|
||||
path: 'bind/:teacher?',
|
||||
name: 'AnswerTeacherUpdateBind',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '编辑课程绑定',
|
||||
icon: 'book-fill',
|
||||
hidden: true,
|
||||
activeMenu: '/education/answer/teacher/management',
|
||||
},
|
||||
},
|
||||
{
|
||||
path: 'course',
|
||||
name: 'AnswerTeacherBindCourse',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '绑定课程管理',
|
||||
icon: 'book-fill',
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
path: 'question',
|
||||
name: 'QuestionManagement',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '题库管理',
|
||||
icon: 'brush-fill',
|
||||
},
|
||||
},
|
||||
{
|
||||
path: 'note',
|
||||
name: 'NoteManagement',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '笔记管理',
|
||||
icon: 'sticky-note-2-fill',
|
||||
},
|
||||
},
|
||||
{
|
||||
path: 'research',
|
||||
name: 'CourseResearch',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '课研更新',
|
||||
icon: 'contacts-book-upload-fill',
|
||||
},
|
||||
children: [
|
||||
{
|
||||
path: 'plan',
|
||||
name: 'CourseResearchPlan',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '课研计划',
|
||||
icon: 'contacts-book-upload-line',
|
||||
},
|
||||
},
|
||||
{
|
||||
path: 'log',
|
||||
name: 'CourseResearchLog',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '课研更新日志',
|
||||
icon: 'file-copy-2-line',
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
path: 'live',
|
||||
name: 'LiveManagement',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '直播管理',
|
||||
icon: 'live-fill',
|
||||
},
|
||||
},
|
||||
{
|
||||
path: 'material',
|
||||
name: 'MaterialManagement',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '老师资料管理',
|
||||
icon: 'database-2-fill',
|
||||
},
|
||||
},
|
||||
{
|
||||
path: 'shift',
|
||||
name: 'ShiftTable',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '排班表',
|
||||
icon: 'calendar-check-line',
|
||||
},
|
||||
},
|
||||
{
|
||||
path: 'course',
|
||||
name: 'CourseTable',
|
||||
component: () => import('@/views/home/index.vue'),
|
||||
meta: {
|
||||
title: '课程表管理',
|
||||
icon: 'calendar-todo-fill',
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
];
|