Merge branch 'dev' of https://gitea.verdnatura.es/verdnatura/salix into 5297-newWorker_iban_not_required
This commit is contained in:
commit
bb39724718
|
@ -16,7 +16,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||
- (Trabajadores -> Nuevo trabajador) Los clientes se crean sin 'TR' pero se añade tipo de negocio 'Trabajador'
|
||||
|
||||
### Fixed
|
||||
-
|
||||
- (Tickets -> Líneas) Se permite hacer split de líneas al mismo ticket
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -78,7 +78,7 @@ module.exports = Self => {
|
|||
const saleIds = sales.map(sale => sale.id);
|
||||
|
||||
const hasClaimedSales = await models.ClaimBeginning.findOne({where: {saleFk: {inq: saleIds}}});
|
||||
if (hasClaimedSales)
|
||||
if (ticketId != id && hasClaimedSales)
|
||||
throw new UserError(`Can't transfer claimed sales`);
|
||||
|
||||
for (const sale of sales) {
|
||||
|
|
|
@ -244,7 +244,12 @@ class Controller extends Section {
|
|||
|
||||
const query = `tickets/${this.ticket.id}/transferSales`;
|
||||
this.$http.post(query, params)
|
||||
.then(res => this.$state.go('ticket.card.sale', {id: res.data.id}));
|
||||
.then(res => {
|
||||
if (res.data && res.data.id === this.ticket.id) {
|
||||
this.$.transfer.hide();
|
||||
this.$.model.refresh();
|
||||
} else this.$state.go('ticket.card.sale', {id: res.data.id});
|
||||
});
|
||||
}
|
||||
|
||||
showEditPricePopover(event, sale) {
|
||||
|
|
Loading…
Reference in New Issue