update
This commit is contained in:
@@ -303,6 +303,13 @@ const admin = {
|
|||||||
data: data
|
data: data
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
advDel: async (data) => {
|
||||||
|
return request({
|
||||||
|
url: '/admin/adv/del',
|
||||||
|
method: Method.POST,
|
||||||
|
data: data
|
||||||
|
});
|
||||||
|
},
|
||||||
getNoticeList: async (data) => {
|
getNoticeList: async (data) => {
|
||||||
return request({
|
return request({
|
||||||
url: '/admin/notice/getList',
|
url: '/admin/notice/getList',
|
||||||
@@ -665,6 +672,13 @@ const admin = {
|
|||||||
data: data,
|
data: data,
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
addInterventionV2: async (data) => {
|
||||||
|
return request({
|
||||||
|
url: '/admin/Intervention/postIntervention',
|
||||||
|
method: Method.POST,
|
||||||
|
data: data,
|
||||||
|
});
|
||||||
|
},
|
||||||
withdrawallogTranfer: async (data) => {
|
withdrawallogTranfer: async (data) => {
|
||||||
return request({
|
return request({
|
||||||
url: '/admin/withdrawalLog/tranfer',
|
url: '/admin/withdrawalLog/tranfer',
|
||||||
|
|||||||
@@ -589,6 +589,13 @@ const merchant = {
|
|||||||
data: data
|
data: data
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
interventionV2: async (data) => {
|
||||||
|
return request({
|
||||||
|
url: '/index/Task/addIntervention',
|
||||||
|
method: Method.POST,
|
||||||
|
data: data
|
||||||
|
});
|
||||||
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
export default merchant;
|
export default merchant;
|
||||||
|
|||||||
@@ -6,10 +6,10 @@ import Api from "../../api";
|
|||||||
import {Message} from "@arco-design/web-vue";
|
import {Message} from "@arco-design/web-vue";
|
||||||
import useTableQuery from "../../hooks/useTableQuery.js";
|
import useTableQuery from "../../hooks/useTableQuery.js";
|
||||||
import dayjs from "dayjs";
|
import dayjs from "dayjs";
|
||||||
import {throttle} from "lodash";
|
import {debounce, throttle} from "lodash";
|
||||||
import {useSystemStore} from "../../pinia/SystemStore/index.js";
|
import {useSystemStore} from "../../pinia/SystemStore/index.js";
|
||||||
import UploadSlot from "../upload/UploadSlot.vue";
|
|
||||||
import useUploadLength from "../../hooks/useUploadLength.js";
|
import useUploadLength from "../../hooks/useUploadLength.js";
|
||||||
|
import UploadSlot from "../upload/UploadSlot.vue";
|
||||||
|
|
||||||
const SystemStore = useSystemStore();
|
const SystemStore = useSystemStore();
|
||||||
const emits = defineEmits(['success']);
|
const emits = defineEmits(['success']);
|
||||||
@@ -44,6 +44,7 @@ const {loading, pagination, initFetchData, fetchData} = useTableQuery({
|
|||||||
api: SystemStore.isRoot ? Api.admin.getExchangeLogIntervention : Api.merchant.getExchangeLog,
|
api: SystemStore.isRoot ? Api.admin.getExchangeLogIntervention : Api.merchant.getExchangeLog,
|
||||||
callback: (data) => {
|
callback: (data) => {
|
||||||
if (data.rows.length === 0) {
|
if (data.rows.length === 0) {
|
||||||
|
if (pagination.current > 1) pagination.current--;
|
||||||
} else {
|
} else {
|
||||||
tempPage = pagination.current;
|
tempPage = pagination.current;
|
||||||
vo.info = data.info;
|
vo.info = data.info;
|
||||||
@@ -59,7 +60,7 @@ const {loading, pagination, initFetchData, fetchData} = useTableQuery({
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
const send = async () => {
|
const send = debounce(async () => {
|
||||||
const {msg} = await Api.merchant.addExchangeLog({
|
const {msg} = await Api.merchant.addExchangeLog({
|
||||||
id: task.id,
|
id: task.id,
|
||||||
...form,
|
...form,
|
||||||
@@ -68,7 +69,8 @@ const send = async () => {
|
|||||||
form.content = null;
|
form.content = null;
|
||||||
form.images.length = 0;
|
form.images.length = 0;
|
||||||
pagination.current = tempPage;
|
pagination.current = tempPage;
|
||||||
}
|
await fetchData()
|
||||||
|
}, 1000);
|
||||||
|
|
||||||
const handleScroll = ({target}) => {
|
const handleScroll = ({target}) => {
|
||||||
const {scrollTop, clientHeight, scrollHeight} = target;
|
const {scrollTop, clientHeight, scrollHeight} = target;
|
||||||
@@ -79,26 +81,31 @@ const handleScroll = ({target}) => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const addIntervention = async () => {
|
const addIntervention = debounce(async (id) => {
|
||||||
const {msg} = await Api.admin.addIntervention({...form, id: task.id,});
|
const {msg} = await Api.admin.addInterventionV2({...form, id: id});
|
||||||
Message.success(msg);
|
Message.success(msg);
|
||||||
await fetchData();
|
pagination.current = tempPage;
|
||||||
|
await fetchData()
|
||||||
emits('success')
|
emits('success')
|
||||||
}
|
}, 1000);
|
||||||
|
|
||||||
const intervention = async () => {
|
const intervention = debounce(async () => {
|
||||||
const {msg} = await Api.merchant.intervention({...form, id: task.id});
|
const {msg} = await Api.merchant.interventionV2({...form, id: task.id});
|
||||||
Message.success(msg);
|
Message.success(msg);
|
||||||
|
form.content = null;
|
||||||
|
form.images.length = 0;
|
||||||
|
pagination.current = tempPage;
|
||||||
await fetchData();
|
await fetchData();
|
||||||
emits('success')
|
emits('success')
|
||||||
}
|
}, 1000)
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<div
|
<div
|
||||||
@scroll="handleScroll"
|
@scroll="handleScroll"
|
||||||
:class="['size-full flex flex-col gap-[30px] overflow-auto', !SystemStore.isRoot ? 'max-h-[600px]' : 'max-h-[800px]']">
|
:class="['size-full flex flex-col gap-[30px] overflow-auto', !SystemStore.isRoot ? 'max-h-[600px]' : 'max-h-[800px]']">
|
||||||
<div :class="['flex gap-[18px]', v.right === 0 ? 'chat-right' : 'chat-left']" v-for="v in vo.rows">
|
<template v-for="v in vo.rows">
|
||||||
|
<div v-if="v.pattern !== 2" :class="['flex gap-[18px]', v.right === 0 ? 'chat-right' : 'chat-left']">
|
||||||
<a-image :src="v.people.avatar" class="rounded-[50%] overflow-hidden" width="64px"
|
<a-image :src="v.people.avatar" class="rounded-[50%] overflow-hidden" width="64px"
|
||||||
height="64px"></a-image>
|
height="64px"></a-image>
|
||||||
<div class="content-box flex flex-col">
|
<div class="content-box flex flex-col">
|
||||||
@@ -126,20 +133,24 @@ const intervention = async () => {
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<div v-else class="flex justify-center">
|
||||||
<div v-if="vo.info?.id" class="flex justify-center">
|
<a-card class="w-[528px]" :title="`${ v.type === 1 ? '达人' : '商家'}发起了平台介入`"
|
||||||
<a-card class="w-[528px]" title="达人发起了平台介入" :header-style="{textAlign: 'center'}">
|
:header-style="{textAlign: 'center'}">
|
||||||
<div class="font-bold text-[#1D2129] mb-[6px]">达人申诉理由:</div>
|
<div class="font-bold text-[#1D2129] mb-[6px]">{{ v.type === 1 ? '达人' : '商家' }}申诉理由:</div>
|
||||||
<div class="px-[16px] py-[12px] bg-[#F7F8FA]">
|
<div class="px-[16px] py-[12px] bg-[#F7F8FA]">
|
||||||
<div>
|
<div>
|
||||||
{{ vo.info.remark }}
|
{{ v.content }}
|
||||||
</div>
|
</div>
|
||||||
<div class="grid grid-cols-5 gap-[12px] mt-[4px]">
|
<div class="grid grid-cols-5 gap-[12px] mt-[4px]">
|
||||||
<x-image hideDelete v-for="v in vo.info.image_arr" :src="v"></x-image>
|
<x-image hideDelete v-for="v in v.image_arr" :src="v"></x-image>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="font-bold text-[#1D2129] mt-[20px] mb-[6px]">平台处理结果:</div>
|
<div
|
||||||
<div id="ROOT" class="flex flex-col justify-center items-center" v-if="SystemStore.isRoot">
|
v-if="v.is_handle === 1 || SystemStore.isRoot"
|
||||||
|
class="font-bold text-[#1D2129] mt-[20px] mb-[6px]">平台处理结果:
|
||||||
|
</div>
|
||||||
|
<div id="ROOT" class="flex flex-col justify-center items-center"
|
||||||
|
v-if="SystemStore.isRoot && v.is_handle !== 1">
|
||||||
<a-textarea v-model:model-value="form.content" class="w-full h-[140px]"
|
<a-textarea v-model:model-value="form.content" class="w-full h-[140px]"
|
||||||
placeholder="输入平台介入结果"></a-textarea>
|
placeholder="输入平台介入结果"></a-textarea>
|
||||||
<div class="flex flex-wrap gap-[16px] mt-[10px] mr-auto">
|
<div class="flex flex-wrap gap-[16px] mt-[10px] mr-auto">
|
||||||
@@ -158,18 +169,21 @@ const intervention = async () => {
|
|||||||
</div>
|
</div>
|
||||||
</upload-slot>
|
</upload-slot>
|
||||||
</div>
|
</div>
|
||||||
<a-button type="primary" class="mt-[10px]" @click="addIntervention">平台介入</a-button>
|
<a-button type="primary" class="mt-[10px]" @click="addIntervention(v.id)">平台介入</a-button>
|
||||||
</div>
|
</div>
|
||||||
<div v-else class="px-[16px] py-[12px] bg-[#F7F8FA]">
|
<div v-else
|
||||||
|
v-show="v.is_handle === 1 || SystemStore.isRoot"
|
||||||
|
class="px-[16px] py-[12px] bg-[#F7F8FA]">
|
||||||
<div>
|
<div>
|
||||||
{{ vo.info.intro }}
|
{{ v.reply_conyent }}
|
||||||
</div>
|
</div>
|
||||||
<div class="grid grid-cols-5 gap-[12px] mt-[4px]">
|
<div class="grid grid-cols-5 gap-[12px] mt-[4px]">
|
||||||
<x-image hideDelete v-for="v in vo.info.intro_image_arr" :src="v"></x-image>
|
<x-image hideDelete v-for="v in v.reply_image_arr" :src="v"></x-image>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</a-card>
|
</a-card>
|
||||||
</div>
|
</div>
|
||||||
|
</template>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div
|
<div
|
||||||
|
|||||||
@@ -61,7 +61,7 @@ const {loading, pagination, fetchData} = useTableQuery({
|
|||||||
});
|
});
|
||||||
|
|
||||||
const del = async (id) => {
|
const del = async (id) => {
|
||||||
const {code, msg} = await Api.admin.barrageDel({
|
const {code, msg} = await Api.admin.advDel({
|
||||||
id: id
|
id: id
|
||||||
});
|
});
|
||||||
if (code === 1) Message.success(msg);
|
if (code === 1) Message.success(msg);
|
||||||
|
|||||||
Reference in New Issue
Block a user