private void GetFillID() { string year = Request["year"]; string month = Request["month"]; TEnvFillSolidVo envFillSolidVo = new TEnvFillSolidVo(); envFillSolidVo.YEAR = year; envFillSolidVo.MONTH = month; envFillSolidVo = new TEnvFillSolidLogic().Details(envFillSolidVo); string json = "{\"ID\":\"" + envFillSolidVo.ID + "\",\"STATUS\":\"" + envFillSolidVo.STATUS + "\"}"; Response.ContentType = "application/json;charset=utf-8"; Response.Write(json); Response.End(); }
private void GetData() { string strWhere = "1=1"; string year = Request["year"]; string month = Request["month"]; string pointId = Request["pointId"]; //拼写条件语句(注:条件中的列名要与点位上的列名一致) if (year != "") { strWhere += " and YEAR='" + year + "'"; } if (month != "") { strWhere += " and MONTH='" + month + "'"; } if (pointId != "") { strWhere += " and ID='" + pointId + "'"; } //填报表需要显示信息(注:这Table里面的第一列数据要与填报表的列名一致) DataTable dtShow = new DataTable(); dtShow = new TEnvFillSolidLogic().CreateShowDT(); CommonLogic com = new CommonLogic(); DataTable dt = com.GetFillData(strWhere, dtShow, "", TEnvPSolidVo.T_ENV_P_SOLID_TABLE, TEnvPSolidItemVo.T_ENV_P_SOLID_ITEM_TABLE, TEnvFillSolidVo.T_ENV_FILL_SOLID_TABLE, TEnvFillSolidItemVo.T_ENV_FILL_SOLID_ITEM_TABLE, SerialType.T_ENV_FILL_SOILD, SerialType.T_ENV_FILL_SOILD_ITEM, "0"); string json = DataTableToJsonUnsureCol(dt); Response.ContentType = "application/json"; Response.Write(json); Response.End(); }