Merge branch 'master' of https://gitea.verdnatura.es/verdnatura/salix-front into 6818-hotfix-refactorParsePhone
gitea/salix-front/pipeline/pr-master This commit looks good
Details
gitea/salix-front/pipeline/pr-master This commit looks good
Details
This commit is contained in:
commit
ad45d612ee
|
@ -133,7 +133,7 @@ const addFilter = async (filter, params) => {
|
||||||
async function fetch(params) {
|
async function fetch(params) {
|
||||||
useArrayData(props.dataKey, params);
|
useArrayData(props.dataKey, params);
|
||||||
arrayData.reset(['filter.skip', 'skip', 'page']);
|
arrayData.reset(['filter.skip', 'skip', 'page']);
|
||||||
await arrayData.fetch({ append: false });
|
await arrayData.fetch({ append: false, updateRouter: mounted.value });
|
||||||
return emitStoreData();
|
return emitStoreData();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -82,11 +82,11 @@ const entriesTableColumns = computed(() => [
|
||||||
</QCardSection>
|
</QCardSection>
|
||||||
<QCardActions align="right">
|
<QCardActions align="right">
|
||||||
<QBtn
|
<QBtn
|
||||||
:label="t('printLabels')"
|
:label="t('myEntries.printLabels')"
|
||||||
color="primary"
|
color="primary"
|
||||||
icon="print"
|
icon="print"
|
||||||
:loading="isLoading"
|
:loading="isLoading"
|
||||||
@click="openReport(`Entries/${entityId}/print`)"
|
@click="openReport(`Entries/${entityId}/labelSupplier`)"
|
||||||
unelevated
|
unelevated
|
||||||
autofocus
|
autofocus
|
||||||
/>
|
/>
|
||||||
|
@ -126,7 +126,9 @@ const entriesTableColumns = computed(() => [
|
||||||
"
|
"
|
||||||
unelevated
|
unelevated
|
||||||
>
|
>
|
||||||
<QTooltip>{{ t('viewLabel') }}</QTooltip>
|
<QTooltip>{{
|
||||||
|
t('myEntries.viewLabel')
|
||||||
|
}}</QTooltip>
|
||||||
</QBtn>
|
</QBtn>
|
||||||
</QTr>
|
</QTr>
|
||||||
</template>
|
</template>
|
||||||
|
|
|
@ -101,7 +101,7 @@ const columns = computed(() => [
|
||||||
name: 'tableActions',
|
name: 'tableActions',
|
||||||
actions: [
|
actions: [
|
||||||
{
|
{
|
||||||
title: t('printLabels'),
|
title: t('myEntries.printLabels'),
|
||||||
icon: 'print',
|
icon: 'print',
|
||||||
isPrimary: true,
|
isPrimary: true,
|
||||||
action: (row) => printBuys(row.id),
|
action: (row) => printBuys(row.id),
|
||||||
|
|
|
@ -43,16 +43,17 @@ const columns = computed(() => [
|
||||||
{
|
{
|
||||||
align: 'left',
|
align: 'left',
|
||||||
name: 'ref',
|
name: 'ref',
|
||||||
label: t('invoiceOutList.tableVisibleColumns.ref'),
|
label: t('globals.reference'),
|
||||||
isTitle: true,
|
isTitle: true,
|
||||||
component: 'select',
|
component: 'select',
|
||||||
attrs: {
|
attrs: {
|
||||||
url: MODEL,
|
url: MODEL,
|
||||||
optionLabel: 'ref',
|
optionLabel: 'ref',
|
||||||
optionValue: 'id',
|
optionValue: 'ref',
|
||||||
},
|
},
|
||||||
columnField: {
|
columnField: { component: null },
|
||||||
component: null,
|
columnFilter: {
|
||||||
|
inWhere: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -147,25 +148,22 @@ function openPdf(id) {
|
||||||
}
|
}
|
||||||
|
|
||||||
function downloadPdf() {
|
function downloadPdf() {
|
||||||
if (selectedRows.value.size === 0) return;
|
if (selectedRows.value.size === 0) return;
|
||||||
const selectedCardsArray = Array.from(selectedRows.value.values());
|
const selectedCardsArray = Array.from(selectedRows.value.values());
|
||||||
|
|
||||||
if (selectedRows.value.size === 1) {
|
if (selectedRows.value.size === 1) {
|
||||||
const [invoiceOut] = selectedCardsArray;
|
const [invoiceOut] = selectedCardsArray;
|
||||||
openPdf(invoiceOut.id);
|
openPdf(invoiceOut.id);
|
||||||
} else {
|
} else {
|
||||||
const invoiceOutIdsArray = selectedCardsArray.map(
|
const invoiceOutIdsArray = selectedCardsArray.map((invoiceOut) => invoiceOut.id);
|
||||||
(invoiceOut) => invoiceOut.id
|
const invoiceOutIds = invoiceOutIdsArray.join(',');
|
||||||
);
|
|
||||||
const invoiceOutIds = invoiceOutIdsArray.join(',');
|
|
||||||
|
|
||||||
const params = {
|
const params = {
|
||||||
ids: invoiceOutIds,
|
ids: invoiceOutIds,
|
||||||
};
|
};
|
||||||
|
|
||||||
openReport(`${MODEL}/downloadZip`, params);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
openReport(`${MODEL}/downloadZip`, params);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
watchEffect(selectedRows);
|
watchEffect(selectedRows);
|
||||||
|
|
Loading…
Reference in New Issue