diff --git a/JSD-4334-高德地图插件功能设计.docx b/JSD-4334-高德地图插件功能设计.docx
new file mode 100644
index 0000000..a185aa4
Binary files /dev/null and b/JSD-4334-高德地图插件功能设计.docx differ
diff --git a/README.md b/README.md
index 26a9fd3..56a183d 100644
--- a/README.md
+++ b/README.md
@@ -1,3 +1,6 @@
# open-JSD-4334
-JSD-4334 GIS地图集成
\ No newline at end of file
+JSD-4334 GIS地图集成 \
+免责说明:该源码为第三方爱好者提供,不保证源码和方案的可靠性,也不提供任何形式的源码教学指导和协助!\
+仅作为开发者学习参考使用!禁止用于任何商业用途!\
+为保护开发者隐私,开发者信息已隐去!若原开发者希望公开自己的信息,可联系hugh处理。
\ No newline at end of file
diff --git a/plugin.xml b/plugin.xml
new file mode 100644
index 0000000..590ca6d
--- /dev/null
+++ b/plugin.xml
@@ -0,0 +1,28 @@
+
+
+ com.fr.plugin.shdcmap
+ com.fr.plugin.shdcmap.v10
+
+ yes
+ 1.1
+ 10.0
+ 2020-04-24
+ fr.open
+ 高德地图功能
]]>
+ [2020-12-08]开发1.0版本]]>
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/com/fr/plugin/shdcmap/CustomChart.java b/src/com/fr/plugin/shdcmap/CustomChart.java
new file mode 100644
index 0000000..4f6582f
--- /dev/null
+++ b/src/com/fr/plugin/shdcmap/CustomChart.java
@@ -0,0 +1,382 @@
+package com.fr.plugin.shdcmap;
+
+import com.fr.chart.chartattr.Chart;
+import com.fr.extended.chart.*;
+import com.fr.general.ComparatorUtils;
+import com.fr.js.NameJavaScript;
+import com.fr.js.NameJavaScriptGroup;
+import com.fr.json.*;
+import com.fr.plugin.shdcmap.data.CustomDataConfig;
+import com.fr.plugin.transform.ExecuteFunctionRecord;
+import com.fr.plugin.transform.FunctionRecorder;
+import com.fr.stable.StringUtils;
+import com.fr.stable.web.Repository;
+import com.fr.stable.xml.XMLPrintWriter;
+import com.fr.stable.xml.XMLableReader;
+import com.fr.web.utils.WebUtils;
+
+import java.util.LinkedHashMap;
+import java.util.List;
+
+/**
+ * @author duan.jingliang
+ */
+@FunctionRecorder
+public class CustomChart extends AbstractChart {
+ private static final String ID = "ShdcGdMapChart";
+ private static final String NAME = "基于高德地图定制";
+
+ private JSONObject mapConf;
+ private JSONObject tipsConf;
+ private JSONArray iconConf;
+ private NameJavaScriptGroup linkNameGroup;
+
+
+ @Override
+ protected String getChartID() {
+ return ID;
+ }
+
+ @Override
+ public String getChartName() {
+ return NAME;
+ }
+
+ @ExecuteFunctionRecord
+ @Override
+ protected void addJSON(CustomDataConfig dataConfig, JSONObject jsonObject, Repository repository, JSONPara jsonPara) throws JSONException {
+ jsonObject.put("data", makeChartData(dataConfig));
+
+ jsonObject.put("mapConf", getMapConf());
+ jsonObject.put("iconConf", getIconConf());
+ jsonObject.put("tipsConf", getTipsConf());
+
+ addAutoLinkJSON(jsonObject, repository, jsonPara);
+
+ // 联动参数
+ String centerx = WebUtils.getHTTPRequestParameter(repository.getHttpServletRequest(), "CENTERLNG");
+ String centery = WebUtils.getHTTPRequestParameter(repository.getHttpServletRequest(), "CENTERLAT");
+ String mapzoom = WebUtils.getHTTPRequestParameter(repository.getHttpServletRequest(), "MAPZOOM");
+
+ JSONObject paramObj = JSONFactory.createJSON(JSON.OBJECT);
+ paramObj.put("centerx", centerx);
+ paramObj.put("centery", centery);
+ paramObj.put("mapzoom", mapzoom);
+ jsonObject.put("linkParam", paramObj);
+ }
+
+ @Override
+ protected String[] requiredJS() {
+ return new String[]{
+ "com/fr/plugin/shdcmap/web/ShdcGdMapWrapper.js"
+ };
+ }
+
+ @Override
+ protected String wrapperName() {
+ return "ShdcGdMapWrapper";
+ }
+
+ @Override
+ protected void readAttr(XMLableReader xmLableReader) {
+ super.readAttr(xmLableReader);
+
+ String jsonStr = xmLableReader.getAttrAsString("mapConf", "");
+ if (StringUtils.isNotEmpty(jsonStr)) {
+ this.setMapConf(new JSONObject(jsonStr));
+ }
+ jsonStr = xmLableReader.getAttrAsString("tipsConf", "");
+ if (StringUtils.isNotEmpty(jsonStr)) {
+ this.setTipsConf(new JSONObject(jsonStr));
+ }
+ jsonStr = xmLableReader.getAttrAsString("iconConf", "");
+ if (StringUtils.isNotEmpty(jsonStr)) {
+ this.setIconConf(new JSONArray(jsonStr));
+ }
+
+ if (null == linkNameGroup) {
+ linkNameGroup = (NameJavaScriptGroup)xmLableReader.readXMLObject(new NameJavaScriptGroup());
+ }
+ }
+
+ @Override
+ protected void writeAttr(XMLPrintWriter xmlPrintWriter) {
+ super.writeAttr(xmlPrintWriter);
+
+ if (null != mapConf) {
+ xmlPrintWriter.attr("mapConf", mapConf.toString());
+ }
+ if (null != tipsConf) {
+ xmlPrintWriter.attr("tipsConf", tipsConf.toString());
+ }
+ if (null != iconConf) {
+ xmlPrintWriter.attr("iconConf", iconConf.toString());
+ }
+ if (null != linkNameGroup) {
+ linkNameGroup.writeXML(xmlPrintWriter);
+ }
+ }
+
+ @Override
+ public boolean equals(Object o) {
+
+ return super.equals(o)
+ && o instanceof Chart
+ && ComparatorUtils.equals(((CustomChart) o).getMapConf(), this.mapConf)
+ && ComparatorUtils.equals(((CustomChart) o).getTipsConf(), this.tipsConf)
+ && ComparatorUtils.equals(((CustomChart) o).getIconConf(), this.iconConf)
+ && ComparatorUtils.equals(((CustomChart) o).getLinkNameGroup(), this.linkNameGroup)
+ ;
+ }
+
+ @Override
+ public Object clone() throws CloneNotSupportedException {
+ CustomChart chart = (CustomChart)super.clone();
+ if (this.linkNameGroup != null) {
+ chart.setLinkNameGroup((NameJavaScriptGroup) this.getLinkNameGroup().clone());
+ }
+ return chart;
+ }
+
+ private void addAutoLinkJSON(JSONObject paramJSONObject, Repository paramRepository, JSONPara paramAbstractChart)
+ throws JSONException {
+ ToHyperlinkJSONHelper.addECNameToLinkGroup(paramAbstractChart.ecName, paramAbstractChart.sheetIndex, this.getLinkNameGroup());
+ paramJSONObject.put("pointLink", ToHyperlinkJSONHelper.addAutoLinkJSON(paramRepository, this.getLinkNameGroup(), hyperLinkParas()));
+ }
+
+ @Override
+ public NameJavaScriptGroup getHotHyperlink(String s) {
+ NameJavaScriptGroup retLinkGroup = new NameJavaScriptGroup();
+ for (int i = 0; i < linkNameGroup.size(); i++) {
+ NameJavaScript hyperlink = linkNameGroup.getNameHyperlink(i);
+ String name = hyperlink.getName();
+ if ("pointLink".equals(s)) {
+ //if (null != name && name.indexOf("地图点") > 0) {
+ try {
+ retLinkGroup.addNameHyperlink((NameJavaScript)hyperlink.clone());
+ } catch (CloneNotSupportedException e) {
+ e.printStackTrace();
+ }
+ //}
+ }
+ }
+ return retLinkGroup;
+ }
+
+ @Override
+ protected HyperLinkPara[] hyperLinkParas() {
+ return new HyperLinkPara[]{
+ new HyperLinkPara() {
+ @Override
+ public String getName() {
+ return "名称";
+ }
+
+ @Override
+ public String getFormulaContent() {
+ return "POINTNAME";
+ }
+
+ @Override
+ public String[] getProps() {
+ return new String[]{"name"};
+ }
+ },
+ new HyperLinkPara() {
+ @Override
+ public String getName() {
+ return "编码";
+ }
+
+ @Override
+ public String getFormulaContent() {
+ return "POINTCODE";
+ }
+
+ @Override
+ public String[] getProps() {
+ return new String[]{"code"};
+ }
+ }
+ };
+ }
+
+ @Override
+ protected List formulas() {
+ return null;
+ }
+
+ @Override
+ protected String demoImagePath() {
+ return "com/fr/plugin/shdcmap/images/demo.png";
+ }
+
+ private JSONArray makeChartData(CustomDataConfig dataConfig) {
+ JSONArray dataArr = JSONFactory.createJSON(JSON.ARRAY);
+ if (null == dataConfig) {
+ return dataArr;
+ }
+
+ List