public void TicketsDataBind() { string keyWord = this.txtKeyWord.Text.Trim(); int tid = QS("tid", 0); GetProjectIdAndUserIDResponse response = ticketApp.GetProjectIdAndUserID(tid); if (!CheckSecurity(response.CreateUserId) || keyWord.Length == 0) { return; } #region set value GetTicketsListByConditionRequest request = new GetTicketsListByConditionRequest(); dto = new TicketsSearchConditionDTO(); dto.OrderExpression = hidOrderBy.Value; dto.OrderDirection = hidOrderDirection.Value; dto.KeyWord = keyWord; dto.Status = CanShowStatus(); dto.Project = response.ProjectId.ToString(); dto.IsInternal = true;//true here, for unlimited dto.IsFeedBack = false; dto.FeedBackTicketsList = ""; request.TicketSc = dto; #endregion string ListNeedRemove = trApp.GetAllRelationStringById(tid, true) + " " + tid; list = ticketApp.GetTicketListBySearchCondition(request, out recordCount, page, anpUsers.PageSize); if (null != list && list.Count > 0) { trNoTickets.Visible = false; } foreach (string item in ListNeedRemove.Split(' ')) { if (item.Length > 0) { int id = Convert.ToInt32(item); list.RemoveAll(x => x.TicketID == id); } } this.rptRelationTicketsList.DataSource = list; this.rptRelationTicketsList.DataBind(); anpUsers.RecordCount = recordCount; }
protected string GetRelatedTickets(object id, object projectID) { return(trApp.GetAllRelationStringById(int.Parse(id.ToString()), false)); }
protected string ShowRelatedByTid(string tid) { return(trApp.GetAllRelationStringById(Convert.ToInt32(tid), false).TrimEnd(',')); }