Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 5172-cliente-impagado
gitea/salix/pipeline/head This commit looks good Details

This commit is contained in:
Alexandre Riera 2023-02-13 13:36:58 +01:00
commit bfc21a7c97
11 changed files with 110 additions and 6 deletions

View File

@ -1,7 +1,7 @@
<h5 class="vn-mb-md vn-mt-lg" translate>Recover password</h5>
<vn-textfield
label="Recovery email"
ng-model="$ctrl.email"
label="User or recovery email"
ng-model="$ctrl.user"
vn-focus>
</vn-textfield>
<div

View File

@ -1,4 +1,4 @@
Recover password: Recuperar contraseña
We will sent you an email to recover your password: Te enviaremos un correo para restablecer tu contraseña
Notification sent!: ¡Notificación enviada!
Recovery email: Correo de recuperación
User or recovery email: Usuario o correo de recuperación

View File

@ -29,5 +29,12 @@
"pickingOrder": {
"type": "number"
}
},
"relations": {
"saleGroup": {
"type": "hasMany",
"model": "saleGroup",
"foreignKey": "parkingFk"
}
}
}

View File

@ -71,7 +71,7 @@ module.exports = Self => {
}, {
relation: 'address',
scope: {
fields: ['street', 'city', 'provinceFk', 'phone', 'mobile', 'postalCode'],
fields: ['street', 'city', 'provinceFk', 'phone', 'mobile', 'postalCode', 'isEqualizated'],
include: {
relation: 'province',
scope: {

View File

@ -41,6 +41,12 @@
"SaleComponent": {
"dataSource": "vn"
},
"SaleGroup": {
"dataSource": "vn"
},
"SaleGroupDetail": {
"dataSource": "vn"
},
"SaleTracking": {
"dataSource": "vn"
},

View File

@ -75,6 +75,11 @@
"type": "hasOne",
"model": "ItemShelvingSale",
"foreignKey": "saleFk"
},
"saleGroupDetail": {
"type": "hasOne",
"model": "SaleGroupDetail",
"foreignKey": "saleFk"
}
}
}

View File

@ -0,0 +1,31 @@
{
"name": "SaleGroup",
"base": "VnModel",
"options": {
"mysql": {
"table": "saleGroup"
}
},
"properties": {
"id": {
"id": true,
"type": "number",
"description": "Identifier"
},
"parkingFk": {
"type": "number"
}
},
"relations": {
"saleGroupDetail": {
"type": "hasMany",
"model": "SaleGroupDetail",
"foreignKey": "saleGroupFk"
},
"parking": {
"type": "belongsTo",
"model": "Parking",
"foreignKey": "parkingFk"
}
}
}

View File

@ -0,0 +1,31 @@
{
"name": "SaleGroupDetail",
"base": "VnModel",
"options": {
"mysql": {
"table": "saleGroupDetail"
}
},
"properties": {
"id": {
"id": true,
"type": "number",
"description": "Identifier"
},
"saleFk": {
"type": "number"
}
},
"relations": {
"sale": {
"type": "belongsTo",
"model": "Sale",
"foreignKey": "saleFk"
},
"saleGroup": {
"type": "belongsTo",
"model": "SaleGroup",
"foreignKey": "saleGroupFk"
}
}
}

View File

@ -17,6 +17,7 @@
<vn-th field="itemFk" number>Item</vn-th>
<vn-th field="concept">Description</vn-th>
<vn-th field="quantity" number>Quantity</vn-th>
<vn-th field="parking" center>Parking</vn-th>
<vn-th></vn-th>
</vn-tr>
</vn-thead>
@ -50,6 +51,7 @@
</vn-fetched-tags>
</vn-td>
<vn-td number>{{::sale.quantity}}</vn-td>
<vn-td center>{{::sale.saleGroupDetail.saleGroup.parking.code | dashIfEmpty}}</vn-td>
<vn-td actions>
<vn-icon-button
vn-click-stop="$ctrl.showSaleTracking(sale)"

View File

@ -9,11 +9,30 @@ class Controller extends Section {
include: [
{
relation: 'item'
}, {
},
{
relation: 'saleTracking',
scope: {
fields: ['isChecked']
}
},
{
relation: 'saleGroupDetail',
scope: {
fields: ['saleGroupFk'],
include: {
relation: 'saleGroup',
scope: {
fields: ['parkingFk'],
include: {
relation: 'parking',
scope: {
fields: ['code']
}
}
}
}
}
}
]
};

View File

@ -105,7 +105,10 @@
</vn-one>
<vn-one class="taxes">
<p><vn-label translate>Subtotal</vn-label> {{$ctrl.summary.totalWithoutVat | currency: 'EUR':2}}</p>
<p><vn-label translate>VAT</vn-label> {{$ctrl.summary.totalWithVat - $ctrl.summary.totalWithoutVat | currency: 'EUR':2}}</p>
<p><vn-label translate ng-if="$ctrl.summary.address.isEqualizated">VAT + RE</vn-label>
<vn-label translate ng-if="!$ctrl.summary.address.isEqualizated">VAT</vn-label>
{{$ctrl.summary.totalWithVat - $ctrl.summary.totalWithoutVat | currency: 'EUR':2}}
</p>
<p><vn-label><strong>Total</strong></vn-label> <strong>{{$ctrl.summary.totalWithVat | currency: 'EUR':2}}</strong></p>
</vn-one>
<vn-auto name="sales">