Merge remote-tracking branch 'origin/build' into build

This commit is contained in:
aixianling
2022-09-15 16:53:38 +08:00
6 changed files with 93 additions and 41 deletions

View File

@@ -62,7 +62,7 @@
>
删除
</el-button>
<ai-download
<!-- <ai-download
:instance="instance"
url="/app/appgirdinfo/exportGirdInfo"
:params="{ ...searchObj, ids: ids.join(',') }"
@@ -72,7 +72,7 @@
>导出全部
</el-button
>
</ai-download>
</ai-download> -->
<ai-import
ref="import"
title="导入"

View File

@@ -136,6 +136,17 @@
<em>从本地上传图片最大支持10MB支持JPG,PNG格式视频最大支持10MB支持MP4格式文件最大支持20MB</em>
</div>
</el-form-item>
<el-form-item label="结束时间" v-if="params.sendChannel === '1'" style="width: 100%;" prop="taskEndTime" :rules="[{ required: true, message: '请选择结束时间', trigger: 'change' }]">
<el-date-picker
style="width: 100%;"
v-model="form.taskEndTime"
type="datetime"
size="small"
:picker-options="pickerOptions"
value-format="yyyy-MM-dd HH:mm:ss"
placeholder="请选择结束时间">
</el-date-picker>
</el-form-item>
<el-form-item label="宣发审批" prop="enableExamine" style="width: 100%;" :rules="[{ required: true, message: '请输入任务名称', trigger: 'blur' }]">
<el-switch
v-model="form.enableExamine"
@@ -324,6 +335,7 @@ export default {
choiceTime: '',
contents: [],
enableExamine: '0',
taskEndTime: '',
examines: [],
wxGroups: [],
wxGroupsName: '',
@@ -584,9 +596,13 @@ export default {
if (valid) {
if (new Date(this.dateForm.choiceTime).getTime() < Date.now()) {
return this.$message.error('定时发送时间不得早于当前时间')
} else {
this.confirm(1)
}
if (this.params.sendChannel === '1' && new Date(this.dateForm.choiceTime).getTime() > new Date(this.form.taskEndTime).getTime()) {
return this.$message.error('定时发送时间不得晚于结束时间')
}
this.confirm(1)
}
})
},
@@ -598,6 +614,10 @@ export default {
return this.$message.error('居民群数量不能为0')
}
if (this.params.sendChannel === '1' && new Date(this.form.taskEndTime).getTime() < Date.now()) {
return this.$message.error('结束时间不得早于当前时间')
}
if (sendType === 1 && !this.dateForm.choiceTime) {
this.isShowDate = true
return false
@@ -622,6 +642,7 @@ export default {
wxGroups: this.form.wxGroups,
contents,
sendType,
sendChannel: this.params.sendChannel,
choiceTime: this.dateForm.choiceTime,
filterCriteria: this.form.filterCriteria.join(','),
examines: this.form.examines.length ? this.form.examines.map(v => {

View File

@@ -37,8 +37,12 @@
</div>
</div>
</ai-info-item>
<ai-info-item label="发送方式" isLine>
<span>{{ info.sendChannel === '1' ? '通知员工转发' : '成员一键群发' }}</span>
</ai-info-item>
<ai-info-item label="创建时间" :value="info.createTime"></ai-info-item>
<ai-info-item label="群发时间" :value="info.choiceTime"></ai-info-item>
<ai-info-item label="结束时间" :value="info.taskEndTime" v-if="info.sendChannel === '1'"></ai-info-item>
<ai-info-item label="群发范围" isLine>
<div class="text">
<span>{{ info.sendScope === '0' ? '全部' : '按条件筛选的' }}</span>
@@ -95,7 +99,7 @@
</div>
<p>{{ memberInfo.executedCount || 0 }}</p>
</div>
<div class="top-item">
<div class="top-item" v-if="info.sendChannel === '0'">
<div class="top-item__title">
<h3>无法执行成员</h3>
<el-tooltip
@@ -113,7 +117,7 @@
<el-radio-group v-model="search1.sendStatus" size="small" @change="search1.current = 1, getMemberInfo()">
<el-radio-button size="small" label="0">未执行</el-radio-button>
<el-radio-button size="small" label="1">已执行</el-radio-button>
<el-radio-button size="small" label="2">无法执行</el-radio-button>
<el-radio-button size="small" label="2" v-if="info.sendChannel === '0'">无法执行</el-radio-button>
</el-radio-group>
<ai-picker
dialogTitle="选择部门"
@@ -170,7 +174,7 @@
</div>
<p>{{ groupInfo.executedCount || 0 }}</p>
</div>
<div class="top-item">
<div class="top-item" v-if="info.sendChannel === '0'">
<div class="top-item__title">
<h3>无法送达居民群</h3>
</div>
@@ -183,7 +187,7 @@
<el-radio-group v-model="search2.sendStatus" size="small" @change="search2.current = 1, getGroupInfo()">
<el-radio-button size="small" label="0">未送达</el-radio-button>
<el-radio-button size="small" label="1">已送达</el-radio-button>
<el-radio-button size="small" label="2">无法送达</el-radio-button>
<el-radio-button size="small" label="2" v-if="info.sendChannel === '0'">无法送达</el-radio-button>
</el-radio-group>
<ai-picker
dialogTitle="选择部门"

View File

@@ -10,7 +10,7 @@
<template slot="content">
<ai-search-bar class="search-bar">
<template #left>
<el-button size="small" type="primary" icon="iconfont iconAdd" @click="toAdd('')">创建宣发</el-button>
<el-button size="small" type="primary" icon="iconfont iconAdd" @click="isShow = true">创建宣发</el-button>
<ai-select
v-model="search.status"
@change="search.current = 1, getList()"
@@ -75,13 +75,24 @@
<template slot-scope="{ row }">
<div class="table-options">
<el-button type="text" @click="remindExamine(row.id)" v-if="['0'].includes(row.status)">催办</el-button>
<el-button type="text" @click="close(row.id)" v-if="['4'].includes(row.status) && row.sendChannel === '1'">关闭</el-button>
<el-button type="text" @click="cancel(row.id)" v-if="['0'].includes(row.status)">撤回</el-button>
<el-button type="text" @click="toDetail(row.id)">详情</el-button>
<el-button type="text" @click="toAdd(row.id)" v-if="['1', '3'].includes(row.status)">编辑</el-button>
<el-button type="text" @click="toAdd(row.sendChannel, row.id)" v-if="['1', '3'].includes(row.status)">编辑</el-button>
</div>
</template>
</el-table-column>
</ai-table>
<ai-dialog
:visible.sync="isShow"
width="590px"
title="定时发送"
customFooter>
<el-button @click="toAdd('0', '')">成员一键群发</el-button>
<el-button @click="toAdd('1', '')">通知成员群发</el-button>
<div class="dialog-footer" slot="footer">
</div>
</ai-dialog>
</template>
</ai-list>
</template>
@@ -107,6 +118,7 @@
endTime: ''
},
name: '',
isShow: false,
user: [],
tableData: [],
loading: false,
@@ -191,6 +203,17 @@
})
},
close (id) {
this.$confirm('确认关闭该群发任务?').then(() => {
this.instance.post(`/app/appmasssendingtask/closeTask?id=${id}`).then(res => {
if (res.code == 0) {
this.$message.success('关闭成功!')
this.getList()
}
})
})
},
cancel (id) {
this.$confirm('确认撤回该群发任务?').then(() => {
this.instance.post(`/app/appmasssendingtask/cancel?id=${id}`).then(res => {
@@ -213,11 +236,12 @@
})
},
toAdd(id) {
toAdd(type, id) {
this.$emit('change', {
type: 'Add',
params: {
id
id,
sendChannel: type
}
})
},

View File

@@ -552,9 +552,10 @@ export default {
}[type]
let formData = new FormData()
formData.append('file', file.file)
formData.append('type', fileType)
formData.append('attachmentType', 1)
formData.append('mediaType', fileType)
let loading = this.$loading()
this.instance.post(`/app/wxcp/upload/uploadFile`, formData, {
this.instance.post(`/app/wxcp/upload/uploadAttachment`, formData, {
withCredentials: false
}).then(res => {
if (res.code == 0) {

View File

@@ -42,8 +42,8 @@
<ai-info-item label="群发范围" isLine>
<div class="text">
<span>{{ info.sendScope === '0' ? '全部' : '按条件筛选的' }}</span>
<i>{{ groups.length }}</i>
<span>个居民</span>
<i>{{ info.executorList.length }}</i>
<span>个居民</span>
<em @click="isShowGroups = true">详情</em>
</div>
</ai-info-item>
@@ -73,25 +73,25 @@
<div class="top">
<div class="top-item">
<div class="top-item__title">
<h3>计划执行成员</h3>
<h3>预计执行员工</h3>
</div>
<p>{{ memberInfo.planCount || 0 }}</p>
</div>
<div class="top-item">
<div class="top-item__title">
<h3>未执行</h3>
<h3>未执行员</h3>
</div>
<p>{{ memberInfo.unExecutedCount || 0 }}</p>
</div>
<div class="top-item">
<div class="top-item__title">
<h3>已执行</h3>
<h3>已执行员</h3>
</div>
<p>{{ memberInfo.executedCount || 0 }}</p>
</div>
<div class="top-item">
<div class="top-item__title">
<h3>无法执行</h3>
<h3>无法执行员</h3>
<el-tooltip
placement="top"
content="由于员工不在可见范围、离职、客户群接收已达到上限等原因,无法执行群发任务的成员总数">
@@ -151,14 +151,17 @@
width="890px"
title="群发范围"
@onConfirm="isShowGroups = false">
<ai-table
:tableData="info.wxGroups"
:col-configs="colConfigs3"
border
tableSize="small"
:isShowPagination="false"
@getList="() => {}">
</ai-table>
<ai-wrapper>
<ai-info-item label="消息发送" isLine :value="info.taskTitle">
<div class="text">
<span>{{ info.sendScope === '0' ? '全部' : '按条件筛选的' }}</span>
<i>{{ info.executorList.length }}</i>
<span>个居民</span>
</div>
</ai-info-item>
<ai-info-item label="添加人" isLine :value="userNames"></ai-info-item>
<ai-info-item label="标签" isLine>{{ info.filterTagsName || '-' }}</ai-info-item>
</ai-wrapper>
</ai-dialog>
<div class="detail-phone" v-if="isShowPhone">
<div class="mask"></div>
@@ -219,7 +222,8 @@
timer: null,
min: 60,
isDisabled: false,
rejecterId: ''
rejecterId: '',
userNames: ''
}
},
@@ -238,15 +242,15 @@
methods: {
getMemberInfo () {
this.instance.post(`/app/appmasssendingtask/detailStatistics`, null, {
this.instance.post(`/app/whchatmomentstask/detailStatistics`, null, {
params: {
...this.search1,
taskId: this.params.id
}
}).then(res => {
if (res.code === 0) {
this.tableData1 = res.data.executedList.records
this.total1 = res.data.executedList.total
// this.tableData1 = res.data.executedList.records
// this.total1 = res.data.executedList.total
this.memberInfo = res.data
}
})
@@ -264,7 +268,7 @@
},
sendMsg () {
this.instance.post(`/app/appmasssendingtask/remindSend?id=${this.params.id}`).then(res => {
this.instance.post(`/app/whchatmomentstask/remindExamine?id=${this.params.id}`).then(res => {
if (res.code === 0) {
this.$message.success('提醒成功')
this.getInfo(this.params.id)
@@ -288,7 +292,7 @@
},
getInfo (id) {
this.instance.post(`/app/whchatmomentstask/customerTasKDetail?id=${id}`).then(res => {
this.instance.post(`/app/whchatmomentstask/queryDetailById?id=${id}`).then(res => {
if (res.code === 0) {
this.info = res.data
if (res.data.status === '4' && res.data.remindTime) {
@@ -308,15 +312,13 @@
}
})
this.info.wxGroups = res.data.wxGroups.map(v => {
this.groups.push(...v.groupIds.split(','))
return {
...v,
groupIds: v.groupIds.split(',')
}
let userNames = ''
res.data.executorList.forEach(e => {
userNames = e.executorName + userNames
})
this.userNames = res.data.executorList.map(e => e.executorName).join(',')
if (res.data.examines && res.data.examines.length) {
const user = res.data.examines.filter(v => v.examineStatus === '2')