Merge branch 'dev' into 4159-tableQ_filter
gitea/salix/pipeline/head This commit looks good
Details
gitea/salix/pipeline/head This commit looks good
Details
This commit is contained in:
commit
d100ab4112
|
@ -1115,7 +1115,8 @@ export default {
|
|||
anyBuyLine: 'vn-entry-summary tr.dark-row'
|
||||
},
|
||||
entryBasicData: {
|
||||
reference: 'vn-entry-basic-data vn-textfield[ng-model="$ctrl.entry.ref"]',
|
||||
reference: 'vn-entry-basic-data vn-textfield[ng-model="$ctrl.entry.reference"]',
|
||||
invoiceNumber: 'vn-entry-basic-data vn-textfield[ng-model="$ctrl.entry.invoiceNumber"]',
|
||||
notes: 'vn-entry-basic-data vn-textfield[ng-model="$ctrl.entry.notes"]',
|
||||
observations: 'vn-entry-basic-data vn-textarea[ng-model="$ctrl.entry.observation"]',
|
||||
supplier: 'vn-entry-basic-data vn-autocomplete[ng-model="$ctrl.entry.supplierFk"]',
|
||||
|
|
|
@ -19,6 +19,7 @@ describe('Entry basic data path', () => {
|
|||
|
||||
it('should edit the basic data', async() => {
|
||||
await page.write(selectors.entryBasicData.reference, 'new movement 8');
|
||||
await page.write(selectors.entryBasicData.invoiceNumber, 'new movement 8');
|
||||
await page.write(selectors.entryBasicData.notes, 'new notes');
|
||||
await page.write(selectors.entryBasicData.observations, ' edited');
|
||||
await page.autocompleteSearch(selectors.entryBasicData.supplier, 'Plants nick');
|
||||
|
@ -45,6 +46,13 @@ describe('Entry basic data path', () => {
|
|||
expect(result).toEqual('new movement 8');
|
||||
});
|
||||
|
||||
it('should confirm the invoiceNumber was edited', async() => {
|
||||
await page.reloadSection('entry.card.basicData');
|
||||
const result = await page.waitToGetProperty(selectors.entryBasicData.invoiceNumber, 'value');
|
||||
|
||||
expect(result).toEqual('new movement 8');
|
||||
});
|
||||
|
||||
it('should confirm the note was edited', async() => {
|
||||
const result = await page.waitToGetProperty(selectors.entryBasicData.notes, 'value');
|
||||
|
||||
|
|
|
@ -154,7 +154,8 @@ module.exports = Self => {
|
|||
e.id,
|
||||
e.supplierFk,
|
||||
e.dated,
|
||||
e.ref,
|
||||
e.ref reference,
|
||||
e.ref invoiceNumber,
|
||||
e.isBooked,
|
||||
e.isExcludedFromAvailable,
|
||||
e.notes,
|
||||
|
|
|
@ -12,10 +12,15 @@ module.exports = Self => {
|
|||
http: {source: 'path'}
|
||||
},
|
||||
{
|
||||
arg: 'ref',
|
||||
arg: 'reference',
|
||||
type: 'string',
|
||||
description: 'The buyed boxes ids',
|
||||
},
|
||||
{
|
||||
arg: 'invoiceNumber',
|
||||
type: 'string',
|
||||
description: 'The registered invoice number',
|
||||
},
|
||||
{
|
||||
arg: 'observation',
|
||||
type: 'string',
|
||||
|
@ -63,7 +68,8 @@ module.exports = Self => {
|
|||
|
||||
await entry.updateAttributes({
|
||||
observation: args.observation,
|
||||
ref: args.ref
|
||||
reference: args.reference,
|
||||
invoiceNumber: args.invoiceNumber
|
||||
}, myOptions);
|
||||
|
||||
const travel = entry.travel();
|
||||
|
|
|
@ -15,13 +15,15 @@ describe('entry import()', () => {
|
|||
});
|
||||
|
||||
it('should import the buy rows', async() => {
|
||||
const expectedRef = '1, 2';
|
||||
const expectedReference = '1, 2';
|
||||
const expectedInvoiceNumber = '1, 2';
|
||||
const expectedObservation = '123456';
|
||||
const ctx = {
|
||||
req: activeCtx,
|
||||
args: {
|
||||
observation: expectedObservation,
|
||||
ref: expectedRef,
|
||||
reference: expectedReference,
|
||||
invoiceNumber: expectedInvoiceNumber,
|
||||
buys: [
|
||||
{
|
||||
itemFk: 1,
|
||||
|
@ -58,7 +60,8 @@ describe('entry import()', () => {
|
|||
}, options);
|
||||
|
||||
expect(updatedEntry.observation).toEqual(expectedObservation);
|
||||
expect(updatedEntry.ref).toEqual(expectedRef);
|
||||
expect(updatedEntry.reference).toEqual(expectedReference);
|
||||
expect(updatedEntry.invoiceNumber).toEqual(expectedInvoiceNumber);
|
||||
expect(entryBuys.length).toEqual(4);
|
||||
|
||||
await tx.rollback();
|
||||
|
|
|
@ -18,8 +18,17 @@
|
|||
"dated": {
|
||||
"type": "date"
|
||||
},
|
||||
"ref": {
|
||||
"type": "string"
|
||||
"reference": {
|
||||
"type": "string",
|
||||
"mysql": {
|
||||
"columnName": "ref"
|
||||
}
|
||||
},
|
||||
"invoiceNumber": {
|
||||
"type": "string",
|
||||
"mysql": {
|
||||
"columnName": "ref"
|
||||
}
|
||||
},
|
||||
"isBooked": {
|
||||
"type": "boolean"
|
||||
|
|
|
@ -48,7 +48,7 @@
|
|||
<vn-textfield
|
||||
vn-one
|
||||
label="Reference"
|
||||
ng-model="$ctrl.entry.ref"
|
||||
ng-model="$ctrl.entry.reference"
|
||||
rule
|
||||
vn-focus>
|
||||
</vn-textfield>
|
||||
|
@ -61,17 +61,25 @@
|
|||
</vn-textfield>
|
||||
</vn-horizontal>
|
||||
<vn-horizontal>
|
||||
<vn-textarea
|
||||
<vn-textfield
|
||||
vn-one
|
||||
label="Observation"
|
||||
ng-model="$ctrl.entry.observation"
|
||||
rule>
|
||||
</vn-textarea>
|
||||
label="Invoice number"
|
||||
ng-model="$ctrl.entry.invoiceNumber"
|
||||
rule
|
||||
vn-focus>
|
||||
</vn-textfield>
|
||||
<vn-autocomplete
|
||||
url="Companies"
|
||||
label="Company"
|
||||
show-field="code"
|
||||
value-field="id"
|
||||
ng-model="$ctrl.entry.companyFk">
|
||||
</vn-autocomplete>
|
||||
</vn-horizontal>
|
||||
<vn-horizontal>
|
||||
<vn-autocomplete
|
||||
vn-one
|
||||
label="Currency"
|
||||
vn-one
|
||||
label="Currency"
|
||||
ng-model="$ctrl.entry.currencyFk"
|
||||
url="Currencies"
|
||||
show-field="code"
|
||||
|
@ -84,13 +92,14 @@
|
|||
ng-model="$ctrl.entry.commission"
|
||||
rule>
|
||||
</vn-input-number>
|
||||
<vn-autocomplete
|
||||
url="Companies"
|
||||
label="Company"
|
||||
show-field="code"
|
||||
value-field="id"
|
||||
ng-model="$ctrl.entry.companyFk">
|
||||
</vn-autocomplete>
|
||||
</vn-horizontal>
|
||||
<vn-horizontal>
|
||||
<vn-textarea
|
||||
vn-one
|
||||
label="Observation"
|
||||
ng-model="$ctrl.entry.observation"
|
||||
rule>
|
||||
</vn-textarea>
|
||||
</vn-horizontal>
|
||||
<vn-horizontal>
|
||||
<vn-check
|
||||
|
|
|
@ -12,6 +12,7 @@
|
|||
<vn-th field="id" number>Id</vn-th>
|
||||
<vn-th field="landed" center expand>Landed</vn-th>
|
||||
<vn-th>Reference</vn-th>
|
||||
<vn-th>Invoice number</vn-th>
|
||||
<vn-th field="supplierFk">Supplier</vn-th>
|
||||
<vn-th field="isBooked" center>Booked</vn-th>
|
||||
<vn-th field="isConfirmed" center>Confirmed</vn-th>
|
||||
|
@ -45,7 +46,8 @@
|
|||
{{::entry.landed | date:'dd/MM/yyyy'}}
|
||||
</span>
|
||||
</vn-td>
|
||||
<vn-td expand>{{::entry.ref}}</vn-td>
|
||||
<vn-td expand>{{::entry.reference}}</vn-td>
|
||||
<vn-td expand>{{::entry.invoiceNumber}}</vn-td>
|
||||
<vn-td expand>{{::entry.supplierName}}</vn-td>
|
||||
<vn-td center><vn-check ng-model="entry.isBooked" disabled="true"></vn-check></vn-td>
|
||||
<vn-td center><vn-check ng-model="entry.isConfirmed" disabled="true"></vn-check></vn-td>
|
||||
|
|
|
@ -14,4 +14,5 @@ Booked: Contabilizada
|
|||
Is inventory: Inventario
|
||||
Notes: Notas
|
||||
Status: Estado
|
||||
Selection: Selección
|
||||
Selection: Selección
|
||||
Invoice number: Núm. factura
|
|
@ -13,9 +13,16 @@
|
|||
<vn-textfield
|
||||
vn-one
|
||||
label="Reference"
|
||||
ng-model="filter.ref">
|
||||
ng-model="filter.reference">
|
||||
</vn-textfield>
|
||||
<vn-textfield
|
||||
vn-one
|
||||
label="Invoice number"
|
||||
ng-model="filter.invoiceNumber">
|
||||
</vn-textfield>
|
||||
</vn-horizontal>
|
||||
<vn-horizontal>
|
||||
<vn-textfield
|
||||
vn-one
|
||||
label="Travel"
|
||||
ng-model="filter.travelFk">
|
||||
|
|
|
@ -5,4 +5,5 @@ From: Desde
|
|||
To: Hasta
|
||||
Agency: Agencia
|
||||
Warehouse: Almacén
|
||||
Search entry by id or a suppliers by name or alias: Buscar entrada por id o proveedores por nombre y alias
|
||||
Search entry by id or a suppliers by name or alias: Buscar entrada por id o proveedores por nombre y alias
|
||||
Invoice number: Núm. factura
|
|
@ -27,7 +27,10 @@
|
|||
value="{{$ctrl.entryData.company.code}}">
|
||||
</vn-label-value>
|
||||
<vn-label-value label="Reference"
|
||||
value="{{$ctrl.entryData.ref}}">
|
||||
value="{{$ctrl.entryData.reference}}">
|
||||
</vn-label-value>
|
||||
<vn-label-value label="Invoice number"
|
||||
value="{{$ctrl.entryData.invoiceNumber}}">
|
||||
</vn-label-value>
|
||||
<vn-label-value label="Notes"
|
||||
value="{{$ctrl.entryData.notes}}">
|
||||
|
|
|
@ -8,4 +8,4 @@ Minimum price: Precio mínimo
|
|||
Buys: Compras
|
||||
Travel: Envio
|
||||
Go to the entry: Ir a la entrada
|
||||
|
||||
Invoice number: Núm. factura
|
||||
|
|
|
@ -264,7 +264,7 @@
|
|||
<tbody>
|
||||
<tr v-for="row in intrastat">
|
||||
<td>{{row.code}}</td>
|
||||
<td width="50%">{{row.description}}</td>
|
||||
<td width="50%">{{row.description || $t('services') }}</td>
|
||||
<td class="number">{{row.stems | number($i18n.locale)}}</td>
|
||||
<td class="number">{{row.netKg | number($i18n.locale)}}</td>
|
||||
<td class="number">{{row.subtotal | currency('EUR', $i18n.locale)}}</td>
|
||||
|
|
|
@ -81,7 +81,7 @@ module.exports = {
|
|||
return this.rawSqlFromDef(`taxes`, [reference]);
|
||||
},
|
||||
fetchIntrastat(reference) {
|
||||
return this.rawSqlFromDef(`intrastat`, [reference, reference, reference]);
|
||||
return this.rawSqlFromDef(`intrastat`, [reference, reference, reference, reference]);
|
||||
},
|
||||
fetchRectified(reference) {
|
||||
return this.rawSqlFromDef(`rectified`, [reference]);
|
||||
|
|
|
@ -33,4 +33,5 @@ issued: Issued
|
|||
plantPassport: Plant passport
|
||||
observations: Observations
|
||||
wireTransfer: "Pay method: Transferencia"
|
||||
accountNumber: "Account number: {0}"
|
||||
accountNumber: "Account number: {0}"
|
||||
services: Services
|
|
@ -33,4 +33,5 @@ issued: F. emisión
|
|||
plantPassport: Pasaporte fitosanitario
|
||||
observations: Observaciones
|
||||
wireTransfer: "Forma de pago: Transferencia"
|
||||
accountNumber: "Número de cuenta: {0}"
|
||||
accountNumber: "Número de cuenta: {0}"
|
||||
services: Servicios
|
|
@ -1,4 +1,4 @@
|
|||
SELECT
|
||||
(SELECT
|
||||
ir.id code,
|
||||
ir.description description,
|
||||
CAST(SUM(IFNULL(i.stems, 1) * s.quantity) AS DECIMAL(10,2)) stems,
|
||||
|
@ -19,4 +19,14 @@ SELECT
|
|||
WHERE t.refFk = ?
|
||||
AND i.intrastatFk
|
||||
GROUP BY i.intrastatFk
|
||||
ORDER BY i.intrastatFk;
|
||||
ORDER BY i.intrastatFk)
|
||||
UNION ALL
|
||||
(SELECT
|
||||
NULL AS code,
|
||||
NULL AS description,
|
||||
0 AS stems,
|
||||
0 AS netKg,
|
||||
CAST(SUM((ts.quantity * ts.price)) AS DECIMAL(10,2)) AS subtotal
|
||||
FROM vn.ticketService ts
|
||||
JOIN vn.ticket t ON ts.ticketFk = t.id
|
||||
WHERE t.refFk = ?);
|
Loading…
Reference in New Issue