Merge branch 'master' into hotFix_invoiceIn_issued
gitea/salix/pipeline/head This commit looks good
Details
gitea/salix/pipeline/head This commit looks good
Details
This commit is contained in:
commit
975154c929
|
@ -5,8 +5,8 @@ const $ = {
|
|||
userName: 'vn-client-web-access vn-textfield[ng-model="$ctrl.account.name"]',
|
||||
email: 'vn-client-web-access vn-textfield[ng-model="$ctrl.account.email"]',
|
||||
saveButton: 'vn-client-web-access button[type=submit]',
|
||||
nameValue: 'vn-client-log .change:nth-child(1) .basic-json:nth-child(1) vn-json-value',
|
||||
activeValue: 'vn-client-log .change:nth-child(2) .basic-json:nth-child(2) vn-json-value'
|
||||
nameValue: 'vn-client-log .change:nth-child(1) .basic-json:nth-child(2) vn-json-value',
|
||||
activeValue: 'vn-client-log .change:nth-child(2) .basic-json:nth-child(1) vn-json-value'
|
||||
};
|
||||
|
||||
describe('Client web access path', () => {
|
||||
|
|
|
@ -28,6 +28,12 @@ export default class Controller extends Component {
|
|||
} else {
|
||||
cssClass = type;
|
||||
switch (type) {
|
||||
case 'number':
|
||||
if (Number.isInteger(value))
|
||||
text = value;
|
||||
else
|
||||
text = Math.round((value + Number.EPSILON) * 1000) / 1000;
|
||||
break;
|
||||
case 'boolean':
|
||||
text = value ? '✓' : '✗';
|
||||
cssClass = value ? 'true' : 'false';
|
||||
|
|
|
@ -75,5 +75,19 @@ describe('Component vnJsonValue', () => {
|
|||
expect(el.textContent).toEqual('2050');
|
||||
expect(el.className).toContain('json-number');
|
||||
});
|
||||
|
||||
it('should display number when value is decimal', () => {
|
||||
controller.value = 10.1;
|
||||
|
||||
expect(el.textContent).toEqual('10.1');
|
||||
expect(el.className).toContain('json-number');
|
||||
});
|
||||
|
||||
it('should display rounded number when value is decimal with lot of decimals', () => {
|
||||
controller.value = 10.124323234;
|
||||
|
||||
expect(el.textContent).toEqual('10.124');
|
||||
expect(el.className).toContain('json-number');
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
|
@ -76,6 +76,8 @@ export default class Controller extends Section {
|
|||
new: this.castJsonValue(newValues[prop])
|
||||
});
|
||||
}
|
||||
log.props.sort(
|
||||
(a, b) => a.nameI18n.localeCompare(b.nameI18n));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -6,3 +6,5 @@ columns:
|
|||
typeFk: type
|
||||
userFk: user
|
||||
companyFk: company
|
||||
workerFk: worker
|
||||
balance: balance
|
||||
|
|
|
@ -6,3 +6,5 @@ columns:
|
|||
typeFk: tipo
|
||||
userFk: usuario
|
||||
companyFk: compañia
|
||||
workerFk: trabajador
|
||||
balance: balance
|
||||
|
|
|
@ -44,4 +44,6 @@ columns:
|
|||
intrastatFk: intrastat
|
||||
genericFk: generic
|
||||
itemFk: item
|
||||
density: density
|
||||
compression: compression
|
||||
|
||||
|
|
|
@ -44,4 +44,6 @@ columns:
|
|||
intrastatFk: intrastat
|
||||
genericFk: genérico
|
||||
itemFk: artículo
|
||||
density: densidad
|
||||
compression: compresión
|
||||
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
name: sale
|
||||
columns:
|
||||
id: id
|
||||
concept: concept
|
||||
quantity: quantity
|
||||
price: price
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
name: línea
|
||||
columns:
|
||||
id: id
|
||||
concept: concepto
|
||||
quantity: cantidad
|
||||
price: precio
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
name: tracking
|
||||
name: state
|
||||
columns:
|
||||
id: id
|
||||
created: created
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
name: seguimiento
|
||||
name: estado
|
||||
columns:
|
||||
id: id
|
||||
created: creado
|
||||
|
|
|
@ -194,7 +194,10 @@ class Controller extends Section {
|
|||
}
|
||||
|
||||
createClaim() {
|
||||
const timeDifference = new Date().getTime() - new Date(this.ticket.shipped).getTime();
|
||||
const today = new Date();
|
||||
today.setHours(0, 0, 0, 0);
|
||||
const timeDifference = today.getTime() - new Date(this.ticket.landed).getTime();
|
||||
|
||||
const pastDays = Math.floor(timeDifference / 86400000);
|
||||
|
||||
if (pastDays >= this.ticketConfig[0].daysForWarningClaim)
|
||||
|
|
Loading…
Reference in New Issue