minor refactor
gitea/salix/pipeline/head This commit looks good
Details
gitea/salix/pipeline/head This commit looks good
Details
This commit is contained in:
parent
05ee2ee2d3
commit
674b959bbc
|
@ -23,7 +23,9 @@ module.exports = function(Self) {
|
||||||
});
|
});
|
||||||
|
|
||||||
Self.canBeInvoiced = async id => {
|
Self.canBeInvoiced = async id => {
|
||||||
let ticket = await Self.app.models.Ticket.findById(id, {fields: ['id', 'refFk', 'shipped', 'totalWithVat']});
|
let ticket = await Self.app.models.Ticket.findById(id, {
|
||||||
|
fields: ['id', 'refFk', 'shipped', 'totalWithVat']
|
||||||
|
});
|
||||||
|
|
||||||
let query = `SELECT vn.hasSomeNegativeBase(?) AS hasSomeNegativeBase`;
|
let query = `SELECT vn.hasSomeNegativeBase(?) AS hasSomeNegativeBase`;
|
||||||
let [result] = await Self.rawSql(query, [id]);
|
let [result] = await Self.rawSql(query, [id]);
|
||||||
|
|
|
@ -121,7 +121,7 @@
|
||||||
<vn-td>{{::ticket.warehouse}}</vn-td>
|
<vn-td>{{::ticket.warehouse}}</vn-td>
|
||||||
<vn-td number>
|
<vn-td number>
|
||||||
<span class="chip {{$ctrl.totalPriceColor(ticket)}}">
|
<span class="chip {{$ctrl.totalPriceColor(ticket)}}">
|
||||||
{{::ticket.totalWithVat | currency: 'EUR': 2}}
|
{{::(ticket.totalWithVat ? ticket.totalWithVat : 0) | currency: 'EUR': 2}}
|
||||||
</span>
|
</span>
|
||||||
</vn-td>
|
</vn-td>
|
||||||
<vn-td actions>
|
<vn-td actions>
|
||||||
|
|
Loading…
Reference in New Issue