Commit e7d0024eb0c0eda990099155c3e12ef8cbfa6a1c
1 parent
d44d4da4
v3.5.0 导出按钮点击之后添加遮罩
Showing
20 changed files
with
124 additions
and
346 deletions
yudao-module-tool/yudao-module-tool-impl/src/main/resources/codegen/vue/views/index.vue.vm
| @@ -51,7 +51,7 @@ | @@ -51,7 +51,7 @@ | ||
| 51 | v-hasPermi="['${permissionPrefix}:create']">新增</el-button> | 51 | v-hasPermi="['${permissionPrefix}:create']">新增</el-button> |
| 52 | </el-col> | 52 | </el-col> |
| 53 | <el-col :span="1.5"> | 53 | <el-col :span="1.5"> |
| 54 | - <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" | 54 | + <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" :loading="exportLoading" |
| 55 | v-hasPermi="['${permissionPrefix}:export']">导出</el-button> | 55 | v-hasPermi="['${permissionPrefix}:export']">导出</el-button> |
| 56 | </el-col> | 56 | </el-col> |
| 57 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | 57 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> |
| @@ -207,6 +207,8 @@ export default { | @@ -207,6 +207,8 @@ export default { | ||
| 207 | return { | 207 | return { |
| 208 | // 遮罩层 | 208 | // 遮罩层 |
| 209 | loading: true, | 209 | loading: true, |
| 210 | + // 导出遮罩层 | ||
| 211 | + exportLoading: false, | ||
| 210 | // 显示搜索条件 | 212 | // 显示搜索条件 |
| 211 | showSearch: true, | 213 | showSearch: true, |
| 212 | // 总条数 | 214 | // 总条数 |
| @@ -392,10 +394,12 @@ export default { | @@ -392,10 +394,12 @@ export default { | ||
| 392 | confirmButtonText: "确定", | 394 | confirmButtonText: "确定", |
| 393 | cancelButtonText: "取消", | 395 | cancelButtonText: "取消", |
| 394 | type: "warning" | 396 | type: "warning" |
| 395 | - }).then(function() { | 397 | + }).then(() => { |
| 398 | + this.exportLoading = true; | ||
| 396 | return export${simpleClassName}Excel(params); | 399 | return export${simpleClassName}Excel(params); |
| 397 | }).then(response => { | 400 | }).then(response => { |
| 398 | this.downloadExcel(response, '${table.classComment}.xls'); | 401 | this.downloadExcel(response, '${table.classComment}.xls'); |
| 402 | + this.exportLoading = false; | ||
| 399 | }) | 403 | }) |
| 400 | } | 404 | } |
| 401 | } | 405 | } |
yudao-ui-admin/src/views/infra/apiAccessLog/index.vue
| @@ -37,7 +37,7 @@ | @@ -37,7 +37,7 @@ | ||
| 37 | <!-- 操作工具栏 --> | 37 | <!-- 操作工具栏 --> |
| 38 | <el-row :gutter="10" class="mb8"> | 38 | <el-row :gutter="10" class="mb8"> |
| 39 | <el-col :span="1.5"> | 39 | <el-col :span="1.5"> |
| 40 | - <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" | 40 | + <el-button type="warning" plain icon="el-icon-download" size="mini" :loading="exportLoading" @click="handleExport" |
| 41 | v-hasPermi="['infra:api-access-log:export']">导出</el-button> | 41 | v-hasPermi="['infra:api-access-log:export']">导出</el-button> |
| 42 | </el-col> | 42 | </el-col> |
| 43 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | 43 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> |
| @@ -123,6 +123,8 @@ export default { | @@ -123,6 +123,8 @@ export default { | ||
| 123 | return { | 123 | return { |
| 124 | // 遮罩层 | 124 | // 遮罩层 |
| 125 | loading: true, | 125 | loading: true, |
| 126 | + // 导出遮罩层 | ||
| 127 | + exportLoading: false, | ||
| 126 | // 显示搜索条件 | 128 | // 显示搜索条件 |
| 127 | showSearch: true, | 129 | showSearch: true, |
| 128 | // 总条数 | 130 | // 总条数 |
| @@ -204,10 +206,12 @@ export default { | @@ -204,10 +206,12 @@ export default { | ||
| 204 | confirmButtonText: "确定", | 206 | confirmButtonText: "确定", |
| 205 | cancelButtonText: "取消", | 207 | cancelButtonText: "取消", |
| 206 | type: "warning" | 208 | type: "warning" |
| 207 | - }).then(function() { | 209 | + }).then(() => { |
| 210 | + this.exportLoading = true; | ||
| 208 | return exportApiAccessLogExcel(params); | 211 | return exportApiAccessLogExcel(params); |
| 209 | }).then(response => { | 212 | }).then(response => { |
| 210 | this.downloadExcel(response, 'API 访问日志.xls'); | 213 | this.downloadExcel(response, 'API 访问日志.xls'); |
| 214 | + this.exportLoading = false; | ||
| 211 | }) | 215 | }) |
| 212 | } | 216 | } |
| 213 | } | 217 | } |
yudao-ui-admin/src/views/infra/apiErrorLog/index.vue
| @@ -37,7 +37,7 @@ | @@ -37,7 +37,7 @@ | ||
| 37 | <!-- 操作工具栏 --> | 37 | <!-- 操作工具栏 --> |
| 38 | <el-row :gutter="10" class="mb8"> | 38 | <el-row :gutter="10" class="mb8"> |
| 39 | <el-col :span="1.5"> | 39 | <el-col :span="1.5"> |
| 40 | - <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" | 40 | + <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" :loading="exportLoading" |
| 41 | v-hasPermi="['infra:api-error-log:export']">导出</el-button> | 41 | v-hasPermi="['infra:api-error-log:export']">导出</el-button> |
| 42 | </el-col> | 42 | </el-col> |
| 43 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | 43 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> |
| @@ -130,6 +130,8 @@ export default { | @@ -130,6 +130,8 @@ export default { | ||
| 130 | return { | 130 | return { |
| 131 | // 遮罩层 | 131 | // 遮罩层 |
| 132 | loading: true, | 132 | loading: true, |
| 133 | + // 导出遮罩层 | ||
| 134 | + exportLoading: false, | ||
| 133 | // 显示搜索条件 | 135 | // 显示搜索条件 |
| 134 | showSearch: true, | 136 | showSearch: true, |
| 135 | // 总条数 | 137 | // 总条数 |
| @@ -226,10 +228,12 @@ export default { | @@ -226,10 +228,12 @@ export default { | ||
| 226 | confirmButtonText: "确定", | 228 | confirmButtonText: "确定", |
| 227 | cancelButtonText: "取消", | 229 | cancelButtonText: "取消", |
| 228 | type: "warning" | 230 | type: "warning" |
| 229 | - }).then(function() { | 231 | + }).then(() => { |
| 232 | + this.exportLoading = true; | ||
| 230 | return exportApiErrorLogExcel(params); | 233 | return exportApiErrorLogExcel(params); |
| 231 | }).then(response => { | 234 | }).then(response => { |
| 232 | this.downloadExcel(response, 'API 错误日志.xls'); | 235 | this.downloadExcel(response, 'API 错误日志.xls'); |
| 236 | + this.exportLoading = false; | ||
| 233 | }) | 237 | }) |
| 234 | } | 238 | } |
| 235 | } | 239 | } |
yudao-ui-admin/src/views/infra/config/index.vue
| @@ -43,13 +43,8 @@ | @@ -43,13 +43,8 @@ | ||
| 43 | v-hasPermi="['infra:config:create']">新增</el-button> | 43 | v-hasPermi="['infra:config:create']">新增</el-button> |
| 44 | </el-col> | 44 | </el-col> |
| 45 | <el-col :span="1.5"> | 45 | <el-col :span="1.5"> |
| 46 | - <el-button | ||
| 47 | - type="warning" | ||
| 48 | - icon="el-icon-download" | ||
| 49 | - size="mini" | ||
| 50 | - @click="handleExport" | ||
| 51 | - v-hasPermi="['infra:config:export']" | ||
| 52 | - >导出</el-button> | 46 | + <el-button type="warning" icon="el-icon-download" size="mini" @click="handleExport" :loading="exportLoading" |
| 47 | + v-hasPermi="['infra:config:export']">导出</el-button> | ||
| 53 | </el-col> | 48 | </el-col> |
| 54 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | 49 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> |
| 55 | </el-row> | 50 | </el-row> |
| @@ -130,6 +125,8 @@ export default { | @@ -130,6 +125,8 @@ export default { | ||
| 130 | return { | 125 | return { |
| 131 | // 遮罩层 | 126 | // 遮罩层 |
| 132 | loading: true, | 127 | loading: true, |
| 128 | + // 导出遮罩层 | ||
| 129 | + exportLoading: false, | ||
| 133 | // 显示搜索条件 | 130 | // 显示搜索条件 |
| 134 | showSearch: true, | 131 | showSearch: true, |
| 135 | // 总条数 | 132 | // 总条数 |
| @@ -279,11 +276,13 @@ export default { | @@ -279,11 +276,13 @@ export default { | ||
| 279 | confirmButtonText: "确定", | 276 | confirmButtonText: "确定", |
| 280 | cancelButtonText: "取消", | 277 | cancelButtonText: "取消", |
| 281 | type: "warning" | 278 | type: "warning" |
| 282 | - }).then(function() { | 279 | + }).then(() => { |
| 280 | + this.exportLoading = true; | ||
| 283 | return exportConfig(queryParams); | 281 | return exportConfig(queryParams); |
| 284 | }).then(response => { | 282 | }).then(response => { |
| 285 | this.downloadExcel(response, '参数配置.xls'); | 283 | this.downloadExcel(response, '参数配置.xls'); |
| 286 | - }) | 284 | + this.exportLoading = false; |
| 285 | + }) | ||
| 287 | }, | 286 | }, |
| 288 | } | 287 | } |
| 289 | }; | 288 | }; |
yudao-ui-admin/src/views/infra/job/index.vue
| @@ -25,7 +25,7 @@ | @@ -25,7 +25,7 @@ | ||
| 25 | v-hasPermi="['infra:job:create']">新增</el-button> | 25 | v-hasPermi="['infra:job:create']">新增</el-button> |
| 26 | </el-col> | 26 | </el-col> |
| 27 | <el-col :span="1.5"> | 27 | <el-col :span="1.5"> |
| 28 | - <el-button type="warning" icon="el-icon-download" size="mini" @click="handleExport" | 28 | + <el-button type="warning" icon="el-icon-download" size="mini" @click="handleExport" :loading="exportLoading" |
| 29 | v-hasPermi="['infra:job:export']">导出</el-button> | 29 | v-hasPermi="['infra:job:export']">导出</el-button> |
| 30 | </el-col> | 30 | </el-col> |
| 31 | <el-col :span="1.5"> | 31 | <el-col :span="1.5"> |
| @@ -136,6 +136,8 @@ export default { | @@ -136,6 +136,8 @@ export default { | ||
| 136 | return { | 136 | return { |
| 137 | // 遮罩层 | 137 | // 遮罩层 |
| 138 | loading: true, | 138 | loading: true, |
| 139 | + // 导出遮罩层 | ||
| 140 | + exportLoading: false, | ||
| 139 | // 显示搜索条件 | 141 | // 显示搜索条件 |
| 140 | showSearch: true, | 142 | showSearch: true, |
| 141 | // 总条数 | 143 | // 总条数 |
| @@ -326,10 +328,12 @@ export default { | @@ -326,10 +328,12 @@ export default { | ||
| 326 | confirmButtonText: "确定", | 328 | confirmButtonText: "确定", |
| 327 | cancelButtonText: "取消", | 329 | cancelButtonText: "取消", |
| 328 | type: "warning" | 330 | type: "warning" |
| 329 | - }).then(function() { | 331 | + }).then(() => { |
| 332 | + this.exportLoading = true; | ||
| 330 | return exportJob(queryParams); | 333 | return exportJob(queryParams); |
| 331 | }).then(response => { | 334 | }).then(response => { |
| 332 | this.downloadExcel(response, '定时任务.xls'); | 335 | this.downloadExcel(response, '定时任务.xls'); |
| 336 | + this.exportLoading = false; | ||
| 333 | }) | 337 | }) |
| 334 | } | 338 | } |
| 335 | } | 339 | } |
yudao-ui-admin/src/views/infra/job/log.vue
| @@ -54,7 +54,7 @@ | @@ -54,7 +54,7 @@ | ||
| 54 | </el-table-column> | 54 | </el-table-column> |
| 55 | <el-table-column label="操作" align="center" class-name="small-padding fixed-width"> | 55 | <el-table-column label="操作" align="center" class-name="small-padding fixed-width"> |
| 56 | <template slot-scope="scope"> | 56 | <template slot-scope="scope"> |
| 57 | - <el-button size="mini" type="text" icon="el-icon-view" @click="handleView(scope.row)" | 57 | + <el-button size="mini" type="text" icon="el-icon-view" @click="handleView(scope.row)" :loading="exportLoading" |
| 58 | v-hasPermi="['infra:job:query']">详细</el-button> | 58 | v-hasPermi="['infra:job:query']">详细</el-button> |
| 59 | </template> | 59 | </template> |
| 60 | </el-table-column> | 60 | </el-table-column> |
| @@ -96,6 +96,8 @@ export default { | @@ -96,6 +96,8 @@ export default { | ||
| 96 | return { | 96 | return { |
| 97 | // 遮罩层 | 97 | // 遮罩层 |
| 98 | loading: true, | 98 | loading: true, |
| 99 | + // 导出遮罩层 | ||
| 100 | + exportLoading: false, | ||
| 99 | // 显示搜索条件 | 101 | // 显示搜索条件 |
| 100 | showSearch: true, | 102 | showSearch: true, |
| 101 | // 总条数 | 103 | // 总条数 |
| @@ -165,10 +167,12 @@ export default { | @@ -165,10 +167,12 @@ export default { | ||
| 165 | confirmButtonText: "确定", | 167 | confirmButtonText: "确定", |
| 166 | cancelButtonText: "取消", | 168 | cancelButtonText: "取消", |
| 167 | type: "warning" | 169 | type: "warning" |
| 168 | - }).then(function() { | 170 | + }).then(() => { |
| 171 | + this.exportLoading = true; | ||
| 169 | return exportJobLogExcel(params); | 172 | return exportJobLogExcel(params); |
| 170 | }).then(response => { | 173 | }).then(response => { |
| 171 | this.downloadExcel(response, '定时任务日志.xls'); | 174 | this.downloadExcel(response, '定时任务日志.xls'); |
| 175 | + this.exportLoading = false; | ||
| 172 | }) | 176 | }) |
| 173 | } | 177 | } |
| 174 | } | 178 | } |
yudao-ui-admin/src/views/pay/merchant/index.vue
| @@ -37,7 +37,7 @@ | @@ -37,7 +37,7 @@ | ||
| 37 | v-hasPermi="['pay:merchant:create']">新增</el-button> | 37 | v-hasPermi="['pay:merchant:create']">新增</el-button> |
| 38 | </el-col> | 38 | </el-col> |
| 39 | <el-col :span="1.5"> | 39 | <el-col :span="1.5"> |
| 40 | - <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" | 40 | + <el-button type="warning" plain icon="el-icon-download" size="mini" :loading="exportLoading" @click="handleExport" |
| 41 | v-hasPermi="['pay:merchant:export']">导出</el-button> | 41 | v-hasPermi="['pay:merchant:export']">导出</el-button> |
| 42 | </el-col> | 42 | </el-col> |
| 43 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | 43 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> |
| @@ -124,6 +124,8 @@ export default { | @@ -124,6 +124,8 @@ export default { | ||
| 124 | return { | 124 | return { |
| 125 | // 遮罩层 | 125 | // 遮罩层 |
| 126 | loading: true, | 126 | loading: true, |
| 127 | + // 导出遮罩层 | ||
| 128 | + exportLoading: false, | ||
| 127 | // 显示搜索条件 | 129 | // 显示搜索条件 |
| 128 | showSearch: true, | 130 | showSearch: true, |
| 129 | // 总条数 | 131 | // 总条数 |
| @@ -285,10 +287,12 @@ export default { | @@ -285,10 +287,12 @@ export default { | ||
| 285 | confirmButtonText: "确定", | 287 | confirmButtonText: "确定", |
| 286 | cancelButtonText: "取消", | 288 | cancelButtonText: "取消", |
| 287 | type: "warning" | 289 | type: "warning" |
| 288 | - }).then(function() { | 290 | + }).then(() => { |
| 291 | + this.exportLoading = true; | ||
| 289 | return exportMerchantExcel(params); | 292 | return exportMerchantExcel(params); |
| 290 | }).then(response => { | 293 | }).then(response => { |
| 291 | this.downloadExcel(response, '支付商户信息.xls'); | 294 | this.downloadExcel(response, '支付商户信息.xls'); |
| 295 | + this.exportLoading = false; | ||
| 292 | }) | 296 | }) |
| 293 | } | 297 | } |
| 294 | } | 298 | } |
yudao-ui-admin/src/views/system/dict/data.vue
| @@ -26,7 +26,7 @@ | @@ -26,7 +26,7 @@ | ||
| 26 | v-hasPermi="['system:dict:create']">新增</el-button> | 26 | v-hasPermi="['system:dict:create']">新增</el-button> |
| 27 | </el-col> | 27 | </el-col> |
| 28 | <el-col :span="1.5"> | 28 | <el-col :span="1.5"> |
| 29 | - <el-button type="warning" icon="el-icon-download" size="mini" @click="handleExport" | 29 | + <el-button type="warning" icon="el-icon-download" size="mini" @click="handleExport" :loading="exportLoading" |
| 30 | v-hasPermi="['system:dict:export']">导出</el-button> | 30 | v-hasPermi="['system:dict:export']">导出</el-button> |
| 31 | </el-col> | 31 | </el-col> |
| 32 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | 32 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> |
| @@ -102,6 +102,8 @@ export default { | @@ -102,6 +102,8 @@ export default { | ||
| 102 | return { | 102 | return { |
| 103 | // 遮罩层 | 103 | // 遮罩层 |
| 104 | loading: true, | 104 | loading: true, |
| 105 | + // 导出遮罩层 | ||
| 106 | + exportLoading: false, | ||
| 105 | // 显示搜索条件 | 107 | // 显示搜索条件 |
| 106 | showSearch: true, | 108 | showSearch: true, |
| 107 | // 总条数 | 109 | // 总条数 |
| @@ -266,11 +268,13 @@ export default { | @@ -266,11 +268,13 @@ export default { | ||
| 266 | confirmButtonText: "确定", | 268 | confirmButtonText: "确定", |
| 267 | cancelButtonText: "取消", | 269 | cancelButtonText: "取消", |
| 268 | type: "warning" | 270 | type: "warning" |
| 269 | - }).then(function() { | 271 | + }).then(() => { |
| 272 | + this.exportLoading = true; | ||
| 270 | return exportData(queryParams); | 273 | return exportData(queryParams); |
| 271 | }).then(response => { | 274 | }).then(response => { |
| 272 | this.downloadExcel(response, '字典数据.xls'); | 275 | this.downloadExcel(response, '字典数据.xls'); |
| 273 | - }) | 276 | + this.exportLoading = false; |
| 277 | + }) | ||
| 274 | } | 278 | } |
| 275 | } | 279 | } |
| 276 | }; | 280 | }; |
yudao-ui-admin/src/views/system/dict/index.vue
| @@ -28,7 +28,7 @@ | @@ -28,7 +28,7 @@ | ||
| 28 | v-hasPermi="['system:dict:create']">新增</el-button> | 28 | v-hasPermi="['system:dict:create']">新增</el-button> |
| 29 | </el-col> | 29 | </el-col> |
| 30 | <el-col :span="1.5"> | 30 | <el-col :span="1.5"> |
| 31 | - <el-button type="warning" icon="el-icon-download" size="mini" @click="handleExport" | 31 | + <el-button type="warning" icon="el-icon-download" size="mini" @click="handleExport" :loading="exportLoading" |
| 32 | v-hasPermi="['system:dict:export']">导出</el-button> | 32 | v-hasPermi="['system:dict:export']">导出</el-button> |
| 33 | </el-col> | 33 | </el-col> |
| 34 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | 34 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> |
| @@ -102,6 +102,8 @@ export default { | @@ -102,6 +102,8 @@ export default { | ||
| 102 | return { | 102 | return { |
| 103 | // 遮罩层 | 103 | // 遮罩层 |
| 104 | loading: true, | 104 | loading: true, |
| 105 | + // 导出遮罩层 | ||
| 106 | + exportLoading: false, | ||
| 105 | // 显示搜索条件 | 107 | // 显示搜索条件 |
| 106 | showSearch: true, | 108 | showSearch: true, |
| 107 | // 总条数 | 109 | // 总条数 |
| @@ -252,10 +254,12 @@ export default { | @@ -252,10 +254,12 @@ export default { | ||
| 252 | confirmButtonText: "确定", | 254 | confirmButtonText: "确定", |
| 253 | cancelButtonText: "取消", | 255 | cancelButtonText: "取消", |
| 254 | type: "warning" | 256 | type: "warning" |
| 255 | - }).then(function() { | 257 | + }).then(() => { |
| 258 | + this.exportLoading = true; | ||
| 256 | return exportType(params); | 259 | return exportType(params); |
| 257 | }).then(response => { | 260 | }).then(response => { |
| 258 | this.downloadExcel(response, '字典类型.xls'); | 261 | this.downloadExcel(response, '字典类型.xls'); |
| 262 | + this.exportLoading = false; | ||
| 259 | }) | 263 | }) |
| 260 | } | 264 | } |
| 261 | } | 265 | } |
yudao-ui-admin/src/views/system/errorCode/index.vue
| @@ -35,7 +35,7 @@ | @@ -35,7 +35,7 @@ | ||
| 35 | v-hasPermi="['system:error-code:create']">新增</el-button> | 35 | v-hasPermi="['system:error-code:create']">新增</el-button> |
| 36 | </el-col> | 36 | </el-col> |
| 37 | <el-col :span="1.5"> | 37 | <el-col :span="1.5"> |
| 38 | - <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" | 38 | + <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" :loading="exportLoading" |
| 39 | v-hasPermi="['system:error-code:export']">导出</el-button> | 39 | v-hasPermi="['system:error-code:export']">导出</el-button> |
| 40 | </el-col> | 40 | </el-col> |
| 41 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | 41 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> |
| @@ -106,6 +106,8 @@ export default { | @@ -106,6 +106,8 @@ export default { | ||
| 106 | return { | 106 | return { |
| 107 | // 遮罩层 | 107 | // 遮罩层 |
| 108 | loading: true, | 108 | loading: true, |
| 109 | + // 导出遮罩层 | ||
| 110 | + exportLoading: false, | ||
| 109 | // 显示搜索条件 | 111 | // 显示搜索条件 |
| 110 | showSearch: true, | 112 | showSearch: true, |
| 111 | // 总条数 | 113 | // 总条数 |
| @@ -245,10 +247,12 @@ export default { | @@ -245,10 +247,12 @@ export default { | ||
| 245 | confirmButtonText: "确定", | 247 | confirmButtonText: "确定", |
| 246 | cancelButtonText: "取消", | 248 | cancelButtonText: "取消", |
| 247 | type: "warning" | 249 | type: "warning" |
| 248 | - }).then(function() { | 250 | + }).then(() => { |
| 251 | + this.exportLoading = true; | ||
| 249 | return exportErrorCodeExcel(params); | 252 | return exportErrorCodeExcel(params); |
| 250 | }).then(response => { | 253 | }).then(response => { |
| 251 | this.downloadExcel(response, '错误码.xls'); | 254 | this.downloadExcel(response, '错误码.xls'); |
| 255 | + this.exportLoading = false; | ||
| 252 | }) | 256 | }) |
| 253 | } | 257 | } |
| 254 | } | 258 | } |
yudao-ui-admin/src/views/system/loginlog/index.vue
| @@ -27,7 +27,7 @@ | @@ -27,7 +27,7 @@ | ||
| 27 | 27 | ||
| 28 | <el-row :gutter="10" class="mb8"> | 28 | <el-row :gutter="10" class="mb8"> |
| 29 | <el-col :span="1.5"> | 29 | <el-col :span="1.5"> |
| 30 | - <el-button type="warning" icon="el-icon-download" size="mini" @click="handleExport" | 30 | + <el-button type="warning" icon="el-icon-download" size="mini" @click="handleExport" :loading="exportLoading" |
| 31 | v-hasPermi="['system:login-log:export']">导出</el-button> | 31 | v-hasPermi="['system:login-log:export']">导出</el-button> |
| 32 | </el-col> | 32 | </el-col> |
| 33 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | 33 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> |
| @@ -70,6 +70,8 @@ export default { | @@ -70,6 +70,8 @@ export default { | ||
| 70 | return { | 70 | return { |
| 71 | // 遮罩层 | 71 | // 遮罩层 |
| 72 | loading: true, | 72 | loading: true, |
| 73 | + // 导出遮罩层 | ||
| 74 | + exportLoading: false, | ||
| 73 | // 显示搜索条件 | 75 | // 显示搜索条件 |
| 74 | showSearch: true, | 76 | showSearch: true, |
| 75 | // 总条数 | 77 | // 总条数 |
| @@ -129,11 +131,13 @@ export default { | @@ -129,11 +131,13 @@ export default { | ||
| 129 | confirmButtonText: "确定", | 131 | confirmButtonText: "确定", |
| 130 | cancelButtonText: "取消", | 132 | cancelButtonText: "取消", |
| 131 | type: "warning" | 133 | type: "warning" |
| 132 | - }).then(function() { | 134 | + }).then(() => { |
| 135 | + this.exportLoading = true; | ||
| 133 | return exportLoginLog(queryParams); | 136 | return exportLoginLog(queryParams); |
| 134 | }).then(response => { | 137 | }).then(response => { |
| 135 | this.downloadExcel(response, '登录日志.xls'); | 138 | this.downloadExcel(response, '登录日志.xls'); |
| 136 | - }) | 139 | + this.exportLoading = false; |
| 140 | + }) | ||
| 137 | } | 141 | } |
| 138 | } | 142 | } |
| 139 | }; | 143 | }; |
yudao-ui-admin/src/views/system/operatelog/index.vue
| @@ -33,7 +33,7 @@ | @@ -33,7 +33,7 @@ | ||
| 33 | 33 | ||
| 34 | <el-row :gutter="10" class="mb8"> | 34 | <el-row :gutter="10" class="mb8"> |
| 35 | <el-col :span="1.5"> | 35 | <el-col :span="1.5"> |
| 36 | - <el-button type="warning" icon="el-icon-download" size="mini" @click="handleExport" | 36 | + <el-button type="warning" icon="el-icon-download" size="mini" @click="handleExport" :loading="exportLoading" |
| 37 | v-hasPermi="['system:operate-log:export']">导出</el-button> | 37 | v-hasPermi="['system:operate-log:export']">导出</el-button> |
| 38 | </el-col> | 38 | </el-col> |
| 39 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | 39 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> |
| @@ -138,6 +138,8 @@ export default { | @@ -138,6 +138,8 @@ export default { | ||
| 138 | return { | 138 | return { |
| 139 | // 遮罩层 | 139 | // 遮罩层 |
| 140 | loading: true, | 140 | loading: true, |
| 141 | + // 导出遮罩层 | ||
| 142 | + exportLoading: false, | ||
| 141 | // 显示搜索条件 | 143 | // 显示搜索条件 |
| 142 | showSearch: true, | 144 | showSearch: true, |
| 143 | // 总条数 | 145 | // 总条数 |
| @@ -216,11 +218,13 @@ export default { | @@ -216,11 +218,13 @@ export default { | ||
| 216 | confirmButtonText: "确定", | 218 | confirmButtonText: "确定", |
| 217 | cancelButtonText: "取消", | 219 | cancelButtonText: "取消", |
| 218 | type: "warning" | 220 | type: "warning" |
| 219 | - }).then(function() { | 221 | + }).then(() => { |
| 222 | + this.exportLoading = true; | ||
| 220 | return exportOperateLog(queryParams); | 223 | return exportOperateLog(queryParams); |
| 221 | }).then(response => { | 224 | }).then(response => { |
| 222 | this.downloadExcel(response, '操作日志.xls'); | 225 | this.downloadExcel(response, '操作日志.xls'); |
| 223 | - }) | 226 | + this.exportLoading = false; |
| 227 | + }) | ||
| 224 | } | 228 | } |
| 225 | } | 229 | } |
| 226 | }; | 230 | }; |
yudao-ui-admin/src/views/system/post/index.vue
| @@ -24,7 +24,7 @@ | @@ -24,7 +24,7 @@ | ||
| 24 | v-hasPermi="['system:post:create']">新增</el-button> | 24 | v-hasPermi="['system:post:create']">新增</el-button> |
| 25 | </el-col> | 25 | </el-col> |
| 26 | <el-col :span="1.5"> | 26 | <el-col :span="1.5"> |
| 27 | - <el-button type="warning" icon="el-icon-download" size="mini" @click="handleExport" | 27 | + <el-button type="warning" icon="el-icon-download" size="mini" @click="handleExport" :loading="exportLoading" |
| 28 | v-hasPermi="['system:post:export']">导出</el-button> | 28 | v-hasPermi="['system:post:export']">导出</el-button> |
| 29 | </el-col> | 29 | </el-col> |
| 30 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | 30 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> |
| @@ -96,6 +96,8 @@ export default { | @@ -96,6 +96,8 @@ export default { | ||
| 96 | return { | 96 | return { |
| 97 | // 遮罩层 | 97 | // 遮罩层 |
| 98 | loading: true, | 98 | loading: true, |
| 99 | + // 导出遮罩层 | ||
| 100 | + exportLoading: false, | ||
| 99 | // 显示搜索条件 | 101 | // 显示搜索条件 |
| 100 | showSearch: true, | 102 | showSearch: true, |
| 101 | // 总条数 | 103 | // 总条数 |
| @@ -238,11 +240,13 @@ export default { | @@ -238,11 +240,13 @@ export default { | ||
| 238 | confirmButtonText: "确定", | 240 | confirmButtonText: "确定", |
| 239 | cancelButtonText: "取消", | 241 | cancelButtonText: "取消", |
| 240 | type: "warning" | 242 | type: "warning" |
| 241 | - }).then(function() { | 243 | + }).then(() => { |
| 244 | + this.exportLoading = true; | ||
| 242 | return exportPost(queryParams); | 245 | return exportPost(queryParams); |
| 243 | }).then(response => { | 246 | }).then(response => { |
| 244 | - this.downloadExcel(response, '岗位数据.xls'); | ||
| 245 | - }) | 247 | + this.downloadExcel(response, '岗位数据.xls'); |
| 248 | + this.exportLoading = false; | ||
| 249 | + }) | ||
| 246 | } | 250 | } |
| 247 | } | 251 | } |
| 248 | }; | 252 | }; |
yudao-ui-admin/src/views/system/role/index.vue
| @@ -30,7 +30,7 @@ | @@ -30,7 +30,7 @@ | ||
| 30 | v-hasPermi="['system:role:create']">新增</el-button> | 30 | v-hasPermi="['system:role:create']">新增</el-button> |
| 31 | </el-col> | 31 | </el-col> |
| 32 | <el-col :span="1.5"> | 32 | <el-col :span="1.5"> |
| 33 | - <el-button type="warning" icon="el-icon-download" size="mini" @click="handleExport" | 33 | + <el-button type="warning" icon="el-icon-download" size="mini" @click="handleExport" :loading="exportLoading" |
| 34 | v-hasPermi="['system:role:export']">导出</el-button> | 34 | v-hasPermi="['system:role:export']">导出</el-button> |
| 35 | </el-col> | 35 | </el-col> |
| 36 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | 36 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> |
| @@ -188,6 +188,8 @@ export default { | @@ -188,6 +188,8 @@ export default { | ||
| 188 | return { | 188 | return { |
| 189 | // 遮罩层 | 189 | // 遮罩层 |
| 190 | loading: true, | 190 | loading: true, |
| 191 | + // 导出遮罩层 | ||
| 192 | + exportLoading: false, | ||
| 191 | // 显示搜索条件 | 193 | // 显示搜索条件 |
| 192 | showSearch: true, | 194 | showSearch: true, |
| 193 | // 总条数 | 195 | // 总条数 |
| @@ -504,10 +506,12 @@ export default { | @@ -504,10 +506,12 @@ export default { | ||
| 504 | cancelButtonText: "取消", | 506 | cancelButtonText: "取消", |
| 505 | type: "warning" | 507 | type: "warning" |
| 506 | }).then(function() { | 508 | }).then(function() { |
| 509 | + this.exportLoading = true; | ||
| 507 | return exportRole(queryParams); | 510 | return exportRole(queryParams); |
| 508 | }).then(response => { | 511 | }).then(response => { |
| 509 | this.downloadExcel(response, '角色数据.xls'); | 512 | this.downloadExcel(response, '角色数据.xls'); |
| 510 | - }) | 513 | + this.exportLoading = false; |
| 514 | + }) | ||
| 511 | } | 515 | } |
| 512 | } | 516 | } |
| 513 | }; | 517 | }; |
yudao-ui-admin/src/views/system/sms/smsChannel.vue
| @@ -28,10 +28,6 @@ | @@ -28,10 +28,6 @@ | ||
| 28 | <el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd" | 28 | <el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd" |
| 29 | v-hasPermi="['system:sms-channel:create']">新增</el-button> | 29 | v-hasPermi="['system:sms-channel:create']">新增</el-button> |
| 30 | </el-col> | 30 | </el-col> |
| 31 | - <el-col :span="1.5"> | ||
| 32 | - <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" | ||
| 33 | - v-hasPermi="['system:sms-channel:export']">导出</el-button> | ||
| 34 | - </el-col> | ||
| 35 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | 31 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> |
| 36 | </el-row> | 32 | </el-row> |
| 37 | 33 | ||
| @@ -247,295 +243,6 @@ export default { | @@ -247,295 +243,6 @@ export default { | ||
| 247 | this.getList(); | 243 | this.getList(); |
| 248 | this.msgSuccess("删除成功"); | 244 | this.msgSuccess("删除成功"); |
| 249 | }) | 245 | }) |
| 250 | - }, | ||
| 251 | - /** 导出按钮操作 */ | ||
| 252 | - handleExport() { | ||
| 253 | - // 处理查询参数 | ||
| 254 | - let params = {...this.queryParams}; | ||
| 255 | - params.pageNo = undefined; | ||
| 256 | - params.pageSize = undefined; | ||
| 257 | - this.addBeginAndEndTime(params, this.dateRangeCreateTime, 'createTime'); | ||
| 258 | - // 执行导出 | ||
| 259 | - this.$confirm('是否确认导出所有短信渠道数据项?', "警告", { | ||
| 260 | - confirmButtonText: "确定", | ||
| 261 | - cancelButtonText: "取消", | ||
| 262 | - type: "warning" | ||
| 263 | - }).then(function() { | ||
| 264 | - return exportSmsChannelExcel(params); | ||
| 265 | - }).then(response => { | ||
| 266 | - this.downloadExcel(response, '短信渠道.xls'); | ||
| 267 | - }) | ||
| 268 | - } | ||
| 269 | - } | ||
| 270 | -}; | ||
| 271 | -</script><template> | ||
| 272 | - <div class="app-container"> | ||
| 273 | - | ||
| 274 | - <!-- 搜索工作栏 --> | ||
| 275 | - <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px"> | ||
| 276 | - <el-form-item label="短信签名" prop="signature"> | ||
| 277 | - <el-input v-model="queryParams.signature" placeholder="请输入短信签名" clearable size="small" @keyup.enter.native="handleQuery"/> | ||
| 278 | - </el-form-item> | ||
| 279 | - <el-form-item label="启用状态" prop="status"> | ||
| 280 | - <el-select v-model="queryParams.status" placeholder="请选择启用状态" clearable size="small"> | ||
| 281 | - <el-option v-for="dict in this.getDictDatas(DICT_TYPE.COMMON_STATUS)" | ||
| 282 | - :key="dict.value" :label="dict.label" :value="dict.value"/> | ||
| 283 | - </el-select> | ||
| 284 | - </el-form-item> | ||
| 285 | - <el-form-item label="创建时间"> | ||
| 286 | - <el-date-picker v-model="dateRangeCreateTime" size="small" style="width: 240px" value-format="yyyy-MM-dd" | ||
| 287 | - type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期" /> | ||
| 288 | - </el-form-item> | ||
| 289 | - <el-form-item> | ||
| 290 | - <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button> | ||
| 291 | - <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button> | ||
| 292 | - </el-form-item> | ||
| 293 | - </el-form> | ||
| 294 | - | ||
| 295 | - <!-- 操作工具栏 --> | ||
| 296 | - <el-row :gutter="10" class="mb8"> | ||
| 297 | - <el-col :span="1.5"> | ||
| 298 | - <el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd" | ||
| 299 | - v-hasPermi="['system:sms-channel:create']">新增</el-button> | ||
| 300 | - </el-col> | ||
| 301 | - <el-col :span="1.5"> | ||
| 302 | - <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" | ||
| 303 | - v-hasPermi="['system:sms-channel:export']">导出</el-button> | ||
| 304 | - </el-col> | ||
| 305 | - <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | ||
| 306 | - </el-row> | ||
| 307 | - | ||
| 308 | - <!-- 列表 --> | ||
| 309 | - <el-table v-loading="loading" :data="list"> | ||
| 310 | - <el-table-column label="编号" align="center" prop="id" /> | ||
| 311 | - <el-table-column label="短信签名" align="center" prop="signature" /> | ||
| 312 | - <el-table-column label="渠道编码" align="center" prop="code"> | ||
| 313 | - <template slot-scope="scope"> | ||
| 314 | - <span>{{ getDictDataLabel(DICT_TYPE.SYSTEM_SMS_CHANNEL_CODE, scope.row.code) }}</span> | ||
| 315 | - </template> | ||
| 316 | - </el-table-column>> | ||
| 317 | - <el-table-column label="启用状态" align="center" prop="status"> | ||
| 318 | - <template slot-scope="scope"> | ||
| 319 | - <span>{{ getDictDataLabel(DICT_TYPE.COMMON_STATUS, scope.row.status) }}</span> | ||
| 320 | - </template> | ||
| 321 | - </el-table-column>> | ||
| 322 | - <el-table-column label="备注" align="center" prop="remark" /> | ||
| 323 | - <el-table-column label="创建时间" align="center" prop="createTime" width="180"> | ||
| 324 | - <template slot-scope="scope"> | ||
| 325 | - <span>{{ parseTime(scope.row.createTime) }}</span> | ||
| 326 | - </template> | ||
| 327 | - </el-table-column> | ||
| 328 | - <el-table-column label="操作" align="center" class-name="small-padding fixed-width"> | ||
| 329 | - <template slot-scope="scope"> | ||
| 330 | - <el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)" | ||
| 331 | - v-hasPermi="['system:sms-channel:update']">修改</el-button> | ||
| 332 | - <el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)" | ||
| 333 | - v-hasPermi="['system:sms-channel:delete']">删除</el-button> | ||
| 334 | - </template> | ||
| 335 | - </el-table-column> | ||
| 336 | - </el-table> | ||
| 337 | - <!-- 分页组件 --> | ||
| 338 | - <pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNo" :limit.sync="queryParams.pageSize" | ||
| 339 | - @pagination="getList"/> | ||
| 340 | - | ||
| 341 | - <!-- 对话框(添加 / 修改) --> | ||
| 342 | - <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body> | ||
| 343 | - <el-form ref="form" :model="form" :rules="rules" label-width="130px"> | ||
| 344 | - <el-form-item label="短信签名" prop="signature"> | ||
| 345 | - <el-input v-model="form.signature" placeholder="请输入短信签名" /> | ||
| 346 | - </el-form-item> | ||
| 347 | - <el-form-item label="渠道编码" prop="code"> | ||
| 348 | - <el-select v-model="form.code" placeholder="请选择渠道编码" :disabled="form.id > 0"> | ||
| 349 | - <el-option v-for="dict in this.getDictDatas(DICT_TYPE.SYSTEM_SMS_CHANNEL_CODE)" | ||
| 350 | - :key="dict.value" :label="dict.label" :value="dict.value" /> | ||
| 351 | - </el-select> | ||
| 352 | - </el-form-item> | ||
| 353 | - <el-form-item label="启用状态"> | ||
| 354 | - <el-radio-group v-model="form.status"> | ||
| 355 | - <el-radio v-for="dict in this.getDictDatas(DICT_TYPE.COMMON_STATUS)" | ||
| 356 | - :key="dict.value" :label="parseInt(dict.value)">{{dict.label}}</el-radio> | ||
| 357 | - </el-radio-group> | ||
| 358 | - </el-form-item> | ||
| 359 | - <el-form-item label="备注" prop="remark"> | ||
| 360 | - <el-input v-model="form.remark" placeholder="请输入备注" /> | ||
| 361 | - </el-form-item> | ||
| 362 | - <el-form-item label="短信 API 的账号" prop="apiKey"> | ||
| 363 | - <el-input v-model="form.apiKey" placeholder="请输入短信 API 的账号" /> | ||
| 364 | - </el-form-item> | ||
| 365 | - <el-form-item v-if="form.code !== 'YUN_PIAN'" label="短信 API 的秘钥" prop="apiSecret"> | ||
| 366 | - <el-input v-model="form.apiSecret" placeholder="请输入短信 API 的秘钥" /> | ||
| 367 | - </el-form-item> | ||
| 368 | - <el-form-item label="短信发送回调 URL" prop="callbackUrl"> | ||
| 369 | - <el-input v-model="form.callbackUrl" placeholder="请输入短信发送回调 URL" /> | ||
| 370 | - </el-form-item> | ||
| 371 | - </el-form> | ||
| 372 | - <div slot="footer" class="dialog-footer"> | ||
| 373 | - <el-button type="primary" @click="submitForm">确 定</el-button> | ||
| 374 | - <el-button @click="cancel">取 消</el-button> | ||
| 375 | - </div> | ||
| 376 | - </el-dialog> | ||
| 377 | - </div> | ||
| 378 | -</template> | ||
| 379 | - | ||
| 380 | -<script> | ||
| 381 | -import { createSmsChannel, updateSmsChannel, deleteSmsChannel, getSmsChannel, getSmsChannelPage } from "@/api/system/sms/smsChannel"; | ||
| 382 | - | ||
| 383 | -export default { | ||
| 384 | - name: "SmsChannel", | ||
| 385 | - components: { | ||
| 386 | - }, | ||
| 387 | - data() { | ||
| 388 | - return { | ||
| 389 | - // 遮罩层 | ||
| 390 | - loading: true, | ||
| 391 | - // 显示搜索条件 | ||
| 392 | - showSearch: true, | ||
| 393 | - // 总条数 | ||
| 394 | - total: 0, | ||
| 395 | - // 短信渠道列表 | ||
| 396 | - list: [], | ||
| 397 | - // 弹出层标题 | ||
| 398 | - title: "", | ||
| 399 | - // 是否显示弹出层 | ||
| 400 | - open: false, | ||
| 401 | - dateRangeCreateTime: [], | ||
| 402 | - // 查询参数 | ||
| 403 | - queryParams: { | ||
| 404 | - pageNo: 1, | ||
| 405 | - pageSize: 10, | ||
| 406 | - signature: null, | ||
| 407 | - status: null, | ||
| 408 | - }, | ||
| 409 | - // 表单参数 | ||
| 410 | - form: {}, | ||
| 411 | - // 表单校验 | ||
| 412 | - apiKeyEnableChannelCodes: ['YUN_PIAN'], | ||
| 413 | - rules: { | ||
| 414 | - signature: [{ required: true, message: "短信签名不能为空", trigger: "blur" }], | ||
| 415 | - code: [{ required: true, message: "渠道编码不能为空", trigger: "blur" }], | ||
| 416 | - status: [{ required: true, message: "启用状态不能为空", trigger: "blur" }], | ||
| 417 | - apiKey: [{ required: true, message: "短信 API 的账号不能为空", trigger: "blur" }], | ||
| 418 | - apiSecret: [{ required: true, message: "短信 API 的秘钥不能为空", trigger: "blur" }], | ||
| 419 | - } | ||
| 420 | - }; | ||
| 421 | - }, | ||
| 422 | - created() { | ||
| 423 | - this.getList(); | ||
| 424 | - }, | ||
| 425 | - methods: { | ||
| 426 | - /** 查询列表 */ | ||
| 427 | - getList() { | ||
| 428 | - this.loading = true; | ||
| 429 | - // 处理查询参数 | ||
| 430 | - let params = {...this.queryParams}; | ||
| 431 | - this.addBeginAndEndTime(params, this.dateRangeCreateTime, 'createTime'); | ||
| 432 | - // 执行查询 | ||
| 433 | - getSmsChannelPage(params).then(response => { | ||
| 434 | - this.list = response.data.list; | ||
| 435 | - this.total = response.data.total; | ||
| 436 | - this.loading = false; | ||
| 437 | - }); | ||
| 438 | - }, | ||
| 439 | - /** 取消按钮 */ | ||
| 440 | - cancel() { | ||
| 441 | - this.open = false; | ||
| 442 | - this.reset(); | ||
| 443 | - }, | ||
| 444 | - /** 表单重置 */ | ||
| 445 | - reset() { | ||
| 446 | - this.form = { | ||
| 447 | - id: undefined, | ||
| 448 | - signature: undefined, | ||
| 449 | - code: undefined, | ||
| 450 | - status: undefined, | ||
| 451 | - remark: undefined, | ||
| 452 | - apiKey: undefined, | ||
| 453 | - apiSecret: undefined, | ||
| 454 | - callbackUrl: undefined, | ||
| 455 | - }; | ||
| 456 | - this.resetForm("form"); | ||
| 457 | - }, | ||
| 458 | - /** 搜索按钮操作 */ | ||
| 459 | - handleQuery() { | ||
| 460 | - this.queryParams.pageNo = 1; | ||
| 461 | - this.getList(); | ||
| 462 | - }, | ||
| 463 | - /** 重置按钮操作 */ | ||
| 464 | - resetQuery() { | ||
| 465 | - this.dateRangeCreateTime = []; | ||
| 466 | - this.resetForm("queryForm"); | ||
| 467 | - this.handleQuery(); | ||
| 468 | - }, | ||
| 469 | - /** 新增按钮操作 */ | ||
| 470 | - handleAdd() { | ||
| 471 | - this.reset(); | ||
| 472 | - this.open = true; | ||
| 473 | - this.title = "添加短信渠道"; | ||
| 474 | - }, | ||
| 475 | - /** 修改按钮操作 */ | ||
| 476 | - handleUpdate(row) { | ||
| 477 | - this.reset(); | ||
| 478 | - const id = row.id; | ||
| 479 | - getSmsChannel(id).then(response => { | ||
| 480 | - this.form = response.data; | ||
| 481 | - this.open = true; | ||
| 482 | - this.title = "修改短信渠道"; | ||
| 483 | - }); | ||
| 484 | - }, | ||
| 485 | - /** 提交按钮 */ | ||
| 486 | - submitForm() { | ||
| 487 | - this.$refs["form"].validate(valid => { | ||
| 488 | - if (!valid) { | ||
| 489 | - return; | ||
| 490 | - } | ||
| 491 | - // 修改的提交 | ||
| 492 | - if (this.form.id != null) { | ||
| 493 | - updateSmsChannel(this.form).then(response => { | ||
| 494 | - this.msgSuccess("修改成功"); | ||
| 495 | - this.open = false; | ||
| 496 | - this.getList(); | ||
| 497 | - }); | ||
| 498 | - return; | ||
| 499 | - } | ||
| 500 | - // 添加的提交 | ||
| 501 | - createSmsChannel(this.form).then(response => { | ||
| 502 | - this.msgSuccess("新增成功"); | ||
| 503 | - this.open = false; | ||
| 504 | - this.getList(); | ||
| 505 | - }); | ||
| 506 | - }); | ||
| 507 | - }, | ||
| 508 | - /** 删除按钮操作 */ | ||
| 509 | - handleDelete(row) { | ||
| 510 | - const id = row.id; | ||
| 511 | - this.$confirm('是否确认删除短信渠道编号为"' + id + '"的数据项?', "警告", { | ||
| 512 | - confirmButtonText: "确定", | ||
| 513 | - cancelButtonText: "取消", | ||
| 514 | - type: "warning" | ||
| 515 | - }).then(function() { | ||
| 516 | - return deleteSmsChannel(id); | ||
| 517 | - }).then(() => { | ||
| 518 | - this.getList(); | ||
| 519 | - this.msgSuccess("删除成功"); | ||
| 520 | - }) | ||
| 521 | - }, | ||
| 522 | - /** 导出按钮操作 */ | ||
| 523 | - handleExport() { | ||
| 524 | - // 处理查询参数 | ||
| 525 | - let params = {...this.queryParams}; | ||
| 526 | - params.pageNo = undefined; | ||
| 527 | - params.pageSize = undefined; | ||
| 528 | - this.addBeginAndEndTime(params, this.dateRangeCreateTime, 'createTime'); | ||
| 529 | - // 执行导出 | ||
| 530 | - this.$confirm('是否确认导出所有短信渠道数据项?', "警告", { | ||
| 531 | - confirmButtonText: "确定", | ||
| 532 | - cancelButtonText: "取消", | ||
| 533 | - type: "warning" | ||
| 534 | - }).then(function() { | ||
| 535 | - return exportSmsChannelExcel(params); | ||
| 536 | - }).then(response => { | ||
| 537 | - this.downloadExcel(response, '短信渠道.xls'); | ||
| 538 | - }) | ||
| 539 | } | 246 | } |
| 540 | } | 247 | } |
| 541 | }; | 248 | }; |
yudao-ui-admin/src/views/system/sms/smsLog.vue
| @@ -49,7 +49,7 @@ | @@ -49,7 +49,7 @@ | ||
| 49 | v-hasPermi="['system:sms-log:create']">新增</el-button> | 49 | v-hasPermi="['system:sms-log:create']">新增</el-button> |
| 50 | </el-col> | 50 | </el-col> |
| 51 | <el-col :span="1.5"> | 51 | <el-col :span="1.5"> |
| 52 | - <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" | 52 | + <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" :loading="exportLoading" |
| 53 | v-hasPermi="['system:sms-log:export']">导出</el-button> | 53 | v-hasPermi="['system:sms-log:export']">导出</el-button> |
| 54 | </el-col> | 54 | </el-col> |
| 55 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | 55 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> |
| @@ -195,6 +195,8 @@ export default { | @@ -195,6 +195,8 @@ export default { | ||
| 195 | return { | 195 | return { |
| 196 | // 遮罩层 | 196 | // 遮罩层 |
| 197 | loading: true, | 197 | loading: true, |
| 198 | + // 导出遮罩层 | ||
| 199 | + exportLoading: false, | ||
| 198 | // 显示搜索条件 | 200 | // 显示搜索条件 |
| 199 | showSearch: true, | 201 | showSearch: true, |
| 200 | // 总条数 | 202 | // 总条数 |
| @@ -275,10 +277,12 @@ export default { | @@ -275,10 +277,12 @@ export default { | ||
| 275 | confirmButtonText: "确定", | 277 | confirmButtonText: "确定", |
| 276 | cancelButtonText: "取消", | 278 | cancelButtonText: "取消", |
| 277 | type: "warning" | 279 | type: "warning" |
| 278 | - }).then(function() { | 280 | + }).then(() => { |
| 281 | + this.exportLoading = true; | ||
| 279 | return exportSmsLogExcel(params); | 282 | return exportSmsLogExcel(params); |
| 280 | }).then(response => { | 283 | }).then(response => { |
| 281 | this.downloadExcel(response, '短信日志.xls'); | 284 | this.downloadExcel(response, '短信日志.xls'); |
| 285 | + this.exportLoading = false; | ||
| 282 | }) | 286 | }) |
| 283 | }, | 287 | }, |
| 284 | /** 详细按钮操作 */ | 288 | /** 详细按钮操作 */ |
yudao-ui-admin/src/views/system/sms/smsTemplate.vue
| @@ -45,7 +45,7 @@ | @@ -45,7 +45,7 @@ | ||
| 45 | v-hasPermi="['system:sms-template:create']">新增</el-button> | 45 | v-hasPermi="['system:sms-template:create']">新增</el-button> |
| 46 | </el-col> | 46 | </el-col> |
| 47 | <el-col :span="1.5"> | 47 | <el-col :span="1.5"> |
| 48 | - <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" | 48 | + <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" :loading="exportLoading" |
| 49 | v-hasPermi="['system:sms-template:export']">导出</el-button> | 49 | v-hasPermi="['system:sms-template:export']">导出</el-button> |
| 50 | </el-col> | 50 | </el-col> |
| 51 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | 51 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> |
| @@ -171,6 +171,8 @@ export default { | @@ -171,6 +171,8 @@ export default { | ||
| 171 | return { | 171 | return { |
| 172 | // 遮罩层 | 172 | // 遮罩层 |
| 173 | loading: true, | 173 | loading: true, |
| 174 | + // 导出遮罩层 | ||
| 175 | + exportLoading: false, | ||
| 174 | // 显示搜索条件 | 176 | // 显示搜索条件 |
| 175 | showSearch: true, | 177 | showSearch: true, |
| 176 | // 总条数 | 178 | // 总条数 |
| @@ -336,10 +338,12 @@ export default { | @@ -336,10 +338,12 @@ export default { | ||
| 336 | confirmButtonText: "确定", | 338 | confirmButtonText: "确定", |
| 337 | cancelButtonText: "取消", | 339 | cancelButtonText: "取消", |
| 338 | type: "warning" | 340 | type: "warning" |
| 339 | - }).then(function() { | 341 | + }).then(() => { |
| 342 | + this.exportLoading = true; | ||
| 340 | return exportSmsTemplateExcel(params); | 343 | return exportSmsTemplateExcel(params); |
| 341 | }).then(response => { | 344 | }).then(response => { |
| 342 | this.downloadExcel(response, '短信模板.xls'); | 345 | this.downloadExcel(response, '短信模板.xls'); |
| 346 | + this.exportLoading = false; | ||
| 343 | }) | 347 | }) |
| 344 | }, | 348 | }, |
| 345 | /** 发送短息按钮 */ | 349 | /** 发送短息按钮 */ |
yudao-ui-admin/src/views/system/tenant/index.vue
| @@ -35,7 +35,7 @@ | @@ -35,7 +35,7 @@ | ||
| 35 | v-hasPermi="['system:tenant:create']">新增</el-button> | 35 | v-hasPermi="['system:tenant:create']">新增</el-button> |
| 36 | </el-col> | 36 | </el-col> |
| 37 | <el-col :span="1.5"> | 37 | <el-col :span="1.5"> |
| 38 | - <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" | 38 | + <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" :loading="exportLoading" |
| 39 | v-hasPermi="['system:tenant:export']">导出</el-button> | 39 | v-hasPermi="['system:tenant:export']">导出</el-button> |
| 40 | </el-col> | 40 | </el-col> |
| 41 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | 41 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> |
| @@ -109,6 +109,8 @@ export default { | @@ -109,6 +109,8 @@ export default { | ||
| 109 | return { | 109 | return { |
| 110 | // 遮罩层 | 110 | // 遮罩层 |
| 111 | loading: true, | 111 | loading: true, |
| 112 | + // 导出遮罩层 | ||
| 113 | + exportLoading: false, | ||
| 112 | // 显示搜索条件 | 114 | // 显示搜索条件 |
| 113 | showSearch: true, | 115 | showSearch: true, |
| 114 | // 总条数 | 116 | // 总条数 |
| @@ -248,11 +250,13 @@ export default { | @@ -248,11 +250,13 @@ export default { | ||
| 248 | confirmButtonText: "确定", | 250 | confirmButtonText: "确定", |
| 249 | cancelButtonText: "取消", | 251 | cancelButtonText: "取消", |
| 250 | type: "warning" | 252 | type: "warning" |
| 251 | - }).then(function() { | 253 | + }).then(() => { |
| 254 | + this.exportLoading = true; | ||
| 252 | return exportTenantExcel(params); | 255 | return exportTenantExcel(params); |
| 253 | }).then(response => { | 256 | }).then(response => { |
| 254 | this.downloadExcel(response, '租户.xls'); | 257 | this.downloadExcel(response, '租户.xls'); |
| 255 | - }) | 258 | + this.exportLoading = false; |
| 259 | + }) | ||
| 256 | } | 260 | } |
| 257 | } | 261 | } |
| 258 | }; | 262 | }; |
yudao-ui-admin/src/views/system/user/index.vue
| @@ -47,7 +47,7 @@ | @@ -47,7 +47,7 @@ | ||
| 47 | v-hasPermi="['system:user:import']">导入</el-button> | 47 | v-hasPermi="['system:user:import']">导入</el-button> |
| 48 | </el-col> | 48 | </el-col> |
| 49 | <el-col :span="1.5"> | 49 | <el-col :span="1.5"> |
| 50 | - <el-button type="warning" icon="el-icon-download" size="mini" @click="handleExport" | 50 | + <el-button type="warning" icon="el-icon-download" size="mini" @click="handleExport" :loading="exportLoading" |
| 51 | v-hasPermi="['system:user:export']">导出</el-button> | 51 | v-hasPermi="['system:user:export']">导出</el-button> |
| 52 | </el-col> | 52 | </el-col> |
| 53 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList" :columns="columns"></right-toolbar> | 53 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList" :columns="columns"></right-toolbar> |
| @@ -261,6 +261,8 @@ export default { | @@ -261,6 +261,8 @@ export default { | ||
| 261 | return { | 261 | return { |
| 262 | // 遮罩层 | 262 | // 遮罩层 |
| 263 | loading: true, | 263 | loading: true, |
| 264 | + // 导出遮罩层 | ||
| 265 | + exportLoading: false, | ||
| 264 | // 显示搜索条件 | 266 | // 显示搜索条件 |
| 265 | showSearch: true, | 267 | showSearch: true, |
| 266 | // 总条数 | 268 | // 总条数 |
| @@ -599,11 +601,13 @@ export default { | @@ -599,11 +601,13 @@ export default { | ||
| 599 | confirmButtonText: "确定", | 601 | confirmButtonText: "确定", |
| 600 | cancelButtonText: "取消", | 602 | cancelButtonText: "取消", |
| 601 | type: "warning" | 603 | type: "warning" |
| 602 | - }).then(function() { | 604 | + }).then(() => { |
| 605 | + this.exportLoading = true; | ||
| 603 | return exportUser(queryParams); | 606 | return exportUser(queryParams); |
| 604 | }).then(response => { | 607 | }).then(response => { |
| 605 | this.downloadExcel(response, '用户数据.xls'); | 608 | this.downloadExcel(response, '用户数据.xls'); |
| 606 | - }) | 609 | + this.exportLoading = false; |
| 610 | + }) | ||
| 607 | }, | 611 | }, |
| 608 | /** 导入按钮操作 */ | 612 | /** 导入按钮操作 */ |
| 609 | handleImport() { | 613 | handleImport() { |
yudao-ui-admin/src/views/tool/testDemo/index.vue
| @@ -39,7 +39,7 @@ | @@ -39,7 +39,7 @@ | ||
| 39 | v-hasPermi="['tool:test-demo:create']">新增</el-button> | 39 | v-hasPermi="['tool:test-demo:create']">新增</el-button> |
| 40 | </el-col> | 40 | </el-col> |
| 41 | <el-col :span="1.5"> | 41 | <el-col :span="1.5"> |
| 42 | - <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" | 42 | + <el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" :loading="exportLoading" |
| 43 | v-hasPermi="['tool:test-demo:export']">导出</el-button> | 43 | v-hasPermi="['tool:test-demo:export']">导出</el-button> |
| 44 | </el-col> | 44 | </el-col> |
| 45 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> | 45 | <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> |
| @@ -113,6 +113,8 @@ export default { | @@ -113,6 +113,8 @@ export default { | ||
| 113 | return { | 113 | return { |
| 114 | // 遮罩层 | 114 | // 遮罩层 |
| 115 | loading: true, | 115 | loading: true, |
| 116 | + // 导出遮罩层 | ||
| 117 | + exportLoading: false, | ||
| 116 | // 显示搜索条件 | 118 | // 显示搜索条件 |
| 117 | showSearch: true, | 119 | showSearch: true, |
| 118 | // 总条数 | 120 | // 总条数 |
| @@ -255,11 +257,13 @@ export default { | @@ -255,11 +257,13 @@ export default { | ||
| 255 | confirmButtonText: "确定", | 257 | confirmButtonText: "确定", |
| 256 | cancelButtonText: "取消", | 258 | cancelButtonText: "取消", |
| 257 | type: "warning" | 259 | type: "warning" |
| 258 | - }).then(function() { | 260 | + }).then(() => { |
| 261 | + this.exportLoading = true; | ||
| 259 | return exportTestDemoExcel(params); | 262 | return exportTestDemoExcel(params); |
| 260 | }).then(response => { | 263 | }).then(response => { |
| 261 | this.downloadExcel(response, '字典类型.xls'); | 264 | this.downloadExcel(response, '字典类型.xls'); |
| 262 | - }) | 265 | + this.exportLoading = false; |
| 266 | + }) | ||
| 263 | } | 267 | } |
| 264 | } | 268 | } |
| 265 | }; | 269 | }; |