Ejemplo n.º 1
0
        /*得到并关联仓库(select标签)*/

        public void ProcessRequest(HttpContext context)
        {
            RegionDC region_dc = new RegionDC();

            List <string> list = new List <string>();

            DataSet ds = region_dc.getRegion_nameBySubinventory_name(context.Request["warehouse_name"]);



            string json = toJson(ds);

            context.Response.ContentType = "text/plain";

            context.Response.Write(json);
        }
        public void ProcessRequest(HttpContext context)
        {
            RegionDC regionDC = new RegionDC();
            DataSet  ds       = regionDC.getRegion_nameBySubinventory_name(context.Request["name"]);

            List <string> modellist = new List <string>();

            if (ds != null && ds.Tables[0].Rows.Count > 0)
            {
                foreach (DataRow dr in ds.Tables[0].Rows)
                {
                    modellist.Add(dr["region_name"].ToString());
                }
            }
            string json = toJson(modellist);

            context.Response.ContentType = "text/plain";
            context.Response.Write(json);
        }