fixing bug placement, registry remove employee temp & remove api get tree form json file
This commit is contained in:
parent
955c2d402f
commit
fde7bd6f11
7 changed files with 186 additions and 191 deletions
|
|
@ -239,9 +239,9 @@ function convertContainStatus(val: string, type: string = "") {
|
|||
case "UN-CONTAIN":
|
||||
return "ยังไม่บรรจุ";
|
||||
case "PREPARE-CONTAIN":
|
||||
return "เตรียม" + (type != "" ? type : "บรรจุ");
|
||||
return "เตรียม" + (!type ? type : "บรรจุ");
|
||||
case "CONTAIN":
|
||||
return (type != "" ? type : "บรรจุ") + "แล้ว";
|
||||
return (!type ? type : "บรรจุ") + "แล้ว";
|
||||
case "DISCLAIM":
|
||||
return "สละสิทธิ์";
|
||||
default:
|
||||
|
|
@ -358,16 +358,15 @@ async function getTable() {
|
|||
});
|
||||
|
||||
// รายชื่อทั้งหมด
|
||||
rows.value = roleAdmin.value
|
||||
rows.value = await (roleAdmin.value
|
||||
? rowsAll.value
|
||||
: rowsAll.value.filter((x: any) => x.statusId !== "CONTAIN");
|
||||
: rowsAll.value.filter((x: any) => x.statusId !== "CONTAIN"));
|
||||
// รายชื่อไปยังหน่วยงาน
|
||||
rowsFilter.value = rows.value.filter(
|
||||
(e: any) => e.draft == "รอส่งตัว" && e.statusNameCheck == "เตรียมบรรจุ"
|
||||
rowsFilter.value = await rows.value.filter(
|
||||
(e: any) => e.draft == "รอส่งตัว"
|
||||
);
|
||||
console.log(rows.value);
|
||||
|
||||
insertAvatar(rowsAll.value);
|
||||
insertAvatar(rows.value);
|
||||
})
|
||||
.catch((e) => {
|
||||
messageError($q, e);
|
||||
|
|
@ -389,13 +388,13 @@ function insertAvatar(items: any) {
|
|||
)
|
||||
)
|
||||
.then((img) => {
|
||||
rowsAll.value[index] = {
|
||||
rows.value[index] = {
|
||||
...x,
|
||||
avatar: img.data.downloadUrl,
|
||||
};
|
||||
})
|
||||
.catch(() => {
|
||||
rowsAll.value[index] = {
|
||||
rows.value[index] = {
|
||||
...x,
|
||||
avatar: avatar,
|
||||
};
|
||||
|
|
@ -829,7 +828,7 @@ onMounted(async () => {
|
|||
</q-td>
|
||||
<q-td auto-width>
|
||||
<q-btn
|
||||
v-if="roleAdmin && props.row.statusId !== 'CONTAIN'"
|
||||
v-if="props.row.statusId !== 'CONTAIN'"
|
||||
icon="mdi-dots-vertical"
|
||||
size="12px"
|
||||
color="grey-7"
|
||||
|
|
@ -841,9 +840,9 @@ onMounted(async () => {
|
|||
<q-list dense style="min-width: 100px">
|
||||
<q-item
|
||||
v-if="
|
||||
(roleAdmin && props.row.statusId === 'UN-CONTAIN') ||
|
||||
(props.row.draft === 'รอส่งตัว' &&
|
||||
props.row.statusId !== 'DISCLAIM')
|
||||
roleAdmin &&
|
||||
props.row.draft !== 'ส่งตัวแล้ว' &&
|
||||
props.row.statusId !== 'DISCLAIM'
|
||||
"
|
||||
clickable
|
||||
v-close-popup
|
||||
|
|
@ -872,11 +871,10 @@ onMounted(async () => {
|
|||
</q-item>
|
||||
<q-item
|
||||
v-if="
|
||||
(props.row.bmaOfficer !== 'บุคคลภายนอก' &&
|
||||
roleAdmin &&
|
||||
props.row.statusId === 'UN-CONTAIN') ||
|
||||
(props.row.draft === 'รอส่งตัว' &&
|
||||
props.row.statusId !== 'DISCLAIM')
|
||||
props.row.bmaOfficer !== 'บุคคลภายนอก' &&
|
||||
roleAdmin &&
|
||||
props.row.draft !== 'ส่งตัวแล้ว' &&
|
||||
props.row.statusId !== 'DISCLAIM'
|
||||
"
|
||||
clickable
|
||||
v-close-popup
|
||||
|
|
@ -904,11 +902,10 @@ onMounted(async () => {
|
|||
|
||||
<q-item
|
||||
v-if="
|
||||
(props.row.bmaOfficer !== 'บุคคลภายนอก' &&
|
||||
roleAdmin &&
|
||||
props.row.statusId === 'UN-CONTAIN') ||
|
||||
(props.row.draft === 'รอส่งตัว' &&
|
||||
props.row.statusId !== 'DISCLAIM')
|
||||
props.row.bmaOfficer !== 'บุคคลภายนอก' &&
|
||||
roleAdmin &&
|
||||
props.row.draft !== 'ส่งตัวแล้ว' &&
|
||||
props.row.statusId !== 'DISCLAIM'
|
||||
"
|
||||
clickable
|
||||
v-close-popup
|
||||
|
|
@ -932,11 +929,10 @@ onMounted(async () => {
|
|||
|
||||
<q-item
|
||||
v-if="
|
||||
(props.row.bmaOfficer !== 'บุคคลภายนอก' &&
|
||||
roleAdmin &&
|
||||
props.row.statusId === 'UN-CONTAIN') ||
|
||||
(props.row.draft === 'รอส่งตัว' &&
|
||||
props.row.statusId !== 'DISCLAIM')
|
||||
props.row.bmaOfficer !== 'บุคคลภายนอก' &&
|
||||
roleAdmin &&
|
||||
props.row.draft !== 'ส่งตัวแล้ว' &&
|
||||
props.row.statusId !== 'DISCLAIM'
|
||||
"
|
||||
clickable
|
||||
v-close-popup
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue