public void SetEntity(EngineeringSpecialtyProvideInfo Info) { this.ReceiveUserIDs = Info.ReceiveUserIDs; this.DocName = Info.DocName; this.DocContent = Info.DocContent; this.LimitDate = Info.LimitDate; }
public void Update(int ID, EngineeringSpecialtyProvideInfo Info) { var entity = this._DB.Get(ID); entity.SetEntity(Info); this._DB.Edit(entity); foreach (var fileID in Info.VolumeFiles) { AddAttach(entity.ID, fileID); } }
public EngineeringSpecialtyProvideEntity(EngineeringSpecialtyProvideInfo Info) { this.ID = Info.ID; this.EngineeringID = Info.EngineeringID; this.SendSpecialtyID = Info.SendSpecialtyID; this.ReceiveSpecialtyID = Info.ReceiveSpecialtyID; this.SendUserID = Info.SendUserID; this.ReceiveUserIDs = Info.ReceiveUserIDs; this.DocName = Info.DocName; this.DocContent = Info.DocContent; this.LimitDate = Info.LimitDate; this.IsDelete = Info.IsDelete; this.CreateDate = Info.CreateDate; this.CanReceive = Info.CanReceive; }
public async Task <int> Add(EngineeringSpecialtyProvideInfo EngineeringSpecialtyProvide) { var entity = new EngineeringSpecialtyProvideEntity(EngineeringSpecialtyProvide); entity.IsDelete = false; entity.CreateDate = DateTime.Now; entity.CanReceive = false; this._DB.Add(entity); foreach (var attachID in EngineeringSpecialtyProvide.AttachIDs) { AddAttach(entity.ID, attachID); } foreach (var fileID in EngineeringSpecialtyProvide.VolumeFiles) { AddAttach(entity.ID, fileID); } var data = new Dictionary <string, object>(); data.Add("ApproveUser", EngineeringSpecialtyProvide.ApproveUser); data.Add("ProvideUser", EngineeringSpecialtyProvide.SendUserID); var pid = ProcessEngine.Instance.CreateProcessInstance("F1", EngineeringSpecialtyProvide.SendUserID, data); // 映射流程实例和卷册关系 _IObjectProcessService.Add(new ObjectProcessEntity() { ObjectID = entity.ID, ObjectKey = "EngineeringSpecialtyProvide", ProcessID = new Guid(pid) }); await ProcessEngine.Instance.Start(pid); return(entity.ID); }
public void UpdateProvide(int ID, EngineeringSpecialtyProvideInfo Info) { this._IEngineeringSpecialtyProvideService.Update(ID, Info); }
public async Task <int> CreateProvide(EngineeringSpecialtyProvideInfo Info) { Info.SendUserID = int.Parse(base.User.Identity.Name); return(await this._IEngineeringSpecialtyProvideService.Add(Info)); }