public ActionResult Index(FormCollection collection) { RoadFlow.Platform.WorkFlowComment bworkFlowComment = new RoadFlow.Platform.WorkFlowComment(); RoadFlow.Platform.Organize borganize = new RoadFlow.Platform.Organize(); IEnumerable <RoadFlow.Data.Model.WorkFlowComment> workFlowCommentList; if (collection != null) { if (!Request.Form["DeleteBut"].IsNullOrEmpty()) { string ids = Request.Form["checkbox_app"]; foreach (string id in ids.Split(',')) { Guid bid; if (!id.IsGuid(out bid)) { continue; } var comment = bworkFlowComment.Get(bid); if (comment != null) { bworkFlowComment.Delete(bid); RoadFlow.Platform.Log.Add("删除了流程意见", comment.Serialize(), RoadFlow.Platform.Log.Types.流程相关); } } bworkFlowComment.RefreshCache(); } } workFlowCommentList = bworkFlowComment.GetAll(); bool isOneSelf = "1" == Request.QueryString["isoneself"]; if (isOneSelf) { workFlowCommentList = workFlowCommentList.Where(p => p.MemberID == RoadFlow.Platform.UsersBLL.PREFIX + RoadFlow.Platform.UsersBLL.CurrentUserID.ToString()); } return(View(workFlowCommentList)); }
protected void Page_Load(object sender, EventArgs e) { RoadFlow.Platform.WorkFlowComment bworkFlowComment = new RoadFlow.Platform.WorkFlowComment(); RoadFlow.Platform.Organize borganize = new RoadFlow.Platform.Organize(); query1 = string.Format("&appid={0}&tabid={1}&isoneself={2}", Request.QueryString["appid"], Request.QueryString["tabid"], Request.QueryString["isoneself"]); if (IsPostBack) { if (!Request.Form["DeleteBut"].IsNullOrEmpty()) { string ids = Request.Form["checkbox_app"]; foreach (string id in ids.Split(',')) { Guid bid; if (!id.IsGuid(out bid)) { continue; } var comment = bworkFlowComment.Get(bid); if (comment != null) { bworkFlowComment.Delete(bid); RoadFlow.Platform.Log.Add("删除了流程意见", comment.Serialize(), RoadFlow.Platform.Log.Types.流程相关); } } bworkFlowComment.RefreshCache(); } } workFlowCommentList = bworkFlowComment.GetAll(); isOneSelf = "1" == Request.QueryString["isoneself"]; if (isOneSelf) { workFlowCommentList = workFlowCommentList.Where(p => p.MemberID == RoadFlow.Platform.Users.PREFIX + RoadFlow.Platform.Users.CurrentUserID.ToString()); } }
public ActionResult Index(FormCollection collection) { RoadFlow.Platform.WorkFlowComment workFlowComment1 = new RoadFlow.Platform.WorkFlowComment(); RoadFlow.Platform.Organize organize = new RoadFlow.Platform.Organize(); IEnumerable <RoadFlow.Data.Model.WorkFlowComment> source = (IEnumerable <RoadFlow.Data.Model.WorkFlowComment>)workFlowComment1.GetAll(); if ("1" == this.Request.QueryString["isoneself"]) { source = source.Where <RoadFlow.Data.Model.WorkFlowComment>((Func <RoadFlow.Data.Model.WorkFlowComment, bool>)(p => p.MemberID == "u_" + RoadFlow.Platform.Users.CurrentUserID.ToString())); } JsonData jsonData = new JsonData(); foreach (RoadFlow.Data.Model.WorkFlowComment workFlowComment2 in (IEnumerable <RoadFlow.Data.Model.WorkFlowComment>)source.OrderBy <RoadFlow.Data.Model.WorkFlowComment, int>((Func <RoadFlow.Data.Model.WorkFlowComment, int>)(p => p.Type)).ThenBy <RoadFlow.Data.Model.WorkFlowComment, int>((Func <RoadFlow.Data.Model.WorkFlowComment, int>)(p => p.Sort))) { jsonData.Add((object)new JsonData() { ["id"] = (JsonData)workFlowComment2.ID.ToString(), ["Comment"] = (JsonData)workFlowComment2.Comment, ["MemberID"] = (JsonData)(workFlowComment2.MemberID.IsNullOrEmpty() ? "所有人员" : organize.GetNames(workFlowComment2.MemberID, ",")), ["Type"] = (JsonData)(workFlowComment2.Type == 0 ? "管理员" : "个人"), ["Sort"] = (JsonData)workFlowComment2.Sort, ["Opation"] = (JsonData)("<a class=\"editlink\" href=\"javascript:edit('" + workFlowComment2.ID.ToString() + "');\">编辑</a>") }); } // ISSUE: reference to a compiler-generated field if (WorkFlowCommentsController.\u003C\u003Eo__1.\u003C\u003Ep__0 == null) { // ISSUE: reference to a compiler-generated field WorkFlowCommentsController.\u003C\u003Eo__1.\u003C\u003Ep__0 = CallSite <Func <CallSite, object, string, object> > .Create(Binder.SetMember(CSharpBinderFlags.None, "list", typeof(WorkFlowCommentsController), (IEnumerable <CSharpArgumentInfo>) new CSharpArgumentInfo[2] { CSharpArgumentInfo.Create(CSharpArgumentInfoFlags.None, (string)null), CSharpArgumentInfo.Create(CSharpArgumentInfoFlags.UseCompileTimeType, (string)null) })); } // ISSUE: reference to a compiler-generated field // ISSUE: reference to a compiler-generated field object obj = WorkFlowCommentsController.\u003C\u003Eo__1.\u003C\u003Ep__0.Target((CallSite)WorkFlowCommentsController.\u003C\u003Eo__1.\u003C\u003Ep__0, this.ViewBag, jsonData.ToJson(true)); return((ActionResult)this.View()); }