เครื่องราชฯ

This commit is contained in:
DESKTOP-1R2VSQH\Lenovo ThinkPad E490 2023-09-19 14:58:16 +07:00
parent 8ebbef05d9
commit 1530da36cf
22 changed files with 159 additions and 777 deletions

View file

@ -40,8 +40,6 @@ const closeModal = () => {
props.close();
};
const clickSave = () => {
console.log(props.insigniadata);
dialogConfirm($q, () => {
if (props.actionType === "insignia") {
props.save(
@ -76,7 +74,7 @@ const clickSave = () => {
dense
lazy-rules
type="text"
label="จำนวน"
label="เครื่องราชฯ"
disable
/>
</div>

View file

@ -97,7 +97,6 @@ const clickSave = () => {
label="จำนวน"
:rules="[(val) => !!val || `${'กรุณากรอกจำนวน'}`]"
/>
<!-- :rules="[(val:any) =>val.length != 13 ||`${'กรุณากรอกเลขประจำตัวประชาชนให้ครบ'}`,]" -->
</div>
</div>
</div>

View file

@ -1,19 +1,18 @@
<script setup lang="ts">
import { ref, onMounted, watch, useAttrs } from "vue";
// import { useRouter } from "vue-router";
import { useCounterMixin } from "@/stores/mixin";
import http from "@/plugins/http";
import config from "@/app.config";
import { useAllocateDataStore } from "@/modules/07_insignia/storeAllocate";
import type { FormProprsalsRound } from "@/modules/07_insignia/interface/request/Main";
import router from "@/router";
import DialogForm from "@/modules/07_insignia/components/4_Allocate/DialogForm.vue";
import DialogEdit from "@/modules/07_insignia/components/4_Allocate/DialogEdit.vue";
import type { OptionDataYear } from "@/modules/07_insignia/interface/index/Main";
import type { QTableProps, QInput } from "quasar";
import { Loading, useQuasar } from "quasar";
import type { load } from "@/router/loader";
import { useQuasar } from "quasar";
const DataStore = useAllocateDataStore();
const mixin = useCounterMixin();
@ -41,16 +40,12 @@ const selectRound = ref<string>();
const selectRoundOption = ref<OptionDataYear[]>([]);
const modal = ref<boolean>(false);
const action = ref<string>("");
const personId = ref<string>();
const profileType = ref<string>("");
const filterKeyword = ref<string>("");
const roundYear = ref<number>();
const insigniaOp = ref<any>([]);
const loadView = ref<boolean>(false);
onMounted(async () => {
await fecthRound();
// await fecthInsigniaType();
});
const fecthRound = async () => {
@ -74,8 +69,6 @@ const fecthRound = async () => {
if (selectRound.value) {
DataStore.roundId = selectRound.value;
}
// roundYear.value = data[0].year;
if (roundYear.value) {
await fecthInsigniaType();
}
@ -111,7 +104,6 @@ const fecthInsigniaType = async () => {
if (DataStore.mainTab) {
tab.value = DataStore.mainTab;
} else tab.value = DataStore.insigniaType[0].name;
loadView.value = true;
fecthInsignia();
})

View file

@ -64,7 +64,6 @@ const fecthListData = async () => {
await http
.get(config.API.insigniaManageOrg(id.value))
.then((res) => {
// console.log("res===>", res)
rows.value = res.data.result.map((e: any) => ({
id: e.id,
organization: e.organizationOrganization,
@ -129,7 +128,9 @@ const save = async (organizationId: string, total: string) => {
const saveEdit = async (organizationId: string, amount: number) => {
showLoader();
await http
.put(config.API.insigniaManageOrg(organizationId), { total: Number(amount) })
.put(config.API.insigniaManageOrg(organizationId), {
total: Number(amount),
})
.then(async () => {
success($q, "แก้ไขมูลสำเร็จ");
await fecthDashboard();