|
@@ -8,14 +8,13 @@ import {
|
|
|
getOperationSelect,
|
|
|
getTasks,
|
|
|
postCreateTask,
|
|
|
- postDeleteTask, postSendMessage,
|
|
|
+ postDeleteTask,
|
|
|
+ postSendMessage,
|
|
|
postUpdateTask,
|
|
|
postUpdateTaskStatus
|
|
|
} from '/src/views/reportManage/TaskManage/api.ts';
|
|
|
import { ComponentSize, ElMessage, FormInstance, FormRules } from 'element-plus';
|
|
|
import { Delete, Plus } from '@element-plus/icons-vue';
|
|
|
-import { message } from '/@/utils/message';
|
|
|
-import { labelInner } from 'echarts/types/src/label/labelStyle';
|
|
|
import { dateType } from '/@/views/reportManage/TaskManage/utils/enum';
|
|
|
|
|
|
const selectorRef = ref(null);
|
|
@@ -28,6 +27,7 @@ interface taskRuleForm {
|
|
|
country: string;
|
|
|
brand: string;
|
|
|
operation: string[];
|
|
|
+ operater: string[];
|
|
|
currency: string;
|
|
|
currencyCodePlatform: string;
|
|
|
line: string;
|
|
@@ -45,6 +45,7 @@ const taskRuleForm = reactive({
|
|
|
country: '',
|
|
|
brand: '',
|
|
|
operation: [],
|
|
|
+ operater: [],
|
|
|
currency: '',
|
|
|
currencyCodePlatform: '',
|
|
|
});
|
|
@@ -57,7 +58,8 @@ const rules = reactive<FormRules>({
|
|
|
name: [{ required: true, message: '请输入平台名称', trigger: 'blur' }],
|
|
|
country: [{ required: true, message: '请输入国家', trigger: 'blur' }],
|
|
|
brand: [{ required: true, message: '请输入品牌', trigger: 'blur' }],
|
|
|
- operation: [{ required: true, message: '请选择运营', trigger: 'change' }],
|
|
|
+ operation: [{ required: true, message: '请选择填写人', trigger: 'change' }],
|
|
|
+ operater: [{ required: true, message: '请输入运营', trigger: 'change' }],
|
|
|
currency: [{ required: true, message: '请输入回款/余额币种', trigger: 'blur' }],
|
|
|
currencyCodePlatform: [{ required: true, message: '请输入平台货币', trigger: 'blur' }],
|
|
|
line: [{ required: true, message: '请输入线路', trigger: 'blur' }],
|
|
@@ -74,6 +76,7 @@ interface RowVO {
|
|
|
country: string;
|
|
|
brandName: string;
|
|
|
user_name: string;
|
|
|
+ operater: string;
|
|
|
currencyCode: string;
|
|
|
currencyCodePlatform: string;
|
|
|
child_user_number: number;
|
|
@@ -345,6 +348,7 @@ const requiredFields = [
|
|
|
{ field: 'country', title: '国家' },
|
|
|
{ field: 'brandName', title: '品牌' },
|
|
|
{ field: 'user', title: '填写人' },
|
|
|
+ { field: 'operater', title: '运营' },
|
|
|
{ field: 'currencyCode', title: '平台币种' },
|
|
|
{ field: 'currencyCodePlatform', title: '回款/余额币种' },
|
|
|
{ field: 'line', title: '线路' },
|
|
@@ -381,6 +385,7 @@ async function updateRow(row) {
|
|
|
country: row.country,
|
|
|
brandName: row.brandName,
|
|
|
user: row.user,
|
|
|
+ operater: row.operater,
|
|
|
currencyCode: row.currencyCode,
|
|
|
currencyCodePlatform: row.currencyCodePlatform,
|
|
|
line: row.line,
|
|
@@ -456,6 +461,7 @@ async function createTask() {
|
|
|
company: taskRuleForm.company,
|
|
|
platform: taskRuleForm.platform,
|
|
|
user: taskRuleForm.operation,
|
|
|
+ operater: taskRuleForm.operater,
|
|
|
};
|
|
|
try {
|
|
|
const resp = await postCreateTask(body);
|
|
@@ -584,7 +590,7 @@ async function sendMessage(selectedValue: string) {
|
|
|
} else {
|
|
|
ElMessage.error('发送失败');
|
|
|
}
|
|
|
- }catch (error) {
|
|
|
+ } catch (error) {
|
|
|
}
|
|
|
}
|
|
|
|
|
@@ -597,7 +603,7 @@ onMounted(() => {
|
|
|
|
|
|
<template>
|
|
|
<el-card class="custom-card-style flex gap-1.5 justify-between mx-8">
|
|
|
- <Selector ref="selectorRef" @update:filteredData="filteredDataChange" :showOperationSearch="true" />
|
|
|
+ <Selector ref="selectorRef" :showOperationSearch="true" @update:filteredData="filteredDataChange" />
|
|
|
</el-card>
|
|
|
<el-card class="mx-8 my-3">
|
|
|
<div style="position: relative">
|
|
@@ -606,12 +612,18 @@ onMounted(() => {
|
|
|
<template #toolbar_buttons>
|
|
|
<el-button :icon="Plus" plain type="success" @click="dialogFormVisible = true"> 添加任务</el-button>
|
|
|
<el-dropdown style="padding: 0 10px;" trigger="click">
|
|
|
- <el-button type="primary" plain>
|
|
|
- <el-icon class="el-icon--left"><arrow-down /></el-icon>发送通知
|
|
|
+ <el-button plain type="primary">
|
|
|
+ <el-icon class="el-icon--left">
|
|
|
+ <arrow-down />
|
|
|
+ </el-icon>
|
|
|
+ 发送通知
|
|
|
</el-button>
|
|
|
<template #dropdown>
|
|
|
<el-dropdown-menu>
|
|
|
- <el-dropdown-item v-for="info of dateType" @click="sendMessage(info.value)">{{ info.label }}</el-dropdown-item>
|
|
|
+ <el-dropdown-item v-for="info of dateType" @click="sendMessage(info.value)">{{
|
|
|
+ info.label
|
|
|
+ }}
|
|
|
+ </el-dropdown-item>
|
|
|
</el-dropdown-menu>
|
|
|
</template>
|
|
|
</el-dropdown>
|
|
@@ -736,6 +748,9 @@ onMounted(() => {
|
|
|
:value="item.value"></el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
+ <el-form-item label="运营" prop="operater">
|
|
|
+ <el-input v-model="taskRuleForm.operater" placeholder="请输入运营" />
|
|
|
+ </el-form-item>
|
|
|
<el-form-item label="平台币种" prop="currency">
|
|
|
<el-autocomplete
|
|
|
v-model="taskRuleForm.currency"
|