示例#1
0
 /// <summary>
 /// 修改
 /// </summary>
 public FineOffice.Modules.OA_FlowProcess Update(FineOffice.Modules.OA_FlowProcess model)
 {
     dal.Initialization();
     FineOffice.Entity.OA_FlowProcess entity = new Entity.OA_FlowProcess
     {
         ID = model.ID,
         ProcessDepartment = model.ProcessDepartment,
         ProcessRole       = model.ProcessRole,
         FlowID            = model.FlowID,
         Feedback          = model.Feedback,
         Remind            = model.Remind,
         AllowGoBack       = model.AllowGoBack,
         TimeLimit         = model.TimeLimit,
         AllowRefuse       = model.AllowRefuse,
         AllowSync         = model.AllowSync,
         IsEnd             = model.IsEnd,
         IsStart           = model.IsStart,
         MessageTo         = model.MessageTo,
         Next             = model.Next,
         Version          = model.Version,
         ProcessName      = model.ProcessName,
         ProcessPersonnel = model.ProcessPersonnel,
         Serial           = model.Serial,
         TopDefault       = model.TopDefault,
         MailTo           = model.MailTo,
         Remark           = model.Remark
     };
     dal.Update(entity);
     dal.Dispose();
     return(null);
 }
示例#2
0
 /// <summary>
 /// 返回一个model
 /// </summary>
 /// <returns></returns>
 public FineOffice.Modules.OA_FlowProcess GetModel(System.Linq.Expressions.Expression <Func <FineOffice.Modules.OA_FlowProcess, bool> > expression)
 {
     dal.Initialization();
     FineOffice.Modules.OA_FlowProcess model =
         (from entity in dal.GetListAll()
          select new FineOffice.Modules.OA_FlowProcess
     {
         ID = entity.ID,
         ProcessDepartment = entity.ProcessDepartment,
         ProcessRole = entity.ProcessRole,
         FlowID = entity.FlowID,
         Feedback = entity.Feedback,
         Remind = entity.Remind,
         AllowGoBack = entity.AllowGoBack,
         TimeLimit = entity.TimeLimit,
         AllowRefuse = entity.AllowRefuse,
         AllowSync = entity.AllowSync,
         IsEnd = entity.IsEnd,
         Version = entity.Version.ToArray(),
         IsStart = entity.IsStart,
         MessageTo = entity.MessageTo,
         Next = entity.Next,
         ProcessName = entity.ProcessName,
         ProcessPersonnel = entity.ProcessPersonnel,
         Serial = entity.Serial,
         TopDefault = entity.TopDefault,
         MailTo = entity.MailTo,
         Remark = entity.Remark
     }).Where(expression).FirstOrDefault();
     dal.Dispose();
     return(model);
 }