天津投入产出系统后端
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

109 lines
4.1 KiB

<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/AppMaster.Master" Inherits="System.Web.Mvc.ViewPage<dynamic>" %>
<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
标准地图
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
<%--异步获取数据生成图表--%>
<%--<%=QMAPP.Common.Web.QMEChart.QMEChartHelper.CreateEchart("echartID", "/EChartExample/GetEchartDataMapExt5", new string[] { "map" })%>--%>
<%--皮肤切换下拉列表--%>
<%--<%=QMAPP.Common.Web.QMEChart.QMEChartHelper.CreateStyleSelector("themeselectMapExt5")%>--%>
<%--刷新按钮--%>
<%--<%=QMAPP.Common.Web.QMEChart.QMEChartHelper.CreateRefresh()%> --%>
<div id="echartID" style="height:400px">
</div>
<%--<script type='text/javascript'>
var myEChart;
require(['echarts', 'echarts/chart/map'],
function (ec) {
myEChart = ec.init(document.getElementById('echartID'));
var ecConfig = require('echarts/config')
});
</script>
<script type='text/javascript'>
function GetEchartData(url, chartObj) {
$.ajax({
type: 'POST',
url: url,
dataType: 'html',
success: function (data) {
eval("var dataStr=" + data + ";");
chartObj.setOption(dataStr);
}
});
}
</script>--%>
<script type="text/javascript" src="../../Scripts/echarts-2.2.2/doc/asset/js/codemirror.js"></script>
<script type="text/javascript">
//百度地图API功能
function loadJScript() {
var script = document.createElement("script");
script.type = "text/javascript";
script.src = "http://api.map.baidu.com/api?v=2.0&ak=1QGBmNu2FM5UMemBsHGUQu3d";
document.body.appendChild(script);
}
function needMap() {
var href = location.href;
return href.indexOf('Map') != -1 || href.indexOf('mix3') != -1 || href.indexOf('mix5') != -1 || href.indexOf('dataRange') != -1;
}
alert(needMap());
var enVersion = location.hash.indexOf('-en') != -1;
var hash = location.hash.replace('-en', '');
hash = hash.replace('#', '') || (needMap() ? 'default' : 'macarons');
hash += enVersion ? '-en' : '';
var startPoint = {
x: 104.114129,
y: 37.550339
};
var BMapExtension;
var curTheme;
function requireCallback(ec, defaultTheme) {
curTheme = themeSelector ? defaultTheme : {};
echarts = ec;
refresh();
}
function refresh(isBtnRefresh) {
require(['BMap'], function (mapEx) {
BMapExtension = mapEx;
if (isBtnRefresh) {
needRefresh = true;
//focusGraphic();
return;
}
needRefresh = false;
domMessage.innerHTML = '';
(new Function(editor.doc.getValue()))();
});
}
require(
[
'echarts',
'http://echarts.baidu.com/doc/example/theme/' + hash.replace('-en', ''),
needMap() ? 'echarts/chart/map' : 'echarts'
],
requireCallback
);
var domMain = document.getElementById('main');
// 初始化地图
var BMapExt = new BMapExtension(domMain, BMap, require('echarts'), require('zrender'));
</script>
<script type="text/javascript" src="../../Scripts/echarts-2.2.2/extension/BMap/doc/BMap.js"></script>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="ToolContent" runat="server">
</asp:Content>