| | |
| | | <div class="mainContent"> |
| | | <div class="main-nav"> |
| | | <span>数据列表</span> |
| | | <el-button type="primary" icon="el-icon-plus" @click="isShowDialog = true; dialogType = 'create'">添加</el-button> |
| | | <el-button class="button-addition" type="primary" icon="el-icon-plus" @click="isShowDialog = true; dialogType = 'create'">添加</el-button> |
| | | </div> |
| | | <!-- 数据展示 --> |
| | | <el-table ref="multipleTable" |
| | |
| | | <el-table-column prop="operation" label="操作" min-width="15"> |
| | | <template slot-scope="scope"> |
| | | <div class="operation"> |
| | | <el-link icon="el-icon-view" :underline="false" @click="handleView(scope.row)">查看</el-link> |
| | | <el-link icon="el-icon-view" :underline="false" @click="handleView(scope.row, 'view')">查看</el-link> |
| | | <el-link icon="el-icon-edit" class="leftPx" :underline="false" @click="handleEdit(scope.row)">编辑</el-link> |
| | | <el-link class="leftPx" icon="el-icon-delete-solid" :underline="false" |
| | | @click="handleDelete([scope.row.id])">删除</el-link> |
| | |
| | | </el-table-column> |
| | | </el-table> |
| | | <!-- 新建消息 --> |
| | | <el-dialog :title="dialogType === 'create' ? '新建短信模板' : '查看短信模板'" :visible.sync="isShowDialog" width="80%" |
| | | <el-dialog :title="dialogType === 'view' ? '查看短信模板' : '更新短信模板'" :visible.sync="isShowDialog" width="80%" |
| | | :before-close="handleConfirmClose"> |
| | | <MyCreate v-if="isShowDialog" @closeMyDialog="handleConfirmClose" :dialogType="dialogType" :tableRowData="messageTemplateData"></MyCreate> |
| | | <MyCreate v-if="isShowDialog" @closeMyDialog="handleConfirmClose" @closeDialog="closeDialog" |
| | | :dialogType="dialogType" :tableRowData="messageTemplateData"></MyCreate> |
| | | </el-dialog> |
| | | <div class="tools"> |
| | | <div class="funs"> |
| | |
| | | }, |
| | | // 重置 |
| | | handleReset(){ |
| | | this.context=""; |
| | | this.messageStatus=0; |
| | | this.getMessageList(); |
| | | }, |
| | | // 查看 |
| | | handleView(data){ |
| | |
| | | }, |
| | | // 获取消息数据 |
| | | getMessageList() { |
| | | SMS.getSMSTemplateList({ current: this.currentPage, pageSize: this.pageSize, context: this.context, type: this.messageType }) |
| | | SMS.getSMSTemplateList({ current: this.currentPage, pageSize: this.pageSize, title: this.context, type: this.messageStatus }) |
| | | .then(({ records, total }) => { |
| | | this.tableData = records; |
| | | this.totalNum = total; |
| | |
| | | .then(() => { |
| | | done(); |
| | | }) |
| | | } |
| | | }, |
| | | closeDialog() { |
| | | this.isShowDialog = false; |
| | | } |
| | | } |
| | | } |
| | | </script> |
| | |
| | | &::v-deep .el-dialog__close { |
| | | width: 20px; |
| | | height: 20px; |
| | | // color: #fff; |
| | | } |
| | | |
| | | &::v-deep .el-dialog__body { |