| | |
| | | <el-form-item class="optionItem" label="短信模板:" prop="messageType"> |
| | | <div class="message-item"> |
| | | <div class="message-item__left"> |
| | | <el-select v-model="role.messageType" placeholder="请选择短信模板"> |
| | | <el-select v-model="role.messageType" placeholder="请选择短信模板" @change="setTemplateValue"> |
| | | <el-option v-for="item in colList" :key="item.id" :label="item.title" |
| | | :value="item.id"> |
| | | </el-option> |
| | |
| | | { required: true, trigger: "blur", message: '请输入短信标题' }, |
| | | ], |
| | | targetTo: [ |
| | | { required: true , trigger: "blur", message: '请选择接收人' }, |
| | | { required: true , trigger: "blur", message: '请选择接收对象' }, |
| | | ], |
| | | body: [ |
| | | { required: true, trigger: ['blur', 'change'], validator: validateMessageContent } |
| | |
| | | }, |
| | | // 选中id |
| | | handleCheck(data, node) { |
| | | this.checkedList = [] |
| | | node.checkedNodes.forEach(item => { |
| | | if(!item.hasOwnProperty('departType')){ |
| | | this.checkedList.push(item.id) |
| | |
| | | sendMessage(params) |
| | | .then(() => { |
| | | this.$message({ type: 'success', message: '操作成功' }); |
| | | this.$emit('closeDialog'); |
| | | this.$emit('closeMyDialog'); |
| | | }) |
| | | .catch(err => this.$message({ type: 'error', message: err })); |
| | | } else { |
| | | this.$message.warning('请检查必填项'); |
| | | } |
| | | }) |
| | | }, |
| | | setTemplateValue(obj){ |
| | | var _this=this |
| | | SMS.getSMSTemplateById(obj).then((result) =>{ |
| | | _this.role.head=result.title |
| | | _this.role.body=result.body |
| | | _this.$refs.edit.editor.txt.html(result.body) |
| | | }) |
| | | }, |
| | | // 重置表单 |
| | |
| | | url: 'sccg/admin/info?name=' + name, |
| | | }) |
| | | .then(res => { |
| | | this.role.targetFrom = res.data.userId |
| | | this.sendUser = res.data.username |
| | | this.role.targetFrom = res.data.userId; |
| | | this.sendUser = res.data.username; |
| | | }) |
| | | } |
| | | } |
| | |
| | | <style lang="scss" scoped> |
| | | .createUser { |
| | | border-radius: 1px; |
| | | background-color: #09152f; |
| | | background-color: white; |
| | | |
| | | main { |
| | | text-align: left; |
| | | background-color: #09152f; |
| | | background-color: white; |
| | | padding-bottom: 50px; |
| | | |
| | | .mainContent { |
| | | display: flex; |
| | | justify-content: center; |
| | | padding-top: 50px; |
| | | &:deep(.el-dialog__title) { |
| | | color: #4b9bb7; |
| | | } |
| | | &::v-deep .el-form-item__label { |
| | | color: #4b9bb7; |
| | | } |
| | | |
| | | &::v-deep .el-input__inner { |
| | | width: 400px; |
| | | background-color: #09152f; |
| | | border: 1px solid #17324c; |
| | | } |
| | | //&:deep(.el-dialog__title) { |
| | | // color: #4b9bb7; |
| | | //} |
| | | //&::v-deep .el-form-item__label { |
| | | // color: #4b9bb7; |
| | | //} |
| | | // |
| | | //&::v-deep .el-input__inner { |
| | | // width: 400px; |
| | | // background-color: #09152f; |
| | | // border: 1px solid #17324c; |
| | | //} |
| | | |
| | | .message-item__left { |
| | | width: 400px; |
| | |
| | | width: 400px; |
| | | } |
| | | |
| | | :deep(.el-input) { |
| | | width: 400px; |
| | | } |
| | | //:deep(.el-input) { |
| | | // width: 400px; |
| | | //} |
| | | |
| | | .message-item { |
| | | display: flex; |
| | |
| | | margin-left: 20px; |
| | | } |
| | | |
| | | :deep(.el-input--suffix) { |
| | | width: 400px; |
| | | } |
| | | |
| | | &::v-deep .el-textarea__inner { |
| | | background-color: #09152f; |
| | | border: 1px solid #17324c; |
| | | } |
| | | //:deep(.el-input--suffix) { |
| | | // width: 400px; |
| | | //} |
| | | // |
| | | //&::v-deep .el-textarea__inner { |
| | | // background-color: #09152f; |
| | | // border: 1px solid #17324c; |
| | | //} |
| | | |
| | | .el-form-item__content { |
| | | width: 400px; |
| | |
| | | } |
| | | } |
| | | } |
| | | </style> |
| | | </style> |