|
@@ -130,7 +130,7 @@ module.exports = app => {
|
|
}
|
|
}
|
|
if (d.unit_price !== undefined && od.pre_used) throw '往期已使用,不可修改单价';
|
|
if (d.unit_price !== undefined && od.pre_used) throw '往期已使用,不可修改单价';
|
|
nd.unit_price = d.unit_price !== undefined ? this.ctx.helper.round(d.unit_price, info.decimal.up) : od.unit_price;
|
|
nd.unit_price = d.unit_price !== undefined ? this.ctx.helper.round(d.unit_price, info.decimal.up) : od.unit_price;
|
|
- const precision = this.ctx.helper.findPrecision(info.precision, d.unit);
|
|
|
|
|
|
+ const precision = this.ctx.helper.findPrecision(info.precision, d.unit || od.unit);
|
|
if (d.order !== undefined) nd.order = d.order;
|
|
if (d.order !== undefined) nd.order = d.order;
|
|
if (d.qty !== undefined) {
|
|
if (d.qty !== undefined) {
|
|
nd.qty = this.ctx.helper.round(d.qty, precision.value);
|
|
nd.qty = this.ctx.helper.round(d.qty, precision.value);
|