コード例 #1
0
        private string GetLinkByGuid(Guid id)
        {
            string pageRelUrl = CommonLinkUtility.GetEmployees(_productID) + "&";

            string pageUrl = string.Empty;

            if (Request["deplist"] == null)
            {
                pageUrl = string.Format("{0}depID={1}&search=&page=1&sort={2}{3}", pageRelUrl,
                                        id == Guid.Empty ? string.Empty : id.ToString(),
                                        Request["sort"], Request["list"] == null ? string.Empty : "&list=" + Request["list"]);
            }
            else
            {
                if (id == Guid.Empty)
                {
                    pageUrl = string.Format("{0}deplist={1}", pageRelUrl, Request["list"] == null ? string.Empty : "&list=" + Request["list"]);
                }
                else
                {
                    pageUrl = string.Format("{0}deplist={1}&search=&page=1&sort={2}{3}", pageRelUrl, id.ToString(),
                                            Request["sort"], Request["list"] == null ? string.Empty : "&list=" + Request["list"]);
                }
            }

            return(ResolveUrl(UrlQueryManager.AddDefaultParameters(Request, pageUrl)));
        }
コード例 #2
0
        protected string GetDepartmentsLink(Guid depId)
        {
            var pageUrl = string.Format("{0}?deplist={1}{2}", Page.AppRelativeVirtualPath, depId.Equals(Guid.Empty) ? string.Empty : depId.ToString(),
                                        Request["list"] == null ? string.Empty : "&list=" + Request["list"]);

            return(UrlQueryManager.AddDefaultParameters(Request, pageUrl, true));
        }
コード例 #3
0
        private string GetLinkByGuid(Guid id)
        {
            var pageUrl = string.Format("{0}?depID={1}&search=&page=1&sort={2}{3}", Page.AppRelativeVirtualPath,
                                        id == Guid.Empty ? string.Empty : id.ToString(),
                                        Request["sort"], Request["list"] == null ? string.Empty : "&list=" + Request["list"]);

            return(UrlQueryManager.AddDefaultParameters(Request, pageUrl, true));
        }
コード例 #4
0
        private string GetLinkForPager()
        {
            var pageUrl = string.Format("{0}?depID={1}&search={2}&sort={3}{4}", Page.AppRelativeVirtualPath,
                                        _strDepartmentId, Request["search"],
                                        Request["sort"], Request["list"] == null ? string.Empty : "&list=" + Request["list"]);

            if (EmployeeStatus == EmployeeStatus.Terminated)
            {
                pageUrl += "&es=0";
            }

            if (IsPending)
            {
                pageUrl += "&eas=0";
            }

            return(UrlQueryManager.AddDefaultParameters(Request, pageUrl, true));
        }
コード例 #5
0
        private string GetTabUrl(string selectedTabId)
        {
            var pageUrl = string.Empty;

            if (selectedTabId == "ListTab")
            {
                pageUrl = string.Format("{0}?depID={1}&search={2}&page={3}&sort={4}{5}", Page.AppRelativeVirtualPath,
                                        _strDepartmentId, Request["search"], Request["page"],
                                        Request["sort"], Request["list"] == null ? string.Empty : "&list=" + Request["list"]);
            }
            if (selectedTabId == "DepTab")
            {
                pageUrl = string.Format("{0}?deplist={1}&search={2}&page={3}&sort={4}{5}", Page.AppRelativeVirtualPath,
                                        _strDepartmentId, Request["search"], Request["page"], Request["sort"], Request["list"] == null ? string.Empty : "&list=" + Request["list"]);
            }
            pageUrl = UrlQueryManager.AddDefaultParameters(Request, pageUrl);
            return(pageUrl);
        }
コード例 #6
0
        protected string GetSortUrl(EmployeeSortType type)
        {
            var pageUrl = string.Format("{0}?depID={1}&search={2}&page={3}&sort={4}{5}", Page.AppRelativeVirtualPath,
                                        _strDepartmentId, Request["search"], Request["page"],
                                        type.Equals(_sortType) && !_invenrt ? "Inv" + type.ToString() : type.ToString(),
                                        Request["list"] == null ? string.Empty : "&list=" + Request["list"]);


            if (EmployeeStatus == EmployeeStatus.Terminated)
            {
                pageUrl += "&es=0";
            }

            if (IsPending)
            {
                pageUrl += "&eas=0";
            }

            return(UrlQueryManager.AddDefaultParameters(Request, pageUrl, true));
        }
コード例 #7
0
        private string GetCardViewLinkRelativeUrl(bool isCardView)
        {
            var pageUrl = UrlQueryManager.AddDefaultParameters(Request, GetCardViewLinkUrl(isCardView));

            return(pageUrl.TrimStart("~/".ToCharArray()));
        }
コード例 #8
0
        protected string GetCardListSwUrl()
        {
            var pageUrl = GetCardViewLinkUrl(_cardView);

            return(UrlQueryManager.AddDefaultParameters(Request, pageUrl, true));
        }