Commit bd70251e by 前端

Merge branch 'chenwq_dev_v2.0.0' into 'v2.0.0'

chenwq_dev_v2.0.0 into v2.0.0

See merge request !42
2 parents 4c106c3e 78676015
...@@ -391,6 +391,8 @@ export default { ...@@ -391,6 +391,8 @@ export default {
}, },
'editForm.object.additionalType'(val) { 'editForm.object.additionalType'(val) {
var idx = this.editFormDataChannel.findIndex(item => item.name == 'pushChannelType') var idx = this.editFormDataChannel.findIndex(item => item.name == 'pushChannelType')
this.editFormDataChannel[idx].optionList[0].isDisabled = val == '4' || !this.condLimitObj.hasQw
this.editFormDataChannel[idx].optionList[1].isDisabled = val == '4' || !this.condLimitObj.hasPhone
if (this.condLimitObj.hasQw) { if (this.condLimitObj.hasQw) {
this.editFormDataChannel[idx].optionList[2].isDisabled = [1, 2, 3].includes(val) this.editFormDataChannel[idx].optionList[2].isDisabled = [1, 2, 3].includes(val)
} }
...@@ -400,16 +402,8 @@ export default { ...@@ -400,16 +402,8 @@ export default {
created() { created() {
this.getDay('weekList', 7) this.getDay('weekList', 7)
this.getDay('monthList', 31) this.getDay('monthList', 31)
console.log(this.condLimitObj) // console.log(this.condLimitObj)
// 有企微 - 企业微信、微信朋友圈 this.limitQwPhone()
// 有手机号 - 短信
var channelIdx = this.editFormDataChannel.findIndex(item => item.name == 'pushChannelType')
// 企微
this.editFormDataChannel[channelIdx].optionList[0].isDisabled = !this.condLimitObj.hasQw
// 短信
this.editFormDataChannel[channelIdx].optionList[1].isDisabled = !this.condLimitObj.hasPhone
// 微信朋友圈
this.editFormDataChannel[channelIdx].optionList[2].isDisabled = !this.condLimitObj.hasQw
}, },
mounted() { mounted() {
...@@ -426,6 +420,18 @@ export default { ...@@ -426,6 +420,18 @@ export default {
}, },
methods: { methods: {
limitQwPhone() {
// 有企微 - 企业微信、微信朋友圈
// 有手机号 - 短信
var channelIdx = this.editFormDataChannel.findIndex(item => item.name == 'pushChannelType')
// 企微
this.editFormDataChannel[channelIdx].optionList[0].isDisabled = !this.condLimitObj.hasQw
// 短信
this.editFormDataChannel[channelIdx].optionList[1].isDisabled = !this.condLimitObj.hasPhone
// 微信朋友圈
this.editFormDataChannel[channelIdx].optionList[2].isDisabled = !this.condLimitObj.hasQw
},
getDay(attrName, day) { getDay(attrName, day) {
let weekNameList = ['一', '二', '三', '四', '五', '六', '日'] let weekNameList = ['一', '二', '三', '四', '五', '六', '日']
for (var i = 0; i < day; i++) { for (var i = 0; i < day; i++) {
...@@ -619,7 +625,7 @@ export default { ...@@ -619,7 +625,7 @@ export default {
.then(() => { .then(() => {
this.cancelJump() this.cancelJump()
}) })
.catch(() => {}) .catch(() => { })
} else { } else {
this.cancelJump() this.cancelJump()
} }
......
...@@ -109,12 +109,15 @@ export default { ...@@ -109,12 +109,15 @@ export default {
label: '初次查看事件', label: '初次查看事件',
prop: 'firstViewDate', prop: 'firstViewDate',
formatter: cellValue => { formatter: cellValue => {
return dayjs(cellValue.firstViewDate).format('YYYY-MM-DD HH:mm:ss') || '未查看' return cellValue.firstViewDate ? dayjs(cellValue.firstViewDate).format('YYYY-MM-DD HH:mm:ss') : '未查看'
} }
}, },
{ {
label: '查看次数', label: '查看次数',
prop: 'viewCount' prop: 'viewCount',
formatter: cellValue => {
return cellValue.viewCount || '-'
}
} }
] ]
}, },
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!