提交者
Gitee
!304 修改数据字典样式回显
Merge pull request !304 from 马小法/master
正在显示
11 个修改的文件
包含
70 行增加
和
108 行删除
| @@ -106,7 +106,11 @@ | @@ -106,7 +106,11 @@ | ||
| 106 | </template> | 106 | </template> |
| 107 | </el-table-column> | 107 | </el-table-column> |
| 108 | #elseif($column.list && "" != $column.dictType) | 108 | #elseif($column.list && "" != $column.dictType) |
| 109 | - <el-table-column label="${comment}" align="center" prop="${javaField}" :formatter="${javaField}Format" /> | 109 | + <el-table-column label="${comment}" align="center" prop="${javaField}"> |
| 110 | + <template slot-scope="scope"> | ||
| 111 | + <dict-tag :options="${javaField}Options" :value="scope.row.${javaField}"/> | ||
| 112 | + </template> | ||
| 113 | + </el-table-column> | ||
| 110 | #elseif($column.list && "" != $javaField) | 114 | #elseif($column.list && "" != $javaField) |
| 111 | #if(${foreach.index} == 1) | 115 | #if(${foreach.index} == 1) |
| 112 | <el-table-column label="${comment}" prop="${javaField}" /> | 116 | <el-table-column label="${comment}" prop="${javaField}" /> |
| @@ -378,20 +382,6 @@ export default { | @@ -378,20 +382,6 @@ export default { | ||
| 378 | this.${businessName}Options.push(data); | 382 | this.${businessName}Options.push(data); |
| 379 | }); | 383 | }); |
| 380 | }, | 384 | }, |
| 381 | -#foreach ($column in $columns) | ||
| 382 | -#if(${column.dictType} != '') | ||
| 383 | -#set($parentheseIndex=$column.columnComment.indexOf("(")) | ||
| 384 | -#if($parentheseIndex != -1) | ||
| 385 | -#set($comment=$column.columnComment.substring(0, $parentheseIndex)) | ||
| 386 | -#else | ||
| 387 | -#set($comment=$column.columnComment) | ||
| 388 | -#end | ||
| 389 | - // $comment字典翻译 | ||
| 390 | - ${column.javaField}Format(row, column) { | ||
| 391 | - return this.selectDictLabel#if($column.htmlType == "checkbox")s#end(this.${column.javaField}Options, row.${column.javaField}); | ||
| 392 | - }, | ||
| 393 | -#end | ||
| 394 | -#end | ||
| 395 | // 取消按钮 | 385 | // 取消按钮 |
| 396 | cancel() { | 386 | cancel() { |
| 397 | this.open = false; | 387 | this.open = false; |
| @@ -135,7 +135,11 @@ | @@ -135,7 +135,11 @@ | ||
| 135 | </template> | 135 | </template> |
| 136 | </el-table-column> | 136 | </el-table-column> |
| 137 | #elseif($column.list && "" != $column.dictType) | 137 | #elseif($column.list && "" != $column.dictType) |
| 138 | - <el-table-column label="${comment}" align="center" prop="${javaField}" :formatter="${javaField}Format" /> | 138 | + <el-table-column label="${comment}" align="center" prop="${javaField}"> |
| 139 | + <template slot-scope="scope"> | ||
| 140 | + <dict-tag :options="${javaField}Options" :value="scope.row.${javaField}"/> | ||
| 141 | + </template> | ||
| 142 | + </el-table-column> | ||
| 139 | #elseif($column.list && "" != $javaField) | 143 | #elseif($column.list && "" != $javaField) |
| 140 | <el-table-column label="${comment}" align="center" prop="${javaField}" /> | 144 | <el-table-column label="${comment}" align="center" prop="${javaField}" /> |
| 141 | #end | 145 | #end |
| @@ -426,20 +430,6 @@ export default { | @@ -426,20 +430,6 @@ export default { | ||
| 426 | this.loading = false; | 430 | this.loading = false; |
| 427 | }); | 431 | }); |
| 428 | }, | 432 | }, |
| 429 | -#foreach ($column in $columns) | ||
| 430 | -#if(${column.dictType} != '') | ||
| 431 | -#set($parentheseIndex=$column.columnComment.indexOf("(")) | ||
| 432 | -#if($parentheseIndex != -1) | ||
| 433 | -#set($comment=$column.columnComment.substring(0, $parentheseIndex)) | ||
| 434 | -#else | ||
| 435 | -#set($comment=$column.columnComment) | ||
| 436 | -#end | ||
| 437 | - // $comment字典翻译 | ||
| 438 | - ${column.javaField}Format(row, column) { | ||
| 439 | - return this.selectDictLabel#if($column.htmlType == "checkbox")s#end(this.${column.javaField}Options, row.${column.javaField}); | ||
| 440 | - }, | ||
| 441 | -#end | ||
| 442 | -#end | ||
| 443 | // 取消按钮 | 433 | // 取消按钮 |
| 444 | cancel() { | 434 | cancel() { |
| 445 | this.open = false; | 435 | this.open = false; |
| @@ -97,7 +97,11 @@ | @@ -97,7 +97,11 @@ | ||
| 97 | <el-table-column type="selection" width="55" align="center" /> | 97 | <el-table-column type="selection" width="55" align="center" /> |
| 98 | <el-table-column label="任务编号" align="center" prop="jobId" /> | 98 | <el-table-column label="任务编号" align="center" prop="jobId" /> |
| 99 | <el-table-column label="任务名称" align="center" prop="jobName" :show-overflow-tooltip="true" /> | 99 | <el-table-column label="任务名称" align="center" prop="jobName" :show-overflow-tooltip="true" /> |
| 100 | - <el-table-column label="任务组名" align="center" prop="jobGroup" :formatter="jobGroupFormat" /> | 100 | + <el-table-column label="任务组名" align="center" prop="jobGroup"> |
| 101 | + <template slot-scope="scope"> | ||
| 102 | + <dict-tag :options="jobGroupOptions" :value="scope.row.jobGroup"/> | ||
| 103 | + </template> | ||
| 104 | + </el-table-column> | ||
| 101 | <el-table-column label="调用目标字符串" align="center" prop="invokeTarget" :show-overflow-tooltip="true" /> | 105 | <el-table-column label="调用目标字符串" align="center" prop="invokeTarget" :show-overflow-tooltip="true" /> |
| 102 | <el-table-column label="cron执行表达式" align="center" prop="cronExpression" :show-overflow-tooltip="true" /> | 106 | <el-table-column label="cron执行表达式" align="center" prop="cronExpression" :show-overflow-tooltip="true" /> |
| 103 | <el-table-column label="状态" align="center"> | 107 | <el-table-column label="状态" align="center"> |
| @@ -359,10 +363,6 @@ export default { | @@ -359,10 +363,6 @@ export default { | ||
| 359 | jobGroupFormat(row, column) { | 363 | jobGroupFormat(row, column) { |
| 360 | return this.selectDictLabel(this.jobGroupOptions, row.jobGroup); | 364 | return this.selectDictLabel(this.jobGroupOptions, row.jobGroup); |
| 361 | }, | 365 | }, |
| 362 | - // 状态字典翻译 | ||
| 363 | - statusFormat(row, column) { | ||
| 364 | - return this.selectDictLabel(this.statusOptions, row.status); | ||
| 365 | - }, | ||
| 366 | // 取消按钮 | 366 | // 取消按钮 |
| 367 | cancel() { | 367 | cancel() { |
| 368 | this.open = false; | 368 | this.open = false; |
| @@ -110,10 +110,18 @@ | @@ -110,10 +110,18 @@ | ||
| 110 | <el-table-column type="selection" width="55" align="center" /> | 110 | <el-table-column type="selection" width="55" align="center" /> |
| 111 | <el-table-column label="日志编号" width="80" align="center" prop="jobLogId" /> | 111 | <el-table-column label="日志编号" width="80" align="center" prop="jobLogId" /> |
| 112 | <el-table-column label="任务名称" align="center" prop="jobName" :show-overflow-tooltip="true" /> | 112 | <el-table-column label="任务名称" align="center" prop="jobName" :show-overflow-tooltip="true" /> |
| 113 | - <el-table-column label="任务组名" align="center" prop="jobGroup" :formatter="jobGroupFormat" :show-overflow-tooltip="true" /> | 113 | + <el-table-column label="任务组名" align="center" prop="jobGroup" :show-overflow-tooltip="true"> |
| 114 | + <template slot-scope="scope"> | ||
| 115 | + <dict-tag :options="jobGroupOptions" :value="scope.row.jobGroup"/> | ||
| 116 | + </template> | ||
| 117 | + </el-table-column> | ||
| 114 | <el-table-column label="调用目标字符串" align="center" prop="invokeTarget" :show-overflow-tooltip="true" /> | 118 | <el-table-column label="调用目标字符串" align="center" prop="invokeTarget" :show-overflow-tooltip="true" /> |
| 115 | <el-table-column label="日志信息" align="center" prop="jobMessage" :show-overflow-tooltip="true" /> | 119 | <el-table-column label="日志信息" align="center" prop="jobMessage" :show-overflow-tooltip="true" /> |
| 116 | - <el-table-column label="执行状态" align="center" prop="status" :formatter="statusFormat" /> | 120 | + <el-table-column label="执行状态" align="center" prop="status"> |
| 121 | + <template slot-scope="scope"> | ||
| 122 | + <dict-tag :options="statusOptions" :value="scope.row.status"/> | ||
| 123 | + </template> | ||
| 124 | + </el-table-column> | ||
| 117 | <el-table-column label="执行时间" align="center" prop="createTime" width="180"> | 125 | <el-table-column label="执行时间" align="center" prop="createTime" width="180"> |
| 118 | <template slot-scope="scope"> | 126 | <template slot-scope="scope"> |
| 119 | <span>{{ parseTime(scope.row.createTime) }}</span> | 127 | <span>{{ parseTime(scope.row.createTime) }}</span> |
| @@ -247,14 +255,6 @@ export default { | @@ -247,14 +255,6 @@ export default { | ||
| 247 | } | 255 | } |
| 248 | ); | 256 | ); |
| 249 | }, | 257 | }, |
| 250 | - // 执行状态字典翻译 | ||
| 251 | - statusFormat(row, column) { | ||
| 252 | - return this.selectDictLabel(this.statusOptions, row.status); | ||
| 253 | - }, | ||
| 254 | - // 任务组名字典翻译 | ||
| 255 | - jobGroupFormat(row, column) { | ||
| 256 | - return this.selectDictLabel(this.jobGroupOptions, row.jobGroup); | ||
| 257 | - }, | ||
| 258 | // 返回按钮 | 258 | // 返回按钮 |
| 259 | handleClose() { | 259 | handleClose() { |
| 260 | this.$store.dispatch("tagsView/delView", this.$route); | 260 | this.$store.dispatch("tagsView/delView", this.$route); |
| @@ -99,7 +99,11 @@ | @@ -99,7 +99,11 @@ | ||
| 99 | <el-table-column label="登录地点" align="center" prop="loginLocation" :show-overflow-tooltip="true" /> | 99 | <el-table-column label="登录地点" align="center" prop="loginLocation" :show-overflow-tooltip="true" /> |
| 100 | <el-table-column label="浏览器" align="center" prop="browser" :show-overflow-tooltip="true" /> | 100 | <el-table-column label="浏览器" align="center" prop="browser" :show-overflow-tooltip="true" /> |
| 101 | <el-table-column label="操作系统" align="center" prop="os" /> | 101 | <el-table-column label="操作系统" align="center" prop="os" /> |
| 102 | - <el-table-column label="登录状态" align="center" prop="status" :formatter="statusFormat" /> | 102 | + <el-table-column label="登录状态" align="center" prop="status"> |
| 103 | + <template slot-scope="scope"> | ||
| 104 | + <dict-tag :options="statusOptions" :value="scope.row.status"/> | ||
| 105 | + </template> | ||
| 106 | + </el-table-column> | ||
| 103 | <el-table-column label="操作信息" align="center" prop="msg" /> | 107 | <el-table-column label="操作信息" align="center" prop="msg" /> |
| 104 | <el-table-column label="登录日期" align="center" prop="loginTime" sortable="custom" :sort-orders="['descending', 'ascending']" width="180"> | 108 | <el-table-column label="登录日期" align="center" prop="loginTime" sortable="custom" :sort-orders="['descending', 'ascending']" width="180"> |
| 105 | <template slot-scope="scope"> | 109 | <template slot-scope="scope"> |
| @@ -172,10 +176,6 @@ export default { | @@ -172,10 +176,6 @@ export default { | ||
| 172 | } | 176 | } |
| 173 | ); | 177 | ); |
| 174 | }, | 178 | }, |
| 175 | - // 登录状态字典翻译 | ||
| 176 | - statusFormat(row, column) { | ||
| 177 | - return this.selectDictLabel(this.statusOptions, row.status); | ||
| 178 | - }, | ||
| 179 | /** 搜索按钮操作 */ | 179 | /** 搜索按钮操作 */ |
| 180 | handleQuery() { | 180 | handleQuery() { |
| 181 | this.queryParams.pageNum = 1; | 181 | this.queryParams.pageNum = 1; |
| @@ -111,12 +111,20 @@ | @@ -111,12 +111,20 @@ | ||
| 111 | <el-table-column type="selection" width="55" align="center" /> | 111 | <el-table-column type="selection" width="55" align="center" /> |
| 112 | <el-table-column label="日志编号" align="center" prop="operId" /> | 112 | <el-table-column label="日志编号" align="center" prop="operId" /> |
| 113 | <el-table-column label="系统模块" align="center" prop="title" /> | 113 | <el-table-column label="系统模块" align="center" prop="title" /> |
| 114 | - <el-table-column label="操作类型" align="center" prop="businessType" :formatter="typeFormat" /> | 114 | + <el-table-column label="操作类型" align="center" prop="businessType"> |
| 115 | + <template slot-scope="scope"> | ||
| 116 | + <dict-tag :options="typeOptions" :value="scope.row.businessType"/> | ||
| 117 | + </template> | ||
| 118 | + </el-table-column> | ||
| 115 | <el-table-column label="请求方式" align="center" prop="requestMethod" /> | 119 | <el-table-column label="请求方式" align="center" prop="requestMethod" /> |
| 116 | <el-table-column label="操作人员" align="center" prop="operName" width="100" :show-overflow-tooltip="true" sortable="custom" :sort-orders="['descending', 'ascending']" /> | 120 | <el-table-column label="操作人员" align="center" prop="operName" width="100" :show-overflow-tooltip="true" sortable="custom" :sort-orders="['descending', 'ascending']" /> |
| 117 | <el-table-column label="操作地址" align="center" prop="operIp" width="130" :show-overflow-tooltip="true" /> | 121 | <el-table-column label="操作地址" align="center" prop="operIp" width="130" :show-overflow-tooltip="true" /> |
| 118 | <el-table-column label="操作地点" align="center" prop="operLocation" :show-overflow-tooltip="true" /> | 122 | <el-table-column label="操作地点" align="center" prop="operLocation" :show-overflow-tooltip="true" /> |
| 119 | - <el-table-column label="操作状态" align="center" prop="status" :formatter="statusFormat" /> | 123 | + <el-table-column label="操作状态" align="center" prop="status"> |
| 124 | + <template slot-scope="scope"> | ||
| 125 | + <dict-tag :options="statusOptions" :value="scope.row.status"/> | ||
| 126 | + </template> | ||
| 127 | + </el-table-column> | ||
| 120 | <el-table-column label="操作日期" align="center" prop="operTime" sortable="custom" :sort-orders="['descending', 'ascending']" width="180"> | 128 | <el-table-column label="操作日期" align="center" prop="operTime" sortable="custom" :sort-orders="['descending', 'ascending']" width="180"> |
| 121 | <template slot-scope="scope"> | 129 | <template slot-scope="scope"> |
| 122 | <span>{{ parseTime(scope.row.operTime) }}</span> | 130 | <span>{{ parseTime(scope.row.operTime) }}</span> |
| @@ -251,10 +259,6 @@ export default { | @@ -251,10 +259,6 @@ export default { | ||
| 251 | } | 259 | } |
| 252 | ); | 260 | ); |
| 253 | }, | 261 | }, |
| 254 | - // 操作日志状态字典翻译 | ||
| 255 | - statusFormat(row, column) { | ||
| 256 | - return this.selectDictLabel(this.statusOptions, row.status); | ||
| 257 | - }, | ||
| 258 | // 操作日志类型字典翻译 | 262 | // 操作日志类型字典翻译 |
| 259 | typeFormat(row, column) { | 263 | typeFormat(row, column) { |
| 260 | return this.selectDictLabel(this.typeOptions, row.businessType); | 264 | return this.selectDictLabel(this.typeOptions, row.businessType); |
| @@ -112,7 +112,11 @@ | @@ -112,7 +112,11 @@ | ||
| 112 | <el-table-column label="参数名称" align="center" prop="configName" :show-overflow-tooltip="true" /> | 112 | <el-table-column label="参数名称" align="center" prop="configName" :show-overflow-tooltip="true" /> |
| 113 | <el-table-column label="参数键名" align="center" prop="configKey" :show-overflow-tooltip="true" /> | 113 | <el-table-column label="参数键名" align="center" prop="configKey" :show-overflow-tooltip="true" /> |
| 114 | <el-table-column label="参数键值" align="center" prop="configValue" /> | 114 | <el-table-column label="参数键值" align="center" prop="configValue" /> |
| 115 | - <el-table-column label="系统内置" align="center" prop="configType" :formatter="typeFormat" /> | 115 | + <el-table-column label="系统内置" align="center" prop="configType"> |
| 116 | + <template slot-scope="scope"> | ||
| 117 | + <dict-tag :options="typeOptions" :value="scope.row.configType"/> | ||
| 118 | + </template> | ||
| 119 | + </el-table-column> | ||
| 116 | <el-table-column label="备注" align="center" prop="remark" :show-overflow-tooltip="true" /> | 120 | <el-table-column label="备注" align="center" prop="remark" :show-overflow-tooltip="true" /> |
| 117 | <el-table-column label="创建时间" align="center" prop="createTime" width="180"> | 121 | <el-table-column label="创建时间" align="center" prop="createTime" width="180"> |
| 118 | <template slot-scope="scope"> | 122 | <template slot-scope="scope"> |
| @@ -252,10 +256,6 @@ export default { | @@ -252,10 +256,6 @@ export default { | ||
| 252 | } | 256 | } |
| 253 | ); | 257 | ); |
| 254 | }, | 258 | }, |
| 255 | - // 参数系统内置字典翻译 | ||
| 256 | - typeFormat(row, column) { | ||
| 257 | - return this.selectDictLabel(this.typeOptions, row.configType); | ||
| 258 | - }, | ||
| 259 | // 取消按钮 | 259 | // 取消按钮 |
| 260 | cancel() { | 260 | cancel() { |
| 261 | this.open = false; | 261 | this.open = false; |
| @@ -49,7 +49,11 @@ | @@ -49,7 +49,11 @@ | ||
| 49 | > | 49 | > |
| 50 | <el-table-column prop="deptName" label="部门名称" width="260"></el-table-column> | 50 | <el-table-column prop="deptName" label="部门名称" width="260"></el-table-column> |
| 51 | <el-table-column prop="orderNum" label="排序" width="200"></el-table-column> | 51 | <el-table-column prop="orderNum" label="排序" width="200"></el-table-column> |
| 52 | - <el-table-column prop="status" label="状态" :formatter="statusFormat" width="100"></el-table-column> | 52 | + <el-table-column prop="status" label="状态" width="100"> |
| 53 | + <template slot-scope="scope"> | ||
| 54 | + <dict-tag :options="statusOptions" :value="scope.row.status"/> | ||
| 55 | + </template> | ||
| 56 | + </el-table-column> | ||
| 53 | <el-table-column label="创建时间" align="center" prop="createTime" width="200"> | 57 | <el-table-column label="创建时间" align="center" prop="createTime" width="200"> |
| 54 | <template slot-scope="scope"> | 58 | <template slot-scope="scope"> |
| 55 | <span>{{ parseTime(scope.row.createTime) }}</span> | 59 | <span>{{ parseTime(scope.row.createTime) }}</span> |
| @@ -223,10 +227,6 @@ export default { | @@ -223,10 +227,6 @@ export default { | ||
| 223 | children: node.children | 227 | children: node.children |
| 224 | }; | 228 | }; |
| 225 | }, | 229 | }, |
| 226 | - // 字典状态字典翻译 | ||
| 227 | - statusFormat(row, column) { | ||
| 228 | - return this.selectDictLabel(this.statusOptions, row.status); | ||
| 229 | - }, | ||
| 230 | // 取消按钮 | 230 | // 取消按钮 |
| 231 | cancel() { | 231 | cancel() { |
| 232 | this.open = false; | 232 | this.open = false; |
| @@ -55,7 +55,11 @@ | @@ -55,7 +55,11 @@ | ||
| 55 | <el-table-column prop="orderNum" label="排序" width="60"></el-table-column> | 55 | <el-table-column prop="orderNum" label="排序" width="60"></el-table-column> |
| 56 | <el-table-column prop="perms" label="权限标识" :show-overflow-tooltip="true"></el-table-column> | 56 | <el-table-column prop="perms" label="权限标识" :show-overflow-tooltip="true"></el-table-column> |
| 57 | <el-table-column prop="component" label="组件路径" :show-overflow-tooltip="true"></el-table-column> | 57 | <el-table-column prop="component" label="组件路径" :show-overflow-tooltip="true"></el-table-column> |
| 58 | - <el-table-column prop="status" label="状态" :formatter="statusFormat" width="80"></el-table-column> | 58 | + <el-table-column prop="status" label="状态" width="80"> |
| 59 | + <template slot-scope="scope"> | ||
| 60 | + <dict-tag :options="statusOptions" :value="scope.row.status"/> | ||
| 61 | + </template> | ||
| 62 | + </el-table-column> | ||
| 59 | <el-table-column label="创建时间" align="center" prop="createTime"> | 63 | <el-table-column label="创建时间" align="center" prop="createTime"> |
| 60 | <template slot-scope="scope"> | 64 | <template slot-scope="scope"> |
| 61 | <span>{{ parseTime(scope.row.createTime) }}</span> | 65 | <span>{{ parseTime(scope.row.createTime) }}</span> |
| @@ -338,20 +342,6 @@ export default { | @@ -338,20 +342,6 @@ export default { | ||
| 338 | this.menuOptions.push(menu); | 342 | this.menuOptions.push(menu); |
| 339 | }); | 343 | }); |
| 340 | }, | 344 | }, |
| 341 | - // 显示状态字典翻译 | ||
| 342 | - visibleFormat(row, column) { | ||
| 343 | - if (row.menuType == "F") { | ||
| 344 | - return ""; | ||
| 345 | - } | ||
| 346 | - return this.selectDictLabel(this.visibleOptions, row.visible); | ||
| 347 | - }, | ||
| 348 | - // 菜单状态字典翻译 | ||
| 349 | - statusFormat(row, column) { | ||
| 350 | - if (row.menuType == "F") { | ||
| 351 | - return ""; | ||
| 352 | - } | ||
| 353 | - return this.selectDictLabel(this.statusOptions, row.status); | ||
| 354 | - }, | ||
| 355 | // 取消按钮 | 345 | // 取消按钮 |
| 356 | cancel() { | 346 | cancel() { |
| 357 | this.open = false; | 347 | this.open = false; |
| @@ -80,20 +80,16 @@ | @@ -80,20 +80,16 @@ | ||
| 80 | prop="noticeTitle" | 80 | prop="noticeTitle" |
| 81 | :show-overflow-tooltip="true" | 81 | :show-overflow-tooltip="true" |
| 82 | /> | 82 | /> |
| 83 | - <el-table-column | ||
| 84 | - label="公告类型" | ||
| 85 | - align="center" | ||
| 86 | - prop="noticeType" | ||
| 87 | - :formatter="typeFormat" | ||
| 88 | - width="100" | ||
| 89 | - /> | ||
| 90 | - <el-table-column | ||
| 91 | - label="状态" | ||
| 92 | - align="center" | ||
| 93 | - prop="status" | ||
| 94 | - :formatter="statusFormat" | ||
| 95 | - width="100" | ||
| 96 | - /> | 83 | + <el-table-column label="公告类型" align="center" prop="noticeType" width="100"> |
| 84 | + <template slot-scope="scope"> | ||
| 85 | + <dict-tag :options="typeOptions" :value="scope.row.noticeType"/> | ||
| 86 | + </template> | ||
| 87 | + </el-table-column> | ||
| 88 | + <el-table-column label="状态" align="center" prop="status" width="100"> | ||
| 89 | + <template slot-scope="scope"> | ||
| 90 | + <dict-tag :options="statusOptions" :value="scope.row.status"/> | ||
| 91 | + </template> | ||
| 92 | + </el-table-column> | ||
| 97 | <el-table-column label="创建者" align="center" prop="createBy" width="100" /> | 93 | <el-table-column label="创建者" align="center" prop="createBy" width="100" /> |
| 98 | <el-table-column label="创建时间" align="center" prop="createTime" width="100"> | 94 | <el-table-column label="创建时间" align="center" prop="createTime" width="100"> |
| 99 | <template slot-scope="scope"> | 95 | <template slot-scope="scope"> |
| @@ -244,14 +240,6 @@ export default { | @@ -244,14 +240,6 @@ export default { | ||
| 244 | this.loading = false; | 240 | this.loading = false; |
| 245 | }); | 241 | }); |
| 246 | }, | 242 | }, |
| 247 | - // 公告状态字典翻译 | ||
| 248 | - statusFormat(row, column) { | ||
| 249 | - return this.selectDictLabel(this.statusOptions, row.status); | ||
| 250 | - }, | ||
| 251 | - // 公告状态字典翻译 | ||
| 252 | - typeFormat(row, column) { | ||
| 253 | - return this.selectDictLabel(this.typeOptions, row.noticeType); | ||
| 254 | - }, | ||
| 255 | // 取消按钮 | 243 | // 取消按钮 |
| 256 | cancel() { | 244 | cancel() { |
| 257 | this.open = false; | 245 | this.open = false; |
| @@ -88,7 +88,11 @@ | @@ -88,7 +88,11 @@ | ||
| 88 | <el-table-column label="岗位编码" align="center" prop="postCode" /> | 88 | <el-table-column label="岗位编码" align="center" prop="postCode" /> |
| 89 | <el-table-column label="岗位名称" align="center" prop="postName" /> | 89 | <el-table-column label="岗位名称" align="center" prop="postName" /> |
| 90 | <el-table-column label="岗位排序" align="center" prop="postSort" /> | 90 | <el-table-column label="岗位排序" align="center" prop="postSort" /> |
| 91 | - <el-table-column label="状态" align="center" prop="status" :formatter="statusFormat" /> | 91 | + <el-table-column label="状态" align="center" prop="status"> |
| 92 | + <template slot-scope="scope"> | ||
| 93 | + <dict-tag :options="statusOptions" :value="scope.row.status"/> | ||
| 94 | + </template> | ||
| 95 | + </el-table-column> | ||
| 92 | <el-table-column label="创建时间" align="center" prop="createTime" width="180"> | 96 | <el-table-column label="创建时间" align="center" prop="createTime" width="180"> |
| 93 | <template slot-scope="scope"> | 97 | <template slot-scope="scope"> |
| 94 | <span>{{ parseTime(scope.row.createTime) }}</span> | 98 | <span>{{ parseTime(scope.row.createTime) }}</span> |
| @@ -224,10 +228,6 @@ export default { | @@ -224,10 +228,6 @@ export default { | ||
| 224 | this.loading = false; | 228 | this.loading = false; |
| 225 | }); | 229 | }); |
| 226 | }, | 230 | }, |
| 227 | - // 岗位状态字典翻译 | ||
| 228 | - statusFormat(row, column) { | ||
| 229 | - return this.selectDictLabel(this.statusOptions, row.status); | ||
| 230 | - }, | ||
| 231 | // 取消按钮 | 231 | // 取消按钮 |
| 232 | cancel() { | 232 | cancel() { |
| 233 | this.open = false; | 233 | this.open = false; |
-
请 注册 或 登录 后发表评论