|
|
@ -162,13 +162,17 @@ |
|
|
|
prop="channel" |
|
|
|
label-width="150px" |
|
|
|
style="display: block"> |
|
|
|
<el-checkbox-group v-model="formData.channel"> |
|
|
|
|
|
|
|
<el-checkbox v-model="formData.isSelChannel" |
|
|
|
key="0" |
|
|
|
label="0">小程序通知</el-checkbox> |
|
|
|
<!-- <el-checkbox-group v-model="formData.channel"> |
|
|
|
<el-checkbox key="0" |
|
|
|
label="0">小程序通知</el-checkbox> |
|
|
|
<!-- <el-checkbox key="1" |
|
|
|
label="1">短信通知</el-checkbox> --> |
|
|
|
<el-checkbox key="1" |
|
|
|
label="1">短信通知</el-checkbox> |
|
|
|
|
|
|
|
</el-checkbox-group> |
|
|
|
</el-checkbox-group> --> |
|
|
|
</el-form-item> |
|
|
|
|
|
|
|
<el-form-item label="通知内容" |
|
|
@ -244,6 +248,7 @@ export default { |
|
|
|
natTime: '', |
|
|
|
natAddress: '', |
|
|
|
natResult: '', |
|
|
|
isSelChannel: false, |
|
|
|
channel: [], |
|
|
|
content: '', |
|
|
|
|
|
|
@ -270,7 +275,7 @@ export default { |
|
|
|
methods: { |
|
|
|
|
|
|
|
async initForm (type, icNatId) { |
|
|
|
|
|
|
|
this.startLoading() |
|
|
|
this.formData.agencyId = this.agencyId |
|
|
|
|
|
|
|
this.$refs['ref_form'].resetFields(); |
|
|
@ -284,6 +289,8 @@ export default { |
|
|
|
await this.loadFormData() |
|
|
|
} |
|
|
|
|
|
|
|
this.endLoading() |
|
|
|
|
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
@ -354,7 +361,14 @@ export default { |
|
|
|
const { data, code, msg } = await requestPost(url, params) |
|
|
|
if (code === 0) { |
|
|
|
this.formData = data |
|
|
|
this.formData.channel = [] |
|
|
|
this.formData.content = '' |
|
|
|
this.formData.icNatId = this.icNatId |
|
|
|
if (this.formData.userId) { |
|
|
|
this.isFromResi = true |
|
|
|
} else { |
|
|
|
this.isFromResi = false |
|
|
|
} |
|
|
|
this.fileList = [] |
|
|
|
if (data.fileName) { |
|
|
|
let obj = { |
|
|
@ -401,12 +415,19 @@ export default { |
|
|
|
return false; |
|
|
|
} |
|
|
|
|
|
|
|
if (this.formData.channel.length > 0 && !this.formData.content) { |
|
|
|
if (this.formData.isSelChannel) { |
|
|
|
if (!this.formData.content) { |
|
|
|
this.$message({ |
|
|
|
type: 'warning', |
|
|
|
message: '请填写通知内容' |
|
|
|
}) |
|
|
|
return false; |
|
|
|
} else { |
|
|
|
this.formData.channel = ['0'] |
|
|
|
} |
|
|
|
|
|
|
|
} else { |
|
|
|
this.formData.channel = [] |
|
|
|
} |
|
|
|
|
|
|
|
this.btnDisable = true |
|
|
@ -518,6 +539,7 @@ export default { |
|
|
|
natTime: '', |
|
|
|
natAddress: '', |
|
|
|
natResult: '', |
|
|
|
isSelChannel: false, |
|
|
|
channel: [], |
|
|
|
content: '', |
|
|
|
|
|
|
|