This commit is contained in:
DESKTOP-1R2VSQH\Lenovo ThinkPad E490 2024-07-01 21:05:57 +07:00
parent 246e2caf96
commit e9029b88d4

View file

@ -228,13 +228,12 @@ const filter = ref<string>("");
/** function เรียกรอบการเสนอขอพระราชทานเครื่องราช*/ /** function เรียกรอบการเสนอขอพระราชทานเครื่องราช*/
async function fecthRound() { async function fecthRound() {
// showLoader(); showLoader();
await http await http
.get(config.API.noteround()) .get(config.API.noteround())
.then(async (res) => { .then(async (res) => {
let data = res.data.result; let data = res.data.result;
console.log(data);
if (data.length !== 0) { if (data.length !== 0) {
selectRoundOption.value = data.map((e: any) => ({ selectRoundOption.value = data.map((e: any) => ({
name: "รอบการเสนอขอพระราชทานเครื่องราชฯ ปี" + " " + (e.year + 543), name: "รอบการเสนอขอพระราชทานเครื่องราชฯ ปี" + " " + (e.year + 543),
@ -247,6 +246,8 @@ async function fecthRound() {
}) })
.catch((err) => { .catch((err) => {
messageError($q, err); messageError($q, err);
})
.finally(() => {
hideLoader(); hideLoader();
}); });
} }