public void Create(MES_M001_Order_Detail MES_M001_Order_Detail) { MES_M001_Order_Detail.CreateDt = DateTime.Now; tb_Sys_User tempUser = appCacheService.GetItem("user") as tb_Sys_User; MES_M001_Order_Detail.CreateUser = tempUser.UserName; MES_M001_Order_Detail.CompCode = tempUser.CompCode; MES_M001_Order_Detail.Validate(); this.MES_M001_Order_DetailRepository.Add(MES_M001_Order_Detail); this.runtimeService.Commit(); }
public void Update(MES_M001_Order_Detail MES_M001_Order_Detail) { MES_M001_Order_Detail.ModifyDt = DateTime.Now; tb_Sys_User tempUser = appCacheService.GetItem("user") as tb_Sys_User; MES_M001_Order_Detail.ModifyUser = tempUser.UserName; MES_M001_Order_Detail.Validate(); var existstb_Sys_Menu = this.GetById(MES_M001_Order_Detail.Id); this.MES_M001_Order_DetailRepository.SetValues(MES_M001_Order_Detail, existstb_Sys_Menu); this.runtimeService.Commit(); }