using System; using System.Collections.Generic; using System.Text; using WIDESEA.Entity.DomainModels; using WIDESEA.Services.Repositories; namespace WIDESEA.Services.Services { public partial class CommonFunction { /// /// 添加库存历史头 /// /// /// public static void AddContainerHeadToHistory(Dt_container_head container_Head, string operateType = "") { Dt_container_head_hty head_Hty = new Dt_container_head_hty(); head_Hty.containerhead_id = Guid.NewGuid(); head_Hty.containerhead_areaid = container_Head.containerhead_areaid; head_Hty.containerhead_barcode = container_Head.containerhead_barcode; head_Hty.containerhead_creator = container_Head.containerhead_creator; head_Hty.containerhead_createtime = container_Head.containerhead_createtime; head_Hty.containerhead_finishtime = DateTime.Now; head_Hty.containerhead_operatetype = operateType; head_Hty.containerhead_compeletor = "System-compeletor"; head_Hty.containerhead_requstkey = container_Head.containerhead_requstkey; head_Hty.containerhead_text1 = container_Head.containerhead_text1; head_Hty.containerhead_text2 = container_Head.containerhead_text2; head_Hty.containerhead_text3 = container_Head.containerhead_text3; head_Hty.containerhead_palletweight = container_Head.containerhead_palletweight; Dt_container_head_htyRepository.Instance.Add(head_Hty, true); Dt_container_headRepository.Instance.Delete(container_Head, true); } } }