isAttachment
This commit is contained in:
parent
57dd12d6d2
commit
13317f94f2
5 changed files with 9 additions and 8 deletions
|
|
@ -39,6 +39,8 @@ let formData = reactive<FormDataDetail>({
|
||||||
commandAffectDate: null, //วันที่ลงนาม
|
commandAffectDate: null, //วันที่ลงนาม
|
||||||
commandExcecuteDate: null, //วันที่คำสั่งมีผล
|
commandExcecuteDate: null, //วันที่คำสั่งมีผล
|
||||||
isBangkok: false,
|
isBangkok: false,
|
||||||
|
isAttachment:true
|
||||||
|
|
||||||
});
|
});
|
||||||
const modalPreview = ref<boolean>(false); //แสดงตัวอย่าง
|
const modalPreview = ref<boolean>(false); //แสดงตัวอย่าง
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -138,9 +138,10 @@ function onDelete(id: string) {
|
||||||
dialogRemove($q, async () => {
|
dialogRemove($q, async () => {
|
||||||
showLoader();
|
showLoader();
|
||||||
await http
|
await http
|
||||||
.get(config.API.commandAction(id, "tab2"))
|
.delete(config.API.commandAction(id, "tab2"))
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
success($q, "ลบข้อมูลสำเร็จ");
|
success($q, "ลบข้อมูลสำเร็จ");
|
||||||
|
getPersonList();
|
||||||
})
|
})
|
||||||
.catch((e) => {
|
.catch((e) => {
|
||||||
messageError($q, e);
|
messageError($q, e);
|
||||||
|
|
|
||||||
|
|
@ -37,8 +37,8 @@ function onSubmit() {
|
||||||
mouthSalaryAmount: formData.salaryAmount, //เงินเดือน
|
mouthSalaryAmount: formData.salaryAmount, //เงินเดือน
|
||||||
positionSalaryAmount: formData.positionSalaryAmount, //เงินประจำตำแหน่ง
|
positionSalaryAmount: formData.positionSalaryAmount, //เงินประจำตำแหน่ง
|
||||||
amount: formData.monthSalaryAmount, //เงินค่าตอบแทนรายเดือน
|
amount: formData.monthSalaryAmount, //เงินค่าตอบแทนรายเดือน
|
||||||
remarkHorizontal: formData.remarkVertical, //หมายเหตุแนวตั้ง
|
remarkVertical: formData.remarkVertical, //หมายเหตุแนวตั้ง
|
||||||
remarkVertical: formData.remarkHorizontal, //หมายเหตุแนวนอน
|
remarkHorizontal: formData.remarkHorizontal, //หมายเหตุแนวนอน
|
||||||
})
|
})
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
success($q, "บันทึกข้อมูลสำเร็จ");
|
success($q, "บันทึกข้อมูลสำเร็จ");
|
||||||
|
|
|
||||||
|
|
@ -25,6 +25,7 @@ interface FormDataDetail {
|
||||||
commandSysId?: string;
|
commandSysId?: string;
|
||||||
commandTypeName?: string;
|
commandTypeName?: string;
|
||||||
isBangkok?: boolean;
|
isBangkok?: boolean;
|
||||||
|
isAttachment:boolean
|
||||||
}
|
}
|
||||||
|
|
||||||
interface ListCommandSalaryType {
|
interface ListCommandSalaryType {
|
||||||
|
|
|
||||||
|
|
@ -23,7 +23,6 @@ const router = useRouter();
|
||||||
const route = useRoute();
|
const route = useRoute();
|
||||||
const commandId = ref<string>(route.params.id.toString()); //ID คำสั่ง
|
const commandId = ref<string>(route.params.id.toString()); //ID คำสั่ง
|
||||||
const store = useCommandDetail();
|
const store = useCommandDetail();
|
||||||
const isAttachment = ref<boolean>(true);
|
|
||||||
|
|
||||||
const childDetailRef = ref<InstanceType<typeof Detail> | null>(null); //ref components รายละเอียดคำสั่ง
|
const childDetailRef = ref<InstanceType<typeof Detail> | null>(null); //ref components รายละเอียดคำสั่ง
|
||||||
const childListPersonsRef = ref<InstanceType<typeof ListPersons> | null>(null); //ref components รายชื่อผู้ออกคำสั่ง
|
const childListPersonsRef = ref<InstanceType<typeof ListPersons> | null>(null); //ref components รายชื่อผู้ออกคำสั่ง
|
||||||
|
|
@ -63,6 +62,7 @@ let formCommandList = reactive<FormDataDetail>({
|
||||||
commandAffectDate: null, //วันที่ลงนาม
|
commandAffectDate: null, //วันที่ลงนาม
|
||||||
commandExcecuteDate: null, //วันที่คำสั่งมีผล
|
commandExcecuteDate: null, //วันที่คำสั่งมีผล
|
||||||
commandSysId: "", // ประเภท คำสั่ง
|
commandSysId: "", // ประเภท คำสั่ง
|
||||||
|
isAttachment:true
|
||||||
});
|
});
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -85,11 +85,8 @@ async function fetchDataCommandList() {
|
||||||
.get(config.API.commandAction(commandId.value, "tab1"))
|
.get(config.API.commandAction(commandId.value, "tab1"))
|
||||||
.then(async (res) => {
|
.then(async (res) => {
|
||||||
const data = await res.data.result;
|
const data = await res.data.result;
|
||||||
console.log("🚀 ~ .then ~ data:", data);
|
|
||||||
formCommandList = data;
|
formCommandList = data;
|
||||||
store.dataCommand = data;
|
store.dataCommand = data;
|
||||||
//รอ API ส่งมา isAttachment.value = data.isAttachment ;
|
|
||||||
isAttachment.value = true; // จำลอง
|
|
||||||
isChangeData.value = false; //จำลอง
|
isChangeData.value = false; //จำลอง
|
||||||
})
|
})
|
||||||
.catch((err) => {
|
.catch((err) => {
|
||||||
|
|
@ -217,7 +214,7 @@ onMounted(async () => {
|
||||||
ref="childAttachedRef"
|
ref="childAttachedRef"
|
||||||
v-model:is-change-data="isChangeData"
|
v-model:is-change-data="isChangeData"
|
||||||
:on-check-change-data="onCheckChangeData"
|
:on-check-change-data="onCheckChangeData"
|
||||||
v-model:is-attachment="isAttachment"
|
v-model:is-attachment="formCommandList.isAttachment "
|
||||||
/>
|
/>
|
||||||
</q-card>
|
</q-card>
|
||||||
</q-tab-panel>
|
</q-tab-panel>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue