refactor: add closeTab

This commit is contained in:
Thanaphon Frappet 2024-10-18 09:10:33 +07:00
parent 8f069de610
commit 7a06bfe87e

View file

@ -46,6 +46,7 @@ import {
EditButton,
UndoButton,
DeleteButton,
CancelButton,
} from 'components/button';
import ProductServiceForm from './ProductServiceForm.vue';
import QuotationFormInfo from './QuotationFormInfo.vue';
@ -210,6 +211,10 @@ const productServiceList = ref<
Required<QuotationPayload['productServiceList'][number]>[]
>([]);
function closeTab() {
window.close();
}
async function assignToProductServiceList() {
const ret = await productServiceStore.fetchProductGroup({
page: 1,
@ -873,6 +878,8 @@ async function searchEmployee(text: string) {
<q-icon name="mdi-play-box-outline" size="xs" class="q-mr-xs" />
{{ $t('general.view', { msg: $t('general.example') }) }}
</q-btn>
<div class="row" style="gap: var(--size-2)">
<CancelButton solid @click="closeTab()" />
<SaveButton
v-if="
quotationFormState.mode === 'create' ||
@ -892,6 +899,7 @@ async function searchEmployee(text: string) {
solid
/>
</div>
</div>
</footer>
<!-- SEC: Dialog -->