แก้ สรุปผล
This commit is contained in:
parent
65c9aab134
commit
0731d6e399
3 changed files with 8 additions and 11 deletions
|
|
@ -21,6 +21,7 @@ import DialogHeader from "@/components/DialogHeader.vue";
|
|||
import http from "@/plugins/http";
|
||||
import config from "@/app.config";
|
||||
|
||||
const type = ref<string>("");
|
||||
const rows = ref<DataListRow[]>([])
|
||||
const $q = useQuasar();
|
||||
const selected = ref<ResponseData[]>([]);
|
||||
|
|
@ -53,8 +54,6 @@ const props = defineProps({
|
|||
getData: Function,
|
||||
rows2: Array,
|
||||
filterKeyword2: String,
|
||||
|
||||
type: String,
|
||||
});
|
||||
|
||||
const checkSelected = computed(() => {
|
||||
|
|
@ -65,7 +64,7 @@ const checkSelected = computed(() => {
|
|||
|
||||
//popup ยืนยันส่งัว
|
||||
const saveOrder = () => {
|
||||
if (props.type) {
|
||||
if (type.value) {
|
||||
dialogConfirm(
|
||||
$q,
|
||||
() => Ordersave(),
|
||||
|
|
@ -85,7 +84,7 @@ const Ordersave = async () => {
|
|||
console.log(body);
|
||||
showLoader();
|
||||
await http
|
||||
.put(config.API.reportresult(props.type as string), body)
|
||||
.put(config.API.reportresult(type.value as string), body)
|
||||
.then((res: any) => {
|
||||
success($q, "ส่งไปออกคำสั่งสำเร็จ");
|
||||
props.closeModal?.();
|
||||
|
|
@ -141,6 +140,7 @@ const fecthTypeOption = async () => {
|
|||
watchEffect(() => {
|
||||
if (props.Modal === true) {
|
||||
selected.value = [];
|
||||
type.value = ''
|
||||
// console.log(props.data.status)
|
||||
rows.value = props.data.persons.filter((item: any) => item.status !== 'REPORT');
|
||||
}
|
||||
|
|
@ -162,8 +162,7 @@ onMounted(async () => {
|
|||
<q-select
|
||||
outlined
|
||||
dense
|
||||
:model-value="type"
|
||||
@update:model-value="updateInputType"
|
||||
v-model="type"
|
||||
:options="optionsType"
|
||||
label="ประเภทคำสั่ง"
|
||||
style="width: 400px; max-width: auto"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue