/// <summary>
        /// 模型数据改变
        /// </summary>
        /// <param name="obj"></param>
        private void dataChanged(MaterialOutStorageInfoModel MaterialOutStorageInfoChange)
        {
            getPageData(pageRepuestParams.PageIndex, pageRepuestParams.PageSize);
            var tmpModel = MaterialOutStorageInfoList.FirstOrDefault(a => a.Id == MaterialOutStorageInfoChange.Id);

            this.MaterialOutStorageInfo = MaterialOutStorageInfoList.FirstOrDefault();
        }
Exemplo n.º 2
0
 public static void SetPalletQuantity(MaterialOutStorageInfoModel materialoutstorageInfo)
 {
     if (materialoutstorageInfo.Quantity != null &&
         materialoutstorageInfo.OutStorageType == OutStorageTypeEnumModel.OutStorageType.成品手动出库)
     {
         if (materialoutstorageInfo.FullPalletQuantity != null && materialoutstorageInfo.FullPalletQuantity.Value != 0)
         {
             decimal dPalletQuantity = materialoutstorageInfo.Quantity.Value / materialoutstorageInfo.FullPalletQuantity.Value;
             if (dPalletQuantity < 1 && dPalletQuantity > 0)
             {
                 dPalletQuantity = 1;
             }
             dPalletQuantity = decimal.Ceiling(dPalletQuantity);
             //
             materialoutstorageInfo.PalletQuantity = dPalletQuantity;
         }
     }
 }