import { V as i, bk as n, Z as a, B as d, gD as l, gL as b, __tla as __tla_0 } from "./index-9PRMimni.js";
import { r as m } from "./dictUtils-D8jA3mBt.js";
let y, O;
let __tla = Promise.all([
    (()=>{
        try {
            return __tla_0;
        } catch  {}
    })()
]).then(async ()=>{
    let j, s, t;
    j = await b("job_order_status");
    s = n();
    ({ t } = i());
    y = (o)=>({
            columns: [
                {
                    title: t("common.messagedefine.Num"),
                    key: "num",
                    width: 60,
                    render: (e, r)=>r + 1
                },
                {
                    title: t("jobOrderList.vessel"),
                    key: "shipName",
                    render: (e)=>e.shipName ? s.getLocale === "en" ? e?.shipNameEn : e?.shipName : ""
                },
                {
                    title: t("jobOrderList.jobOrderNo"),
                    key: "jobOrderNo",
                    render (e) {
                        return e.jobOrderNo ? a(d, {
                            text: !0,
                            type: "primary",
                            onClick () {
                                const r = {
                                    shipId: e.shipId,
                                    id: e.id,
                                    planId: e.planId,
                                    type: "view"
                                };
                                o.viewJobOrder(r);
                            }
                        }, e.jobOrderNo) : "";
                    }
                },
                {
                    title: t("jobOrderList.jobCode"),
                    key: "jobCode"
                },
                {
                    title: t("jobOrderList.jobTitle"),
                    key: "jobTitle"
                },
                {
                    title: t("jobOrderList.doneBy"),
                    key: "picName",
                    render: (e)=>e.picName ? s.getLocale === "en" ? e?.picNameEn : e?.picName : ""
                },
                {
                    title: t("jobOrderList.jobDoneDate"),
                    key: "jobEndDateTime",
                    render (e) {
                        return e.jobEndDateTime ? l(e.jobEndDateTime).format("YYYY-MM-DD") : "";
                    }
                },
                {
                    title: t("jobOrderList.completedWork"),
                    key: "completeContent"
                },
                {
                    title: t("jobOrderList.status"),
                    key: "status",
                    render: (e)=>m(j, e.status)
                }
            ]
        });
    O = ()=>({
            columns: [
                {
                    title: t("jobOrderList.jobCode"),
                    key: "jobCode",
                    width: 140
                },
                {
                    title: t("jobOrderList.jobTitle"),
                    key: "jobTitle",
                    width: 140
                },
                {
                    title: t("jobOrderList.errorMessage"),
                    key: "errorMessage.message",
                    width: 140
                }
            ]
        });
});
export { y as a, O as c, __tla };
