Commit 1c148811 by xuyl

更新联调内容,优化样式以及门店下拉搜索框

1 parent 9c923e39
...@@ -33,7 +33,7 @@ const batchmessagingRecord = params => { ...@@ -33,7 +33,7 @@ const batchmessagingRecord = params => {
}) })
} }
// 企微群发查看预计群发人数 // 企微群发查看预计群发人数
const atchmessagingCustomercount = params => { const batchmessagingCustomercount = params => {
params.method = 'entmicro.api.wechatcloudcontrol.batchmessaging.customercount' params.method = 'entmicro.api.wechatcloudcontrol.batchmessaging.customercount'
return http({ return http({
url: URL, url: URL,
...@@ -49,7 +49,8 @@ const atchmessagingCreate = params => { ...@@ -49,7 +49,8 @@ const atchmessagingCreate = params => {
url: URL, url: URL,
method: 'POST', method: 'POST',
data: params, data: params,
sign: true sign: true,
returnAll:true
}) })
} }
const getStoreList = params => { const getStoreList = params => {
...@@ -71,14 +72,13 @@ const recordSend = params => { ...@@ -71,14 +72,13 @@ const recordSend = params => {
}) })
} }
// 企微高级群发查看预计群发人数
export default { export default {
querylabeltree, querylabeltree,
queryCrowdtree, queryCrowdtree,
batchmessagingRecord, batchmessagingRecord,
atchmessagingCustomercount, batchmessagingCustomercount,
atchmessagingCreate, atchmessagingCreate,
getStoreList, getStoreList,
recordSend recordSend
......
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
</div> </div>
</GLTable> </GLTable>
<GLDialog :title="'授权登入二维码'" mode="small" :visible.sync="qrCodeVisible"> <GLDialog :title="'授权登入二维码'" mode="small" :visible.sync="qrCodeVisible">
<div class="qrIMGbox"> <div v-loading="addLoading" class="qrIMGbox">
<img class="qrIMG" :src="qrcodeUrl" /> <img class="qrIMG" :src="qrcodeUrl" />
</div> </div>
<span slot="footer" class="dialog-footer"> <span slot="footer" class="dialog-footer">
...@@ -40,6 +40,8 @@ export default { ...@@ -40,6 +40,8 @@ export default {
data() { data() {
return { return {
url, url,
verifyQRCodeFailsToOpen: false,
addLoading: false,
qrcodeUrl: '', qrcodeUrl: '',
qrCodeVisible: false, qrCodeVisible: false,
qrcodeId: '', qrcodeId: '',
...@@ -130,40 +132,48 @@ export default { ...@@ -130,40 +132,48 @@ export default {
//接收到的数据为空 //接收到的数据为空
this.$refs.activeTable.data.length ? (this.$refs.activeTable.tableHeightValues = '') : this.$refs.activeTable.setTableHeightFun() this.$refs.activeTable.data.length ? (this.$refs.activeTable.tableHeightValues = '') : this.$refs.activeTable.setTableHeightFun()
}, },
handleqrCode() { async handleqrCode() {
this.addLoading = true
this.qrCodeVisible = true this.qrCodeVisible = true
// this.$apis.collocation await this.$apis.collocation
// .getLoginQcCode({}) .getLoginQcCode({})
// .then(res => { .then(res => {
// if (res.code == '-1') { this.addLoading = false
// this.qrCodeVisible = false ;(this.verifyQRCodeFailsToOpen = true), (this.qrcodeUrl = `data:image/png;base64,${res.qcCodeUrl}`)
// } else { this.qrcodeId = res.id
// this.qrcodeUrl = `data:image/png;base64,${res.data}` })
// this.this.qrcodeId = res.id .catch(err => {
// this.qrCodeVisible = true this.qrCodeVisible = false
// } })
// })
// .catch(err => {
// this.qrCodeVisible = false
// })
}, },
verifyQRCodeIsInvalid() { verifyQRCodeIsInvalid() {
this.qrCodeInterval = setInterval(() => { this.qrCodeInterval = setInterval(() => {
// this.$apis.collocation.getQcCodeDetail({ id: this.qrcodeId }).then(res => { this.$apis.collocation.getQcCodeDetail({ id: this.qrcodeId }).then(res => {
// if (res && res.data == true) { if (res == true) {
// return this.$message({
// } else { type: 'error',
// } message: '二维码已失效,请刷新'
// }) })
this.verifyQRCodeFailsToOpen = false
clearInterval(this.qrCodeInterval)
return
}
})
}, 3000000) }, 3000000)
}, },
refreshQrcode() { refreshQrcode() {
this.handleqrCode() this.handleqrCode()
} }
}, },
computed: {
listenChange() {
const { verifyQRCodeFailsToOpen, qrCodeVisible } = this
return { verifyQRCodeFailsToOpen, qrCodeVisible }
}
},
watch: { watch: {
qrCodeVisible(newVal) { listenChange(val) {
if (newVal == true) { if (val.qrCodeVisible == true && val.verifyQRCodeFailsToOpen == true) {
this.verifyQRCodeIsInvalid() this.verifyQRCodeIsInvalid()
} else { } else {
clearInterval(this.qrCodeInterval) clearInterval(this.qrCodeInterval)
......
...@@ -15,15 +15,14 @@ ...@@ -15,15 +15,14 @@
</div> </div>
</div> </div>
<div slot="sendState" slot-scope="scope"> <div slot="sendState" slot-scope="scope">
<div class="loginStatus" v-if="scope.scope.sendState"> <div class="loginStatus">
<span class="cycle" :style="{ background: scope.scope.sendState == '1' ? '#2CCA74' : scope.scope.sendState == '2' ? '#EB4E4E' : scope.scope.sendState == '0' ? '#FDB757' : '' }"></span> <span class="cycle" :style="{ background: scope.scope.sendState == '1' ? '#2CCA74' : scope.scope.sendState == '2' ? '#EB4E4E' : scope.scope.sendState == '0' ? '#FDB757' : '' }"></span>
{{ scope.scope.sendState == '1' ? '已完成' : scope.scope.sendState == '2' ? '发送失败' : scope.scope.sendState == '0' ? '发送中' : '' }} {{ scope.scope.sendState == '1' ? '已完成' : scope.scope.sendState == '2' ? '发送失败' : scope.scope.sendState == '0' ? '发送中' : '' }}
</div> </div>
<div v-else>--</div>
</div> </div>
</GLTable> </GLTable>
</div> </div>
<el-drawer size="40%" title="发送记录" :visible.sync="sendRecordDrawer.isVisible" :direction="sendRecordDrawer.direction"> <el-drawer size="50%" title="发送记录" :visible.sync="sendRecordDrawer.isVisible" :direction="sendRecordDrawer.direction">
<div class="horizon"></div> <div class="horizon"></div>
<div class="sendRecordDrawerbox"> <div class="sendRecordDrawerbox">
<div v-for="(item, index) in sendRecordDrawer.traceFailandSuccess" :key="index" class="itemContent"> <div v-for="(item, index) in sendRecordDrawer.traceFailandSuccess" :key="index" class="itemContent">
...@@ -33,7 +32,14 @@ ...@@ -33,7 +32,14 @@
</div> </div>
</div> </div>
</div> </div>
<GLTable ref="sendRecordDrawerRef" :noDataImg="url" :getListApi="sendRecordDrawer.getListApi" :searchForm="sendRecordDrawer.searchForm" :tableParams="sendRecordDrawer.tableParams" :pageConf="sendRecordDrawer.pageConf"></GLTable> <GLTable ref="sendRecordDrawerRef" :noDataImg="url" :getListApi="sendRecordDrawer.getListApi" :searchForm="sendRecordDrawer.searchForm" :tableParams="sendRecordDrawer.tableParams" :pageConf="sendRecordDrawer.pageConf">
<div slot="sendResult" slot-scope="scope">
<div class="loginStatus">
<span class="cycle" :style="{ background: scope.scope.sendResult == true ? '#2CCA74' : scope.scope.sendResult == false ? '#EB4E4E' : '' }"></span>
{{ scope.scope.sendResult == true ? '成功' : scope.scope.sendResult == false ? '失败' : '' }}
</div>
</div>
</GLTable>
</el-drawer> </el-drawer>
</div> </div>
</template> </template>
...@@ -63,7 +69,7 @@ export default { ...@@ -63,7 +69,7 @@ export default {
} }
], ],
searchForm: { searchForm: {
messagingId: '' msgId: ''
}, },
tableParams: { tableParams: {
listName: 'data', listName: 'data',
...@@ -78,18 +84,19 @@ export default { ...@@ -78,18 +84,19 @@ export default {
}, },
{ {
label: '发送结果', label: '发送结果',
prop: 'sendResult' prop: 'sendResult',
addHtml: 'sendResult'
} }
] ]
}, },
getListApi: this.$apis.wechatGroup.recordSend, getListApi: this.$apis.wechatGroup.recordSend,
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' } pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'count' }
}, },
searchForm: {}, searchForm: {},
searchFormData: [ searchFormData: [
{ {
label: '群发名称', label: '群发名称',
name: 'messagingName', name: 'msgName',
type: 'input', type: 'input',
isClear: true isClear: true
}, },
...@@ -107,7 +114,7 @@ export default { ...@@ -107,7 +114,7 @@ export default {
}, },
{ {
label: '群发门店', label: '群发门店',
name: 'merchantName', name: 'msgMerchantName',
type: 'input', type: 'input',
isClear: true isClear: true
} }
...@@ -130,7 +137,10 @@ export default { ...@@ -130,7 +137,10 @@ export default {
}, },
{ {
label: '标签/人群', label: '标签/人群',
prop: 'labelCrowdName' prop: 'labelCrowdName',
width: 170,
// addHtml: 'labelCrowdName',
line: 1
}, },
{ {
label: '创建时间', label: '创建时间',
...@@ -202,11 +212,10 @@ export default { ...@@ -202,11 +212,10 @@ export default {
const { msgId, successCompletion, failCompletion } = scope const { msgId, successCompletion, failCompletion } = scope
this.sendRecordDrawer.traceFailandSuccess[0].num = successCompletion this.sendRecordDrawer.traceFailandSuccess[0].num = successCompletion
this.sendRecordDrawer.traceFailandSuccess[1].num = failCompletion this.sendRecordDrawer.traceFailandSuccess[1].num = failCompletion
this.sendRecordDrawer.searchForm.messagingId = msgId this.sendRecordDrawer.searchForm.msgId = msgId
// await this.$refs.sendRecordDrawerRef.refreshTable()
this.sendRecordDrawer.isVisible = true this.sendRecordDrawer.isVisible = true
this.$nextTick(() => { this.$nextTick(() => {
this.$refs.sendRecordDrawerRef.refreshTable() this.$refs.sendRecordDrawerRef.refreshTable()
}) })
} }
} }
...@@ -214,6 +223,17 @@ export default { ...@@ -214,6 +223,17 @@ export default {
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.loginStatus {
display: flex;
align-items: center;
.cycle {
margin-right: 8px;
width: 6px;
height: 6px;
display: inline-block;
border-radius: 50%;
}
}
.createANewGroupBtn { .createANewGroupBtn {
margin-bottom: 16px; margin-bottom: 16px;
} }
...@@ -259,9 +279,9 @@ export default { ...@@ -259,9 +279,9 @@ export default {
.sendRecordDrawerbox { .sendRecordDrawerbox {
padding: 20px; padding: 20px;
display: flex; display: flex;
justify-content: space-around; justify-content: space-between;
.itemContent { .itemContent {
width: 334px; width: 46%;
padding: 8px 0 8px 20px; padding: 8px 0 8px 20px;
border: 1px solid #e8e8ea; border: 1px solid #e8e8ea;
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!