ออกคำสั่ง => คำสั้งปรับโครงสร้าง

This commit is contained in:
DESKTOP-1R2VSQH\Lenovo ThinkPad E490 2024-06-28 17:48:36 +07:00
parent dc079e31fd
commit e9367dea5c
7 changed files with 94 additions and 30 deletions

View file

@ -157,7 +157,7 @@ const OriginalDataFetch = async () => {
};
// redirect step
const redirectToPage = (id?: string, status?: string) => {
const redirectToPage = (id?: string, status?: string, name?: string) => {
let step = 1;
switch (status) {
case "จัดทำร่างคำสั่ง":
@ -167,10 +167,10 @@ const redirectToPage = (id?: string, status?: string) => {
step = 2;
break;
case "เลือกผู้ได้รับสำเนาคำสั่ง":
step = 3;
step = name === "คำสั่งปรับโครงสร้าง" ? 2 : 3;
break;
default:
step = 4;
step = name === "คำสั่งปรับโครงสร้าง" ? 3 : 4;
break;
}
router.push(`/order/detail/${id}?step=${step}`);
@ -495,7 +495,11 @@ const paginationLabel = (start: string, end: string, total: string) => {
:props="props"
class="cursor-pointer"
@click="
redirectToPage(props.row.orderId, props.row.OrderStatus)
redirectToPage(
props.row.orderId,
props.row.OrderStatus,
props.row.OrderType
)
"
>
<q-td key="Order" :props="props">