Tarea #696
This commit is contained in:
parent
31fa66e052
commit
33b9efc5b7
|
@ -158,45 +158,49 @@
|
|||
</vn-vertical>
|
||||
</vn-one>
|
||||
<vn-one margin-medium>
|
||||
<h5 translate>Recovery</h5>
|
||||
<vn-vertical ng-if="$ctrl.summary.recovery">
|
||||
<vn-label-value label="Since"
|
||||
value="{{$ctrl.summary.recovery.started | date:'dd/MM/yyyy'}}">
|
||||
<h5 translate>Business data</h5>
|
||||
<vn-label-value label="Total greuge"
|
||||
value="{{$ctrl.summary.totalGreuge | currency:'€ ':2}}">
|
||||
</vn-label-value>
|
||||
<vn-label-value label="To"
|
||||
value="{{$ctrl.summary.recovery.finished | date:'dd/MM/yyyy'}}">
|
||||
<vn-label-value label="Mana"
|
||||
value="{{$ctrl.summary.mana.mana | currency:'€ ':2}}">
|
||||
</vn-label-value>
|
||||
<vn-label-value label="Amount"
|
||||
value="{{$ctrl.summary.recovery.amount | currency:'€ ':2}}">
|
||||
<vn-label-value label="Rate"
|
||||
value="{{$ctrl.summary.claimsRatio[0].priceIncreasing | percentage}}">
|
||||
</vn-label-value>
|
||||
<vn-label-value label="Period"
|
||||
value="{{$ctrl.summary.recovery.period}}">
|
||||
<vn-label-value label="Average invoiced"
|
||||
value="{{$ctrl.summary.averageInvoiced.invoiced | currency:'€ ':2}}">
|
||||
</vn-label-value>
|
||||
<vn-label-value label="Claims"
|
||||
value="{{$ctrl.summary.claimsRatio[0].claimingRate | percentage}}">
|
||||
</vn-label-value>
|
||||
</vn-vertical>
|
||||
</vn-one>
|
||||
<vn-one margin-medium>
|
||||
<h5 translate>Financial data</h5>
|
||||
<vn-label-value label="Mana"
|
||||
value="{{$ctrl.summary.mana.mana | currency:'€ ':2}}">
|
||||
</vn-label-value>
|
||||
<h5 translate>Financial information</h5>
|
||||
<vn-label-value label="Risk"
|
||||
value="{{$ctrl.summary.debt.debt | currency:'€ ':2}}">
|
||||
</vn-label-value>
|
||||
<vn-label-value label="Average invoiced"
|
||||
value="{{$ctrl.summary.averageInvoiced.invoiced | currency:'€ ':2}}">
|
||||
</vn-label-value>
|
||||
<vn-label-value label="Total greuge"
|
||||
value="{{$ctrl.summary.totalGreuge | currency:'€ ':2}}">
|
||||
value="{{$ctrl.summary.debt.debt | currency:'€ ':2}}"
|
||||
ng-class="{bold: $ctrl.summary.debt.debt > $ctrl.summary.credit}">
|
||||
</vn-label-value>
|
||||
<vn-label-value label="Credit"
|
||||
value="{{$ctrl.summary.credit | currency:'€ ':2}}">
|
||||
value="{{$ctrl.summary.credit | currency:'€ ':2}}"
|
||||
ng-class="{bold: $ctrl.summary.credit > $ctrl.summary.creditInsurance ||
|
||||
($ctrl.summary.credit && $ctrl.summary.creditInsurance == null)}">
|
||||
</vn-label-value>
|
||||
<vn-label-value label="Secured credit"
|
||||
value="{{$ctrl.summary.creditInsurance | currency:'€ ':2}}">
|
||||
</vn-label-value>
|
||||
<vn-label-value label="Grade"
|
||||
value="{{$ctrl.grade}}">
|
||||
<vn-label-value label="Balance"
|
||||
value="{{$ctrl.summary.clientRisks[0].amount | currency:'€ ':2}}">
|
||||
</vn-label-value>
|
||||
<vn-label-value label="Balance due"
|
||||
value="{{$ctrl.summary.defaulters[0].amount | currency:'€ ':2}}"
|
||||
ng-class="{bold: $ctrl.summary.defaulters[0].amount}">
|
||||
</vn-label-value>
|
||||
<vn-vertical ng-if="$ctrl.summary.recovery.started">
|
||||
<vn-label-value label="Recovery since"
|
||||
value="{{$ctrl.summary.recovery.started | date:'dd/MM/yyyy'}}">
|
||||
</vn-label-value>
|
||||
</vn-vertical>
|
||||
</vn-one>
|
||||
</vn-horizontal>
|
||||
</vn-vertical>
|
||||
|
|
|
@ -1,9 +1,13 @@
|
|||
Default address: Consignatario pred.
|
||||
Total greuge: Greuge total
|
||||
Financial data: Datos financieros
|
||||
Financial information: Datos financieros
|
||||
Mana: Maná
|
||||
Risk: Riesgo
|
||||
Secured credit: Crédito asegurado
|
||||
Average invoiced: Consumo medio
|
||||
Sales person: Comercial
|
||||
Recovery: Recobro
|
||||
Balance due: Saldo vencido
|
||||
Rate: Tarifa
|
||||
Business data: Datos comerciales
|
||||
Recovery since: Recobro desde
|
||||
|
|
|
@ -3,3 +3,7 @@ vn-dialog {
|
|||
min-width: 10em;
|
||||
}
|
||||
}
|
||||
|
||||
vn-client-summary .bold {
|
||||
font-family: vn-font-bold;
|
||||
}
|
|
@ -2,3 +2,5 @@ import './phone';
|
|||
import './ucwords';
|
||||
import './dash-if-empty';
|
||||
import './dateTime';
|
||||
import './percentage';
|
||||
import './currency';
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -8,6 +8,14 @@
|
|||
}
|
||||
},
|
||||
"properties": {
|
||||
"clientFk": {
|
||||
"type": "Number",
|
||||
"id": true
|
||||
},
|
||||
"companyFk": {
|
||||
"type": "Number",
|
||||
"id": true
|
||||
},
|
||||
"amount": {
|
||||
"type": "Number"
|
||||
}
|
||||
|
|
|
@ -60,6 +60,29 @@ module.exports = Self => {
|
|||
},
|
||||
where: {finished: null}
|
||||
}
|
||||
},
|
||||
{
|
||||
relation: 'defaulters',
|
||||
scope: {
|
||||
fields: ['amount'],
|
||||
order: 'created DESC',
|
||||
limit: 1
|
||||
}
|
||||
},
|
||||
{
|
||||
relation: 'clientsRisk',
|
||||
scope: {
|
||||
where: {companyFk: 442},
|
||||
fields: ['amount'],
|
||||
limit: 1
|
||||
}
|
||||
},
|
||||
{
|
||||
relation: 'claimsRatio',
|
||||
scope: {
|
||||
fields: ['claimingRate', 'priceIncreasing'],
|
||||
limit: 1
|
||||
}
|
||||
}
|
||||
],
|
||||
where: {id: clientId}
|
||||
|
|
|
@ -9,6 +9,10 @@
|
|||
},
|
||||
"validateUpsert": true,
|
||||
"properties": {
|
||||
"clientFk": {
|
||||
"type": "Number",
|
||||
"id": true
|
||||
},
|
||||
"yearSale": {
|
||||
"type": "Number"
|
||||
},
|
||||
|
|
|
@ -177,6 +177,21 @@
|
|||
"type": "belongsTo",
|
||||
"model": "BankEntity",
|
||||
"foreignKey": "bankEntityFk"
|
||||
}
|
||||
},
|
||||
"defaulters": {
|
||||
"type": "hasMany",
|
||||
"model": "Defaulter",
|
||||
"foreignKey": "clientFk"
|
||||
},
|
||||
"clientsRisk": {
|
||||
"type": "hasMany",
|
||||
"model": "ClientRisk",
|
||||
"foreignKey": "clientFk"
|
||||
},
|
||||
"claimsRatio": {
|
||||
"type": "hasMany",
|
||||
"model": "ClaimRatio",
|
||||
"foreignKey": "clientFk"
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue