var jyzf = ['AH_SL_YL', 'ZJ_SL_YL', 'AH_SL_ZF']; var jl = ['TBA_SW_XAJ', 'AH_SL_JL', 'ZJ_SL_JL']; var slgc = ['DW_XAJ_ST', 'FD_XAJ', 'HS_SK_XAJ', 'CA_SK_XAJ']; var qsh = ['AH_SL_WIU', 'ZJ_SL_WIU']; var gxdata = { init: function (table, $, layer, form) { form.on('select(xaj-sel-unit)', function (data) { var selIndex = data.elem.selectedIndex; var selunit = data.elem[data.elem.selectedIndex].getAttribute("id"); $('.tba-unit-button').hide(); $('#' + selunit + '-buttons').show(); var bizCode = "TBA_SW_XAJ"; var tp = "0"; //水文数据范围:太湖流域管理局 if (selIndex == 0) { bizCode = "TBA_SW_XAJ"; } else if (selIndex == 1) { //安徽省水利厅 bizCode = 'AH_SL_YL'; } else if (selIndex == 2) { //浙江省水利厅 bizCode = 'ZJ_SL_YL'; } else if (selIndex == 3) { //国家电网有限公司华东分部 bizCode = 'DW_XAJ_ST'; } else if (selIndex == 4) { //新安江水力发电厂 bizCode = 'FD_XAJ'; } else if (selIndex == 5) { //黄山市水利局 bizCode = 'HS_SK_XAJ'; } else if (selIndex == 6) { //淳安县水利水电局 bizCode = 'CA_SK_XAJ'; } else if (selIndex == 7) { //各地区政府 bizCode = 'GDP_XAJ'; } else { //新安江流域 bizCode = 'DRP'; tp = "DRP"; } window.location.href = ctx + "web/xaj-data.html?page=" + pageParam + "&bizCode=" + bizCode + "&unit=" + selunit + "&tp=" + tp; }); form.on('select(xaj-sel-tp)', function (data) { let bizCode = data.value; window.location.href = ctx + "web/xaj-data.html?page=" + pageParam + "&bizCode=" + bizCode + "&unit=all_xaj" + "&tp=" + bizCode; }); $(document).on('click', '.tba-btn', function () { var bizCodeParam = $(this).attr("id"); window.location.href = ctx + "web/xaj-data.html?page=" + pageParam + "&bizCode=" + bizCodeParam + "&unit=" + unitParam + "&tp=0"; return false; }); $("#szSearchBtn").click(function () { table.reload('rtuDataGrid', { where: { startTime: $("#startTime").val(), endTime: $("#endTime").val(), } //设定异步数据接口的额外参数 }); }) $("#szSearchBtn1").click(function () { table.reload('rtuDataGrid1', { where: { startTime: $("#startTime1").val(), endTime: $("#endTime1").val(), } //设定异步数据接口的额外参数 }); }) }, format0data: function (rows) { if (rows && Array.isArray(rows)) { for (var i = 0; i < rows.length; i++) { var row = rows[i]; for (var key in row) { if (row[key] != null) { if (key == 'drp' || key == 'dyp' || key == 'q' || key == 'inq' || key == 'outq' || key == 'z' || key == 'dwz') { row[key] = Number(row[key]).toFixed(1); } if (key == 'peoCitySum' || key == 'peoCountySum' || key == 'pepSum' || key == 'peoRadio' || key == 'gdpSum' || key == 'insduAdd' || key == 'gdArea') { row[key] = Number(row[key]).toFixed(2); } if (key == 'w' || key == 'ww') { row[key] = Number(row[key]).toFixed(3); } } // if ((typeof row[key]) == "string") { // var fVal = parseFloat(row[key]); // if (fVal && fVal < 1 && fVal >= 0) { // if (row[key].substr(0, 1) != "0") { // row[key] = "0" + row[key]; // } // } // } } } } return rows; }, getDataDefine: function (bizCode) { switch (bizCode) { case 'DRP': return { newestDataUrl: ctx + 'gx/xaj/newest?tp=' + bizCode, listDataUrl: ctx + 'gx/xaj/list?tp=' + bizCode, downloadUrl: ctx + 'gx/sw/gcdd/download?tp=' + bizCode, timeBetween: 1, layuiTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 100, templet: '#xuhao'} , {field: 'stnm', title: '断面名称', fixed: 'left', align: 'center', width: 200} , {field: 'tm', title: '时间', align: 'center', fixed: 'left', width: 200, templet: '#timeTpl'} , {field: 'drp', title: '降雨量(mm)', align: 'center', width: 150,} , {field: 'prov', title: '省份', align: 'center', width: 150} , {field: 'city', title: '城市', align: 'center', width: 150} , {field: 'county', title: '县级市', align: 'center', width: 150} ], chartTable: [ {field: 'tm', title: '时间', align: 'center', sort: true, width: 200} , {field: 'drp', title: '降雨量(mm)', align: 'center', width: 150, templet: '#UPZTpl'} ], chart: { title: '水文监测', xCategory: 'tm', yAxis: ["mm"], series: [ { name: '降雨量', field: 'drp', type: 'bar', color: "#5793F3", yAxisIndex: 0, selected: true }, ] } } break; case 'ZZ': return { newestDataUrl: ctx + 'gx/xaj/newest?tp=' + bizCode, listDataUrl: ctx + 'gx/xaj/list?tp=' + bizCode, downloadUrl: ctx + 'gx/sw/gcdd/download?tp=' + bizCode, timeBetween: 1, layuiTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 100, templet: '#xuhao'} , {field: 'stnm', title: '断面名称', fixed: 'left', align: 'center', width: 200} , {field: 'tm', title: '时间', align: 'center', fixed: 'left', width: 200, templet: '#timeTpl'} , {field: 'z', title: '水位(m)', align: 'center', width: 200} , {field: 'q', title: '径流量(m³/s)', align: 'center', width: 200,} , {field: 'prov', title: '省份', align: 'center', width: 150} , {field: 'city', title: '城市', align: 'center', width: 150} , {field: 'county', title: '县级市', align: 'center', width: 150} ], chartTable: [ {field: 'tm', title: '时间', align: 'center', sort: true, width: 200, templet: '#timeTpl'} , {field: 'z', title: '水位(m)', align: 'center', width: 200} , {field: 'q', title: '径流量(m³/s)', align: 'center', width: 200} ], chart: { title: '水文监测', xCategory: 'tm', yAxis: ["m", "m³/s"], series: [ {name: '水位', field: 'z', type: "line", color: "#49af4d", yAxisIndex: 0, selected: true}, {name: '径流量', field: 'q', type: 'bar', color: "#5793F3", yAxisIndex: 1, selected: true}, ] } } break; case 'DYP': return { newestDataUrl: ctx + 'gx/xaj/newest?tp=' + bizCode, listDataUrl: ctx + 'gx/xaj/list?tp=' + bizCode, downloadUrl: ctx + 'gx/sw/gcdd/download?tp=' + bizCode, timeBetween: 1, layuiTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 100, templet: '#xuhao'} , {field: 'stnm', title: '断面名称', fixed: 'left', align: 'center', width: 200} , {field: 'tm', title: '时间', align: 'center', fixed: 'left', width: 200, templet: '#timeTpl'} , {field: 'dyp', title: '蒸发量(mm)', align: 'center', width: 300,} , {field: 'prov', title: '省份', align: 'center', width: 150} , {field: 'city', title: '城市', align: 'center', width: 150} , {field: 'county', title: '县级市', align: 'center', width: 150} ], chartTable: [ {field: 'tm', title: '时间', align: 'center', sort: true, width: 200, templet: '#timeTpl'} , {field: 'dyp', title: '蒸发量(mm)', align: 'center', width: 150, templet: '#UPZTpl'} ], chart: { title: '水文监测', xCategory: 'tm', yAxis: ["mm"], series: [ { name: '蒸发量', field: 'dyp', type: 'bar', color: "#5793F3", yAxisIndex: 0, selected: true }, ] } } break; case 'WIU': return { newestDataUrl: ctx + 'gx/xaj/newest?tp=' + bizCode, listDataUrl: ctx + 'gx/xaj/list?tp=' + bizCode, downloadUrl: ctx + 'gx/sw/gcdd/download?tp=' + bizCode, timeBetween: 1, layuiTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 100, templet: '#xuhao'} , {field: 'stnm', title: '取用水户名称', fixed: 'left', align: 'center', width: 450} , {field: 'uscc', title: '社会信用代码', align: 'center', width: 300} , {field: 'tradTp', title: '取水户类型', align: 'center', width: 120} , {field: 'prov', title: '省份', align: 'center', width: 120} , {field: 'city', title: '城市', align: 'center', width: 120} , {field: 'county', title: '县级市', align: 'center', width: 120} ], } break; // case 'SK': // return { // newestDataUrl: ctx + 'gx/xaj/skswList?tp=' + bizCode, // listDataUrl: ctx + 'gx/xaj/skswList?tp=' + bizCode, // downloadUrl: ctx + 'gx/xaj/skswList?tp=' + bizCode, // timeBetween: 1, // layuiTable: [ // {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 100, templet: '#xuhao'} // , {field: 'stnm', title: '站点名称', fixed: 'left', align: 'center', width: 250} // , {field: 'tm', title: '时间', fixed: 'left', align: 'center', width: 250} // , {field: 'z', title: '水位', align: 'center', width: 200} // , {field: 'w', title: '蓄水量(万m³)', align: 'center', width: 200} // ], // chartTable: [ // {field: 'tm', title: '时间', align: 'center', width: 150} // , {field: 'z', title: '水位', align: 'center', width: 150} // , {field: 'w', title: '蓄水量(万m³)', align: 'center', width: 150} // ], // chart: { // title: '水库蓄水变化过程图', // xCategory: 'tm', // yAxis: ["m", "万m³"], // series: [ // { // name: '水位', // field: 'z', // type: 'line', // color: "#3adbe0", // yAxisIndex: 0, // selected: true // }, // { // name: '蓄水量', // field: 'w', // type: 'bar', // color: "#5793F3", // yAxisIndex: 1, // selected: true // } // ] // } // } // break; case 'TBA_SW_XAJ': return { newestDataUrl: ctx + 'gx/xaj/newest?bizCode=' + bizCode, listDataUrl: ctx + 'gx/xaj/list?bizCode=' + bizCode, downloadUrl: ctx + 'gx/sw/gcdd/download?bizCode=' + bizCode, timeBetween: 1, layuiTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 100, templet: '#xuhao'} , {field: 'stnm', title: '断面名称', fixed: 'left', align: 'center', width: 200} , {field: 'tm', title: '时间', align: 'center', fixed: 'left', width: 200, templet: '#timeTpl'} , {field: 'q', title: '下泄流量(m³/s)', align: 'center', width: 200,} , {field: 'gurdinfo', title: '保障情况', align: 'center', width: 500} ], chartTable: [ {field: 'tm', title: '时间', align: 'center', sort: true, width: 200, templet: '#timeTpl'} , {field: 'q', title: '下泄流量(m³/s)', align: 'center', width: 150, templet: '#UPZTpl'} ], chart: { title: '水文监测', xCategory: 'tm', yAxis: ["m³/s"], series: [ {name: '下泄流量', field: 'q', type: 'bar', color: "#5793F3", selected: true}, ] } } break; case 'AH_SL_JL': case 'ZJ_SL_JL': return { newestDataUrl: ctx + 'gx/xaj/newest?bizCode=' + bizCode, listDataUrl: ctx + 'gx/xaj/list?bizCode=' + bizCode, downloadUrl: ctx + 'gx/sw/gcdd/download?bizCode=' + bizCode, timeBetween: 1, layuiTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 100, templet: '#xuhao'} , {field: 'stnm', title: '断面名称', fixed: 'left', align: 'center', width: 200} , {field: 'tm', title: '时间', align: 'center', fixed: 'left', width: 200, templet: '#timeTpl'} , {field: 'z', title: '水位(m)', align: 'center', width: 200} , {field: 'q', title: '径流量(m³/s)', align: 'center', width: 200,} , {field: 'prov', title: '省份', align: 'center', width: 150} , {field: 'city', title: '城市', align: 'center', width: 150} , {field: 'county', title: '县级市', align: 'center', width: 150} ], chartTable: [ {field: 'tm', title: '时间', align: 'center', sort: true, width: 200, templet: '#timeTpl'} , {field: 'z', title: '水位(m)', align: 'center', width: 200} , {field: 'q', title: '径流量(m³/s)', align: 'center', width: 200} ], chart: { title: '水文监测', xCategory: 'tm', yAxis: ["m", "m³/s"], series: [ {name: '水位', field: 'z', type: "line", color: "#49af4d", yAxisIndex: 0, selected: true}, {name: '径流量', field: 'q', type: 'bar', color: "#5793F3", yAxisIndex: 1, selected: true}, ] } } break; case 'AH_SL_YL': case 'ZJ_SL_YL': return { newestDataUrl: ctx + 'gx/xaj/newest?bizCode=' + bizCode, listDataUrl: ctx + 'gx/xaj/list?bizCode=' + bizCode, downloadUrl: ctx + 'gx/sw/gcdd/download?bizCode=' + bizCode, timeBetween: 1, layuiTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 100, templet: '#xuhao'} , {field: 'stnm', title: '断面名称', fixed: 'left', align: 'center', width: 200} , {field: 'tm', title: '时间', align: 'center', fixed: 'left', width: 200, templet: '#timeTpl'} , {field: 'drp', title: '降雨量(mm)', align: 'center', width: 150,} , {field: 'prov', title: '省份', align: 'center', width: 150} , {field: 'city', title: '城市', align: 'center', width: 150} , {field: 'county', title: '县级市', align: 'center', width: 150} ], chartTable: [ {field: 'tm', title: '时间', align: 'center', sort: true, width: 200} , {field: 'drp', title: '降雨量(mm)', align: 'center', width: 150, templet: '#UPZTpl'} ], chart: { title: '水文监测', xCategory: 'tm', yAxis: ["mm"], series: [ { name: '降雨量', field: 'drp', type: 'bar', color: "#5793F3", yAxisIndex: 0, selected: true }, ] } } break; case 'AH_SL_ZF': return { newestDataUrl: ctx + 'gx/xaj/newest?bizCode=' + bizCode, listDataUrl: ctx + 'gx/xaj/list?bizCode=' + bizCode, downloadUrl: ctx + 'gx/sw/gcdd/download?bizCode=' + bizCode, timeBetween: 1, layuiTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 100, templet: '#xuhao'} , {field: 'stnm', title: '断面名称', fixed: 'left', align: 'center', width: 200} , {field: 'tm', title: '时间', align: 'center', fixed: 'left', width: 200, templet: '#timeTpl'} , {field: 'dyp', title: '蒸发量(mm)', align: 'center', width: 300,} , {field: 'prov', title: '省份', align: 'center', width: 150} , {field: 'city', title: '城市', align: 'center', width: 150} , {field: 'county', title: '县级市', align: 'center', width: 150} ], chartTable: [ {field: 'tm', title: '时间', align: 'center', sort: true, width: 200, templet: '#timeTpl'} , {field: 'dyp', title: '蒸发量(mm)', align: 'center', width: 150, templet: '#UPZTpl'} ], chart: { title: '水文监测', xCategory: 'tm', yAxis: ["mm"], series: [ { name: '蒸发量', field: 'dyp', type: 'bar', color: "#5793F3", yAxisIndex: 0, selected: true }, ] } } break; case 'AH_SL_WIU': case 'ZJ_SL_WIU': return { newestDataUrl: ctx + 'gx/xaj/newest?bizCode=' + bizCode, listDataUrl: ctx + 'gx/xaj/list?bizCode=' + bizCode, downloadUrl: ctx + 'gx/sw/gcdd/download?bizCode=' + bizCode, timeBetween: 1, layuiTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 100, templet: '#xuhao'} , {field: 'stnm', title: '取用水户名称', fixed: 'left', align: 'center', width: 450} , {field: 'uscc', title: '社会信用代码', align: 'center', width: 300} , {field: 'tradTp', title: '取水户类型', align: 'center', width: 120} , {field: 'prov', title: '省份', align: 'center', width: 120} , {field: 'city', title: '城市', align: 'center', width: 120} , {field: 'county', title: '县级市', align: 'center', width: 120} ], } break; case 'DW_XAJ_ST': return { newestDataUrl: ctx + 'gx/xaj/newest?bizCode=' + bizCode, listDataUrl: ctx + 'gx/xaj/list?bizCode=' + bizCode, downloadUrl: ctx + 'gx/sw/gcdd/download?bizCode=' + bizCode, timeBetween: 1, layuiTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 100, templet: '#xuhao'} , {field: 'stnm', title: '站点名称', fixed: 'left', align: 'center', width: 250} , { field: 'tm', title: '时间', fixed: 'left', align: 'center', width: 150, templet: '#timeTpl' } , {field: 'z', title: '坝上水位(m)', align: 'center', width: 150} , {field: 'inq', title: '入库流量(m³/s)', align: 'center', width: 150} , {field: 'outq', title: '出库流量(m³/s)', align: 'center', width: 150} ], chartTable: [ {field: 'tm', title: '时间', align: 'center', sort: true, width: 150, templet: '#timeTpl'} , {field: 'z', title: '坝上水位(m)', align: 'center', width: 150} , {field: 'inq', title: '入库流量(m³/s)', align: 'center', width: 150} , {field: 'outq', title: '出库流量(m³/s)', align: 'center', width: 150} ], chart: { title: '水文监测', xCategory: 'tm', yAxis: ["m", "m³/s"], series: [ { name: '坝上水位', field: 'z', type: 'line', color: "#5793F3", yAxisIndex: 0, selected: true }, { name: '入库流量', field: 'inq', type: 'bar', color: "#30AF30", yAxisIndex: 1, selected: true }, { name: '出库流量', field: 'outq', type: 'bar', color: "#368BFF", yAxisIndex: 1, selected: true }, ] } } break; case 'FD_XAJ': return { newestDataUrl: ctx + 'gx/xaj/newest?bizCode=' + bizCode, listDataUrl: ctx + 'gx/xaj/list?bizCode=' + bizCode, downloadUrl: ctx + 'gx/sw/gcdd/download?bizCode=' + bizCode, timeBetween: 1, layuiTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 100, templet: '#xuhao'} , {field: 'stnm', title: '站点名称', fixed: 'left', align: 'center', width: 250} , { field: 'tm', title: '时间', fixed: 'left', align: 'center', width: 200, templet: '#timeTpl' } , {field: 'z', title: '坝上水位(m)', align: 'center', width: 200} , {field: 'dwz', title: '坝下水位(m)', align: 'center', width: 200} , {field: 'inq', title: '入库流量(m³/s)', align: 'center', width: 200} , {field: 'outq', title: '出库流量(m³/s)', align: 'center', width: 200} ], chartTable: [ {field: 'tm', title: '时间', align: 'center', sort: true, width: 150, templet: '#timeTpl'} , {field: 'inq', title: '入库流量(m³/s)', align: 'center', width: 150} , {field: 'outq', title: '出库流量(m³/s)', align: 'center', width: 150} , {field: 'z', title: '坝上水位(m)', align: 'center', width: 150} , {field: 'dwz', title: '坝下水位(m)', align: 'center', width: 150} ], chart: { title: '水文监测', xCategory: 'tm', yAxis: ["m", "m³/s"], series: [ { name: '坝上水位', field: 'z', type: 'line', color: "#5793F3", yAxisIndex: 0, selected: true }, { name: '坝下水位', field: 'dwz', type: 'line', color: "#4F5FCBCC", yAxisIndex: 0, selected: true }, { name: '入库流量', field: 'inq', type: 'bar', color: "#30AF30", yAxisIndex: 1, selected: true }, { name: '出库流量', field: 'outq', type: 'bar', color: "#368BFF", yAxisIndex: 1, selected: true }, ] } } break; case 'FD_XAJ_FILE': case 'HS_SK_XAJ_FILE': case 'CA_SK_XAJ_FILE': return { newestDataUrl: ctx + 'gx/xaj/file/list?bizCode=' + bizCode, // listDataUrl: ctx + 'gx/xaj/list?bizCode=' + bizCode, // downloadUrl: ctx + 'gx/sw/gcdd/download?bizCode=' + bizCode, timeBetween: 1, layuiTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 100, templet: '#xuhao'} // , {field: 'stcd', title: '站码', align: 'center', width: 120} , {field: 'stnm', title: '站点名称', align: 'center', width: 200} , {field: 'fileName', title: '文件名称', align: 'center', width: 700} , {field: 'fileTime', title: '上传时间', align: 'center', width: 150} , { field: 'filePath', title: '操作', align: 'center', width: 200, templet: function (e) { let url = ctx + "doc/" + e.filePath + "/" + e.fileName + "' download='" + ctx + "doc/" + e.filePath + "/" + e.fileName; // return "\n" + // "下载"; return ""; } } ], } break; case 'HS_SK_XAJ': case 'CA_SK_XAJ': return { newestDataUrl: ctx + 'gx/xaj/newest?bizCode=' + bizCode, listDataUrl: ctx + 'gx/xaj/list?bizCode=' + bizCode, timeBetween: 1, layuiTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 100, templet: '#xuhao'} , {field: 'stnm', title: '站点名称', fixed: 'left', align: 'center', width: 250} , {field: 'tm', title: '时间', align: 'center', width: 200, templet: '#timeTpl'} , {field: 'ww', title: '下泄水量(万m³)', align: 'center', width: 200} ], chartTable: [ {field: 'tm', title: '时间', align: 'center', sort: true, width: 200, templet: '#timeTpl'} , {field: 'ww', title: '下泄水量(万m³)', align: 'center', width: 200} ], chart: { title: '水文监测', xCategory: 'tm', yAxis: ["万m³"], series: [ { name: '下泄水量', field: 'ww', type: 'bar', color: "#5793F3", yAxisIndex: 0, selected: true }, ] } } break; case 'DW_XAJ_ST_KR': case 'HS_SK_XAJ_KR': case 'CA_SK_XAJ_KR': case 'FD_XAJ_KR': return { newestDataUrl: ctx + 'gx/xaj/krList?bizCode=' + bizCode, listDataUrl: ctx + 'gx/xaj/krList?bizCode=' + bizCode, downloadUrl: ctx + 'gx/xaj/krList?bizCode=' + bizCode, timeBetween: 1, layuiTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 100, templet: '#xuhao'} , {field: 'stnm', title: '站点名称', fixed: 'left', align: 'center', width: 250} , {field: 'z', title: '水位(m)', fixed: 'left', align: 'center', width: 200} , {field: 'w', title: '库容(万m³)', align: 'center', width: 200} ], chartTable: [ {field: 'z', title: '水位(m)', align: 'center', width: 150} ], chart: { title: '库容曲线', xCategory: 'kr', yAxis: ["m³"], series: [ { name: '水位', field: 'z', type: 'line', color: "#5793F3", yAxisIndex: 0, selected: true } ] } } break; case 'DW_XAJ_ST_XS': case 'HS_SK_XAJ_XS': case 'CA_SK_XAJ_XS': return { newestDataUrl: ctx + 'gx/xaj/skswList?bizCode=' + bizCode, listDataUrl: ctx + 'gx/xaj/skswList?bizCode=' + bizCode, downloadUrl: ctx + 'gx/xaj/skswList?bizCode=' + bizCode, timeBetween: 1, layuiTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 100, templet: '#xuhao'} , {field: 'stnm', title: '站点名称', fixed: 'left', align: 'center', width: 250} , {field: 'tm', title: '时间', fixed: 'left', align: 'center', width: 250} , {field: 'z', title: '水位(m)', align: 'center', width: 200} , {field: 'w', title: '蓄水量(万m³)', align: 'center', width: 200} ], chartTable: [ {field: 'tm', title: '时间', align: 'center', width: 150} , {field: 'z', title: '水位(m)', align: 'center', width: 150} , {field: 'w', title: '蓄水量(万m³)', align: 'center', width: 150} ], chart: { title: '水库蓄水变化过程图', xCategory: 'tm', yAxis: ["m", "万m³"], series: [ { name: '水位', field: 'z', type: 'line', color: "#3adbe0", yAxisIndex: 0, selected: true }, { name: '蓄水量', field: 'w', type: 'bar', color: "#5793F3", yAxisIndex: 1, selected: true } ] } } break; case 'FD_XAJ_XS': return { newestDataUrl: ctx + 'gx/xaj/skswList?bizCode=' + bizCode, listDataUrl: ctx + 'gx/xaj/skswList?bizCode=' + bizCode, downloadUrl: ctx + 'gx/xaj/skswList?bizCode=' + bizCode, timeBetween: 1, layuiTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 100, templet: '#xuhao'} , {field: 'stnm', title: '站点名称', fixed: 'left', align: 'center', width: 250} , {field: 'tm', title: '时间', fixed: 'left', align: 'center', width: 250} , {field: 'z', title: '水位(m)', align: 'center', width: 200} , {field: 'w', title: '蓄水量(亿m³)', align: 'center', width: 200} ], chartTable: [ {field: 'tm', title: '时间', align: 'center', width: 150} , {field: 'z', title: '水位(m)', align: 'center', width: 150} , {field: 'w', title: '蓄水量(亿m³)', align: 'center', width: 150} ], chart: { title: '水库蓄水变化过程图', xCategory: 'tm', yAxis: ["m", "亿m³"], series: [ { name: '水位', field: 'z', type: 'line', color: "#3adbe0", yAxisIndex: 0, selected: true }, { name: '蓄水量', field: 'w', type: 'bar', color: "#5793F3", yAxisIndex: 1, selected: true } ] } } break; case 'WIU_XAJ': return { listDataUrl: ctx + 'gx/xaj/wiuMonthList?bizCode=' + bizCode, timeBetween: 1, layuiTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 80, templet: '#xuhao'} , {field: 'tm', title: '时间', fixed: 'left', align: 'center', width: 150} , {field: 'gongshuiWW', title: '公共供水企业用水量', align: 'center', width: 150} , {field: 'fwWW', title: '服务业自备水源用水量', align: 'center', width: 150} , {field: 'insdutryWW', title: '工业自备水源用水量', align: 'center', width: 150} ], chartTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 80, templet: '#xuhao'} , {field: 'tm', title: '时间', fixed: 'left', align: 'center', width: 150} , {field: 'gongshuiWW', title: '公共供水企业用水量', align: 'center', width: 150} , {field: 'fwWW', title: '服务业自备水源用水量', align: 'center', width: 150} , {field: 'insdutryWW', title: '工业自备水源用水量', align: 'center', width: 150} ], chart: { title: '分行业月度用水量', xCategory: 'tm', yAxis: ["万m³"], series: [ { field: 'gongshuiWW', name: '公共供水企业用水量', type: 'bar', stack: 'tradTp', color: "#FCD521", selected: true } , { field: 'fwWW', name: '服务业自备水源用水量', type: 'bar', stack: 'tradTp', color: "#6F17FF", selected: true } , { field: 'insdutryWW', name: '工业自备水源用水量', type: 'bar', stack: 'tradTp', color: "#0277F4", selected: true } ] } } break; case 'GDP_XAJ': return { newestDataUrl: ctx + 'gx/xaj/gdpnewest?bizCode=' + bizCode, listDataUrl: ctx + 'gx/xaj/gdpList?bizCode=' + bizCode, downloadUrl: ctx + 'gx/sw/gcdd/download?bizCode=' + bizCode, timeBetween: 1, layuiTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 100, templet: '#xuhao'} , {field: 'prov', title: '省份', fixed: 'left', align: 'center', width: 80} , {field: 'city', title: '城市', fixed: 'left', align: 'center', width: 80} , {field: 'county', title: '县区', fixed: 'left', align: 'center', width: 80} , {field: 'yr', title: '年份', fixed: 'left', align: 'center', width: 80} , {field: 'peoCitySum', title: '城市人口总数(万人)', align: 'center', width: 180} , {field: 'peoCountySum', title: '农村人口总数(万人)', align: 'center', width: 180} , {field: 'pepSum', title: '人口总数(万人)', align: 'center', width: 150} , {field: 'peoRadio', title: '城镇化率(%)', align: 'center', width: 150} // , {field: 'gdp1Sum', title: '一产', align: 'center', width: 80} // , {field: 'gdp2Sum', title: '二产', align: 'center', width: 80} // , {field: 'gdp3Sum', title: '三产', align: 'center', width: 80} , {field: 'gdpSum', title: '国内(地区)生产总值(亿元)', align: 'center', width: 250} , {field: 'insduAdd', title: '工业增加值(亿元)', align: 'center', width: 190} //, {field: 'effectIrrArea', title: '农田有效灌溉面积(万亩)', align: 'center', width: 120} , {field: 'gdArea', title: '耕地面积(万亩)', align: 'center', width: 190} ], chartTable: [ {field: 'id', title: '序号', fixed: 'left', align: 'center', width: 100, templet: '#xuhao'} , {field: 'yr', title: '年份', fixed: 'left', align: 'center', width: 80} , {field: 'peoCitySum', title: '城市人口总数(万人)', align: 'center', width: 180} , {field: 'peoCountySum', title: '农村人口总数(万人)', align: 'center', width: 180} , {field: 'pepSum', title: '人口总数(万人)', align: 'center', width: 150} , {field: 'peoRadio', title: '城镇化率(%)', align: 'center', width: 150} , {field: 'gdpSum', title: '国内(地区)生产总值(亿元)', align: 'center', width: 250} , {field: 'insduAdd', title: '工业增加值(亿元)', align: 'center', width: 190} // , {field: 'effectIrrArea', title: '农田有效灌溉面积(万亩)', align: 'center', width: 100} , {field: 'gdArea', title: '耕地面积(万亩)', align: 'center', width: 190} ], chart: { title: 'GDP监测', xCategory: 'yr', yAxis: ["万人", "%", "亿元", "万亩"], series: [ , { field: 'peoCitySum', name: '城市人口总数(万人)', type: 'bar', stack: 'peoTp', yAxisIndex: 0, selected: false } , { field: 'peoCountySum', name: '农村人口总数(万人)', type: 'bar', stack: 'peoTp', yAxisIndex: 0, selected: false } , { field: 'pepSum', name: '人口总数(万人)', type: 'line', stack: 'peoTp1', yAxisIndex: 0, selected: false } , {field: 'peoRadio', name: '城镇化率(%)', type: 'bar', yAxisIndex: 1, selected: false} , { field: 'gdpSum', name: '国内(地区)生产总值(亿元)', type: 'bar', yAxisIndex: 2, selected: true } , {field: 'insduAdd', name: '工业增加值(亿元)', type: 'bar', yAxisIndex: 2, selected: false} , {field: 'gdArea', name: '耕地面积(万亩)', type: 'bar', yAxisIndex: 3, selected: false} ] } } break; } } } function isblank(str) { return str == '' || str == undefined || str == null; } function arrSUM(arr) { var s = 0; arr.forEach(function (val, idx, arr) { if (val) { s += val; } }, 0); return s; } function downLoad(fileId) { window.location.href = ctx + "biz/doc/file/downloadFile?fileId=" + fileId; } //罗桐埠和街口生态断面指标数据 function stTargetData(stcd) { switch (stcd) { case '70112100'://罗桐埠 return [ { silent: false, label: { position: 'middle', // 文字位置 formatter: '预警线 22.7m³/s', //文字 color: '#FA4009' }, yAxis: 22.7, lineStyle: {type: 'solid', color: "#FA4009", width: 1} } ]; case '70111400'://街口 return [ { silent: false, label: { position: 'middle', // 文字位置 formatter: '蓝色预警线 9.2m³/s', //文字 color: '#0C57D0' }, yAxis: 9.2, lineStyle: {type: 'solid', color: "#0C57D0", width: 1} }, { silent: false, label: { position: 'middle', // 文字位置 formatter: '橙色预警线 7.7m³/s', //文字 color: '#FFAF0F' }, yAxis: 7.7, lineStyle: {type: 'solid', color: "#FFAF0F", width: 1} }, { silent: false, label: { position: 'middle', // 文字位置 formatter: '红色预警线 6.2m³/s', //文字 color: '#FA4009' }, yAxis: 6.2, lineStyle: {type: 'solid', color: "#FA4009", width: 1} } ]; } }