feat: 修改密码
This commit is contained in:
@ -25,7 +25,7 @@
|
||||
v-for="(item, index) in new Array(10).fill(0)"
|
||||
:key="index"
|
||||
></span>
|
||||
<Button type="text" size="small" class="!p-0 !h-22px ml-10px">更改</Button>
|
||||
<Button type="text" size="small" class="!p-0 !h-22px ml-10px" @click="openChangePasswordModal">更改</Button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -110,11 +110,7 @@
|
||||
/>
|
||||
</Modal>
|
||||
|
||||
<SafetyVerificationModal
|
||||
ref="safetyVerificationModalRef"
|
||||
@success="handleVerifySuccess"
|
||||
@cancel="handleVerifyCancel"
|
||||
/>
|
||||
<ChangePasswordModal ref="changePasswordModalRef" />
|
||||
<ChangeNameModal ref="changeNameModalRef" />
|
||||
<ChangeMobileModal ref="changeMobileModalRef" />
|
||||
</div>
|
||||
@ -123,7 +119,7 @@
|
||||
import { Avatar, Button, Form, FormItem, Input, message } from 'ant-design-vue';
|
||||
import Modal from '@/components/modal.vue';
|
||||
import PuzzleVerification from '@/views/login/components/PuzzleVerification.vue';
|
||||
import SafetyVerificationModal from './components/safety-verification-modal/index.vue';
|
||||
import ChangePasswordModal from './components/change-password-modal/index.vue';
|
||||
import ChangeNameModal from './components/change-name-modal/index.vue';
|
||||
import ChangeMobileModal from './components/change-mobile-modal/index.vue';
|
||||
|
||||
@ -137,7 +133,7 @@ import { useUserStore } from '@/stores';
|
||||
import icon1 from './img/icon1.png';
|
||||
|
||||
const store = useUserStore();
|
||||
const safetyVerificationModalRef = ref(null);
|
||||
const changePasswordModalRef = ref(null);
|
||||
const changeNameModalRef = ref(null);
|
||||
const changeMobileModalRef = ref(null);
|
||||
|
||||
@ -175,8 +171,6 @@ const mobile = computed(() => {
|
||||
return _mobile.replace(/(\d{3})\d{4}(\d{4})/, '$1****$2');
|
||||
});
|
||||
|
||||
console.log(store.userInfo);
|
||||
|
||||
// 表单校验规则
|
||||
const formRules = {
|
||||
mobile: [
|
||||
@ -256,6 +250,9 @@ const openChangeNameModal = () => {
|
||||
const openChangeMobileModal = () => {
|
||||
changeMobileModalRef.value.open();
|
||||
};
|
||||
const openChangePasswordModal = () => {
|
||||
changePasswordModalRef.value.open(dataSource.value.mobile);
|
||||
};
|
||||
|
||||
async function handleSubmitUserInfo() {
|
||||
await updateMyInfo(userInfoForm);
|
||||
|
||||
Reference in New Issue
Block a user