diff --git a/src/modules/02_organization/components/DialogFormAgency.vue b/src/modules/02_organization/components/DialogFormAgency.vue
index 5565a54e0..0abc8c71f 100644
--- a/src/modules/02_organization/components/DialogFormAgency.vue
+++ b/src/modules/02_organization/components/DialogFormAgency.vue
@@ -543,22 +543,24 @@ watch(
/>
- 1)
- "
- mask="##"
+ (actionType === 'EDIT' && props?.dataNode?.orgLevel > 1)
+ )
+ "
+ :readonly="
+ (actionType === 'ADD' &&
+ props?.dataNode?.orgLevel !== 0 &&
+ level !== 0) ||
+ (actionType === 'EDIT' && props?.dataNode?.orgLevel > 1)
+ " -->
+ ([
{
name: "commandDateAffect",
align: "left",
- label: "วัน เดือน ปี",
+ label: "วันที่คำสั่งมีผล",
sortable: true,
field: "commandDateAffect",
headerStyle: "font-size: 14px",
@@ -75,49 +76,6 @@ const baseColumns = ref([
.toString()
.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
},
- {
- name: "amount",
- align: "left",
- label: empType.value === "-employee" ? "ค่าตอบแทนรายเดือน" : "เงินเดือน",
- sortable: true,
- field: "amount",
- headerStyle: "font-size: 14px",
- style: "font-size: 14px",
- format: (v) => Number(v).toLocaleString(),
- sort: (a: string, b: string) =>
- a
- .toString()
- .localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
- },
- {
- name: "positionSalaryAmount",
- align: "left",
- label: "เงินประจำตำแหน่ง",
- sortable: true,
- field: "positionSalaryAmount",
- headerStyle: "font-size: 14px",
- style: "font-size: 14px",
- format: (v) => Number(v).toLocaleString(),
- sort: (a: string, b: string) =>
- a
- .toString()
- .localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
- },
- {
- name: "mouthSalaryAmount",
- align: "left",
- label: "เงินค่าตอบแทนรายเดือน",
- sortable: true,
- field: "mouthSalaryAmount",
- headerStyle: "font-size: 14px",
- style: "font-size: 14px",
- format: (v) => Number(v).toLocaleString(),
- sort: (a: string, b: string) =>
- a
- .toString()
- .localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
- },
-
{
name: "posNo",
align: "left",
@@ -141,7 +99,7 @@ const baseColumns = ref([
{
name: "positionName",
align: "left",
- label: "ตำแหน่ง",
+ label: empType.value === "-employee" ? "ตำแหน่ง" : "ตำแหน่งในสายงาน",
sortable: true,
field: "positionName",
headerStyle: "font-size: 14px",
@@ -154,7 +112,7 @@ const baseColumns = ref([
{
name: "positionType",
align: "left",
- label: "ประเภทตำแหน่ง",
+ label: empType.value === "-employee" ? "กลุ่มงาน" : "ประเภทตำแหน่ง",
sortable: true,
field: "positionType",
headerStyle: "font-size: 14px",
@@ -167,7 +125,7 @@ const baseColumns = ref([
{
name: "positionLevel",
align: "left",
- label: "ระดับ",
+ label: empType.value === "-employee" ? "ระดับชั้นงาน" : "ระดับ",
sortable: true,
field: "positionLevel",
format(val, row) {
@@ -185,16 +143,58 @@ const baseColumns = ref([
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
},
{
- name: "commandName",
+ name: "positionExecutive",
align: "left",
- label: "เอกสารอ้างอิง",
+ label: "ตำแหน่งทางการบริหาร",
sortable: true,
- field: "commandName",
+ field: "positionExecutive",
headerStyle: "font-size: 14px",
style: "font-size: 14px",
sort: (a: string, b: string) =>
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
},
+ {
+ name: "amount",
+ align: "left",
+ label: empType.value === "-employee" ? "ค่าตอบแทนรายเดือน" : "เงินเดือน",
+ sortable: true,
+ field: "amount",
+ headerStyle: "font-size: 14px",
+ style: "font-size: 14px",
+ format: (v) => Number(v).toLocaleString(),
+ sort: (a: string, b: string) =>
+ a
+ .toString()
+ .localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
+ },
+ // {
+ // name: "positionSalaryAmount",
+ // align: "left",
+ // label: "เงินประจำตำแหน่ง",
+ // sortable: true,
+ // field: "positionSalaryAmount",
+ // headerStyle: "font-size: 14px",
+ // style: "font-size: 14px",
+ // format: (v) => Number(v).toLocaleString(),
+ // sort: (a: string, b: string) =>
+ // a
+ // .toString()
+ // .localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
+ // },
+ // {
+ // name: "mouthSalaryAmount",
+ // align: "left",
+ // label: "เงินค่าตอบแทนรายเดือน",
+ // sortable: true,
+ // field: "mouthSalaryAmount",
+ // headerStyle: "font-size: 14px",
+ // style: "font-size: 14px",
+ // format: (v) => Number(v).toLocaleString(),
+ // sort: (a: string, b: string) =>
+ // a
+ // .toString()
+ // .localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
+ // },
{
name: "refCommandNo",
align: "left",
@@ -211,6 +211,51 @@ const baseColumns = ref([
sort: (a: string, b: string) =>
a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
},
+ {
+ name: "commandName",
+ align: "left",
+ label: "ประเภทคำสั่ง",
+ sortable: true,
+ field: "commandName",
+ headerStyle: "font-size: 14px",
+ style: "font-size: 14px",
+ sort: (a: string, b: string) =>
+ a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
+ },
+ {
+ name: "commandDateSign",
+ align: "left",
+ label: "วันที่ลงนาม",
+ sortable: true,
+ field: "commandDateSign",
+ headerStyle: "font-size: 14px",
+ style: "font-size: 14px",
+ format: (v) => date2Thai(v),
+ sort: (a: string, b: string) =>
+ a
+ .toString()
+ .localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
+ },
+ {
+ name: "organization",
+ align: "left",
+ label: "สังกัด",
+ sortable: true,
+ field: "organization",
+ headerStyle: "font-size: 14px",
+ style: "font-size: 14px",
+ format(val, row) {
+ return findOrgName({
+ root: row.orgRoot,
+ child1: row.orgChild1,
+ child2: row.orgChild2,
+ child3: row.orgChild3,
+ child4: row.orgChild4,
+ });
+ },
+ sort: (a: string, b: string) =>
+ a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
+ },
{
name: "remark",
align: "left",
@@ -244,9 +289,12 @@ const visibleColumns = ref([
"positionName",
"positionType",
"positionLevel",
+ "positionExecutive",
+ "commandDateSign",
"commandName",
"refCommandNo",
"remark",
+ "organization",
]);
const pagination = ref({
sortBy: "",
@@ -874,7 +922,7 @@ onMounted(async () => {
>
แก้ไขข้อมูล
- {
icon="mdi-arrow-up-bold"
@click="onSwapUp(props.row.id)"
>
-
+ -->
- {
icon="mdi-arrow-down-bold"
@click="onSwapDown(props.row.id)"
>
-
+ -->
@@ -1123,7 +1171,7 @@ onMounted(async () => {
-
+
(
@@ -62,7 +63,7 @@ const baseColumns = ref([
{
name: "commandDateAffect",
align: "left",
- label: "วัน เดือน ปี",
+ label: "วันที่คำสั่งมีผล",
sortable: true,
field: "commandDateAffect",
headerStyle: "font-size: 14px",
@@ -73,6 +74,83 @@ const baseColumns = ref([
.toString()
.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
},
+ {
+ name: "posNo",
+ align: "left",
+ label: "ตำแหน่งเลขที่",
+ sortable: true,
+ field: "posNo",
+ headerStyle: "font-size: 14px",
+ style: "font-size: 14px",
+ format(val, row) {
+ return row.posNoAbb && row.posNo
+ ? `${row.posNoAbb}${row.posNo}`
+ : row.posNo
+ ? row.posNo
+ : "-";
+ },
+ sort: (a: string, b: string) =>
+ a
+ .toString()
+ .localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
+ },
+ {
+ name: "positionName",
+ align: "left",
+ label: empType.value === "-employee" ? "ตำแหน่ง" : "ตำแหน่งในสายงาน",
+ sortable: true,
+ field: "positionName",
+ headerStyle: "font-size: 14px",
+ style: "font-size: 14px",
+ sort: (a: string, b: string) =>
+ a
+ .toString()
+ .localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
+ },
+ {
+ name: "positionType",
+ align: "left",
+ label: empType.value === "-employee" ? "กลุ่มงาน" : "ประเภทตำแหน่ง",
+ sortable: true,
+ field: "positionType",
+ headerStyle: "font-size: 14px",
+ style: "font-size: 14px",
+ sort: (a: string, b: string) =>
+ a
+ .toString()
+ .localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
+ },
+ {
+ name: "positionLevel",
+ align: "left",
+ label: empType.value === "-employee" ? "ระดับชั้นงาน" : "ระดับ",
+ sortable: true,
+ field: "positionLevel",
+ format(val, row) {
+ return `${
+ row.positionLevel
+ ? row.positionLevel
+ : row.positionCee
+ ? row.positionCee
+ : "-"
+ }`;
+ },
+ headerStyle: "font-size: 14px",
+ style: "font-size: 14px",
+ sort: (a: string, b: string) =>
+ a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
+ },
+ {
+ name: "positionExecutive",
+ align: "left",
+ label: "ตำแหน่งทางการบริหาร",
+ sortable: true,
+ field: "positionExecutive",
+ headerStyle: "font-size: 14px",
+ style: "font-size: 14px",
+ sort: (a: string, b: string) =>
+ a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
+ },
{
name: "amount",
align: "left",
@@ -115,88 +193,6 @@ const baseColumns = ref([
.toString()
.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
},
-
- {
- name: "posNo",
- align: "left",
- label: "ตำแหน่งเลขที่",
- sortable: true,
- field: "posNo",
- headerStyle: "font-size: 14px",
- style: "font-size: 14px",
- format(val, row) {
- return row.posNoAbb && row.posNo
- ? `${row.posNoAbb}${row.posNo}`
- : row.posNo
- ? row.posNo
- : "-";
- },
- sort: (a: string, b: string) =>
- a
- .toString()
- .localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
- },
- {
- name: "positionName",
- align: "left",
- label: "ตำแหน่ง",
- sortable: true,
- field: "positionName",
- headerStyle: "font-size: 14px",
- style: "font-size: 14px",
- sort: (a: string, b: string) =>
- a
- .toString()
- .localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
- },
- {
- name: "positionType",
- align: "left",
- label: "ประเภทตำแหน่ง",
- sortable: true,
- field: "positionType",
- headerStyle: "font-size: 14px",
- style: "font-size: 14px",
- sort: (a: string, b: string) =>
- a
- .toString()
- .localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
- },
- {
- name: "positionLevel",
- align: "left",
- label: "ระดับ",
- sortable: true,
- field: "positionLevel",
- format(val, row) {
- return `${
- row.positionLevel
- ? row.positionLevel
- : row.positionCee
- ? row.positionCee
- : "-"
- }`;
- },
- headerStyle: "font-size: 14px",
- style: "font-size: 14px",
- sort: (a: string, b: string) =>
- a
- .toString()
- .localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
- },
- {
- name: "commandName",
- align: "left",
- label: "เอกสารอ้างอิง",
- sortable: true,
- field: "commandName",
- headerStyle: "font-size: 14px",
- style: "font-size: 14px",
- sort: (a: string, b: string) =>
- a
- .toString()
- .localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
- },
{
name: "refCommandNo",
align: "left",
@@ -210,11 +206,54 @@ const baseColumns = ref([
},
headerStyle: "font-size: 14px",
style: "font-size: 14px",
+ sort: (a: string, b: string) =>
+ a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
+ },
+ {
+ name: "commandName",
+ align: "left",
+ label: "ประเภทคำสั่ง",
+ sortable: true,
+ field: "commandName",
+ headerStyle: "font-size: 14px",
+ style: "font-size: 14px",
+ sort: (a: string, b: string) =>
+ a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
+ },
+ {
+ name: "commandDateSign",
+ align: "left",
+ label: "วันที่ลงนาม",
+ sortable: true,
+ field: "commandDateSign",
+ headerStyle: "font-size: 14px",
+ style: "font-size: 14px",
+ format: (v) => date2Thai(v),
sort: (a: string, b: string) =>
a
.toString()
.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
},
+ {
+ name: "organization",
+ align: "left",
+ label: "สังกัด",
+ sortable: true,
+ field: "organization",
+ headerStyle: "font-size: 14px",
+ style: "font-size: 14px",
+ format(val, row) {
+ return findOrgName({
+ root: row.orgRoot,
+ child1: row.orgChild1,
+ child2: row.orgChild2,
+ child3: row.orgChild3,
+ child4: row.orgChild4,
+ });
+ },
+ sort: (a: string, b: string) =>
+ a.localeCompare(b, undefined, { numeric: true, sensitivity: "base" }),
+ },
{
name: "remark",
align: "left",
@@ -250,9 +289,12 @@ const visibleColumns = ref([
"positionName",
"positionType",
"positionLevel",
+ "positionExecutive",
+ "commandDateSign",
"commandName",
"refCommandNo",
"remark",
+ "organization",
]);
const pagination = ref({
sortBy: "",
@@ -810,7 +852,7 @@ onMounted(() => {
>
แก้ไขข้อมูล
- {
icon="mdi-arrow-down-bold"
@click="onSwapDown(props.row.id)"
>
-
+ -->
@@ -1059,7 +1101,7 @@ onMounted(() => {
-
+