ทะเบียนประวัติ ยืนยันตรวจสอบข้อมูลและปลดล็อค
This commit is contained in:
parent
6e6e0d2cf9
commit
4e8cff183a
3 changed files with 43 additions and 10 deletions
|
|
@ -918,7 +918,21 @@ const roleRegistryverify = ref<boolean>(false);
|
|||
function onClickVerified() {
|
||||
dialogConfirm(
|
||||
$q,
|
||||
async () => {},
|
||||
async () => {
|
||||
showLoader();
|
||||
await http
|
||||
.put(config.API.profileVerified(profileId.value))
|
||||
.then((res) => {
|
||||
checIsVerified();
|
||||
success($q, "ยืนยันการตรวจสอบข้อมูลสำเร็จ");
|
||||
})
|
||||
.catch((e) => {
|
||||
messageError($q, e);
|
||||
})
|
||||
.finally(() => {
|
||||
hideLoader();
|
||||
});
|
||||
},
|
||||
"ยืนยันการตรวจสอบข้อมูล",
|
||||
"ต้องการยืนยันการตรวจสอบข้อมูลนี้หรือไม่?"
|
||||
);
|
||||
|
|
@ -927,7 +941,21 @@ function onClickVerified() {
|
|||
function onClickUnlock() {
|
||||
dialogConfirm(
|
||||
$q,
|
||||
async () => {},
|
||||
async () => {
|
||||
showLoader();
|
||||
await http
|
||||
.put(config.API.profileVerifiedUnlock(profileId.value))
|
||||
.then((res) => {
|
||||
checIsVerified();
|
||||
success($q, "ปลดล็อคให้แก้ไขข้อมูลสำเร็จ");
|
||||
})
|
||||
.catch((e) => {
|
||||
messageError($q, e);
|
||||
})
|
||||
.finally(() => {
|
||||
hideLoader();
|
||||
});
|
||||
},
|
||||
"ยืนยันการปลดให้แก้ไขข้อมูล",
|
||||
"ต้องการยืนยันการปลดให้แก้ไขข้อมูลนี้หรือไม่?"
|
||||
);
|
||||
|
|
@ -985,13 +1013,14 @@ async function checIsVerified() {
|
|||
.then((res) => {
|
||||
const data = res.data.result;
|
||||
|
||||
profileStore.isVerified = data.isVerified
|
||||
? true
|
||||
: roleRegistryverify.value
|
||||
? true
|
||||
: roleKeyregistry.value
|
||||
? false
|
||||
: false;
|
||||
profileStore.isVerified = data.isVerified;
|
||||
// profileStore.isVerified = data.isVerified
|
||||
// ? true
|
||||
// : roleRegistryverify.value
|
||||
// ? true
|
||||
// : roleKeyregistry.value
|
||||
// ? false
|
||||
// : false;
|
||||
})
|
||||
.catch((err) => {
|
||||
messageError($q, err);
|
||||
|
|
|
|||
|
|
@ -99,7 +99,7 @@
|
|||
v-if="props.row.isVerified"
|
||||
name="verified"
|
||||
color="green"
|
||||
size="2rem"
|
||||
size="1.4rem"
|
||||
/>
|
||||
</div>
|
||||
<div v-else-if="col.name == 'fullname'">
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue