แก้บรรจุแต่งตั้ง รายชื่อที่สอบผ่าน

This commit is contained in:
Warunee Tamkoo 2024-10-28 12:16:50 +07:00
parent 627696ea65
commit e6dcc39765
5 changed files with 87 additions and 102 deletions

View file

@ -27,8 +27,8 @@ const date = defineModel<Date>("datePos", { required: true }); //วันยท
const positionData = defineModel<any[]>("position", { required: true }); //
const isAll = defineModel<boolean>("isAll", { required: true }); //
const isBlank = defineModel<boolean>("isBlank", { required: true }); //
const isPosition = defineModel<boolean>("isPosition", { required: true });
const isPositionOld = defineModel<boolean>("isPositionOld", { required: true }); //
const isPosition = defineModel<string>("isPosition", { required: true });
// const isPositionOld = defineModel<boolean>("isPositionOld", { required: true }); //
const posType = defineModel<FormPosType>("posType", { required: true }); //
const posLevel = defineModel<string>("posLevel", { required: true }); //
const optionPosType = defineModel<FormPosType[]>("optionPosType", {
@ -37,6 +37,7 @@ const optionPosType = defineModel<FormPosType[]>("optionPosType", {
const optionPosLevel = defineModel<FormPosLevel[]>("optionPosLevel", {
required: true,
});
const bmaOfficer = defineModel<string>("bmaOfficer", { required: true });
const positionRows = ref<DataPositionNo[]>(positionData.value);
@ -219,16 +220,16 @@ async function onClickSelectPos(id: string) {
}
}
function onPositionOld() {
props.fetchDataTable?.(props.nodeId, props.nodeLevel);
if (isPositionOld.value == false) {
posType.value.id = "";
posType.value.posTypeName = "";
posType.value.posTypeRank = null;
posType.value.posLevels = [];
posLevel.value = "";
}
}
// function onPositionOld() {
// props.fetchDataTable?.(props.nodeId, props.nodeLevel);
// if (isPositionOld.value == false) {
// posType.value.id = "";
// posType.value.posTypeName = "";
// posType.value.posTypeRank = null;
// posType.value.posLevels = [];
// posLevel.value = "";
// }
// }
// filter filter
watch(positionData, (newVal, oldVal) => {
@ -269,18 +270,6 @@ onMounted(async () => {
>
<q-tooltip>แสดงเฉพาะตำแหนงวาง </q-tooltip>
</q-checkbox>
<q-checkbox
keep-color
v-model="isPosition"
label="แสดงเฉพาะตำแหน่งที่ตรงกับการสอบ"
color="primary"
@update:model-value="
props.fetchDataTable?.(props.nodeId, props.nodeLevel)
"
>
<q-tooltip>แสดงเฉพาะตำแหนงทตรงกบการสอบ</q-tooltip>
</q-checkbox>
<q-checkbox
keep-color
v-model="isAll"
@ -295,20 +284,34 @@ onMounted(async () => {
<div class="col-12">
<div class="row q-gutter-sm no-wrap">
<div>
<q-checkbox
<q-radio
keep-color
v-model="isPositionOld"
label="แสดงตำแหน่งที่ตรงกับประเภทและระดับเดิม"
v-model="isPosition"
val="exam"
label="แสดงเฉพาะตำแหน่งที่ตรงกับการสอบ"
color="primary"
@update:model-value="onPositionOld"
:disable="bmaOfficer == 'บุคคลภายนอก'"
>
<q-tooltip>แสดงตำแหนงทตรงกประเภทและระดบเด</q-tooltip>
</q-checkbox>
<q-tooltip>แสดงเฉพาะตำแหนงทตรงกการสอบ</q-tooltip>
</q-radio>
</div>
<div class="col-3">
<div>
<q-radio
keep-color
v-model="isPosition"
val="select"
label="แสดงตำแหน่งที่ตรงกับประเภทและระดับ"
color="primary"
:disable="bmaOfficer == 'บุคคลภายนอก'"
>
<q-tooltip>แสดงตำแหนงทตรงกบประเภทและระด</q-tooltip>
</q-radio>
</div>
<div class="col-2">
<q-select
v-if="isPositionOld"
v-if="isPosition == 'select'"
v-model="posType"
:options="optionPosType"
option-label="posTypeName"
@ -319,14 +322,14 @@ onMounted(async () => {
>
</q-select>
</div>
<div class="col-3">
<div class="col-2">
<q-select
v-if="isPositionOld"
v-if="isPosition == 'select'"
:readonly="posType == null"
v-model="posLevel"
:options="optionPosLevel"
option-label="posLevelName"
option-value="posLevelName"
option-value="id"
label="ระดับตำแหน่ง"
dense
outlined