fix bug
This commit is contained in:
parent
ace4e47c94
commit
a18581abbe
3 changed files with 9 additions and 8 deletions
|
|
@ -877,7 +877,6 @@ const getClass = (val: boolean) => {
|
|||
v-model="command"
|
||||
hide-bottom-space
|
||||
:label="`${'คำสั่งเลขที่'}`"
|
||||
:rules="[(val) => !!val || `${'กรุณากรอกคำสั่งเลขที่'}`]"
|
||||
/>
|
||||
</div>
|
||||
<label class="col-1 flex justify-center items-center text-bold"
|
||||
|
|
|
|||
|
|
@ -455,7 +455,7 @@ function fetchSalaryRound() {
|
|||
v-model="command"
|
||||
hide-bottom-space
|
||||
:label="`${'คำสั่งเลขที่'}`"
|
||||
:rules="[(val) => !!val || `${'กรุณากรอกคำสั่งเลขที่'}`]"
|
||||
|
||||
/>
|
||||
</div>
|
||||
<label class="col-1 flex justify-center items-center text-bold"
|
||||
|
|
|
|||
|
|
@ -86,8 +86,8 @@ function fetchPosType() {
|
|||
id: e.id,
|
||||
name: e.posTypeName,
|
||||
}));
|
||||
salaryPosTypeOptionMain.value = listOption;
|
||||
salaryPosTypeOption.value = listOption;
|
||||
salaryPosTypeOptionMain.value = listOption;
|
||||
})
|
||||
.catch((err) => {
|
||||
messageError($q, err);
|
||||
|
|
@ -105,8 +105,8 @@ function fetchPosLevel(id: string) {
|
|||
name: e.posLevelName,
|
||||
})) || [];
|
||||
|
||||
salaryPosLevelOptionMain.value = listOption;
|
||||
salaryPosLevelOption.value = listOption;
|
||||
salaryPosLevelOptionMain.value = listOption;
|
||||
if (!listOption.some((e: DataOption) => e.id === formData.posLevelId)) {
|
||||
formData.posLevelId = "";
|
||||
}
|
||||
|
|
@ -146,18 +146,20 @@ function fetchSalaryDetail(id: string) {
|
|||
*/
|
||||
watch(
|
||||
() => modal.value,
|
||||
() => {
|
||||
async () => {
|
||||
if (modal.value) {
|
||||
fetchPosType();
|
||||
await fetchPosType();
|
||||
|
||||
if (props.typeAction === "edit") {
|
||||
showLoader();
|
||||
setTimeout(() => {
|
||||
if (props.data) {
|
||||
salaryId.value = props.data.id;
|
||||
fetchPosLevel(props?.data?.posTypeId);
|
||||
fetchSalaryDetail(props.data.id);
|
||||
fetchPosLevel(props.data.posTypeId);
|
||||
hideLoader();
|
||||
}
|
||||
}, 100);
|
||||
}, 2000);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue