#7283 #7831 itemMigration #553

Merged
carlossa merged 77 commits from 7283-itemMigration into dev 2024-10-25 07:09:13 +00:00
1 changed files with 13 additions and 1 deletions
Showing only changes of commit e4aec1773b - Show all commits

View File

@ -7,6 +7,7 @@ import { useArrayData } from 'composables/useArrayData';
import { toCurrency } from 'filters/index';
import useNotify from 'src/composables/useNotify.js';
import axios from 'axios';
import ItemRequestDenyForm from './ItemRequestDenyForm.vue';
import { toDate } from 'src/filters';
import VnTable from 'components/VnTable/VnTable.vue';
import VnInput from 'src/components/common/VnInput.vue';
@ -26,6 +27,10 @@ const arrayData = useArrayData('ItemRequests', {
});
const store = arrayData.store;
const userParams = {
state: 'pending',
};
watch(
() => store.data,
(value) => (itemRequestsOptions.value = value)
@ -174,7 +179,9 @@ const onDenyAccept = (_, responseData) => {
itemRequestsOptions.value[denyRequestIndex.value].isOk = responseData.isOk;
itemRequestsOptions.value[denyRequestIndex.value].attenderFk =
responseData.attenderFk;
console.log('itemRequestsOptions: ', itemRequestsOptions.value);
itemRequestsOptions.value[denyRequestIndex.value].response = responseData.response;
console.log('itemRequestsOptions.value', itemRequestsOptions.value);
denyRequestId.value = null;
denyRequestIndex.value = null;
};
@ -341,8 +348,10 @@ onBeforeMount(() => {
url="ticketRequests/filter"
order="shippedDate ASC, isOk ASC"
:columns="columns"
:user-params="userParams"
:is-editable="true"
auto-load
:disable-option="{ card: true }"
>
<template #column-attenderName="{ row }">
<span class="link" @click.stop>
@ -378,7 +387,7 @@ onBeforeMount(() => {
{{ row.itemDescription }}
</span>
</template>
<template #column-action="{ row, rowIndex }">
<template #column-tableActions="{ row, rowIndex }">
<QTd>
<QIcon
v-if="row.response?.length"
@ -405,6 +414,9 @@ onBeforeMount(() => {
</QTd>
</template>
</VnTable>
<QDialog ref="denyFormRef" transition-show="scale" transition-hide="scale">
<ItemRequestDenyForm :request-id="denyRequestId" @on-data-saved="onDenyAccept" />
</QDialog>
</template>
<i18n>