BUG修改

This commit is contained in:
a0049873 2022-07-28 17:12:30 +08:00
parent e47d7cf470
commit fc524a6b43
2 changed files with 46 additions and 25 deletions

View File

@ -5,7 +5,6 @@ import { isURL } from '@/utils/validate'
import store from '@/store'
import Cookies from 'js-cookie'
// 解决ElementUI导航栏中的vue-router在3.0版本以上重复点菜单报错问题
const originalPush = Router.prototype.push
Router.prototype.push = function push (location) {
@ -42,7 +41,8 @@ export const moduleRoutes = {
meta: { title: '主入口布局' },
children: [
// todos 临时调整,后期去掉
{ path: '/home', redirect: '/bscatalogue-bscatalogue', component: () => import('@/views/modules/home'), name: 'home', meta: { title: '首页', isTab: true } },
// { path: '/home', redirect: '/bscatalogue-bscatalogue', component: () => import('@/views/modules/home'), name: 'home', meta: { title: '首页', isTab: true } },
{ path: '/home', redirect: '/workBench-workBench', component: () => import('@/views/modules/home'), name: 'home', meta: { title: '首页', isTab: true } },
{ path: '/iframe', component: null, name: 'iframe', meta: { title: 'iframe', isTab: true } }
]
}

View File

@ -56,6 +56,7 @@ import { isEmail, isMobile } from '@/utils/validate'
export default {
data () {
return {
submitFlag: true,
visible: false,
roleList: [],
roleIdListDefault: [],
@ -170,6 +171,22 @@ export default {
]).then(() => {
if (this.dataForm.id) {
this.getInfo()
} else {
this.dataForm = {
id: '',
username: '',
deptId: '',
deptName: '',
password: '',
confirmPassword: '',
realName: '',
gender: 0,
email: '',
mobile: '',
roleIdList: [],
postIdList: [],
status: 1
}
}
})
})
@ -219,6 +236,8 @@ export default {
if (!valid) {
return false
}
if (this.submitFlag) {
this.submitFlag = false
this.dataForm.password = Encrypt(this.dataForm.password)
if (this.dataForm.id) {
delete this.dataForm.password
@ -242,7 +261,9 @@ export default {
this.$emit('refreshDataList')
}
})
this.submitFlag = true
}).catch(() => {})
}
})
}, 1000, { leading: true, trailing: false })
}