แก้ไข type
This commit is contained in:
parent
e72f86e1d4
commit
a3905a84b6
5 changed files with 32 additions and 12 deletions
|
|
@ -205,7 +205,7 @@ const defaultAdd = () => {
|
||||||
if (props.statusAdd) {
|
if (props.statusAdd) {
|
||||||
edit.value = props.statusAdd;
|
edit.value = props.statusAdd;
|
||||||
name.value = "";
|
name.value = "";
|
||||||
if (uploader.value !== null) {
|
if (uploader.value) {
|
||||||
uploader.value.reset();
|
uploader.value.reset();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -116,7 +116,11 @@
|
||||||
lazy-rules
|
lazy-rules
|
||||||
:readonly="!edit"
|
:readonly="!edit"
|
||||||
:borderless="!edit"
|
:borderless="!edit"
|
||||||
:model-value="date2Thai(informaData.birthDate)"
|
:model-value="
|
||||||
|
informaData.birthDate == null
|
||||||
|
? ''
|
||||||
|
: date2Thai(informaData.birthDate)
|
||||||
|
"
|
||||||
:rules="[(val:string) => !!val || `${'กรุณาเลือก วัน/เดือน/ปี เกิด'}`]"
|
:rules="[(val:string) => !!val || `${'กรุณาเลือก วัน/เดือน/ปี เกิด'}`]"
|
||||||
:label="`${'วัน/เดือน/ปี เกิด'}`"
|
:label="`${'วัน/เดือน/ปี เกิด'}`"
|
||||||
>
|
>
|
||||||
|
|
@ -1051,7 +1055,10 @@ const editData = async () => {
|
||||||
nationality: informaData.value.nationality,
|
nationality: informaData.value.nationality,
|
||||||
race: informaData.value.ethnicity,
|
race: informaData.value.ethnicity,
|
||||||
religionId: informaData.value.religionId,
|
religionId: informaData.value.religionId,
|
||||||
birthDate: dateToISO(informaData.value.birthDate) ?? dateToISO(new Date()),
|
birthDate:
|
||||||
|
informaData.value.birthDate == null
|
||||||
|
? dateToISO(new Date())
|
||||||
|
: dateToISO(informaData.value.birthDate),
|
||||||
bloodGroupId: informaData.value.bloodId,
|
bloodGroupId: informaData.value.bloodId,
|
||||||
relationshipId: informaData.value.statusId,
|
relationshipId: informaData.value.statusId,
|
||||||
telephoneNumber: informaData.value.tel,
|
telephoneNumber: informaData.value.tel,
|
||||||
|
|
|
||||||
|
|
@ -70,7 +70,7 @@
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<template v-slot:body-selection="scope">
|
<template v-slot:body-selection="scope">
|
||||||
<q-checkbox
|
<!-- <q-checkbox
|
||||||
keep-color
|
keep-color
|
||||||
color="primary"
|
color="primary"
|
||||||
dense
|
dense
|
||||||
|
|
@ -83,6 +83,12 @@
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
"
|
"
|
||||||
|
/> -->
|
||||||
|
<q-checkbox
|
||||||
|
keep-color
|
||||||
|
color="primary"
|
||||||
|
dense
|
||||||
|
v-model="scope.selected"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
|
@ -175,6 +181,7 @@ import { ref } from "vue";
|
||||||
import { useQuasar } from "quasar";
|
import { useQuasar } from "quasar";
|
||||||
import type { QInput } from "quasar";
|
import type { QInput } from "quasar";
|
||||||
import { useCounterMixin } from "@/stores/mixin";
|
import { useCounterMixin } from "@/stores/mixin";
|
||||||
|
import type { QTableProps } from "quasar";
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
next: {
|
next: {
|
||||||
|
|
@ -197,7 +204,7 @@ const $q = useQuasar();
|
||||||
const filterRef = ref<QInput>();
|
const filterRef = ref<QInput>();
|
||||||
const filter = ref<string>("");
|
const filter = ref<string>("");
|
||||||
const visibleColumns = ref<String[]>(["no", "idcard", "name", "educate"]);
|
const visibleColumns = ref<String[]>(["no", "idcard", "name", "educate"]);
|
||||||
const columns = [
|
const columns = ref<QTableProps["columns"]>([
|
||||||
{ name: "no", align: "left", label: "ลำดับ", field: "no", sortable: true },
|
{ name: "no", align: "left", label: "ลำดับ", field: "no", sortable: true },
|
||||||
{
|
{
|
||||||
name: "idcard",
|
name: "idcard",
|
||||||
|
|
@ -220,7 +227,7 @@ const columns = [
|
||||||
field: "educate",
|
field: "educate",
|
||||||
sortable: true,
|
sortable: true,
|
||||||
},
|
},
|
||||||
];
|
]);
|
||||||
|
|
||||||
const rows = [
|
const rows = [
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -270,7 +270,7 @@
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<template v-slot:body-selection="scope">
|
<template v-slot:body-selection="scope">
|
||||||
<q-checkbox
|
<!-- <q-checkbox
|
||||||
keep-color
|
keep-color
|
||||||
color="primary"
|
color="primary"
|
||||||
dense
|
dense
|
||||||
|
|
@ -283,6 +283,12 @@
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
"
|
"
|
||||||
|
/> -->
|
||||||
|
<q-checkbox
|
||||||
|
keep-color
|
||||||
|
color="primary"
|
||||||
|
dense
|
||||||
|
v-model="scope.selected"
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
|
@ -337,6 +343,7 @@ import type { QInput, QForm } from "quasar";
|
||||||
import type { treeTab } from "@/modules/05_placement/interface/index/Main";
|
import type { treeTab } from "@/modules/05_placement/interface/index/Main";
|
||||||
import http from "@/plugins/http";
|
import http from "@/plugins/http";
|
||||||
import config from "@/app.config";
|
import config from "@/app.config";
|
||||||
|
import type { QTableProps } from "quasar";
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
next: {
|
next: {
|
||||||
|
|
@ -370,7 +377,7 @@ const selectedModal = ref([]);
|
||||||
const test = ref([]);
|
const test = ref([]);
|
||||||
const filterModal = ref<string>("");
|
const filterModal = ref<string>("");
|
||||||
const visibleColumnsModal = ref<String[]>(["no", "idcard", "name"]);
|
const visibleColumnsModal = ref<String[]>(["no", "idcard", "name"]);
|
||||||
const columnsModal = [
|
const columnsModal = ref<QTableProps["columns"]>([
|
||||||
{ name: "no", align: "left", label: "ลำดับ", field: "no", sortable: true },
|
{ name: "no", align: "left", label: "ลำดับ", field: "no", sortable: true },
|
||||||
{
|
{
|
||||||
name: "idcard",
|
name: "idcard",
|
||||||
|
|
@ -386,7 +393,7 @@ const columnsModal = [
|
||||||
field: "name",
|
field: "name",
|
||||||
sortable: true,
|
sortable: true,
|
||||||
},
|
},
|
||||||
];
|
]);
|
||||||
|
|
||||||
const rowsModal = [
|
const rowsModal = [
|
||||||
{
|
{
|
||||||
|
|
@ -482,7 +489,7 @@ const visibleColumns = ref<String[]>([
|
||||||
"agency",
|
"agency",
|
||||||
"send",
|
"send",
|
||||||
]);
|
]);
|
||||||
const columns = [
|
const columns = ref<QTableProps["columns"]>([
|
||||||
{ name: "no", align: "left", label: "ลำดับ", field: "no", sortable: true },
|
{ name: "no", align: "left", label: "ลำดับ", field: "no", sortable: true },
|
||||||
{
|
{
|
||||||
name: "idcard",
|
name: "idcard",
|
||||||
|
|
@ -519,7 +526,7 @@ const columns = [
|
||||||
field: "send",
|
field: "send",
|
||||||
sortable: true,
|
sortable: true,
|
||||||
},
|
},
|
||||||
];
|
]);
|
||||||
|
|
||||||
const rows = ref([
|
const rows = ref([
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -166,7 +166,6 @@
|
||||||
</template>
|
</template>
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, onMounted } from "vue";
|
import { ref, onMounted } from "vue";
|
||||||
import router from "@/router";
|
|
||||||
import { useQuasar } from "quasar";
|
import { useQuasar } from "quasar";
|
||||||
import { useCounterMixin } from "@/stores/mixin";
|
import { useCounterMixin } from "@/stores/mixin";
|
||||||
import type { QInput, QForm } from "quasar";
|
import type { QInput, QForm } from "quasar";
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue