2022-07-12 18:10:42 +08:00
|
|
|
|
<template>
|
2022-07-15 16:43:41 +08:00
|
|
|
|
<div class="AppCooperationPropaganda">
|
2022-07-13 14:35:20 +08:00
|
|
|
|
<AiTopFixed>
|
|
|
|
|
|
<div class="search">
|
|
|
|
|
|
<div class="searchBox">
|
2022-07-15 13:52:11 +08:00
|
|
|
|
<u-search placeholder="请输入任务名称" v-model="taskTitle" @search="searchBtn" @clear="taskTitle='',current=1, list=[],getList()" :show-action="false"></u-search>
|
2022-07-13 14:35:20 +08:00
|
|
|
|
</div>
|
2022-07-15 10:44:31 +08:00
|
|
|
|
<div class="filterBtn" @click="filterShow = true"><img src="./images/shaixuan.png" alt="">筛选</div>
|
2022-07-13 14:35:20 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
</AiTopFixed>
|
2022-07-15 13:52:11 +08:00
|
|
|
|
<div class="resident_list" v-if="list.length">
|
2022-07-15 14:48:27 +08:00
|
|
|
|
<div class="card" @click="toDetail(item)" v-for="(item,index) in list" :key="index">
|
2022-07-13 14:35:20 +08:00
|
|
|
|
<div class="card_title">
|
2022-07-15 13:52:11 +08:00
|
|
|
|
<div class="card_left">{{ item.taskTitle }}</div>
|
|
|
|
|
|
<div class="card_right"><span :class="item.status==0? 'status0': item.status==1? 'status1': item.status==2? 'status2':
|
|
|
|
|
|
item.status == 3? 'status3':item.status==4? 'status4': 'status5'"></span>{{ $dict.getLabel('mstStatus', item.status) }}</div>
|
2022-07-13 14:35:20 +08:00
|
|
|
|
</div>
|
2022-07-14 15:40:57 +08:00
|
|
|
|
<div>创建时间:<span>{{ item.createTime }}</span></div>
|
2022-07-20 17:00:46 +08:00
|
|
|
|
<div>共需<span class="num">{{ item.groupOwnerCount || 0 }}</span>名成员完成群发,目前已完成<span class="num">{{ item.completionRate || 0 }}%</span></div>
|
|
|
|
|
|
<div>
|
|
|
|
|
|
创建部门:
|
|
|
|
|
|
<span v-if="item.createUserId">/<AiOpenData type="departmentName" :openid="item.createUserId" style="display: inline-block" /></span>
|
|
|
|
|
|
<span v-if="item.createUserSecondDept">/<AiOpenData type="departmentName" :openid="item.createUserSecondDept" style="display: inline-block" /></span>
|
|
|
|
|
|
</div>
|
2022-07-13 14:35:20 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
2022-07-15 13:52:11 +08:00
|
|
|
|
<AiEmpty description="暂无数据" v-if="!list.length"/>
|
2022-07-15 10:44:31 +08:00
|
|
|
|
<u-popup v-model="filterShow" mode="bottom" border-radius="14">
|
|
|
|
|
|
<div class="popup">
|
|
|
|
|
|
<div class="tips"></div>
|
|
|
|
|
|
<div class="title">
|
|
|
|
|
|
<div
|
|
|
|
|
|
class="cancel"
|
|
|
|
|
|
@click.stop="(filterShow = false), (timeSelect = 0)"
|
|
|
|
|
|
>
|
|
|
|
|
|
取消
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<p>筛选条件</p>
|
|
|
|
|
|
<div class="confirm" @click.stop="selectConfirm">确定</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<scroll-view class="select-content" scroll-y="true">
|
|
|
|
|
|
<div class="type-list">
|
|
|
|
|
|
<div class="type-title">创建人</div>
|
2022-07-20 17:00:46 +08:00
|
|
|
|
<AiPagePicker type="custom" :selected.sync="userIdList" nodeKey="userId" :ops="{url:`./selectUser`,label: 'id'}">
|
|
|
|
|
|
<span class="label" v-if="userIdList.length">已选择</span>
|
|
|
|
|
|
<span v-else style="color:#999;">请选择</span>
|
|
|
|
|
|
<u-icon name="arrow-right" color="#999" size="24" style="margin-left:8px;"/>
|
|
|
|
|
|
</AiPagePicker>
|
2022-07-15 10:44:31 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
<div class="type-list">
|
|
|
|
|
|
<div class="type-title">群发时间</div>
|
|
|
|
|
|
<div class="item">
|
|
|
|
|
|
<div>开始时间</div>
|
|
|
|
|
|
<div style="display: flex;">
|
|
|
|
|
|
<u-input v-model="startTime" disabled placeholder="请选择开始时间" @click="showStart = true" />
|
|
|
|
|
|
<u-icon name="arrow-right"></u-icon>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<div class="item">
|
|
|
|
|
|
<div>结束时间</div>
|
|
|
|
|
|
<div style="display: flex;">
|
|
|
|
|
|
<u-input v-model="endTime" disabled placeholder="请选择开始时间" @click="showEnd = true" />
|
|
|
|
|
|
<u-icon name="arrow-right"></u-icon>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</scroll-view>
|
|
|
|
|
|
<u-picker mode="time" v-model="showStart" @confirm="confirmStart"></u-picker>
|
|
|
|
|
|
<u-picker mode="time" v-model="showEnd" @confirm="confirmEnd"></u-picker>
|
|
|
|
|
|
<div class="popBtn">
|
|
|
|
|
|
<div @click="reset">重置</div>
|
|
|
|
|
|
<div @click="selectConfirm">确认</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</u-popup>
|
2022-07-13 14:35:20 +08:00
|
|
|
|
</div>
|
2022-07-12 18:10:42 +08:00
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
|
|
export default {
|
2022-07-15 16:43:41 +08:00
|
|
|
|
name: 'AppCooperationPropaganda',
|
|
|
|
|
|
appName: '协同宣发',
|
2022-07-12 18:10:42 +08:00
|
|
|
|
data() {
|
|
|
|
|
|
return {
|
|
|
|
|
|
current: 1,
|
2022-07-14 15:40:57 +08:00
|
|
|
|
name: '',
|
|
|
|
|
|
list: [],
|
2022-07-15 10:44:31 +08:00
|
|
|
|
filterShow: false,
|
|
|
|
|
|
startTime: '',
|
|
|
|
|
|
endTime: '',
|
2022-07-15 13:52:11 +08:00
|
|
|
|
start: "",
|
|
|
|
|
|
end: "",
|
2022-07-15 10:44:31 +08:00
|
|
|
|
showStart: false,
|
|
|
|
|
|
showEnd: false,
|
2022-07-15 13:52:11 +08:00
|
|
|
|
taskTitle: '',
|
2022-07-20 17:00:46 +08:00
|
|
|
|
userId: '',
|
|
|
|
|
|
userList: [],
|
|
|
|
|
|
userIdList: []
|
2022-07-12 18:10:42 +08:00
|
|
|
|
}
|
|
|
|
|
|
},
|
2022-07-13 16:59:58 +08:00
|
|
|
|
methods: {
|
2022-07-15 14:48:27 +08:00
|
|
|
|
toDetail(item) {
|
2022-07-15 16:43:41 +08:00
|
|
|
|
uni.navigateTo({url: `./cooperationDetail?id=${item.id}&time=${item.createTime}`})
|
2022-07-14 15:40:57 +08:00
|
|
|
|
},
|
2022-07-15 13:52:11 +08:00
|
|
|
|
searchBtn() {
|
|
|
|
|
|
this.current = 1
|
|
|
|
|
|
this.list = [],
|
|
|
|
|
|
this.getList()
|
|
|
|
|
|
},
|
2022-07-14 15:40:57 +08:00
|
|
|
|
getList() {
|
|
|
|
|
|
this.$http.post(`/app/appmasssendingtask/list`, null, {
|
|
|
|
|
|
params: {
|
|
|
|
|
|
current: this.current,
|
2022-07-15 13:52:11 +08:00
|
|
|
|
taskTitle: this.taskTitle,
|
2022-07-20 17:00:46 +08:00
|
|
|
|
createUserId: this.userId,
|
2022-07-15 13:52:11 +08:00
|
|
|
|
startTime: this.start,
|
|
|
|
|
|
endTime: this.end,
|
2022-07-14 15:40:57 +08:00
|
|
|
|
}
|
|
|
|
|
|
}).then(res=> {
|
|
|
|
|
|
if(res?.data) {
|
|
|
|
|
|
this.list = this.current == 1? res.data.records : [...res.data.records, ...this.list]
|
|
|
|
|
|
}
|
|
|
|
|
|
})
|
2022-07-15 10:44:31 +08:00
|
|
|
|
},
|
2022-07-18 11:35:11 +08:00
|
|
|
|
|
2022-07-15 10:44:31 +08:00
|
|
|
|
reset() {
|
|
|
|
|
|
this.startTime = '',
|
2022-07-20 17:00:46 +08:00
|
|
|
|
this.endTime = '',
|
|
|
|
|
|
this.userIdList = []
|
2022-07-25 09:11:26 +08:00
|
|
|
|
uni.clearStorageSync('userSelect')
|
2022-07-15 10:44:31 +08:00
|
|
|
|
},
|
2022-07-25 09:11:26 +08:00
|
|
|
|
|
2022-07-15 13:52:11 +08:00
|
|
|
|
selectConfirm() {
|
2022-07-22 17:40:34 +08:00
|
|
|
|
if(this.userIdList.length) {
|
|
|
|
|
|
this.userId = this.userIdList[0].userId
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// let arr = this.userIdList
|
|
|
|
|
|
// console.log(arr[0],222);
|
|
|
|
|
|
// console.log(this.userIdList,111);
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-07-15 13:52:11 +08:00
|
|
|
|
this.start = this.startTime,
|
|
|
|
|
|
this.end = this.endTime
|
2022-07-18 11:35:11 +08:00
|
|
|
|
let startTmp = this.start.split("-");
|
|
|
|
|
|
let endTmp = this.end.split("-");
|
|
|
|
|
|
let stT = new Date(startTmp[0], startTmp[1], startTmp[2]);
|
|
|
|
|
|
let edT = new Date(endTmp[0], endTmp[1], endTmp[2]);
|
|
|
|
|
|
if (stT.getTime() >= edT.getTime()) {
|
|
|
|
|
|
this.$u.toast("开始日期不能大于或等于结束日期!");
|
|
|
|
|
|
this.filterShow = true
|
|
|
|
|
|
return
|
|
|
|
|
|
}
|
2022-07-15 13:52:11 +08:00
|
|
|
|
this.filterShow = false
|
|
|
|
|
|
this.getList()
|
|
|
|
|
|
},
|
2022-07-15 10:44:31 +08:00
|
|
|
|
confirmStart(val) {
|
|
|
|
|
|
this.startTime = val.year + '-' + val.month + '-' + val.day
|
|
|
|
|
|
},
|
|
|
|
|
|
confirmEnd(val) {
|
|
|
|
|
|
this.endTime = val.year + '-' + val.month + '-' + val.day
|
|
|
|
|
|
},
|
2022-07-13 16:59:58 +08:00
|
|
|
|
},
|
2022-07-13 14:35:20 +08:00
|
|
|
|
onShow() {
|
|
|
|
|
|
document.title = '群发居民群'
|
2022-07-22 17:40:34 +08:00
|
|
|
|
this.getList()
|
2022-07-15 13:52:11 +08:00
|
|
|
|
this.$dict.load('mstStatus').then(() => {
|
|
|
|
|
|
this.getList()
|
|
|
|
|
|
})
|
|
|
|
|
|
|
2022-07-13 14:35:20 +08:00
|
|
|
|
},
|
2022-07-12 18:10:42 +08:00
|
|
|
|
onReachBottom() {
|
|
|
|
|
|
this.current ++
|
2022-07-15 10:44:31 +08:00
|
|
|
|
this.getList()
|
2022-07-12 18:10:42 +08:00
|
|
|
|
},
|
|
|
|
|
|
}
|
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
|
|
<style lang="scss" scoped>
|
2022-07-15 16:43:41 +08:00
|
|
|
|
.AppCooperationPropaganda {
|
2022-07-13 14:35:20 +08:00
|
|
|
|
.search {
|
|
|
|
|
|
display: flex;
|
|
|
|
|
|
height: 80px;
|
|
|
|
|
|
align-items: center;
|
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
|
|
|
|
|
|
|
.searchBox {
|
|
|
|
|
|
width: 562px;
|
|
|
|
|
|
}
|
|
|
|
|
|
.filterBtn {
|
2022-07-14 15:40:57 +08:00
|
|
|
|
img {
|
|
|
|
|
|
width: 28px;
|
|
|
|
|
|
height: 28px;
|
|
|
|
|
|
}
|
2022-07-13 14:35:20 +08:00
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
.resident_list {
|
|
|
|
|
|
padding: 24px 32px 20px 32px;
|
|
|
|
|
|
box-sizing: border-box;
|
|
|
|
|
|
.card {
|
|
|
|
|
|
background: #FFF;
|
|
|
|
|
|
border-radius: 16px;
|
|
|
|
|
|
padding: 30px;
|
2022-07-14 15:40:57 +08:00
|
|
|
|
margin-bottom: 24px;
|
2022-07-13 14:35:20 +08:00
|
|
|
|
& > div {
|
|
|
|
|
|
padding: 10px 0;
|
|
|
|
|
|
}
|
|
|
|
|
|
.num {
|
|
|
|
|
|
color: #3AA0FF;
|
|
|
|
|
|
}
|
|
|
|
|
|
.card_title {
|
|
|
|
|
|
display: flex;
|
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
|
.card_left {
|
|
|
|
|
|
font-size: 32px;
|
|
|
|
|
|
color: #000000;
|
|
|
|
|
|
font-weight: 600;
|
|
|
|
|
|
}
|
|
|
|
|
|
.card_right {
|
|
|
|
|
|
span {
|
|
|
|
|
|
display: inline-block;
|
|
|
|
|
|
width: 16px;
|
|
|
|
|
|
height: 16px;
|
2022-07-15 13:52:11 +08:00
|
|
|
|
// background: #3399FF;
|
2022-07-13 14:35:20 +08:00
|
|
|
|
border-radius: 50%;
|
|
|
|
|
|
margin-right: 10px;
|
|
|
|
|
|
}
|
2022-07-15 13:52:11 +08:00
|
|
|
|
|
|
|
|
|
|
.status0 {
|
|
|
|
|
|
background: #3399FF;
|
|
|
|
|
|
}
|
|
|
|
|
|
.status1 {
|
|
|
|
|
|
background: #FFA938;
|
|
|
|
|
|
}
|
|
|
|
|
|
.status2 {
|
|
|
|
|
|
background: #3399FF;
|
|
|
|
|
|
}
|
|
|
|
|
|
.status3 {
|
|
|
|
|
|
background: #1CCEB0;
|
|
|
|
|
|
}
|
|
|
|
|
|
.status4 {
|
|
|
|
|
|
background: #FF6758;
|
|
|
|
|
|
}
|
|
|
|
|
|
.status5 {
|
|
|
|
|
|
background: #FF6758;
|
|
|
|
|
|
}
|
|
|
|
|
|
.status6 {
|
|
|
|
|
|
background: #999999;
|
|
|
|
|
|
}
|
2022-07-13 14:35:20 +08:00
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
2022-07-15 10:44:31 +08:00
|
|
|
|
.popup {
|
|
|
|
|
|
box-sizing: border-box;
|
|
|
|
|
|
// height: 800px;
|
|
|
|
|
|
.tips {
|
|
|
|
|
|
width: 80px;
|
|
|
|
|
|
height: 6px;
|
|
|
|
|
|
background: #dddddd;
|
|
|
|
|
|
border-radius: 4px;
|
|
|
|
|
|
padding: 0 32px;
|
|
|
|
|
|
box-sizing: border-box;
|
|
|
|
|
|
margin: 32px auto 8px auto;
|
|
|
|
|
|
}
|
|
|
|
|
|
.title {
|
|
|
|
|
|
height: 48px;
|
|
|
|
|
|
line-height: 48px;
|
|
|
|
|
|
font-size: 34px;
|
|
|
|
|
|
font-family: PingFangSC-Medium, PingFang SC;
|
|
|
|
|
|
font-weight: 500;
|
|
|
|
|
|
color: #222;
|
|
|
|
|
|
padding: 0 32px;
|
|
|
|
|
|
box-sizing: border-box;
|
|
|
|
|
|
padding-bottom: 32px;
|
|
|
|
|
|
.cancel {
|
|
|
|
|
|
display: inline-block;
|
|
|
|
|
|
width: 200px;
|
|
|
|
|
|
color: #aaa;
|
|
|
|
|
|
}
|
|
|
|
|
|
.confirm {
|
|
|
|
|
|
display: inline-block;
|
|
|
|
|
|
width: 200px;
|
|
|
|
|
|
text-align: right;
|
|
|
|
|
|
color: #333;
|
|
|
|
|
|
}
|
|
|
|
|
|
p {
|
|
|
|
|
|
display: inline-block;
|
|
|
|
|
|
width: calc(100% - 400px);
|
|
|
|
|
|
text-align: center;
|
|
|
|
|
|
font-size: 28px;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
.select-content {
|
|
|
|
|
|
height: calc(100% - 100px);
|
|
|
|
|
|
overflow-y: scroll;
|
|
|
|
|
|
}
|
|
|
|
|
|
.type-list {
|
|
|
|
|
|
padding: 0 32px;
|
|
|
|
|
|
box-sizing: border-box;
|
|
|
|
|
|
margin-bottom: 32px;
|
|
|
|
|
|
.type-title {
|
|
|
|
|
|
line-height: 108px;
|
|
|
|
|
|
font-size: 32px;
|
|
|
|
|
|
font-family: PingFangSC-Medium, PingFang SC;
|
|
|
|
|
|
font-weight: 500;
|
|
|
|
|
|
color: #333;
|
|
|
|
|
|
}
|
|
|
|
|
|
.item {
|
|
|
|
|
|
display: flex;
|
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
|
& > div:last-child {
|
|
|
|
|
|
::v-deep .uni-input-input,
|
|
|
|
|
|
::v-deep .uni-input-placeholder {
|
|
|
|
|
|
text-align: right;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
.active {
|
|
|
|
|
|
background: #1365dd;
|
|
|
|
|
|
color: #fff;
|
|
|
|
|
|
}
|
2022-07-20 17:00:46 +08:00
|
|
|
|
.user {
|
|
|
|
|
|
display: flex;
|
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
|
}
|
2022-07-15 10:44:31 +08:00
|
|
|
|
}
|
|
|
|
|
|
.popBtn {
|
|
|
|
|
|
display: flex;
|
|
|
|
|
|
height: 98px;
|
|
|
|
|
|
line-height: 98px;
|
|
|
|
|
|
div {
|
|
|
|
|
|
width: 50%;
|
|
|
|
|
|
border: 2px solid #3399ff;
|
|
|
|
|
|
text-align: center;
|
|
|
|
|
|
}
|
|
|
|
|
|
div:first-child {
|
|
|
|
|
|
color: #3399ff;
|
|
|
|
|
|
}
|
|
|
|
|
|
div:last-child {
|
|
|
|
|
|
color: #fff;
|
|
|
|
|
|
background: #3399ff;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2022-07-15 13:52:11 +08:00
|
|
|
|
|
|
|
|
|
|
|
2022-07-13 14:35:20 +08:00
|
|
|
|
}
|
2022-07-12 18:10:42 +08:00
|
|
|
|
</style>
|