Commit f7958dcf40afc23a5c467a1ddb159291b7fa59aa
Merge remote-tracking branch 'origin/fix/master' into feature/1.8.0-uniapp
# Conflicts: # yudao-ui-admin/src/components/ImageUpload/index.vue
Showing
4 changed files
with
13 additions
and
7 deletions
yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/vue/views/index.vue.vm
| ... | ... | @@ -390,7 +390,7 @@ export default { |
| 390 | 390 | this.exportLoading = true; |
| 391 | 391 | return export${simpleClassName}Excel(params); |
| 392 | 392 | }).then(response => { |
| 393 | - this.$download.excel(response, '${table.classComment}.xls'); | |
| 393 | + this.$download.excel(response, "${table.classComment}.xls"); | |
| 394 | 394 | this.exportLoading = false; |
| 395 | 395 | }).catch(() => {}); |
| 396 | 396 | } | ... | ... |
yudao-ui-admin/src/components/ImageUpload/index.vue
| ... | ... | @@ -43,7 +43,7 @@ |
| 43 | 43 | </template> |
| 44 | 44 | |
| 45 | 45 | <script> |
| 46 | -import { getToken } from "@/utils/auth"; | |
| 46 | +import {getToken} from "@/utils/auth"; | |
| 47 | 47 | |
| 48 | 48 | export default { |
| 49 | 49 | props: { |
| ... | ... | @@ -95,9 +95,9 @@ export default { |
| 95 | 95 | if (typeof item === "string") { |
| 96 | 96 | // 不带有 http 的路径, 才拼接 baseUrl. |
| 97 | 97 | if (item.indexOf("http") === -1) { |
| 98 | - item = { name: this.baseUrl + item, url: this.baseUrl + item }; | |
| 98 | + item = {name: this.baseUrl + item, url: this.baseUrl + item}; | |
| 99 | 99 | } else { |
| 100 | - item = { name: item, url: item }; | |
| 100 | + item = {name: item, url: item}; | |
| 101 | 101 | } |
| 102 | 102 | } |
| 103 | 103 | return item; |
| ... | ... | @@ -128,7 +128,7 @@ export default { |
| 128 | 128 | }, |
| 129 | 129 | // 上传成功回调 |
| 130 | 130 | handleUploadSuccess(res) { |
| 131 | - this.uploadList.push({ name: res.data.fileName, url: res.data.fileUrl }); | |
| 131 | + this.uploadList.push({name: res.data.fileName, url: res.data.fileUrl}); | |
| 132 | 132 | if (this.uploadList.length === this.number) { |
| 133 | 133 | this.fileList = this.fileList.concat(this.uploadList); |
| 134 | 134 | this.uploadList = []; | ... | ... |
yudao-ui-admin/src/views/infra/swagger/index.vue
yudao-ui-admin/src/views/system/menu/index.vue
| 1 | 1 | <template> |
| 2 | 2 | <div class="app-container"> |
| 3 | 3 | <doc-alert title="功能权限" url="https://doc.iocoder.cn/resource-permission" /> |
| 4 | + <doc-alert title="菜单路由" url="https://doc.iocoder.cn/vue2/route/" /> | |
| 5 | + <!-- 搜索工作栏 --> | |
| 4 | 6 | <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch"> |
| 5 | 7 | <el-form-item label="菜单名称" prop="name"> |
| 6 | 8 | <el-input v-model="queryParams.name" placeholder="请输入菜单名称" clearable @keyup.enter.native="handleQuery"/> |
| ... | ... | @@ -187,6 +189,7 @@ import IconSelect from "@/components/IconSelect"; |
| 187 | 189 | |
| 188 | 190 | import { SystemMenuTypeEnum, CommonStatusEnum } from '@/utils/constants' |
| 189 | 191 | import { getDictDatas, DICT_TYPE } from '@/utils/dict' |
| 192 | +import {isExternal} from "@/utils/validate"; | |
| 190 | 193 | |
| 191 | 194 | export default { |
| 192 | 195 | name: "Menu", |
| ... | ... | @@ -344,7 +347,7 @@ export default { |
| 344 | 347 | || this.form.type === SystemMenuTypeEnum.MENU) { |
| 345 | 348 | // 如果是外链,则不进行校验 |
| 346 | 349 | const path = this.form.path |
| 347 | - if (path.indexOf('http://') === -1 || path.indexOf('https://') === -1) { | |
| 350 | + if (!isExternal(path)) { | |
| 348 | 351 | // 父权限为根节点,path 必须以 / 开头 |
| 349 | 352 | if (this.form.parentId === 0 && path.charAt(0) !== '/') { |
| 350 | 353 | this.$modal.msgSuccess('前端必须以 / 开头') | ... | ... |