#6464 correct negativeBases #373

Merged
jon merged 20 commits from 6464-fixNegativeBases into dev 2024-06-27 10:30:20 +00:00
15 changed files with 87 additions and 25 deletions
Showing only changes of commit b97f7e6b42 - Show all commits

View File

@ -139,6 +139,7 @@ const columns = computed(() => [
props: (prop) => ({
disable: true,
'model-value': Boolean(prop.value),
class: 'disabled-checkbox',
jon marked this conversation as resolved Outdated
Outdated
Review

Quitar el uso de esta clase

Quitar el uso de esta clase
}),
},
{

View File

@ -86,7 +86,9 @@ async function search() {
store.filter.skip = 0;
store.skip = 0;
const { params: newParams } = await arrayData.addFilter({ params });
console.log('params: ', params);
userParams.value = newParams;
console.log('userParams: ', userParams);
if (!props.showAll && !Object.values(params).length) store.data = [];

View File

@ -145,6 +145,15 @@ select:-webkit-autofill {
color: var(--vn-label-color);
}
.disabled-checkbox {
& .q-checkbox__label {
color: var(--vn-text-color);
}
& .q-checkbox__inner {
color: var(--vn-label-color);
}
}
.q-chip,
.q-notification__message,
.q-notification__icon {

View File

@ -183,10 +183,11 @@ const toCustomerAddressEdit = (addressId) => {
<QCheckbox
:label="t('Is equalizated')"
v-model="item.isEqualizated"
class="q-mr-lg"
class="q-mr-lg disabled-checkbox"
jon marked this conversation as resolved Outdated
Outdated
Review

Esta clase no la acabo de entender, sin ella funciona igual

Esta clase no la acabo de entender, sin ella funciona igual
Outdated
Review

Es para que los checkbox estén todos como en salix, por eso hay varios archivos que el único cambio es ese

Es para que los checkbox estén todos como en salix, por eso hay varios archivos que el único cambio es ese
disable
/>
<QCheckbox
class="disabled-checkbox"
:label="t('Is logiflora allowed')"
v-model="item.isLogifloraAllowed"
disable

View File

@ -249,7 +249,11 @@ const sendEmailAction = () => {
<template #body-cell-conciliated="{ row }">
<QTd align="center">
<QCheckbox :model-value="row.isConciliate === 1" disable />
<QCheckbox
:model-value="row.isConciliate === 1"
disable
class="disabled-checkbox"
/>
</QTd>
</template>

View File

@ -81,6 +81,7 @@ const tableColumnComponents = {
props: (prop) => ({
disable: true,
'model-value': Boolean(prop.value),
class: 'disabled-checkbox',
}),
event: () => {},
},

View File

@ -128,36 +128,43 @@ const creditWarning = computed(() => {
:text="t('customer.summary.fiscalData')"
/>
<QCheckbox
class="disabled-checkbox"
:label="t('customer.summary.isEqualizated')"
v-model="entity.isEqualizated"
:disable="true"
/>
<QCheckbox
class="disabled-checkbox"
:label="t('customer.summary.isActive')"
v-model="entity.isActive"
:disable="true"
/>
<QCheckbox
class="disabled-checkbox"
:label="t('customer.summary.invoiceByAddress')"
v-model="entity.hasToInvoiceByAddress"
:disable="true"
/>
<QCheckbox
class="disabled-checkbox"
:label="t('customer.summary.verifiedData')"
v-model="entity.isTaxDataChecked"
:disable="true"
/>
<QCheckbox
class="disabled-checkbox"
:label="t('customer.summary.hasToInvoice')"
v-model="entity.hasToInvoice"
:disable="true"
/>
<QCheckbox
class="disabled-checkbox"
:label="t('customer.summary.notifyByEmail')"
v-model="entity.isToBeMailed"
:disable="true"
/>
<QCheckbox
class="disabled-checkbox"
:label="t('customer.summary.vies')"
v-model="entity.isVies"
:disable="true"
@ -175,18 +182,21 @@ const creditWarning = computed(() => {
<VnLv :label="t('customer.summary.bankAccount')" :value="entity.iban" />
<VnLv :label="t('customer.summary.dueDay')" :value="entity.dueDay" />
<QCheckbox
class="disabled-checkbox"
style="padding: 0"
:label="t('customer.summary.hasLcr')"
v-model="entity.hasLcr"
:disable="true"
/>
<QCheckbox
class="disabled-checkbox"
:label="t('customer.summary.hasCoreVnl')"
v-model="entity.hasCoreVnl"
:disable="true"
/>
<QCheckbox
class="disabled-checkbox"
:label="t('customer.summary.hasB2BVnl')"
v-model="entity.hasSepaVnl"
:disable="true"
@ -220,6 +230,7 @@ const creditWarning = computed(() => {
:value="entity.account.name"
/>
<QCheckbox
class="disabled-checkbox"
:label="t('customer.summary.webAccess')"
v-model="entity.account.active"
:disable="true"

View File

@ -233,6 +233,7 @@ const fetchEntryBuys = async () => {
/>
<QCheckbox
class="disabled-checkbox"
:label="t('entry.summary.travelDelivered')"
v-model="entry.travel.isDelivered"
:disable="true"
@ -248,6 +249,7 @@ const fetchEntryBuys = async () => {
/>
<QCheckbox
class="disabled-checkbox"
:label="t('entry.summary.travelReceived')"
v-model="entry.travel.isReceived"
:disable="true"
@ -262,26 +264,31 @@ const fetchEntryBuys = async () => {
<QIcon name="open_in_new" />
</router-link>
<QCheckbox
class="disabled-checkbox"
:label="t('entry.summary.ordered')"
v-model="entry.isOrdered"
:disable="true"
/>
<QCheckbox
class="disabled-checkbox"
:label="t('entry.summary.confirmed')"
v-model="entry.isConfirmed"
:disable="true"
/>
<QCheckbox
class="disabled-checkbox"
:label="t('entry.summary.booked')"
v-model="entry.isBooked"
:disable="true"
/>
<QCheckbox
class="disabled-checkbox"
:label="t('entry.summary.raid')"
v-model="entry.isRaid"
:disable="true"
/>
<QCheckbox
class="disabled-checkbox"
:label="t('entry.summary.excludedFromAvailable')"
v-model="entry.isExcludedFromAvailable"
:disable="true"

View File

@ -277,6 +277,7 @@ function getLink(param) {
:value="invoiceIn.company?.code"
/>
<QCheckbox
class="disabled-checkbox"
:label="t('invoiceIn.summary.booked')"
v-model="invoiceIn.isBooked"
:disable="true"

View File

@ -7,7 +7,7 @@ import InvoiceOutNegativeFilter from './InvoiceOutNegativeBasesFilter.vue';
import VnSubToolbar from 'src/components/ui/VnSubToolbar.vue';
import WorkerDescriptorProxy from 'src/pages/Worker/Card/WorkerDescriptorProxy.vue';
import TicketDescriptorProxy from 'src/pages/Ticket/Card/TicketDescriptorProxy.vue';
// import VnSearchbar from 'src/components/ui/VnSearchbar.vue';
import { toCurrency } from 'src/filters';
import { useInvoiceOutGlobalStore } from 'src/stores/invoiceOutGlobal.js';
import { useStateStore } from 'stores/useStateStore';
@ -36,24 +36,28 @@ onBeforeMount(async () => {
};
arrayData.value = useArrayData('InvoiceOutNegative', {
url: 'InvoiceOuts/negativeBases',
limit: 0,
userParams: defaultParams,
exprBuilder: exprBuilder,
});
await arrayData.value.fetch({ append: false });
const test = await arrayData.value.fetch({ append: false });
console.log('test: ', test);
stateStore.rightDrawer = true;
});
const componentIsRendered = ref(false);
console.log('componentIsRendered: ', componentIsRendered);
onMounted(() =>
nextTick(() => {
nextTick(async () => {
componentIsRendered.value = true;
await arrayData.value.fetch();
console.log('3ntra');
})
);
const rows = computed(() => arrayData.value.store.data);
console.log('rows: ', rows);
const columns = computed(() => [
{
@ -147,6 +151,13 @@ const downloadCSV = async () => {
<template>
<template v-if="stateStore.isHeaderMounted()">
<!--<Teleport to="#searchbar">
<VnSearchbar
data-key="InvoiceOutNegative"
:limit="20"
:label="t('Search negative bases')"
/>
</Teleport>-->
<Teleport
to="#st-actions"
v-if="stateStore?.isSubToolbarShown() && componentIsRendered"
@ -156,36 +167,29 @@ const downloadCSV = async () => {
</QBtn>
</Teleport>
</template>
<QDrawer v-model="stateStore.rightDrawer" side="right" :width="256" show-if-above>
<QScrollArea class="fit text-grey-8">
<InvoiceOutNegativeFilter data-key="InvoiceOutNegative" />
</QScrollArea>
</QDrawer>
<VnSubToolbar />
<QPage class="column items-center q-pa-md">
<QTable
:columns="columns"
:rows="rows"
row-key="clientId"
class="full-width q-mt-md"
>
<QDrawer v-model="stateStore.rightDrawer" side="right" :width="256" show-if-above>
<QScrollArea class="fit text-grey-8">
<InvoiceOutNegativeFilter data-key="InvoiceOutNegative" />
</QScrollArea>
</QDrawer>
<QTable :columns="columns" :rows="rows" class="full-width q-mt-md">
<template #body-cell-clientId="{ row }">
<QTd>
<QBtn flat dense color="blue"> {{ row.clientId }}</QBtn>
<QBtn flat dense> {{ row.clientId }}</QBtn>
<CustomerDescriptorProxy :id="row.clientId" />
</QTd>
</template>
<template #body-cell-ticketId="{ row }">
<QTd>
<QBtn flat dense color="blue"> {{ row.ticketFk }}</QBtn>
<QBtn flat dense> {{ row.ticketFk }}</QBtn>
<TicketDescriptorProxy :id="row.ticketFk" />
</QTd>
</template>
<template #body-cell-worker="{ row }">
<QTd>
<QBtn class="no-uppercase" flat dense color="blue">{{
row.workerName
}}</QBtn>
<QBtn class="no-uppercase" flat dense>{{ row.workerName }}</QBtn>
<WorkerDescriptorProxy :id="row.comercialId" />
</QTd>
</template>
@ -196,12 +200,20 @@ const downloadCSV = async () => {
</template>
<template #body-cell-hasToInvoice="{ row }">
<QTd>
<QCheckbox :model-value="!!row.hasToInvoice" disable />
<QCheckbox
class="disabled-checkbox"
:model-value="!!row.hasToInvoice"
disable
/>
</QTd>
</template>
<template #body-cell-verifiedData="{ row }">
<QTd>
<QCheckbox :model-value="!!row.isTaxDataChecked" disable />
<QCheckbox
class="disabled-checkbox"
:model-value="!!row.isTaxDataChecked"
disable
/>
</QTd>
</template>
</QTable>
@ -216,6 +228,9 @@ const downloadCSV = async () => {
.no-uppercase {
text-transform: none;
}
.q-btn {
color: $color-link;
}
</style>
<i18n>

View File

@ -224,6 +224,7 @@ onUnmounted(() => (stateStore.rightDrawer = false));
<template #body-cell-ig="{ row }">
<QTd @click.stop>
<QCheckbox
class="disabled-checkbox"
v-model="row.isIgnored"
:disable="true"
:false-value="0"

View File

@ -96,6 +96,7 @@ const isAdministrative = computed(() => {
<VnLv :info="t('Este artículo necesita una foto')">
<template #value>
<QCheckbox
class="disabled-checkbox"
:label="t('item.summary.doPhoto')"
v-model="item.isPhotoRequested"
:disable="true"

View File

@ -525,7 +525,11 @@ onUnmounted(() => (stateStore.rightDrawer = false));
</template>
<template #body-cell-isActive="{ row }">
<QTd>
<QCheckbox :model-value="!!row.isActive" disable />
<QCheckbox
class="disabled-checkbox"
:model-value="!!row.isActive"
disable
/>
</QTd>
</template>
<template #body-cell-actions="{ row }">

View File

@ -75,11 +75,13 @@ function getUrl(section) {
</template>
</VnLv>
<QCheckbox
class="disabled-checkbox"
:label="t('supplier.summary.verified')"
v-model="supplier.isSerious"
:disable="true"
/>
<QCheckbox
class="disabled-checkbox"
:label="t('supplier.summary.isActive')"
v-model="supplier.isActive"
:disable="true"

View File

@ -261,6 +261,7 @@ async function setTravelData(travelData) {
:value="travel.warehouseOut?.name"
/>
<QCheckbox
class="disabled-checkbox"
:label="t('travel.summary.delivered')"
v-model="travel.isDelivered"
:disable="true"
@ -273,6 +274,7 @@ async function setTravelData(travelData) {
:value="travel.warehouseIn?.name"
/>
<QCheckbox
class="disabled-checkbox"
:label="t('travel.summary.received')"
v-model="travel.isReceived"
:disable="true"