Compare commits

...

2 Commits

Author SHA1 Message Date
Michael Bai
6f65bcf2d5 fix: 修复导入模版生成table时,没有显示number字段类型所在列的问题 2021-05-23 22:00:07 -05:00
Michael Bai
8a97928d1d fix: 修改用户创建/更新密码策略选项值 2021-05-23 21:58:07 -05:00
2 changed files with 4 additions and 4 deletions

View File

@@ -207,7 +207,7 @@ export default {
if (!d) { if (!d) {
return 0 return 0
} }
if (!itemColData || !itemColData.length) { if (typeof itemColData !== 'number' && (!itemColData || !itemColData.length)) {
return 0 return 0
} }
return itemColData.length return itemColData.length

View File

@@ -59,7 +59,7 @@ export default {
password: { password: {
component: UserPassword, component: UserPassword,
hidden: (formValue) => { hidden: (formValue) => {
if (formValue.password_strategy) { if (formValue.password_strategy === 'custom') {
return false return false
} }
return !formValue.update_password return !formValue.update_password
@@ -81,7 +81,7 @@ export default {
} }
], ],
hidden: (formValue) => { hidden: (formValue) => {
if (formValue.password_strategy) { if (formValue.password_strategy === 'custom') {
return false return false
} }
return !formValue.update_password || !this.user.can_public_key_auth return !formValue.update_password || !this.user.can_public_key_auth
@@ -148,7 +148,7 @@ export default {
methods: { methods: {
cleanFormValue(value) { cleanFormValue(value) {
const method = this.getMethod() const method = this.getMethod()
if (method === 'post' && !value.password_strategy) { if (method === 'post' && value.password_strategy === 'email') {
delete value['password'] delete value['password']
if (this.currentOrgIsRoot) { if (this.currentOrgIsRoot) {
delete value['groups'] delete value['groups']