isAttachment

This commit is contained in:
STW_TTTY\stwtt 2024-09-26 11:21:26 +07:00
parent 57dd12d6d2
commit 13317f94f2
5 changed files with 9 additions and 8 deletions

View file

@ -23,7 +23,6 @@ const router = useRouter();
const route = useRoute();
const commandId = ref<string>(route.params.id.toString()); //ID
const store = useCommandDetail();
const isAttachment = ref<boolean>(true);
const childDetailRef = ref<InstanceType<typeof Detail> | null>(null); //ref components
const childListPersonsRef = ref<InstanceType<typeof ListPersons> | null>(null); //ref components
@ -63,6 +62,7 @@ let formCommandList = reactive<FormDataDetail>({
commandAffectDate: null, //
commandExcecuteDate: null, //
commandSysId: "", //
isAttachment:true
});
/**
@ -85,11 +85,8 @@ async function fetchDataCommandList() {
.get(config.API.commandAction(commandId.value, "tab1"))
.then(async (res) => {
const data = await res.data.result;
console.log("🚀 ~ .then ~ data:", data);
formCommandList = data;
store.dataCommand = data;
// API isAttachment.value = data.isAttachment ;
isAttachment.value = true; //
isChangeData.value = false; //
})
.catch((err) => {
@ -217,7 +214,7 @@ onMounted(async () => {
ref="childAttachedRef"
v-model:is-change-data="isChangeData"
:on-check-change-data="onCheckChangeData"
v-model:is-attachment="isAttachment"
v-model:is-attachment="formCommandList.isAttachment "
/>
</q-card>
</q-tab-panel>