ปรับฟอร์มประเมิน ตัวชี้วัด
This commit is contained in:
parent
6c10587139
commit
e41b2974f7
3 changed files with 25 additions and 17 deletions
|
|
@ -44,7 +44,7 @@ const formDetail = reactive<any>({
|
|||
includingName: "",
|
||||
including: "",
|
||||
target: "",
|
||||
unit: null,
|
||||
unit: "",
|
||||
weight: null,
|
||||
achievement1: "",
|
||||
achievement2: "",
|
||||
|
|
@ -59,6 +59,7 @@ const formDetail = reactive<any>({
|
|||
strategy: null,
|
||||
strategyId: "",
|
||||
strategyName: "",
|
||||
documentInfoEvidence: "",
|
||||
});
|
||||
|
||||
function fetchIndicators() {
|
||||
|
|
@ -219,7 +220,7 @@ function onSubmit() {
|
|||
|
||||
const formBody = {
|
||||
target: formDetail.target,
|
||||
unit: Number(formDetail.unit),
|
||||
unit: formDetail.unit,
|
||||
weight: Number(formDetail.weight),
|
||||
meaning: formDetail.meaning,
|
||||
formula: formDetail.formula,
|
||||
|
|
@ -305,12 +306,8 @@ watch(
|
|||
|
||||
<q-card bordered flat class="q-mt-sm no-shadow bg-white col-12">
|
||||
<div class="row q-px-md q-py-sm items-center bg-grey-1">
|
||||
<div class="col-4">
|
||||
<span>รหัสตัวชี้วัด</span>
|
||||
</div>
|
||||
<div class="col-4">
|
||||
<span>ชื่อตัวชี้วัด</span>
|
||||
</div>
|
||||
<div class="col-4">ลำดับ/รหัสตัวชี้วัด</div>
|
||||
<div class="col-4">ชื่อตัวชี้วัด</div>
|
||||
</div>
|
||||
<q-separator />
|
||||
|
||||
|
|
@ -363,7 +360,7 @@ watch(
|
|||
</div>
|
||||
|
||||
<div class="col-12 row">
|
||||
<div class="col-4 text-grey-6">รหัสตัวชี้วัด</div>
|
||||
<div class="col-4 text-grey-6">ลำดับ/รหัสตัวชี้วัด</div>
|
||||
<div class="col-8">{{ formDetail.including }}</div>
|
||||
</div>
|
||||
<div class="col-12 row">
|
||||
|
|
@ -399,7 +396,6 @@ watch(
|
|||
(val) => !!val || `${'กรุณากรอกหน่วยนับ'}`,
|
||||
]"
|
||||
hide-bottom-space
|
||||
mask="#"
|
||||
reverse-fill-mask
|
||||
/>
|
||||
</div>
|
||||
|
|
@ -490,6 +486,19 @@ watch(
|
|||
class="inputgreen"
|
||||
/>
|
||||
</div>
|
||||
|
||||
<div class="col-12">
|
||||
<q-input
|
||||
v-model="formDetail.documentInfoEvidence"
|
||||
label="ข้อมูลเอกสารหลักฐาน"
|
||||
type="textarea"
|
||||
outlined
|
||||
dense
|
||||
:rules="[(val:string) => !!val || `${'กรุณากรอกข้อมูลเอกสารหลักฐาน'}`,]"
|
||||
hide-bottom-space
|
||||
class="inputgreen"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@ const formData = reactive<FormDataAssigned>({
|
|||
including: "", //รหัสตัวชี้วัด
|
||||
includingName: "", //ชื่อตัวชี้วัด
|
||||
target: "", //ค่าเป้าหมาย
|
||||
unit: null, //หน่วยนับ
|
||||
unit: "", //หน่วยนับ
|
||||
weight: null, //น้ำหนัก (ร้อยละ)
|
||||
meaning: "", //นิยามหรือความหมายของตัวชี้วัด
|
||||
formula: "", //สูตรคำนวณ
|
||||
|
|
@ -80,7 +80,7 @@ function closeDialog() {
|
|||
formData.including = "";
|
||||
formData.includingName = "";
|
||||
formData.target = "";
|
||||
formData.unit = null;
|
||||
formData.unit = "";
|
||||
formData.achievement1 = "";
|
||||
formData.achievement2 = "";
|
||||
formData.achievement3 = "";
|
||||
|
|
@ -95,7 +95,7 @@ function onSubmit() {
|
|||
dialogConfirm($q, async () => {
|
||||
showLoader();
|
||||
formData.weight = Number(formData.weight);
|
||||
formData.unit = Number(formData.unit);
|
||||
formData.unit = formData.unit;
|
||||
formData.kpiUserEvaluationId = store.dataEvaluation.id;
|
||||
|
||||
try {
|
||||
|
|
@ -140,11 +140,11 @@ watch(
|
|||
<q-input
|
||||
outlined
|
||||
v-model="formData.including"
|
||||
label="รหัสตัวชี้วัด"
|
||||
label="ลำดับ/รหัสตัวชี้วัด"
|
||||
bg-color="white"
|
||||
dense
|
||||
class="inputgreen"
|
||||
:rules="[(val) => !!val || `${'กรุณากรอกรหัสตัวชี้วัด'}`]"
|
||||
:rules="[(val) => !!val || `${'กรุณากรอกลำดับ/รหัสตัวชี้วัด'}`]"
|
||||
hide-bottom-space
|
||||
lazy-rules
|
||||
/>
|
||||
|
|
@ -182,7 +182,6 @@ watch(
|
|||
:rules="[(val:string) => !!val || `${'กรุณากรอกหน่วยนับ'}`,]"
|
||||
hide-bottom-space
|
||||
class="inputgreen"
|
||||
mask="#"
|
||||
reverse-fill-mask
|
||||
lazy-rules
|
||||
/>
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ interface FormDataAssigned {
|
|||
including: string;
|
||||
includingName: string;
|
||||
target: string;
|
||||
unit: number | null;
|
||||
unit: string;
|
||||
weight: number | null;
|
||||
achievement1: string;
|
||||
achievement2: string;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue