| | |
| | | |
| | | return zcInfo; |
| | | } |
| | | |
| | | public static object GetZCInfo2(Dt_container_size_info_hty size_info_hty, Dt_container_detail_hty detail_hty, string materiel, string barcode, string fcbAVG, string ydAVG, string zjAVG, string ldCode |
| | | , string target, string direction,string materiel_id) |
| | | { |
| | | decimal fcbMes = string.IsNullOrEmpty(fcbAVG) ? 0 : decimal.Parse(fcbAVG); |
| | | decimal fcbWms = string.IsNullOrEmpty(size_info_hty.csize_four_3) ? 0 : decimal.Parse(size_info_hty.csize_four_3); |
| | | decimal fcbdiff = 0; |
| | | if (fcbMes != 0 && fcbWms != 0) |
| | | fcbdiff = fcbMes - fcbWms; |
| | | |
| | | decimal ydMes = string.IsNullOrEmpty(ydAVG) ? 0 : decimal.Parse(ydAVG); |
| | | decimal ydWms = string.IsNullOrEmpty(size_info_hty.csize_three_3) ? 0 : decimal.Parse(size_info_hty.csize_three_3); |
| | | decimal yddiff = 0; |
| | | if (ydMes != 0 && ydWms != 0) |
| | | yddiff = ydMes - ydWms; |
| | | |
| | | decimal zjMes = string.IsNullOrEmpty(zjAVG) ? 0 : decimal.Parse(zjAVG); |
| | | decimal zjWms = string.IsNullOrEmpty(size_info_hty.csize_in_value) ? 0 : decimal.Parse(size_info_hty.csize_in_value); |
| | | decimal zjdiff = 0; |
| | | if (zjMes != 0 && zjWms != 0) |
| | | zjdiff = zjMes - zjWms; |
| | | |
| | | |
| | | //decimal fcbDiff = ((string.IsNullOrEmpty(fcbAVG) ? 0 : decimal.Parse(fcbAVG)) - (string.IsNullOrEmpty(container.csize_four_3) ? 0 : decimal.Parse(container.csize_four_3))); |
| | | //decimal ydDiff = ((string.IsNullOrEmpty(ydAVG) ? 0 : decimal.Parse(ydAVG) - (string.IsNullOrEmpty(container.csize_three_3) ? 0 : decimal.Parse(container.csize_three_3)))); |
| | | //decimal zjdDiff = ((string.IsNullOrEmpty(zjAVG) ? 0 : decimal.Parse(zjAVG) - (string.IsNullOrEmpty(container.csize_in_value) ? 0 : decimal.Parse(container.csize_in_value)))); |
| | | |
| | | dt_selectionRecord record = new dt_selectionRecord() |
| | | { |
| | | record_barcode = detail_hty.containerdtl_barcode, |
| | | record_createTime = DateTime.Now, |
| | | record_fcbAVG_diff = fcbdiff, |
| | | record_fcbAVG_mes = fcbMes, |
| | | record_fcbAVG_wms = fcbWms, |
| | | record_id = Guid.NewGuid(), |
| | | record_ldCode = ldCode, |
| | | record_ldNumber = barcode, |
| | | record_locationId = "æå¨éé
ï¼æ²¡æåºä½", |
| | | record_madeUnit = detail_hty.containerdtl_madeUnit, |
| | | record_materielId = materiel_id, |
| | | record_materielNumber = detail_hty.containerdtl_goodsCode, |
| | | record_materielType = detail_hty.containerdtl_type, |
| | | record_standa = detail_hty.containerdtl_standard, |
| | | record_userName = Core.ManageUser.UserContext.Current.UserTrueName, |
| | | record_weight = string.IsNullOrEmpty(detail_hty.containerdtl_goodsWeight) ? 0 : decimal.Parse(detail_hty.containerdtl_goodsWeight), |
| | | record_ydAVG_diff = yddiff, |
| | | record_ydAVG_mes = ydMes, |
| | | record_ydAVG_wms = ydWms, |
| | | record_zjAVG_diff = zjdiff, |
| | | record_zjAVG_mes = zjMes, |
| | | record_zjAVG_wms = zjWms, |
| | | record_direction = "left".Equals(direction) ? "左侧" : "å³ä¾§", |
| | | record_outstation = "æå¨éé
", |
| | | record_inboundTime = "æå¨éé
", |
| | | record_lotNumber = "æå¨éé
", |
| | | record_ProductDate = "æå¨éé
" |
| | | }; |
| | | dt_selectionRecordRepository.Instance.Add(record, true); |
| | | |
| | | object zcInfo = new |
| | | { |
| | | wmsInfo = new List<object>(){ |
| | | new |
| | | { |
| | | name = "轮对å·", |
| | | value = ldCode, |
| | | }, |
| | | new{ |
| | | name = "è½´æ¿ç¼å·", |
| | | value = record.record_materielNumber, |
| | | }, |
| | | new |
| | | { |
| | | name = "è½´æ¿ç±»å«", |
| | | value = record.record_standa, |
| | | }, |
| | | new |
| | | { |
| | | name="è½´æ¿å
å¾å¹³åå¼", |
| | | value = record.record_zjAVG_wms, |
| | | }, |
| | | new |
| | | { |
| | | name = "è½´æ¿å
å¾è¿çé", |
| | | value = record.record_zjAVG_diff, |
| | | }, |
| | | new |
| | | { |
| | | name = "éé(å
)", |
| | | value = record.record_weight, |
| | | } |
| | | } |
| | | }; |
| | | |
| | | return zcInfo; |
| | | } |
| | | } |
| | | } |