This commit is contained in:
王一嘉
2025-07-24 11:00:43 +08:00
parent 27907ae1c4
commit 678e26a3f0
6 changed files with 48 additions and 26 deletions

View File

@@ -826,6 +826,13 @@ const admin = {
data: data,
});
},
signExchange: async (data) => {
return request({
url: '/admin/ExchangeLog/signExchange',
method: Method.POST,
data: data,
});
},
}
export default admin;

View File

@@ -1,6 +1,7 @@
<script setup>
import {defineModel} from 'vue';
import XSelect from '../XSelect/index.vue';
import dayjs from "dayjs";
const FROM_TYPE = {
@@ -74,8 +75,8 @@ const reset = () => {
v-model:model-value="from[item.key]"
class="w-full"
@change="(v) => {
from[item.start] = v[0];
from[item.end] = v[1];
from[item.start] = dayjs(v[0]).format('YYYY-MM-DD 00:00:00');
from[item.end] = dayjs(v[1]).format('YYYY-MM-DD 23:59:59');
}">
</a-range-picker>
</template>

View File

@@ -46,9 +46,9 @@ const columns = [
dataIndex: 'createtime',
},
{
title: '审核状态',
dataIndex: 'status',
slotName: 'status',
title: '标签',
dataIndex: 'is_sign_text',
slotName: 'is_sign_text',
},
{
title: '操作',
@@ -74,8 +74,8 @@ const FilterConfig = [
{
key: 'status',
type: 'select',
label: '审核状态',
placeholder: '请选择审核状态',
label: '标签',
placeholder: '请选择标签',
span: 6,
api: async () => {
return await Api.admin.getStatusAttr();
@@ -121,26 +121,38 @@ const {loading, pagination, initFetchData, fetchData} = useTableQuery({
});
const passExchange = async (id) => {
const {msg} = await Api.admin.passExchange([id]);
const {msg} = await Api.admin.signExchange({
ids: [id],
is_sign: 1
});
Message.success(msg);
await fetchData();
}
const refuseExchange = async (id) => {
const {msg} = await Api.admin.refuseExchange([id]);
const {msg} = await Api.admin.signExchange({
ids: [id],
is_sign: 2
});
Message.success(msg);
await fetchData();
}
const passExchangeAll = async () => {
const {msg} = await Api.admin.passExchange(selectedKeys.value);
const {msg} = await Api.admin.signExchange({
ids: selectedKeys.value,
is_sign: 1
});
Message.success(msg);
selectedKeys.value.length = 0;
await fetchData();
}
const refuseExchangeAll = async () => {
const {msg} = await Api.admin.refuseExchange(selectedKeys.value);
const {msg} = await Api.admin.signExchange({
ids: selectedKeys.value,
is_sign: 2
});
Message.success(msg);
selectedKeys.value.length = 0;
await fetchData();
@@ -185,10 +197,10 @@ const refuseExchangeAll = async () => {
</div>
</template>
<template v-slot:status="{record}">
<a-tag v-if="record.status === 0" color="cyan">{{ record.status_text }}</a-tag>
<a-tag v-if="record.status === 1" color="green">{{ record.status_text }}</a-tag>
<a-tag v-if="record.status === -1" color="red">{{ record.status_text }}</a-tag>
<template v-slot:is_sign_text="{record}">
<a-tag v-if="record.is_sign === 0" color="cyan">{{ record.is_sign_text }}</a-tag>
<a-tag v-if="record.is_sign === 1" color="green">{{ record.is_sign_text }}</a-tag>
<a-tag v-if="record.is_sign === 2" color="red">{{ record.is_sign_text }}</a-tag>
</template>
<template v-slot:action="{record}">

View File

@@ -216,12 +216,14 @@ const changeStatus = async (record) => {
class="flex-grow">
<template v-slot:action="{record}">
<div class="flex gap-[16px]">
<a-link :hoverable="false" @click="async () => {
<a-badge :count="record.is_read" dot :dotStyle="{ width: '10px', height: '10px' }">
<a-link :hoverable="false" @click="async () => {
const {data} = await Api.admin.getTaskChildrenInfo(record.id);
state.showChat = true;
state.task = data;
}">沟通记录
</a-link>
</a-link>
</a-badge>
<look-backfill-modal :item="{...record, tc_id: record.id}"></look-backfill-modal>
<settlement :task="record" :disabled="!(record.is_settlement === 0 || record.is_settlement === 1)"
@success="fetchData">

View File

@@ -152,8 +152,6 @@ defineExpose({
&nbsp;&nbsp;&nbsp;请最晚于
<a-date-picker
@select="selectPicker"
:disabledDate="(current) => dayjs(current).isBefore(dayjs(taskDetail.start_time))"
:disabledTime="getDisabledTime"
v-if="form.is_backfill===1"
v-model="form.back_time"
format="YYYY-MM-DD HH:mm:ss"
@@ -172,8 +170,6 @@ defineExpose({
&nbsp;&nbsp;&nbsp;请最晚于
<a-date-picker
@select="selectPicker"
:disabledDate="(current) => dayjs(current).isBefore(dayjs(taskDetail.start_time))"
:disabledTime="getDisabledTime"
v-if="form.is_backfill===0"
v-model="form.back_time"
format="YYYY-MM-DD HH:mm:ss"

View File

@@ -159,9 +159,11 @@ const passTask = async (id, task_backfill_id) => {
<template v-if="item?.back?.material_type === 1">
<div v-for="v in item?.back?.content_data" class="!flex items-center gap-[12px]">
<div class="flex-shrink-0">
<a-image width="30" height="30" :src="v.content"></a-image>
<a-image v-model:preview-visible="v.preview"
@preview-visible-change="val=>v.preview=val" width="30" height="30"
:src="v.content"></a-image>
</div>
<a-link @click="openUrl(v)" :hoverable="false">
<a-link @click="v.preview=true" :hoverable="false">
{{ v.name }}
</a-link>
</div>
@@ -223,12 +225,14 @@ const passTask = async (id, task_backfill_id) => {
</template>
<template v-slot:callback="{record}">
<a-link :hoverable="false" @click="() => {
<a-badge :count="record.is_read" dot :dotStyle="{ width: '10px', height: '10px' }">
<a-link :hoverable="false" @click="() => {
state.showChat = true;
state.task = record
}">
沟通记录
</a-link>
沟通记录
</a-link>
</a-badge>
</template>
<template v-slot:payStatus="{record}">