Esempio n. 1
0
        public void ProcessRequest(HttpContext context)
        {
            pp = new MLMGC.Security.PersonalPage(true);
            nv = HttpContext.Current.Request.Form;
            context.Response.ContentType = "text/plain";
            string type = nv["key"];

            switch (type)
            {
            case "updatebase":    //修改个人基本信息
                UpdateBase();
                break;

            case "updatejob":    //个人用户添加/修改工作信息
                UpdateJob();
                break;

            case "deletejob":    //个人用户删除工作信息
                DeleteJob();
                break;

            case "getjob":    //个人用户查询工作信息详情
                GetJob();
                break;

            default:
                context.Response.Write("Hello World");
                break;
            }
        }
Esempio n. 2
0
        /// <summary>
        /// 录入新来源
        /// </summary>
        void SourceAdd()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);

            string name = nv["name"];
            int    putin;

            if (!int.TryParse(nv["putin"], out putin))
            {
                HttpContext.Current.Response.Write("参数错误");
                return;
            }
            string   intro = nv["intro"];
            E_Source data  = new E_Source();

            data.PersonalID = pp.PersonalID;
            data.SourceID   = 0;
            data.SourceCode = "";
            data.SourceName = name;
            data.Putin      = putin;
            data.Intro      = intro;
            int areaid = new T_Source().Add(data);

            HttpContext.Current.Response.Write(areaid);
        }
Esempio n. 3
0
        public void ProcessRequest(HttpContext context)
        {
            nv = System.Web.HttpUtility.ParseQueryString(context.Request.Url.Query);
            pp = new MLMGC.Security.PersonalPage(true);

            switch (nv["key"].ToString())
            {
            case "add":
                Add();
                break;

            case "delete":
                Delete();
                break;

            case "newlist":
                NewList();
                break;

            case "toplist":
                TopList();
                break;

            default:
                context.Response.Write("error");
                break;
            }
        }
Esempio n. 4
0
        /// <summary>
        /// 修改来源
        /// </summary>
        void SourceUpdate()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            int sourceid = int.Parse(nv["sourceid"]);

            string name = nv["name"];
            int    putin;

            if (!int.TryParse(nv["putin"], out putin))
            {
                HttpContext.Current.Response.Write("参数错误");
                return;
            }
            string   intro = nv["intro"];
            E_Source data  = new E_Source();

            data.PersonalID = pp.PersonalID;
            data.SourceID   = sourceid;
            data.SourceCode = "";
            data.SourceName = name;
            data.Putin      = putin;
            data.Intro      = intro;
            bool b = new T_Source().Update(data);

            HttpContext.Current.Response.Write(b ? "1" : "0");
        }
Esempio n. 5
0
        /// <summary>
        /// 删除地区
        /// </summary>
        void AreaDelete()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            int    areaid = int.Parse(nv["areaid"]);
            E_Area data   = new E_Area();

            data.PersonalID = pp.PersonalID;
            data.AreaID     = areaid;
            bool b = new T_Area().Delete(data);

            HttpContext.Current.Response.Write(b ? "1" : "0");
        }
Esempio n. 6
0
        /// <summary>
        /// 删除行业信息
        /// </summary>
        void TradeDelete()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            int     tradeid = int.Parse(nv["tradeid"]);
            E_Trade data    = new E_Trade();

            data.PersonalID = pp.PersonalID;
            data.TradeID    = tradeid;
            bool b = new T_Trade().Delete(data);

            HttpContext.Current.Response.Write(b ? "1" : "0");
        }
Esempio n. 7
0
        /// <summary>
        /// 删除来源
        /// </summary>
        void SourceDelete()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            int      sourceid = int.Parse(nv["sourceid"]);
            E_Source data     = new E_Source();

            data.PersonalID = pp.PersonalID;
            data.SourceID   = sourceid;
            bool b = new T_Source().Delete(data);

            HttpContext.Current.Response.Write(b ? "1" : "0");
        }
Esempio n. 8
0
        /// <summary>
        /// 录入新报废理由
        /// </summary>
        void ScrapAdd()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            string  name = nv["name"];
            E_Scrap data = new E_Scrap();

            data.PersonalID = pp.PersonalID;
            data.ScrapID    = 0;
            data.ScrapName  = name;
            int scrapid = new T_Scrap().Add(data);

            HttpContext.Current.Response.Write(scrapid);
        }
Esempio n. 9
0
        /// <summary>
        /// 删除意向进展信息
        /// </summary>
        void WishDelete()
        {
            //MLMGC.Security.EnterprisePage ep = new MLMGC.Security.EnterprisePage(true);
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            int    wishid = int.Parse(nv["wishid"]);
            E_Wish data   = new E_Wish();

            data.PersonalID = pp.PersonalID;
            data.WishID     = wishid;
            bool b = new T_Wish().Delete(data);

            HttpContext.Current.Response.Write(b ? "1" : "0");
        }
Esempio n. 10
0
        /// <summary>
        /// 录入新失败
        /// </summary>
        void NoTradedAdd()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            string      name = nv["name"];
            E_NotTraded data = new E_NotTraded();

            data.PersonalID    = pp.PersonalID;
            data.NotTradedID   = 0;
            data.NotTradedName = name;
            int tradeid = new T_NotTraded().Add(data);

            HttpContext.Current.Response.Write(tradeid);
        }
Esempio n. 11
0
        /// <summary>
        /// 录入新行业
        /// </summary>
        void TradeAdd()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            string  name = nv["name"];
            E_Trade data = new E_Trade();

            data.PersonalID = pp.PersonalID;
            data.TradeID    = 0;
            data.TradeCode  = "";
            data.TradeName  = name;
            int tradeid = new T_Trade().Add(data);

            HttpContext.Current.Response.Write(tradeid);
        }
Esempio n. 12
0
        /// <summary>
        /// 来源是否存在
        /// </summary>
        void SourceExists()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            int      sourceid = int.Parse(nv["sourceid"]);
            string   name     = nv["name"];
            E_Source data     = new E_Source();

            data.PersonalID = pp.PersonalID;
            data.SourceID   = sourceid;
            data.SourceName = name;
            bool b = new T_Source().Exists(data);

            HttpContext.Current.Response.Write(b ? "1" : "0");
        }
Esempio n. 13
0
        /// <summary>
        /// 删除失败信息
        /// </summary>
        void NoTradedDelete()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            int nottradedid = 0;

            int.TryParse(nv["nottradedid"], out nottradedid);
            E_NotTraded data = new E_NotTraded();

            data.PersonalID  = pp.PersonalID;
            data.NotTradedID = nottradedid;
            bool b = new T_NotTraded().Delete(data);

            HttpContext.Current.Response.Write(b ? "1" : "0");
        }
Esempio n. 14
0
        /// <summary>
        /// 地区是否存在
        /// </summary>
        void AreaExists()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            int    areaid = int.Parse(nv["areaid"]);
            string name   = nv["name"];
            E_Area data   = new E_Area();

            data.PersonalID = pp.PersonalID;
            data.AreaID     = areaid;
            data.AreaName   = name;
            bool b = new T_Area().Exists(data);

            HttpContext.Current.Response.Write(b ? "1" : "0");
        }
Esempio n. 15
0
        /// <summary>
        /// 删除报废理由
        /// </summary>
        void ScrapDelete()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            int scrapid = 0;

            int.TryParse(nv["scrapid"], out scrapid);
            E_Scrap data = new E_Scrap();

            data.PersonalID = pp.PersonalID;
            data.ScrapID    = scrapid;
            bool b = new T_Scrap().Delete(data);

            HttpContext.Current.Response.Write(b ? "1" : "0");
        }
Esempio n. 16
0
        /// <summary>
        /// 行业是否存在
        /// </summary>
        void TradeExists()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            int     tradeid = int.Parse(nv["tradeid"]);
            string  name    = nv["name"];
            E_Trade data    = new E_Trade();

            data.PersonalID = pp.PersonalID;
            data.TradeID    = tradeid;
            data.TradeName  = name;
            bool b = new T_Trade().Exists(data);

            HttpContext.Current.Response.Write(b ? "1" : "0");
        }
Esempio n. 17
0
        /// <summary>
        /// 录入新地区
        /// </summary>
        void AreaAdd()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            //string code = nv["code"];
            string name = nv["name"];
            E_Area data = new E_Area();

            data.PersonalID = pp.PersonalID;
            data.AreaID     = 0;
            data.AreaCode   = "";
            data.AreaName   = name;
            int areaid = new T_Area().Add(data);

            HttpContext.Current.Response.Write(areaid);
        }
Esempio n. 18
0
        /// <summary>
        /// 意向进展状态是否存在
        /// </summary>
        void WishExists()
        {
            //MLMGC.Security.EnterprisePage ep = new MLMGC.Security.EnterprisePage(true);
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            int    wishid = int.Parse(nv["wishid"]);
            string name   = nv["name"];
            E_Wish data   = new E_Wish();

            data.PersonalID = pp.PersonalID;
            data.WishID     = wishid;
            data.WishName   = name;
            bool b = new T_Wish().Exists(data);

            HttpContext.Current.Response.Write(b ? "1" : "0");
        }
Esempio n. 19
0
        /// <summary>
        /// 添加下载记录
        /// </summary>
        private void Download()
        {
            //获取文库id
            int    id;
            string usertype = nv["usertype"];

            if (!int.TryParse(nv["id"], out id))
            {
                HttpContext.Current.Response.Write("参数错误");
                return;
            }
            E_WenKuDownload data = new E_WenKuDownload();

            data.WenKuID = id;
            //判断用户类型:1=企业用户,2=个人用户
            if (usertype == "1")
            {
                MLMGC.Security.EnterprisePage ep = new MLMGC.Security.EnterprisePage(true);
                data.UserID       = ep.UserID;
                data.EnterpriseID = ep.EnterpriceID;
                data.UserType     = MLMGC.DataEntity.User.UserType.企业用户;
            }
            else
            {
                MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
                data.UserID   = pp.UserID;
                data.UserType = MLMGC.DataEntity.User.UserType.个人用户;
            }

            bool flag = new T_WenKuDownload().Add(data);
            //声明返回json对象
            JsonObjectCollection colDR = new JsonObjectCollection();

            colDR.Add(new JsonStringValue("flag", flag ? "1" : "0"));

            //成功添加数据之后 再次获取原文件的地址。
            E_WenKu dataW = new T_WenKu().GetModel(new E_WenKu()
            {
                WenKuID = id
            });

            if (dataW != null)
            {
                colDR.Add(new JsonStringValue("url", MLMGC.COMP.Config.GetWenKuUrl(dataW.FileUrl)));
            }

            HttpContext.Current.Response.Write(colDR.ToString());
        }
Esempio n. 20
0
        /// <summary>
        /// 设置属性
        /// </summary>
        void SetProperty()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            string     trade  = nv["trade"];
            string     area   = nv["area"];
            string     source = nv["source"];
            E_Property data   = new E_Property();

            data.PersonalID = pp.PersonalID;
            data.TradeFlag  = trade == "true" ? EnumPropertyEnabled.启用 : EnumPropertyEnabled.禁用;
            data.AreaFlag   = area == "true" ? EnumPropertyEnabled.启用 : EnumPropertyEnabled.禁用;
            data.SourceFlag = source == "true" ? EnumPropertyEnabled.启用 : EnumPropertyEnabled.禁用;
            bool b = new T_Property().Set(data);

            HttpContext.Current.Response.Write(b ? "1" : "0");
        }
