refactor: add prefixId

This commit is contained in:
Net 2024-07-25 14:44:32 +07:00
parent 1e4e2c2927
commit 1bbb5007d3
17 changed files with 241 additions and 175 deletions

View file

@ -2952,6 +2952,7 @@ watch(isMainPage, () => {
>
<template #prepend>
<ProfileUpload
prefix-id="form-dialog"
v-model:url-profile="profileUrl"
v-model:status-toggle="statusToggle"
v-model:profile-submit="profileSubmit"
@ -2965,6 +2966,7 @@ watch(isMainPage, () => {
dense
outlined
separator
prefix-id="form-dialog"
:type-customer="customerType"
:options-branch="branchOption"
v-model:registered-branch-id="formData.registeredBranchId"
@ -2984,11 +2986,13 @@ watch(isMainPage, () => {
<div class="col-12 row bordered q-pt-none rounded">
<TabComponent
prefix-id="form-dialog"
v-model:customer-branch="formData.customerBranch"
v-model:tab-index="indexTab"
>
<template #address>
<FormAddress
prefix-id="form-dialog"
:id="indexTab"
v-if="
indexTab !== undefined && formData.customerBranch?.[indexTab]
@ -3010,6 +3014,7 @@ watch(isMainPage, () => {
<template #businessInformation>
<FormBusiness
prefix-id="form-dialog"
v-if="
indexTab !== undefined && formData.customerBranch?.[indexTab]
"
@ -3046,6 +3051,7 @@ watch(isMainPage, () => {
v-if="
indexTab !== undefined && formData.customerBranch?.[indexTab]
"
prefix-id="form-dialog"
:type-customer="customerType"
v-model:branch-no="formData.customerBranch[indexTab].branchNo"
v-model:tax-no="formData.customerBranch[indexTab].taxNo"
@ -3069,6 +3075,7 @@ watch(isMainPage, () => {
</template>
<template #contactInformation>
<ContactComponent
prefix-id="form-dialog"
v-if="
indexTab !== undefined && formData.customerBranch?.[indexTab]
"
@ -3081,6 +3088,7 @@ watch(isMainPage, () => {
</template>
<template #otherDocuments>
<OtherInformation
prefix-id="form-dialog"
v-if="
indexTab !== undefined && formData.customerBranch?.[indexTab]
"
@ -3129,6 +3137,7 @@ watch(isMainPage, () => {
>
<template #prepend>
<ProfileUpload
prefix-id="form-dialog"
v-model:url-profile="profileUrl"
v-model:status-toggle="statusToggle"
v-model:profile-submit="profileSubmit"
@ -3139,6 +3148,7 @@ watch(isMainPage, () => {
<template #information>
<BasicInformation
prefix-id="form-dialog"
v-if="formDataEmployeeTab === 'personalInfo'"
employee
dense
@ -3155,6 +3165,7 @@ watch(isMainPage, () => {
<template #person>
<FormPerson
prefix-id="form-dialog"
v-if="formDataEmployeeTab === 'personalInfo'"
dense
outlined
@ -3171,6 +3182,7 @@ watch(isMainPage, () => {
/>
<FormEmployeeHealthCheck
prefix-id="form-dialog"
v-if="
formDataEmployeeTab === 'healthCheck' &&
formDataEmployee.employeeCheckup
@ -3185,6 +3197,7 @@ watch(isMainPage, () => {
"
/>
<FormEmployeeWorkHistory
prefix-id="form-dialog"
v-if="formDataEmployeeTab === 'workHistory'"
dense
outlined
@ -3194,6 +3207,7 @@ watch(isMainPage, () => {
v-model:workplace-option="optionStore.globalOption.area"
/>
<FormEmployeeOther
prefix-id="form-dialog"
v-if="
formDataEmployeeTab === 'other' && formDataEmployee.employeeOtherInfo
"
@ -3204,6 +3218,7 @@ watch(isMainPage, () => {
</template>
<template #by-type>
<FormEmployeePassport
prefix-id="form-dialog"
v-if="formDataEmployeeTab === 'personalInfo'"
dense
outlined
@ -3225,6 +3240,7 @@ watch(isMainPage, () => {
"
/>
<FormEmployeeVisa
prefix-id="form-dialog"
v-if="formDataEmployeeTab === 'personalInfo'"
dense
outlined
@ -3260,11 +3276,13 @@ watch(isMainPage, () => {
<div class="col-12 row bordered q-pt-none rounded">
<TabComponent
prefix-id="form-dialog-branch"
v-model:customer-branch="formData.customerBranch"
v-model:tab-index="indexTab"
>
<template #address>
<FormAddress
prefix-id="form-dialog-branch"
:id="indexTab"
v-if="
indexTab !== undefined && formData.customerBranch?.[indexTab]
@ -3285,6 +3303,7 @@ watch(isMainPage, () => {
<template #businessInformation>
<FormBusiness
prefix-id="form-dialog-branch"
v-if="
indexTab !== undefined && formData.customerBranch?.[indexTab]
"
@ -3318,6 +3337,7 @@ watch(isMainPage, () => {
</template>
<template #about>
<AboutComponent
prefix-id="form-dialog-branch"
v-if="
indexTab !== undefined && formData.customerBranch?.[indexTab]
"
@ -3343,6 +3363,7 @@ watch(isMainPage, () => {
</template>
<template #contactInformation>
<ContactComponent
prefix-id="form-dialog-branch"
v-if="
indexTab !== undefined && formData.customerBranch?.[indexTab]
"
@ -3355,6 +3376,7 @@ watch(isMainPage, () => {
</template>
<template #otherDocuments>
<OtherInformation
prefix-id="form-dialog-branch"
v-if="
indexTab !== undefined && formData.customerBranch?.[indexTab]
"
@ -3391,11 +3413,13 @@ watch(isMainPage, () => {
<div class="col-12 row bordered q-pt-none rounded">
<TabComponent
prefix-id="form-dialog"
v-model:customer-branch="formData.customerBranch"
v-model:tab-index="indexTab"
>
<template #address>
<FormAddress
prefix-id="form-dialog"
:id="indexTab"
v-if="
indexTab !== undefined && formData.customerBranch?.[indexTab]
@ -3416,6 +3440,7 @@ watch(isMainPage, () => {
<template #businessInformation>
<FormBusiness
prefix-id="form-dialog"
v-if="
indexTab !== undefined && formData.customerBranch?.[indexTab]
"
@ -3449,6 +3474,7 @@ watch(isMainPage, () => {
</template>
<template #about>
<AboutComponent
prefix-id="form-dialog"
v-if="
indexTab !== undefined && formData.customerBranch?.[indexTab]
"
@ -3478,6 +3504,7 @@ watch(isMainPage, () => {
v-if="
indexTab !== undefined && formData.customerBranch?.[indexTab]
"
prefix-id="form-dialog"
v-model:mail="formData.customerBranch[indexTab].email"
v-model:telephone="formData.customerBranch[indexTab].telephoneNo"
dense
@ -3487,6 +3514,7 @@ watch(isMainPage, () => {
</template>
<template #otherDocuments>
<OtherInformation
prefix-id="form-dialog"
v-if="
indexTab !== undefined && formData.customerBranch?.[indexTab]
"
@ -3559,6 +3587,7 @@ watch(isMainPage, () => {
</template>
<template #information>
<BasicInformation
prefix-id="drawer-info-customer"
dense
outlined
separator
@ -3580,12 +3609,14 @@ watch(isMainPage, () => {
<div class="col-12 row bordered q-pt-none rounded">
<TabComponent
prefix-id="drawer-info-customer"
:readonly="!infoDrawerEdit"
v-model:customer-branch="formData.customerBranch"
v-model:tab-index="indexTab"
>
<template #address>
<FormAddress
prefix-id="drawer-info-customer"
:id="indexTab"
v-if="
indexTab !== undefined &&
@ -3614,6 +3645,7 @@ watch(isMainPage, () => {
<template #businessInformation>
<FormBusiness
prefix-id="drawer-info-customer"
v-if="
indexTab !== undefined &&
formData.customerBranch?.[indexTab]
@ -3649,6 +3681,7 @@ watch(isMainPage, () => {
</template>
<template #about>
<AboutComponent
prefix-id="drawer-info-customer"
v-if="
indexTab !== undefined &&
formData.customerBranch?.[indexTab]
@ -3681,6 +3714,7 @@ watch(isMainPage, () => {
</template>
<template #contactInformation>
<ContactComponent
prefix-id="drawer-info-customer"
v-if="
indexTab !== undefined &&
formData.customerBranch?.[indexTab]
@ -3697,6 +3731,7 @@ watch(isMainPage, () => {
</template>
<template #otherDocuments>
<OtherInformation
prefix-id="drawer-info-customer"
v-if="
indexTab !== undefined &&
formData.customerBranch?.[indexTab]
@ -3782,6 +3817,7 @@ watch(isMainPage, () => {
</template>
<template #information>
<BasicInformation
prefix-id="drawer-info-customer-branch"
dense
outlined
separator
@ -3803,6 +3839,7 @@ watch(isMainPage, () => {
<div class="col-12 row bordered q-pt-none rounded">
<TabComponent
prefix-id="drawer-info-customer-branch"
:edit="true"
:readonly="true"
v-model:customer-branch="formData.customerBranch"
@ -3810,6 +3847,7 @@ watch(isMainPage, () => {
>
<template #address>
<FormAddress
prefix-id="drawer-info-customer-branch"
:id="indexTab"
v-if="
indexTab !== undefined &&
@ -3838,6 +3876,7 @@ watch(isMainPage, () => {
<template #businessInformation>
<FormBusiness
prefix-id="drawer-info-customer-branch"
v-if="
indexTab !== undefined &&
formData.customerBranch?.[indexTab]
@ -3873,6 +3912,7 @@ watch(isMainPage, () => {
</template>
<template #about>
<AboutComponent
prefix-id="drawer-info-customer-branch"
v-if="formData.customerBranch?.[0]"
:type-customer="customerType"
v-model:branch-code="formData.customerBranch[indexTab].code"
@ -3898,6 +3938,7 @@ watch(isMainPage, () => {
</template>
<template #contactInformation>
<ContactComponent
prefix-id="drawer-info-customer-branch"
v-if="
indexTab !== undefined &&
formData.customerBranch?.[indexTab]
@ -3914,6 +3955,7 @@ watch(isMainPage, () => {
</template>
<template #otherDocuments>
<OtherInformation
prefix-id="drawer-info-customer-branch"
v-if="
indexTab !== undefined &&
formData.customerBranch?.[indexTab]
@ -4005,6 +4047,7 @@ watch(isMainPage, () => {
</template>
<template #information>
<BasicInformation
prefix-id="drawer-info-employee"
v-if="formDataEmployeeTab === 'personalInfo'"
employee
dense
@ -4022,6 +4065,7 @@ watch(isMainPage, () => {
<template #person>
<FormPerson
prefix-id="drawer-info-employee"
v-if="formDataEmployeeTab === 'personalInfo'"
dense
outlined
@ -4039,6 +4083,7 @@ watch(isMainPage, () => {
/>
<FormEmployeeHealthCheck
prefix-id="drawer-info-employee"
v-if="
formDataEmployeeTab === 'healthCheck' &&
formDataEmployee.employeeCheckup
@ -4056,6 +4101,7 @@ watch(isMainPage, () => {
"
/>
<FormEmployeeWorkHistory
prefix-id="drawer-info-employee"
v-if="formDataEmployeeTab === 'workHistory'"
dense
outlined
@ -4066,6 +4112,7 @@ watch(isMainPage, () => {
v-model:workplace-option="optionStore.globalOption.area"
/>
<FormEmployeeOther
prefix-id="drawer-info-employee"
v-if="
formDataEmployeeTab === 'other' &&
formDataEmployee.employeeOtherInfo
@ -4078,6 +4125,7 @@ watch(isMainPage, () => {
</template>
<template #by-type>
<FormEmployeePassport
prefix-id="drawer-info-employee"
v-if="formDataEmployeeTab === 'personalInfo'"
dense
outlined
@ -4100,6 +4148,7 @@ watch(isMainPage, () => {
"
/>
<FormEmployeeVisa
prefix-id="drawer-info-employee"
v-if="formDataEmployeeTab === 'personalInfo'"
dense
outlined