Merge branch 'develop' of github.com:Frappet/bma-ehr-frontend into develop

This commit is contained in:
Warunee Tamkoo 2024-02-02 15:54:10 +07:00
commit 385c44d53c
2 changed files with 16 additions and 10 deletions

View file

@ -1,5 +1,5 @@
<script setup lang="ts"> <script setup lang="ts">
import { ref, reactive, watch,defineProps } from "vue"; import { ref, watch, defineProps } from "vue";
import { useQuasar } from "quasar"; import { useQuasar } from "quasar";
import http from "@/plugins/http"; import http from "@/plugins/http";
import config from "@/app.config"; import config from "@/app.config";
@ -44,7 +44,7 @@ function save() {
dialogConfirm($q, () => { dialogConfirm($q, () => {
const data = rows.value; const data = rows.value;
const dataId = data.map((item: any) => item.id); const dataId = data.map((item: any) => item.id);
showLoader() showLoader();
http http
.post(config.API.orgPosSort, { .post(config.API.orgPosSort, {
id: store.treeId, id: store.treeId,
@ -54,13 +54,13 @@ function save() {
.then((res) => { .then((res) => {
modal.value = false; modal.value = false;
success($q, "บันทึกข้อมูลสำเร็จ"); success($q, "บันทึกข้อมูลสำเร็จ");
props.fetchDataTable?.(store.treeId,store.level,false) props.fetchDataTable?.(store.treeId, store.level, false);
}) })
.catch((e) => { .catch((e) => {
messageError($q, e); messageError($q, e);
}) })
.finally(() => { .finally(() => {
hideLoader() hideLoader();
}); });
}); });
} }
@ -95,7 +95,6 @@ function getData() {
}); });
} }
watch( watch(
() => modal.value, () => modal.value,
() => { () => {
@ -136,13 +135,17 @@ watch(
hide-pagination hide-pagination
hide-header hide-header
/> />
<div v-else class="bg-grey-1 text-center q-pa-md"> <div v-else class="bg-grey-1 text-center q-pa-md">ไมอม</div>
ไมอม
</div>
</q-card-section> </q-card-section>
<q-separator /> <q-separator />
<q-card-actions align="right" class="bg-white text-teal"> <q-card-actions align="right" class="bg-white text-teal">
<q-btn :disable="rows.length === 0" type="submit" :label="`บันทึก`" color="public" @click="save" /> <q-btn
:disable="rows.length === 0"
type="submit"
:label="`บันทึก`"
color="public"
@click="save"
/>
</q-card-actions> </q-card-actions>
</q-card> </q-card>
</q-dialog> </q-dialog>

View file

@ -568,7 +568,10 @@ function updatePagination(newPagination: NewPagination) {
/> />
<!-- ดลำด --> <!-- ดลำด -->
<DialogSort v-model:sort-position="modalSort" /> <DialogSort
v-model:sort-position="modalSort"
:fetchDataTable="props.fetchDataTable"
/>
<!-- ายตำแหน --> <!-- ายตำแหน -->
<DialogMovePos <DialogMovePos