Browse Source

[1.3.7-prepare][Fix-5699][UI] Fix update user error in user information (#5902)

Shiwen Cheng 3 years ago committed by GitHub
parent
commit
16ac482d9e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 7
      dolphinscheduler-ui/src/js/conf/home/pages/security/pages/users/_source/createUser.vue
  2. 15
      dolphinscheduler-ui/src/js/conf/home/pages/user/pages/account/_source/info.vue

7
dolphinscheduler-ui/src/js/conf/home/pages/security/pages/users/_source/createUser.vue

@ -124,7 +124,8 @@
} }
}, },
props: { props: {
item: Object item: Object,
fromUserInfo: Boolean
}, },
methods: { methods: {
_ok () { _ok () {
@ -277,7 +278,7 @@
this.userPassword = '' this.userPassword = ''
this.email = this.item.email this.email = this.item.email
this.phone = this.item.phone this.phone = this.item.phone
if (this.item.tenantId) { if (this.fromUserInfo || this.item.tenantId) {
this.tenantId = this.item.tenantId this.tenantId = this.item.tenantId
} }
this.$nextTick(() => { this.$nextTick(() => {
@ -294,7 +295,7 @@
this.userPassword = '' this.userPassword = ''
this.email = this.item.email this.email = this.item.email
this.phone = this.item.phone this.phone = this.item.phone
if (this.item.tenantId) { if (this.fromUserInfo || this.item.tenantId) {
this.tenantId = this.item.tenantId this.tenantId = this.item.tenantId
} }
if (this.queueList.length > 0) { if (this.queueList.length > 0) {

15
dolphinscheduler-ui/src/js/conf/home/pages/user/pages/account/_source/info.vue

@ -73,7 +73,7 @@
</div> </div>
</template> </template>
<script> <script>
import { mapState, mapMutations } from 'vuex' import { mapActions, mapState, mapMutations } from 'vuex'
import mListBoxF from '@/module/components/listBoxF/listBoxF' import mListBoxF from '@/module/components/listBoxF/listBoxF'
import mCreateUser from '@/conf/home/pages/security/pages/users/_source/createUser' import mCreateUser from '@/conf/home/pages/security/pages/users/_source/createUser'
@ -85,6 +85,7 @@
props: {}, props: {},
methods: { methods: {
...mapMutations('user', ['setUserInfo']), ...mapMutations('user', ['setUserInfo']),
...mapActions('user', ['getUserInfo']),
/** /**
* edit * edit
*/ */
@ -101,19 +102,17 @@
return h(mCreateUser, { return h(mCreateUser, {
on: { on: {
onUpdate (param) { onUpdate (param) {
self.setUserInfo({ self.setUserInfo(param)
userName: param.userName, self.getUserInfo().finally(() => {
userPassword: param.userPassword, modal.remove()
email: param.email,
phone: param.phone
}) })
modal.remove()
}, },
close () { close () {
} }
}, },
props: { props: {
item: item item: item,
fromUserInfo: true
} }
}) })
} }

Loading…
Cancel
Save