Compare commits
2 commits
cf468e14cb
...
b0b834cb9b
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b0b834cb9b | ||
|
|
0d5cb36fb2 |
2 changed files with 23 additions and 14 deletions
|
|
@ -402,6 +402,7 @@ const modalDialogSalary = ref<boolean>(false); //แสดง popup ตำแห
|
|||
const isStatusEdit = ref<boolean>(false); //สถานะแก้ไขข้อมูลตำแหน่งเงินเดือน
|
||||
const salaryId = ref<string>(""); //id ที่ต้องการแก้ไข
|
||||
const dataLevel = ref<DataPosType[]>([]); //รายการ ตำแหน่งเงินเดือน
|
||||
const idCommandId = ref<boolean>(false); //เช็คว่ามี commandId หรือไม่
|
||||
|
||||
const commandCodeOptions = ref<DataOption[]>(store.commandCodeData); //รายการปรเภทคำสั่ง
|
||||
const posTypeOptions = ref<DataOption[]>(store.posTypeData); //รายการประเภทตำแหน่ง | กลุ่มงาน
|
||||
|
|
@ -658,6 +659,7 @@ async function onClickOpenDialog(
|
|||
} else {
|
||||
await fetchOptionGroup();
|
||||
}
|
||||
idCommandId.value = statusEdit ? (data.commandId ? true : false) : false;
|
||||
commandCodeOptions.value = store.commandCodeData;
|
||||
posTypeOptions.value = store.posTypeData;
|
||||
posLevelOptions.value = store.posLevelData;
|
||||
|
|
@ -978,6 +980,7 @@ onMounted(async () => {
|
|||
<q-tooltip>ประวัติแก้ไขตำแหน่ง/เงินเดือน</q-tooltip>
|
||||
</q-btn>
|
||||
|
||||
<!-- :disable="(props.row.commandId !== null && props.row.commandId !== '') || props.row.commandType === 'C-PM-47'" -->
|
||||
<q-btn
|
||||
v-if="
|
||||
!isLeave &&
|
||||
|
|
@ -985,11 +988,7 @@ onMounted(async () => {
|
|||
checkPermission($route)?.attrOwnership === 'OWNER'
|
||||
"
|
||||
flat
|
||||
:disable="
|
||||
(props.row.commandId !== null && props.row.commandId !== '') ||
|
||||
props.row.commandType === 'C-PM-47'
|
||||
"
|
||||
:color="props.row.commandId ? 'grey' : 'edit'"
|
||||
color="edit"
|
||||
dense
|
||||
round
|
||||
icon="edit"
|
||||
|
|
@ -1154,7 +1153,8 @@ onMounted(async () => {
|
|||
<div class="row q-col-gutter-sm">
|
||||
<div class="col-6">
|
||||
<q-input
|
||||
:class="classInput(true)"
|
||||
:class="classInput(!idCommandId)"
|
||||
:readonly="idCommandId"
|
||||
outlined
|
||||
dense
|
||||
lazy-rules
|
||||
|
|
@ -1174,7 +1174,8 @@ onMounted(async () => {
|
|||
autoApply
|
||||
year-picker
|
||||
:enableTimePicker="false"
|
||||
class="inputgreen"
|
||||
:class="classInput(!idCommandId)"
|
||||
:disabled="idCommandId"
|
||||
>
|
||||
<template #year="{ year }">{{ year + 543 }}</template>
|
||||
<template #year-overlay-value="{ value }">{{
|
||||
|
|
@ -1191,6 +1192,8 @@ onMounted(async () => {
|
|||
: formData.commandYear + 543
|
||||
"
|
||||
label="ปี พ.ศ."
|
||||
:class="classInput(!idCommandId)"
|
||||
:readonly="idCommandId"
|
||||
>
|
||||
<template v-slot:prepend>
|
||||
<q-icon
|
||||
|
|
|
|||
|
|
@ -66,6 +66,7 @@ const keyword = ref<string>(""); //คำค้นหา
|
|||
const modalCommand = ref<boolean>(false);
|
||||
const command = ref<string>("");
|
||||
const commandId = ref<string>("");
|
||||
const idCommandId = ref<boolean>(false); //สถานะการมีคำสั่ง
|
||||
const baseColumns = ref<QTableColumn[]>([
|
||||
{
|
||||
name: "commandDateAffect",
|
||||
|
|
@ -638,6 +639,7 @@ async function onClickOpenDialog(
|
|||
} else {
|
||||
await fetchOptionGroup();
|
||||
}
|
||||
idCommandId.value = statusEdit && data.commandId ? true : false;
|
||||
commandCodeOptions.value = store.commandCodeData;
|
||||
posTypeOptions.value = store.posTypeData;
|
||||
posLevelOptions.value = store.posLevelData;
|
||||
|
|
@ -939,6 +941,10 @@ onMounted(async () => {
|
|||
>
|
||||
<q-tooltip>ประวัติแก้ไขตำแหน่ง/เงินเดือน</q-tooltip>
|
||||
</q-btn>
|
||||
<!-- :disable="
|
||||
(props.row.commandId !== null && props.row.commandId !== '') ||
|
||||
props.row.commandType === 'C-PM-47'
|
||||
" -->
|
||||
<q-btn
|
||||
v-if="
|
||||
!isLeave &&
|
||||
|
|
@ -946,11 +952,7 @@ onMounted(async () => {
|
|||
checkPermission($route)?.attrOwnership === 'OWNER'
|
||||
"
|
||||
flat
|
||||
:disable="
|
||||
(props.row.commandId !== null && props.row.commandId !== '') ||
|
||||
props.row.commandType === 'C-PM-47'
|
||||
"
|
||||
:color="props.row.commandId ? 'grey' : 'edit'"
|
||||
color="edit"
|
||||
dense
|
||||
round
|
||||
icon="edit"
|
||||
|
|
@ -1119,7 +1121,8 @@ onMounted(async () => {
|
|||
<div class="row q-col-gutter-sm">
|
||||
<div class="col-6">
|
||||
<q-input
|
||||
:class="classInput(true)"
|
||||
:class="classInput(!idCommandId)"
|
||||
:readonly="idCommandId"
|
||||
outlined
|
||||
dense
|
||||
lazy-rules
|
||||
|
|
@ -1139,7 +1142,8 @@ onMounted(async () => {
|
|||
autoApply
|
||||
year-picker
|
||||
:enableTimePicker="false"
|
||||
class="inputgreen"
|
||||
:class="classInput(!idCommandId)"
|
||||
:disable="idCommandId"
|
||||
>
|
||||
<template #year="{ year }">{{ year + 543 }}</template>
|
||||
<template #year-overlay-value="{ value }">{{
|
||||
|
|
@ -1156,6 +1160,8 @@ onMounted(async () => {
|
|||
: formData.commandYear + 543
|
||||
"
|
||||
label="ปี พ.ศ."
|
||||
:class="classInput(!idCommandId)"
|
||||
:readonly="idCommandId"
|
||||
>
|
||||
<template v-slot:prepend>
|
||||
<q-icon
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue