public ActionResult Designate(FormCollection collection) { string taskid = Request.QueryString["taskid"]; string taskID; if (taskid.IsGuid(out taskID)) { string user = Request.Form["user"]; string openerid = Request.QueryString["openerid"]; Next.WorkFlow.BLL.WorkFlowTaskBLL btask = new Next.WorkFlow.BLL.WorkFlowTaskBLL(); var users = new Next.Admin.BLL.DeptBLL().GetAllUsers(user); System.Text.StringBuilder sb = new System.Text.StringBuilder(); foreach (var user1 in users) { btask.DesignateTask(taskID, user1); //RoadFlow.Platform.Log.Add("管理员指派了流程任务", "将任务" + taskID + "指派给了:" + user1.Name + user1.ID, RoadFlow.Platform.Log.Types.流程相关); sb.Append(user1.Name); sb.Append(","); } string userNames = sb.ToString().TrimEnd(','); ViewBag.Script = "alert('已成功指派给:" + userNames + "!');new RoadUI.Window().reloadOpener();new RoadUI.Window().close();"; } return(View()); }
public ActionResult Index(FormCollection collection) { Next.WorkFlow.BLL.WorkFlowCommentBLL bworkFlowComment = new Next.WorkFlow.BLL.WorkFlowCommentBLL(); Next.Admin.BLL.DeptBLL borganize = new Next.Admin.BLL.DeptBLL(); IEnumerable <WorkFlowComment> workFlowCommentList; if (collection != null) { if (!Request.Form["DeleteBut"].IsNullOrEmpty()) { string ids = Request.Form["checkbox_app"]; foreach (string id in ids.Split(',')) { string bid; if (!id.IsGuid(out bid)) { continue; } var comment = bworkFlowComment.FindByID(bid); if (comment != null) { bworkFlowComment.Delete(bid); //Next.WorkFlow.BLL.Log.Add("删除了流程意见", comment.Serialize(), Next.WorkFlow.BLL.Log.Types.流程相关); } } //bworkFlowComment.RefreshCache(); } } workFlowCommentList = bworkFlowComment.GetAll(); bool isOneSelf = "1" == Request.QueryString["isoneself"]; if (isOneSelf) { workFlowCommentList = workFlowCommentList.Where(p => p.MemberID == Next.Admin.BLL.UserBLL.PREFIX + new Next.Admin.BLL.UserBLL().CurrentUserID.ToString()); } return(View(workFlowCommentList)); }
public ActionResult Index(FormCollection collection) { Next.WorkFlow.BLL.WorkFlowDelegationBLL bworkFlowDelegation = new Next.WorkFlow.BLL.WorkFlowDelegationBLL(); Next.Admin.BLL.DeptBLL borganize = new Next.Admin.BLL.DeptBLL(); Next.Admin.BLL.UserBLL busers = new Next.Admin.BLL.UserBLL(); Next.WorkFlow.BLL.WorkFlowInfoBLL bworkFlow = new Next.WorkFlow.BLL.WorkFlowInfoBLL(); IEnumerable <WorkFlowDelegation> workFlowDelegationList; string startTime = string.Empty; string endTime = string.Empty; string suserid = string.Empty; string query1 = string.Format("&appid={0}&tabid={1}&isoneself={2}", Request.QueryString["appid"], Request.QueryString["tabid"], Request.QueryString["isoneself"]); if (collection != null) { if (!Request.Form["DeleteBut"].IsNullOrEmpty()) { string ids = Request.Form["checkbox_app"]; foreach (string id in ids.Split(',')) { string bid; if (!id.IsGuid(out bid)) { continue; } var comment = bworkFlowDelegation.FindByID(bid); if (comment != null) { bworkFlowDelegation.Delete(bid); //RoadFlow.Platform.Log.Add("删除了流程意见", comment.Serialize(), RoadFlow.Platform.Log.Types.流程相关); } } //bworkFlowDelegation.RefreshCache(); } startTime = Request.Form["S_StartTime"]; endTime = Request.Form["S_EndTime"]; suserid = Request.Form["S_UserID"]; } else { startTime = Request.QueryString["S_StartTime"]; endTime = Request.QueryString["S_EndTime"]; suserid = Request.QueryString["S_UserID"]; } query1 += "&S_StartTime=" + startTime + "&S_EndTime=" + endTime + "&S_UserID=" + suserid; string pager; bool isOneSelf = "1" == Request.QueryString["isoneself"]; if (isOneSelf) { workFlowDelegationList = bworkFlowDelegation.GetPagerData(out pager, query1, new Next.Admin.BLL.UserBLL().CurrentUserID.ToString(), startTime, endTime); } else { workFlowDelegationList = bworkFlowDelegation.GetPagerData(out pager, query1, Next.Admin.BLL.UserBLL.RemovePrefix(suserid), startTime, endTime); } ViewBag.Query1 = query1; ViewBag.startTime = startTime; ViewBag.endTime = endTime; ViewBag.suserid = suserid; return(View(workFlowDelegationList)); }