コード例 #1
0
ファイル: ActivityAjax.ashx.cs プロジェクト: evelh/Done
        /// <summary>
        /// 查看客户/联系人等获取活动列表
        /// </summary>
        /// <param name="context"></param>
        private void GetActivities(HttpContext context)
        {
            var           queryStr    = context.Request.QueryString;
            string        id          = queryStr["id"];
            string        type        = queryStr["page"];
            string        order       = queryStr["order"];
            List <string> actTypeList = new List <string>();

            if (!string.IsNullOrEmpty(queryStr["todo"]) && queryStr["todo"].Equals("1"))
            {
                actTypeList.Add("todo");
            }
            if (!string.IsNullOrEmpty(queryStr["crmnote"]) && queryStr["crmnote"].Equals("1"))
            {
                actTypeList.Add("crmnote");
            }
            if (!string.IsNullOrEmpty(queryStr["opportunity"]) && queryStr["opportunity"].Equals("1"))
            {
                actTypeList.Add("opportunity");
            }
            if (!string.IsNullOrEmpty(queryStr["sale"]) && queryStr["sale"].Equals("1"))
            {
                actTypeList.Add("sale");
            }
            if (!string.IsNullOrEmpty(queryStr["ticket"]) && queryStr["ticket"].Equals("1"))
            {
                actTypeList.Add("ticket");
            }
            if (!string.IsNullOrEmpty(queryStr["contract"]) && queryStr["contract"].Equals("1"))
            {
                actTypeList.Add("contract");
            }
            if (!string.IsNullOrEmpty(queryStr["project"]) && queryStr["project"].Equals("1"))
            {
                actTypeList.Add("project");
            }

            context.Response.Write(new Tools.Serialize().SerializeJson(bll.GetActivitiesHtml(actTypeList, long.Parse(id), type, order, LoginUserId, LoginUser.security_Level_id, UserPermit)));
        }