Esempio n. 21
0
        /// <summary>
        /// 失败是否存在
        /// </summary>
        void NoTradedExists()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            int nottradedid = 0;

            int.TryParse(nv["nottradedid"], out nottradedid);
            string      name = nv["name"];
            E_NotTraded data = new E_NotTraded();

            data.PersonalID    = pp.PersonalID;
            data.NotTradedID   = nottradedid;
            data.NotTradedName = name;
            bool b = new T_NotTraded().Exists(data);

            HttpContext.Current.Response.Write(b ? "1" : "0");
        }
Esempio n. 22
0
        /// <summary>
        /// 报废理由是否存在
        /// </summary>
        void ScrapExists()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            int scrapid = 0;

            int.TryParse(nv["scrapid"], out scrapid);
            string  name = nv["name"];
            E_Scrap data = new E_Scrap();

            data.PersonalID = pp.PersonalID;
            data.ScrapID    = scrapid;
            data.ScrapName  = name;
            bool b = new T_Scrap().Exists(data);

            HttpContext.Current.Response.Write(b ? "1" : "0");
        }
Esempio n. 23
0
        /// <summary>
        /// 录入新意向进展状态
        /// </summary>
        void WishAdd()
        {
            //MLMGC.Security.EnterprisePage ep = new MLMGC.Security.EnterprisePage(true);
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            string name    = nv["name"];
            int    percent = int.Parse(nv["percent"]);
            E_Wish data    = new E_Wish();

            data.PersonalID  = pp.PersonalID;
            data.WishID      = 0;
            data.WishName    = name;
            data.WishPercent = percent;
            int tradeid = new T_Wish().Add(data);

            HttpContext.Current.Response.Write(tradeid);
        }
Esempio n. 24
0
        public void ProcessRequest(HttpContext context)
        {
            context.Response.ContentType = "text/plain";
            //---获取用户角色等信息
            bp = new MLMGC.Security.PersonalPage(true);
            if (bp.PersonalID < 1)
            {
                context.Response.Write("timeout");
                return;
            }
            nv = context.Request.Form;
            switch (nv["key"])
            {
            case "exists":       //判断名录是否存在
                Exists();
                break;

            case "existscontact":    //判断手机或电话是否存在
                ExistsContact();
                break;

            case "updatebase":    //修改基本信息
                UpdateBaseInfo();
                break;

            case "updatestatus":    //修改状态
                UpdateStatus();
                break;

            case "exchange":    //新沟通记录
                Exchange();
                break;

            case "delete":    //批量删除名录信息
                Delete();
                break;

            default:
                context.Response.Write("Hello World");
                break;
            }
        }
Esempio n. 25
0
        public void ProcessRequest(HttpContext context)
        {
            context.Response.ContentType = "text/plain";
            nv = HttpContext.Current.Request.Form;
            pp = new MLMGC.Security.PersonalPage(true);

            switch (nv["key"])
            {
            case "clientinfoexists":    //判断名录名称手机号,电话号码是否存在
                ClientInfoExists();
                break;

            case "updatebase":    //修改基本信息
                UpdateBase();
                break;

            case "updatestatus":    //修改状态
                UpdateStatus();
                break;

            case "addexchange":
                AddExchange();
                break;

            case "delete":
                Delete();
                break;

            case "share":
                Share();
                break;

            case "myget":
                MyGet();
                break;

            default:
                context.Response.Write("Hello World");
                break;
            }
        }
Esempio n. 26
0
        /// <summary>
        /// 显示行业信息
        /// </summary>
        void TradeShow()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            int     tradeid = int.Parse(nv["tradeid"]);
            E_Trade data    = new E_Trade();

            data.PersonalID = pp.PersonalID;
            data.TradeID    = tradeid;
            data            = new T_Trade().GetModel(data);
            if (data == null)
            {
                data         = new E_Trade();
                data.TradeID = 0;
            }
            JsonObjectCollection colDR = new JsonObjectCollection();

            colDR.Add(new JsonStringValue("id", data.TradeID.ToString()));
            colDR.Add(new JsonStringValue("code", data.TradeCode));
            colDR.Add(new JsonStringValue("name", data.TradeName));
            HttpContext.Current.Response.Write(colDR.ToString());
        }
Esempio n. 27
0
        /// <summary>
        /// 显示地区信息
        /// </summary>
        void AreaShow()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            int    areaid = int.Parse(nv["areaid"]);
            E_Area data   = new E_Area();

            data.PersonalID = pp.PersonalID;
            data.AreaID     = areaid;
            data            = new T_Area().GetModel(data);
            if (data == null)
            {
                data        = new E_Area();
                data.AreaID = 0;
            }
            JsonObjectCollection colDR = new JsonObjectCollection();

            colDR.Add(new JsonStringValue("id", data.AreaID.ToString()));
            colDR.Add(new JsonStringValue("code", data.AreaCode));
            colDR.Add(new JsonStringValue("name", data.AreaName));
            HttpContext.Current.Response.Write(colDR.ToString());
        }
Esempio n. 28
0
        /// <summary>
        /// 获取显示报废理由
        /// </summary>
        void ScrapShow()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            int scrapid = 0;

            int.TryParse(nv["scrapid"], out scrapid);
            E_Scrap data = new E_Scrap();

            data.PersonalID = pp.PersonalID;
            data.ScrapID    = scrapid;
            data            = new T_Scrap().GetModel(data);
            if (data == null)
            {
                data         = new E_Scrap();
                data.ScrapID = 0;
            }
            JsonObjectCollection colDR = new JsonObjectCollection();

            colDR.Add(new JsonStringValue("id", data.ScrapID.ToString()));
            colDR.Add(new JsonStringValue("name", data.ScrapName));
            HttpContext.Current.Response.Write(colDR.ToString());
        }
Esempio n. 29
0
        /// <summary>
        /// 获取显示意向进展状态信息
        /// </summary>
        void WishShow()
        {
            //MLMGC.Security.EnterprisePage ep = new MLMGC.Security.EnterprisePage(true);
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            int    wishid = int.Parse(nv["wishid"]);
            E_Wish data   = new E_Wish();

            data.PersonalID = pp.PersonalID;
            data.WishID     = wishid;
            data            = new T_Wish().GetModel(data);
            if (data == null)
            {
                data        = new E_Wish();
                data.WishID = 0;
            }
            JsonObjectCollection colDR = new JsonObjectCollection();

            colDR.Add(new JsonStringValue("id", data.WishID.ToString()));
            colDR.Add(new JsonStringValue("name", data.WishName));
            colDR.Add(new JsonStringValue("percent", data.WishPercent.ToString()));
            HttpContext.Current.Response.Write(colDR.ToString());
        }
Esempio n. 30
0
        /// <summary>
        /// 获取显示失败状态信息
        /// </summary>
        void NoTradedShow()
        {
            MLMGC.Security.PersonalPage pp = new MLMGC.Security.PersonalPage(true);
            int nottradedid = 0;

            int.TryParse(nv["nottradedid"], out nottradedid);
            E_NotTraded data = new E_NotTraded();

            data.PersonalID  = pp.PersonalID;
            data.NotTradedID = nottradedid;
            data             = new T_NotTraded().GetModel(data);
            if (data == null)
            {
                data             = new E_NotTraded();
                data.NotTradedID = 0;
            }
            JsonObjectCollection colDR = new JsonObjectCollection();

            colDR.Add(new JsonStringValue("id", data.NotTradedID.ToString()));
            colDR.Add(new JsonStringValue("name", data.NotTradedName));
            HttpContext.Current.Response.Write(colDR.ToString());
        }