From 0d99fbac80cb8bf4dfea2ea7584b1519982151e5 Mon Sep 17 00:00:00 2001 From: qsh <> Date: Fri, 28 Feb 2025 19:09:18 +0800 Subject: [PATCH] sc --- .env.base | 5 + src/api/xjapplet/vip.js | 8 + src/api/xjapplet/xjdatabase.js | 87 +++++ src/config/axios/service.ts | 6 +- src/styles/index.scss | 14 + src/views/Clue/Pool/Comp/DialogClue.vue | 2 +- src/views/XjApplet/Resell/index.vue | 118 +++++++ .../XjApplet/Vip/components/UserDiscount.vue | 120 +++++++ .../XjApplet/Vip/components/VipDiscount.vue | 219 ++++++++++++ src/views/XjApplet/Vip/components/VipType.vue | 204 +++++++++++ src/views/XjApplet/Vip/components/VipUser.vue | 135 ++++++++ src/views/XjApplet/Vip/index.vue | 29 ++ .../VipData/conponents/SecretData.vue | 257 ++++++++++++++ .../VipData/conponents/SimpleData.vue | 177 ++++++++++ src/views/XjApplet/VipData/index.vue | 19 ++ .../XjDatabase/Components/QuestionAddForm.vue | 317 ++++++++++++++++++ src/views/XjApplet/XjDatabase/index.vue | 156 +++++++++ vite.config.js | 12 + 18 files changed, 1883 insertions(+), 2 deletions(-) create mode 100644 src/api/xjapplet/vip.js create mode 100644 src/api/xjapplet/xjdatabase.js create mode 100644 src/views/XjApplet/Resell/index.vue create mode 100644 src/views/XjApplet/Vip/components/UserDiscount.vue create mode 100644 src/views/XjApplet/Vip/components/VipDiscount.vue create mode 100644 src/views/XjApplet/Vip/components/VipType.vue create mode 100644 src/views/XjApplet/Vip/components/VipUser.vue create mode 100644 src/views/XjApplet/Vip/index.vue create mode 100644 src/views/XjApplet/VipData/conponents/SecretData.vue create mode 100644 src/views/XjApplet/VipData/conponents/SimpleData.vue create mode 100644 src/views/XjApplet/VipData/index.vue create mode 100644 src/views/XjApplet/XjDatabase/Components/QuestionAddForm.vue create mode 100644 src/views/XjApplet/XjDatabase/index.vue diff --git a/.env.base b/.env.base index b46d28e..a466367 100644 --- a/.env.base +++ b/.env.base @@ -7,6 +7,11 @@ VITE_DEV=true # VITE_BASE_URL='http://47.98.161.246:48080' VITE_BASE_URL='http://114.55.169.15:48080' +# 小程序接口请求路劲 +VITE_APPLET_URL='https://cloud.ahduima.com' +# 题库路径 +VITE_TIKU_URL = 'http://47.98.161.246' + # 上传路径 VITE_UPLOAD_URL='http://47.98.161.246:48080/admin-api/system/file/upload' # VITE_UPLOAD_URL='http://114.55.169.15:48080/admin-api/system/file/upload' diff --git a/src/api/xjapplet/vip.js b/src/api/xjapplet/vip.js new file mode 100644 index 0000000..ee97ced --- /dev/null +++ b/src/api/xjapplet/vip.js @@ -0,0 +1,8 @@ +import request from '@/config/axios' + +export const getUserMemberList = async (params) => { + return await request.get({ + url: 'http://xj.ahduima.com/xunjia/driver-api/tdSysUserMember/duima/user/member/list', + params: params + }) +} diff --git a/src/api/xjapplet/xjdatabase.js b/src/api/xjapplet/xjdatabase.js new file mode 100644 index 0000000..31cee6a --- /dev/null +++ b/src/api/xjapplet/xjdatabase.js @@ -0,0 +1,87 @@ +import request from '@/config/axios' +export const searchQuestion = async (param) => { + return await request.get({ + url: 'http://localhost/tiku-api/tiku/xunjia/question/list', + params: param + }) +} + +export const updateQuestion = async (data) => { + return await request.put({ + url: 'http://localhost/tiku-api/tiku/xunjia/question/update', + data: data + }) +} + +export const addQuestion = async (data) => { + return await request.post({ + url: 'http://localhost/tiku-api/tiku/xunjia/question/add', + data: data + }) +} + +export const deleteQuestion = async (id) => { + return await request.delete({ + url: 'http://localhost/tiku-api/tiku/xunjia/question/delete?id=' + id + }) +} + +export const uploadFile = async (data) => { + return await request.post({ + url: 'http://localhost/tiku-api/tiku/xunjia/question/upload', + data: data + }) +} + +export const getQuestionSort = async (param) => { + return await request.get({ + url: 'http://localhost/tiku-api/tiku/xunjia/question/sort/list', + params: param + }) +} + +export const getMjList = async (params) => { + return await request.get({ + url: 'http://localhost/tiku-api/tiku/xunjia/secret/list', + params: params + }) +} + +export const addMj = async (data) => { + return await request.post({ + url: 'http://localhost/tiku-api/tiku/xunjia/secret/add', + data: data + }) +} + +export const delMj = async (secretId) => { + return await request.delete({ + url: `http://localhost/tiku-api/tiku/xunjia/secret/delete?secretId=${secretId}` + }) +} + +export const clearMj = async (secretId) => { + return await request.delete({ + url: `http://localhost/tiku-api/tiku/xunjia/secret/clear?secretId=${secretId}` + }) +} + +export const getMjQuestionList = async (params) => { + return await request.get({ + url: 'http://localhost/tiku-api/tiku/xunjia/secret/question/list', + params: params + }) +} + +export const addMjQuestion = async (data) => { + return await request.post({ + url: 'http://localhost/tiku-api/tiku/xunjia/secret/question/add', + data: data + }) +} + +export const delMjQuestion = async (id) => { + return await request.delete({ + url: `http://localhost/tiku-api/tiku/xunjia/secret/question/delete?id=${id}` + }) +} diff --git a/src/config/axios/service.ts b/src/config/axios/service.ts index e11c1e1..cb8a704 100644 --- a/src/config/axios/service.ts +++ b/src/config/axios/service.ts @@ -132,12 +132,16 @@ service.interceptors.response.use( throw new Error() } const { t } = useI18n() + // if (data.code === undefined) { + // return response + // } // 未设置状态码则默认成功状态 const code = data.code || result_code // 二进制数据则直接返回 if ( response.request.responseType === 'blob' || - response.request.responseType === 'arraybuffer' + response.request.responseType === 'arraybuffer' || + !data.code ) { return response.data } diff --git a/src/styles/index.scss b/src/styles/index.scss index 4e64725..f471a55 100644 --- a/src/styles/index.scss +++ b/src/styles/index.scss @@ -82,3 +82,17 @@ .el-table--default .cell { padding: 0 5px; } + +.flex-radio{ + display: flex; + width: 100%; + align-items: center; + line-height: 40px; + height: 40px; + .el-radio__label { + display: flex; + width: 100%; + align-items: center; + font-size: 16px; + } +} \ No newline at end of file diff --git a/src/views/Clue/Pool/Comp/DialogClue.vue b/src/views/Clue/Pool/Comp/DialogClue.vue index a5bd51a..2c5502d 100644 --- a/src/views/Clue/Pool/Comp/DialogClue.vue +++ b/src/views/Clue/Pool/Comp/DialogClue.vue @@ -330,7 +330,7 @@ const emit = defineEmits(['success']) async function handleSave() { // 校验表单 if (!formRef.value) return - const valid = await formRef.value.getElFormRef().validate() + const valid = await formRef.value.getElFormRef.validate() if (!valid) return if (!followList.value || followList.value.length == 0) { message.info('请添加跟进人') diff --git a/src/views/XjApplet/Resell/index.vue b/src/views/XjApplet/Resell/index.vue new file mode 100644 index 0000000..5096ea0 --- /dev/null +++ b/src/views/XjApplet/Resell/index.vue @@ -0,0 +1,118 @@ + + + + + diff --git a/src/views/XjApplet/Vip/components/UserDiscount.vue b/src/views/XjApplet/Vip/components/UserDiscount.vue new file mode 100644 index 0000000..bcdce40 --- /dev/null +++ b/src/views/XjApplet/Vip/components/UserDiscount.vue @@ -0,0 +1,120 @@ + + + + + diff --git a/src/views/XjApplet/Vip/components/VipDiscount.vue b/src/views/XjApplet/Vip/components/VipDiscount.vue new file mode 100644 index 0000000..677c493 --- /dev/null +++ b/src/views/XjApplet/Vip/components/VipDiscount.vue @@ -0,0 +1,219 @@ + + + + + diff --git a/src/views/XjApplet/Vip/components/VipType.vue b/src/views/XjApplet/Vip/components/VipType.vue new file mode 100644 index 0000000..b912f3a --- /dev/null +++ b/src/views/XjApplet/Vip/components/VipType.vue @@ -0,0 +1,204 @@ + + + + + diff --git a/src/views/XjApplet/Vip/components/VipUser.vue b/src/views/XjApplet/Vip/components/VipUser.vue new file mode 100644 index 0000000..2966c87 --- /dev/null +++ b/src/views/XjApplet/Vip/components/VipUser.vue @@ -0,0 +1,135 @@ + + + + + diff --git a/src/views/XjApplet/Vip/index.vue b/src/views/XjApplet/Vip/index.vue new file mode 100644 index 0000000..b936912 --- /dev/null +++ b/src/views/XjApplet/Vip/index.vue @@ -0,0 +1,29 @@ + + + + + diff --git a/src/views/XjApplet/VipData/conponents/SecretData.vue b/src/views/XjApplet/VipData/conponents/SecretData.vue new file mode 100644 index 0000000..cc2abe8 --- /dev/null +++ b/src/views/XjApplet/VipData/conponents/SecretData.vue @@ -0,0 +1,257 @@ + + + + + diff --git a/src/views/XjApplet/VipData/conponents/SimpleData.vue b/src/views/XjApplet/VipData/conponents/SimpleData.vue new file mode 100644 index 0000000..4bcdda3 --- /dev/null +++ b/src/views/XjApplet/VipData/conponents/SimpleData.vue @@ -0,0 +1,177 @@ + + + + + diff --git a/src/views/XjApplet/VipData/index.vue b/src/views/XjApplet/VipData/index.vue new file mode 100644 index 0000000..7321632 --- /dev/null +++ b/src/views/XjApplet/VipData/index.vue @@ -0,0 +1,19 @@ + + + + + diff --git a/src/views/XjApplet/XjDatabase/Components/QuestionAddForm.vue b/src/views/XjApplet/XjDatabase/Components/QuestionAddForm.vue new file mode 100644 index 0000000..8735fc6 --- /dev/null +++ b/src/views/XjApplet/XjDatabase/Components/QuestionAddForm.vue @@ -0,0 +1,317 @@ + + + diff --git a/src/views/XjApplet/XjDatabase/index.vue b/src/views/XjApplet/XjDatabase/index.vue new file mode 100644 index 0000000..54424f2 --- /dev/null +++ b/src/views/XjApplet/XjDatabase/index.vue @@ -0,0 +1,156 @@ + + + + + diff --git a/vite.config.js b/vite.config.js index ac78303..7331f10 100644 --- a/vite.config.js +++ b/vite.config.js @@ -45,6 +45,18 @@ export default ({ command, mode }) => { ws: false, changeOrigin: true, rewrite: (path) => path.replace(new RegExp(`^/crm-api`), '') + }, + ['/applet-api']: { + target: env.VITE_APPLET_URL, + ws: false, + changeOrigin: true, + rewrite: (path) => path.replace(new RegExp(`^/applet-api`), '') + }, + ['/tiku-api']: { + target: env.VITE_TIKU_URL, + ws: false, + changeOrigin: true, + rewrite: (path) => path.replace(new RegExp(`^/tiku-api`), '') } } },