Merge branch 'anandadev' into develop
This commit is contained in:
commit
9edb214a6e
10 changed files with 425 additions and 254 deletions
|
|
@ -1 +1,9 @@
|
|||
export type {};
|
||||
interface FormProprsalsRound {
|
||||
id: number;
|
||||
name: string;
|
||||
year: number;
|
||||
startDate: number;
|
||||
endDate: number;
|
||||
status: string;
|
||||
}
|
||||
export type { FormProprsalsRound };
|
||||
|
|
|
|||
|
|
@ -3,11 +3,17 @@
|
|||
*/
|
||||
|
||||
const Main = () => import("@/modules/07_insignia/views/Main.vue");
|
||||
const ReportView = () => import("../07_insignia/components/report/ReportView.vue")
|
||||
const report_01 = () => import("../07_insignia/components/report/Report_01.vue")
|
||||
const ReportView = () =>
|
||||
import("../07_insignia/components/report/ReportView.vue");
|
||||
const report_01 = () =>
|
||||
import("../07_insignia/components/report/Report_01.vue");
|
||||
const ResultInsignia = () =>
|
||||
import("@/modules/07_insignia/components/ResultInsignia.vue");
|
||||
const Coin = () => import("@/modules/07_insignia/components/Coin.vue");
|
||||
const insigniaProposals = () =>
|
||||
import("@/modules/07_insignia/views/1_Proposals/listProposals.vue");
|
||||
const roundAdd = () =>
|
||||
import("@/modules/07_insignia/views/1_Proposals/addProposals.vue");
|
||||
|
||||
export default [
|
||||
{
|
||||
|
|
|
|||
|
|
@ -0,0 +1,175 @@
|
|||
<template>
|
||||
<div class="col-xs-12 col-sm-12 col-md-11">
|
||||
<div class="toptitle col-12 row items-center">
|
||||
<q-btn
|
||||
icon="mdi-arrow-left"
|
||||
unelevated
|
||||
round
|
||||
dense
|
||||
flat
|
||||
color="primary"
|
||||
class="q-mr-sm"
|
||||
@click="router.go(-1)"
|
||||
/>
|
||||
<div>เพิ่มรอบการเสนอขอพระราชทานเครื่องราชอิสริยาภรณ์</div>
|
||||
</div>
|
||||
<div class="col-12">
|
||||
<q-card bordered>
|
||||
<div class="col-12 row q-col-gutter-md q-pa-md">
|
||||
<div class="col-xs-12 col-sm-12 row">
|
||||
<q-separator />
|
||||
<div class="col-12 row q-pa-sm q-col-gutter-sm">
|
||||
<q-input
|
||||
class="col-10"
|
||||
dense
|
||||
outlined
|
||||
v-model="roundInsig"
|
||||
label="รอบการเสนอขอพระราชทานเครื่องราชฯ"
|
||||
/>
|
||||
<q-input
|
||||
class="col-2"
|
||||
dense
|
||||
outlined
|
||||
v-model="year"
|
||||
label="ปีที่เสนอ"
|
||||
/>
|
||||
<datepicker
|
||||
menu-class-name="modalfix"
|
||||
v-model="dateStart"
|
||||
:locale="'th'"
|
||||
autoApply
|
||||
class="col-xs-12 col-sm-5"
|
||||
borderless
|
||||
:enableTimePicker="false"
|
||||
week-start="0"
|
||||
>
|
||||
<template #year="{ year }">
|
||||
{{ year + 543 }}
|
||||
</template>
|
||||
<template #year-overlay-value="{ value }">
|
||||
{{ parseInt(value + 543) }}
|
||||
</template>
|
||||
<template #trigger>
|
||||
<q-input
|
||||
outlined
|
||||
dense
|
||||
class="col-xs-12 col-sm-5"
|
||||
:model-value="
|
||||
dateStart != null ? date2Thai(dateStart) : null
|
||||
"
|
||||
:label="`${'วันเริ่มต้น'}`"
|
||||
:rules="[(val) => !!val || `${'กรุณาเลือกวันเริ่มต้น'}`]"
|
||||
>
|
||||
<template v-slot:prepend>
|
||||
<q-icon
|
||||
name="event"
|
||||
class="cursor-pointer"
|
||||
style="color: var(--q-primary)"
|
||||
>
|
||||
</q-icon>
|
||||
</template>
|
||||
</q-input>
|
||||
</template>
|
||||
</datepicker>
|
||||
<datepicker
|
||||
menu-class-name="modalfix"
|
||||
v-model="dateEnd"
|
||||
class="col-xs-12 col-sm-5"
|
||||
:locale="'th'"
|
||||
autoApply
|
||||
borderless
|
||||
:enableTimePicker="false"
|
||||
week-start="0"
|
||||
>
|
||||
<template #year="{ year }">
|
||||
{{ year + 543 }}
|
||||
</template>
|
||||
<template #year-overlay-value="{ value }">
|
||||
{{ parseInt(value + 543) }}
|
||||
</template>
|
||||
<template #trigger>
|
||||
<q-input
|
||||
outlined
|
||||
dense
|
||||
class="col-xs-12 col-sm-4"
|
||||
:model-value="dateEnd != null ? date2Thai(dateEnd) : null"
|
||||
:label="`${'วันสิ้นสุด'}`"
|
||||
:rules="[
|
||||
(val) => !!val || `${'กรุณาเลือกวันที่วันสิ้นสุด'}`,
|
||||
]"
|
||||
>
|
||||
<template v-slot:prepend>
|
||||
<q-icon
|
||||
name="event"
|
||||
class="cursor-pointer"
|
||||
style="color: var(--q-primary)"
|
||||
>
|
||||
</q-icon>
|
||||
</template>
|
||||
</q-input>
|
||||
</template>
|
||||
</datepicker>
|
||||
|
||||
<q-input
|
||||
class="col-xs-12 col-sm-2"
|
||||
dense
|
||||
outlined
|
||||
v-model="datelast"
|
||||
label="จำนวนวันแจ้งเตือนก่อนวันสิ้นสุด"
|
||||
/>
|
||||
<q-file
|
||||
class="col-xs-12 col-sm-10"
|
||||
outlined
|
||||
dense
|
||||
v-model="files"
|
||||
label="อัปโหลดเอกสารประกอบ"
|
||||
hide-bottom-space
|
||||
lazy-rules
|
||||
:rules="[
|
||||
(val) => val || 'กรุณาเลือกไฟล์หนังสือถึงหน่วยงานที่รับโอน',
|
||||
]"
|
||||
>
|
||||
<template v-slot:prepend>
|
||||
<q-icon name="attach_file" />
|
||||
</template>
|
||||
</q-file>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<q-separator />
|
||||
<q-separator />
|
||||
<div class="row col-12 q-pa-sm">
|
||||
<q-space />
|
||||
<q-btn
|
||||
unelevated
|
||||
dense
|
||||
class="q-px-md items-center"
|
||||
color="light-blue-10"
|
||||
label="บันทึก"
|
||||
@click="router.go(-1)"
|
||||
/>
|
||||
</div>
|
||||
</q-card>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import type { QTableProps } from "quasar";
|
||||
import { ref } from "vue";
|
||||
import { useQuasar } from "quasar";
|
||||
import { useRouter } from "vue-router";
|
||||
import { useCounterMixin } from "@/stores/mixin";
|
||||
|
||||
const mixin = useCounterMixin();
|
||||
const { date2Thai } = mixin;
|
||||
const router = useRouter();
|
||||
const $q = useQuasar();
|
||||
const dateStart = ref<any>(new Date());
|
||||
const dateEnd = ref<any>(new Date());
|
||||
|
||||
const roundInsig = ref<string>("");
|
||||
const year = ref<string>("");
|
||||
const datelast = ref<string>("");
|
||||
|
||||
const routeName = router.currentRoute.value.name;
|
||||
</script>
|
||||
|
|
@ -116,11 +116,11 @@
|
|||
size="12px"
|
||||
flat
|
||||
round
|
||||
color="indigo"
|
||||
color="light-blue-8"
|
||||
@click.stop.prevent="clickProposals(props.row.id)"
|
||||
icon="mdi-clipboard-arrow-down"
|
||||
icon="mdi-file-download"
|
||||
>
|
||||
<q-tooltip>ดาวน์โหลดเอกสารประกอบ</q-tooltip>
|
||||
<q-tooltip>ดาวน์โหลดเอกสารประกอบ </q-tooltip>
|
||||
</q-btn>
|
||||
</q-td>
|
||||
<q-td auto-width>
|
||||
|
|
@ -161,6 +161,7 @@ import { ref, useAttrs } from "vue";
|
|||
import type { QTableProps } from "quasar";
|
||||
import router from "@/router";
|
||||
import { useQuasar } from "quasar";
|
||||
import type { FormProprsalsRound } from " @/modules/07_insignia/interface/request/Main.ts";
|
||||
|
||||
const $q = useQuasar(); //ใช้ noti quasar
|
||||
const modal = ref<boolean>(false);
|
||||
|
|
@ -229,7 +230,7 @@ const columns = ref<QTableProps["columns"]>([
|
|||
]);
|
||||
|
||||
// ข้อมูลตาราง (จำลอง)
|
||||
const rows = ref<any[]>([
|
||||
const rows = ref<FormProprsalsRound[]>([
|
||||
{
|
||||
round: "รอบการเสนอขอพระราชทานเครื่องราชฯ",
|
||||
year: "2566",
|
||||
|
|
@ -284,10 +285,7 @@ const clickDelete = (id: string) => {
|
|||
};
|
||||
|
||||
const clickAdd = () => {
|
||||
modal.value = true;
|
||||
};
|
||||
const clickClose = async () => {
|
||||
modal.value = false;
|
||||
router.push({ name: "roundAdd" });
|
||||
};
|
||||
|
||||
// ค้นหาในตาราง
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue