Commit cc9cc439 authored by 顾俭's avatar 顾俭

启用防伪码送货单 单箱数量=送货数量

parent f2c80704
...@@ -426,17 +426,19 @@ angular.module('IOne').controller('DeliveryOrderUpdateController', function ($ro ...@@ -426,17 +426,19 @@ angular.module('IOne').controller('DeliveryOrderUpdateController', function ($ro
}); });
// aship 定制 原产地批次号制造日期默认值 // aship 定制 原产地批次号制造日期默认值
angular.forEach($scope.currentDeliveryOrderDetails, function (item) { if ($scope.currentDeliveryOrder.supplier.useBarcode == 'Y') {
if (!item.sourceArea) { angular.forEach($scope.currentDeliveryOrderDetails, function (item) {
item.sourceArea = "-"; if (!item.sourceArea) {
} item.sourceArea = "-";
if (!item.manufacturingDate) { }
item.manufacturingDate = new Date(); if (!item.manufacturingDate) {
} item.manufacturingDate = new Date();
if (!item.batchId) { }
item.batchId = $filter('date')(item.manufacturingDate, 'yyyyMMdd'); if (!item.batchId) {
} item.batchId = $filter('date')(item.manufacturingDate, 'yyyyMMdd');
}); }
});
}
//保存用户所选的采购类型、是否钢卷条件 //保存用户所选的采购类型、是否钢卷条件
if ($rootScope.userInfo.suppliers.length > 0) { if ($rootScope.userInfo.suppliers.length > 0) {
...@@ -505,6 +507,11 @@ angular.module('IOne').controller('DeliveryOrderUpdateController', function ($ro ...@@ -505,6 +507,11 @@ angular.module('IOne').controller('DeliveryOrderUpdateController', function ($ro
$scope.initAggregationGrid = function () { $scope.initAggregationGrid = function () {
angular.forEach($scope.deliveryOrderAggregationGridOptions.data, function (item) { angular.forEach($scope.deliveryOrderAggregationGridOptions.data, function (item) {
// aship 定制 单箱数量=送货数量
if ($scope.currentDeliveryOrder.supplier.useBarcode == 'Y') {
item.amountPerBox =item.totalAmount;
}
item.getFullPackingBoxAmount = function () { item.getFullPackingBoxAmount = function () {
if (item.amountPerBox > 0 && item.totalAmount > 0) { if (item.amountPerBox > 0 && item.totalAmount > 0) {
return item.fullPackingBoxAmount = Math.floor(item.totalAmount / item.amountPerBox); return item.fullPackingBoxAmount = Math.floor(item.totalAmount / item.amountPerBox);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment