module.exports =
/******/ (function(modules) { // webpackBootstrap
/******/ 	// The module cache
/******/ 	var installedModules = {};
/******/
/******/ 	// The require function
/******/ 	function __webpack_require__(moduleId) {
/******/
/******/ 		// Check if module is in cache
/******/ 		if(installedModules[moduleId]) {
/******/ 			return installedModules[moduleId].exports;
/******/ 		}
/******/ 		// Create a new module (and put it into the cache)
/******/ 		var module = installedModules[moduleId] = {
/******/ 			i: moduleId,
/******/ 			l: false,
/******/ 			exports: {}
/******/ 		};
/******/
/******/ 		// Execute the module function
/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
/******/
/******/ 		// Flag the module as loaded
/******/ 		module.l = true;
/******/
/******/ 		// Return the exports of the module
/******/ 		return module.exports;
/******/ 	}
/******/
/******/
/******/ 	// expose the modules object (__webpack_modules__)
/******/ 	__webpack_require__.m = modules;
/******/
/******/ 	// expose the module cache
/******/ 	__webpack_require__.c = installedModules;
/******/
/******/ 	// define getter function for harmony exports
/******/ 	__webpack_require__.d = function(exports, name, getter) {
/******/ 		if(!__webpack_require__.o(exports, name)) {
/******/ 			Object.defineProperty(exports, name, { enumerable: true, get: getter });
/******/ 		}
/******/ 	};
/******/
/******/ 	// define __esModule on exports
/******/ 	__webpack_require__.r = function(exports) {
/******/ 		if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
/******/ 			Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
/******/ 		}
/******/ 		Object.defineProperty(exports, '__esModule', { value: true });
/******/ 	};
/******/
/******/ 	// create a fake namespace object
/******/ 	// mode & 1: value is a module id, require it
/******/ 	// mode & 2: merge all properties of value into the ns
/******/ 	// mode & 4: return value when already ns object
/******/ 	// mode & 8|1: behave like require
/******/ 	__webpack_require__.t = function(value, mode) {
/******/ 		if(mode & 1) value = __webpack_require__(value);
/******/ 		if(mode & 8) return value;
/******/ 		if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;
/******/ 		var ns = Object.create(null);
/******/ 		__webpack_require__.r(ns);
/******/ 		Object.defineProperty(ns, 'default', { enumerable: true, value: value });
/******/ 		if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));
/******/ 		return ns;
/******/ 	};
/******/
/******/ 	// getDefaultExport function for compatibility with non-harmony modules
/******/ 	__webpack_require__.n = function(module) {
/******/ 		var getter = module && module.__esModule ?
/******/ 			function getDefault() { return module['default']; } :
/******/ 			function getModuleExports() { return module; };
/******/ 		__webpack_require__.d(getter, 'a', getter);
/******/ 		return getter;
/******/ 	};
/******/
/******/ 	// Object.prototype.hasOwnProperty.call
/******/ 	__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
/******/
/******/ 	// __webpack_public_path__
/******/ 	__webpack_require__.p = "lib/mapboxgl/";
/******/
/******/
/******/ 	// Load entry module and return exports
/******/ 	return __webpack_require__(__webpack_require__.s = 691);
/******/ })
/************************************************************************/
/******/ ({

/***/ 0:
/***/ (function(module, exports) {

module.exports = require("@babel/runtime/helpers/interopRequireDefault");

/***/ }),

/***/ 1:
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return normalizeComponent; });
/* globals __VUE_SSR_CONTEXT__ */

// IMPORTANT: Do NOT use ES2015 features in this file (except for modules).
// This module is a runtime utility for cleaner component module output and will
// be included in the final webpack user bundle.

function normalizeComponent(
  scriptExports,
  render,
  staticRenderFns,
  functionalTemplate,
  injectStyles,
  scopeId,
  moduleIdentifier /* server only */,
  shadowMode /* vue-cli only */
) {
  // Vue.extend constructor export interop
  var options =
    typeof scriptExports === 'function' ? scriptExports.options : scriptExports

  // render functions
  if (render) {
    options.render = render
    options.staticRenderFns = staticRenderFns
    options._compiled = true
  }

  // functional template
  if (functionalTemplate) {
    options.functional = true
  }

  // scopedId
  if (scopeId) {
    options._scopeId = 'data-v-' + scopeId
  }

  var hook
  if (moduleIdentifier) {
    // server build
    hook = function (context) {
      // 2.3 injection
      context =
        context || // cached call
        (this.$vnode && this.$vnode.ssrContext) || // stateful
        (this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext) // functional
      // 2.2 with runInNewContext: true
      if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {
        context = __VUE_SSR_CONTEXT__
      }
      // inject component styles
      if (injectStyles) {
        injectStyles.call(this, context)
      }
      // register component module identifier for async chunk inferrence
      if (context && context._registeredComponents) {
        context._registeredComponents.add(moduleIdentifier)
      }
    }
    // used by ssr in case component is cached and beforeCreate
    // never gets called
    options._ssrRegister = hook
  } else if (injectStyles) {
    hook = shadowMode
      ? function () {
          injectStyles.call(
            this,
            (options.functional ? this.parent : this).$root.$options.shadowRoot
          )
        }
      : injectStyles
  }

  if (hook) {
    if (options.functional) {
      // for template-only hot-reload because in that case the render fn doesn't
      // go through the normalizer
      options._injectStyles = hook
      // register for functional component in vue file
      var originalRender = options.render
      options.render = function renderWithStyleInjection(h, context) {
        hook.call(context)
        return originalRender(h, context)
      }
    } else {
      // inject component registration as beforeCreate hook
      var existing = options.beforeCreate
      options.beforeCreate = existing ? [].concat(existing, hook) : [hook]
    }
  }

  return {
    exports: scriptExports,
    options: options
  }
}


/***/ }),

/***/ 10:
/***/ (function(module, exports) {

module.exports = require("lodash.isplainobject");

/***/ }),

/***/ 11:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/_utils/vue-types/utils.js");

/***/ }),

/***/ 111:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/table-popup");

/***/ }),

/***/ 112:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/select");

/***/ }),

/***/ 12:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/_utils/util.js");

/***/ }),

/***/ 15:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/static/libs/iclient-mapboxgl/iclient-mapboxgl.min.js");

/***/ }),

/***/ 16:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/_lang/index.js");

/***/ }),

/***/ 17:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/_mixin/control.js");

/***/ }),

/***/ 18:
/***/ (function(module, exports) {

module.exports = require("@babel/runtime/helpers/extends");

/***/ }),

/***/ 2:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/init.js");

/***/ }),

/***/ 22:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/_mixin/Card.js");

/***/ }),

/***/ 23:
/***/ (function(module, exports) {

module.exports = require("lodash.isequal");

/***/ }),

/***/ 26:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/message");

/***/ }),

/***/ 27:
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _node_modules_babel_loader_lib_index_js_node_modules_ts_loader_index_js_ref_0_1_node_modules_vue_loader_lib_index_js_vue_loader_options_Option_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(28);
/* harmony import */ var _node_modules_babel_loader_lib_index_js_node_modules_ts_loader_index_js_ref_0_1_node_modules_vue_loader_lib_index_js_vue_loader_options_Option_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_babel_loader_lib_index_js_node_modules_ts_loader_index_js_ref_0_1_node_modules_vue_loader_lib_index_js_vue_loader_options_Option_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0__);
/* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _node_modules_babel_loader_lib_index_js_node_modules_ts_loader_index_js_ref_0_1_node_modules_vue_loader_lib_index_js_vue_loader_options_Option_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0__) if(["default"].indexOf(__WEBPACK_IMPORT_KEY__) < 0) (function(key) { __webpack_require__.d(__webpack_exports__, key, function() { return _node_modules_babel_loader_lib_index_js_node_modules_ts_loader_index_js_ref_0_1_node_modules_vue_loader_lib_index_js_vue_loader_options_Option_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0__[key]; }) }(__WEBPACK_IMPORT_KEY__));
 /* harmony default export */ __webpack_exports__["default"] = (_node_modules_babel_loader_lib_index_js_node_modules_ts_loader_index_js_ref_0_1_node_modules_vue_loader_lib_index_js_vue_loader_options_Option_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0___default.a); 

/***/ }),

/***/ 28:
/***/ (function(module, exports, __webpack_require__) {

"use strict";


var _interopRequireDefault = __webpack_require__(0);
Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.optionTypes = exports.default = void 0;
var _select = _interopRequireDefault(__webpack_require__(51));
var _vueTypes = _interopRequireDefault(__webpack_require__(8));
var _Theme = _interopRequireDefault(__webpack_require__(4));
var _AntdRender = _interopRequireDefault(__webpack_require__(6));
var optionTypes = exports.optionTypes = {
  disabled: _vueTypes.default.bool,
  key: _vueTypes.default.string,
  title: _vueTypes.default.string,
  value: _vueTypes.default.oneOfType([_vueTypes.default.string, _vueTypes.default.number])
};
var _default = exports.default = {
  name: 'SmSelectOption',
  isSelectOption: true,
  defaultComponent: _select.default.Option,
  mixins: [_Theme.default, _AntdRender.default],
  inheritAttrs: false,
  props: optionTypes
};

/***/ }),

/***/ 282:
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _node_modules_babel_loader_lib_index_js_node_modules_vue_loader_lib_index_js_vue_loader_options_Query_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(283);
/* harmony import */ var _node_modules_babel_loader_lib_index_js_node_modules_vue_loader_lib_index_js_vue_loader_options_Query_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_babel_loader_lib_index_js_node_modules_vue_loader_lib_index_js_vue_loader_options_Query_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__);
/* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _node_modules_babel_loader_lib_index_js_node_modules_vue_loader_lib_index_js_vue_loader_options_Query_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__) if(["default"].indexOf(__WEBPACK_IMPORT_KEY__) < 0) (function(key) { __webpack_require__.d(__webpack_exports__, key, function() { return _node_modules_babel_loader_lib_index_js_node_modules_vue_loader_lib_index_js_vue_loader_options_Query_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0__[key]; }) }(__WEBPACK_IMPORT_KEY__));
 /* harmony default export */ __webpack_exports__["default"] = (_node_modules_babel_loader_lib_index_js_node_modules_vue_loader_lib_index_js_vue_loader_options_Query_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_0___default.a); 

/***/ }),

/***/ 283:
/***/ (function(module, exports, __webpack_require__) {

"use strict";


var _interopRequireDefault = __webpack_require__(0);
Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = void 0;
var _extends2 = _interopRequireDefault(__webpack_require__(18));
var _Theme = _interopRequireDefault(__webpack_require__(4));
var _control = _interopRequireDefault(__webpack_require__(17));
var _Card = _interopRequireDefault(__webpack_require__(22));
var _mapGetter = _interopRequireDefault(__webpack_require__(7));
var _LineStyle = _interopRequireDefault(__webpack_require__(41));
var _FillStyle = _interopRequireDefault(__webpack_require__(40));
var _CircleStyle = _interopRequireDefault(__webpack_require__(33));
var _QueryViewModel = _interopRequireDefault(__webpack_require__(693));
var _Select = _interopRequireDefault(__webpack_require__(112));
var _Option = _interopRequireDefault(__webpack_require__(84));
var _Button = _interopRequireDefault(__webpack_require__(39));
var _Empty = _interopRequireDefault(__webpack_require__(399));
var _Spin = _interopRequireDefault(__webpack_require__(35));
var _Icon = _interopRequireDefault(__webpack_require__(53));
var _Message = _interopRequireDefault(__webpack_require__(26));
var _TablePopup = _interopRequireDefault(__webpack_require__(111));
var _util = __webpack_require__(12);
var _lodash = _interopRequireDefault(__webpack_require__(23));
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
var _default2 = exports.default = {
  name: 'SmQuery',
  components: {
    SmSelect: _Select.default,
    SmSelectOption: _Option.default,
    SmButton: _Button.default,
    SmEmpty: _Empty.default,
    SmSpin: _Spin.default,
    SmIcon: _Icon.default,
    TablePopup: _TablePopup.default
  },
  mixins: [_mapGetter.default, _control.default, _Theme.default, _Card.default],
  props: {
    iconClass: {
      type: String,
      default: 'sm-components-icon-search-list'
    },
    headerName: {
      type: String,
      default: function _default() {
        return this.$t('query.query');
      }
    },
    maxFeatures: {
      type: Number,
      default: 200
    },
    layerStyle: {
      type: Object,
      default: function _default() {
        return {
          line: new _LineStyle.default({
            'line-width': 3,
            'line-color': '#409eff',
            'line-opacity': 1
          }),
          circle: new _CircleStyle.default({
            'circle-color': '#409eff',
            'circle-opacity': 0.6,
            'circle-radius': 8,
            'circle-stroke-width': 2,
            'circle-stroke-color': '#409eff',
            'circle-stroke-opacity': 1
          }),
          fill: new _FillStyle.default({
            'fill-color': '#409eff',
            'fill-opacity': 0.6,
            'fill-outline-color': '#409eff'
          }),
          stokeLine: new _LineStyle.default({
            'line-width': 3,
            'line-color': '#409eff',
            'line-opacity': 1
          })
        };
      }
    },
    iportalData: {
      type: Array
    },
    restData: {
      type: Array
    },
    restMap: {
      type: Array
    }
  },
  data: function data() {
    return {
      isHidden: false,
      message: null,
      selectOptions: [{
        label: this.$t('query.currentMapBounds'),
        value: 'currentMapBounds'
      }, {
        label: this.$t('query.mapBounds'),
        value: 'mapBounds'
      }],
      queryResult: null,
      activeTab: 'job',
      activePanelIndex: null,
      activeResultIndex: null,
      isQuery: false,
      jobInfos: [],
      tablePopupProps: {}
    };
  },
  watch: {
    iportalData: function iportalData(newVal, oldVal) {
      if (!(0, _lodash.default)(newVal, oldVal)) {
        this.clearResult();
        this.formatJobInfos();
      }
    },
    restData: function restData(newVal, oldVal) {
      if (!(0, _lodash.default)(newVal, oldVal)) {
        this.clearResult();
        this.formatJobInfos();
      }
    },
    restMap: function restMap(newVal, oldVal) {
      if (!(0, _lodash.default)(newVal, oldVal)) {
        this.clearResult();
        this.formatJobInfos();
      }
    },
    layerStyle: function layerStyle() {
      this.viewModel && (this.viewModel.layerStyle = this.$props.layerStyle);
    }
  },
  mounted: function mounted() {
    this.formatJobInfos();
    this.registerEvents();
  },
  loaded: function loaded() {
    this.clear();
  },
  created: function created() {
    this.viewModel = new _QueryViewModel.default(this.$props);
  },
  removed: function removed() {
    this.queryResult = null;
    this.jobInfo = null;
    this.activeTab = 'job';
    this.popup && this.popup.remove() && (this.popup = null);
  },
  methods: {
    clear: function clear() {
      this.queryResult = null;
      this.map && this.viewModel && this.viewModel.clearResultLayer();
      this.popup && this.popup.remove() && (this.popup = null);
    },
    formatJobInfos: function formatJobInfos() {
      var _this = this;
      if (this.viewModel) {
        this.jobInfos = [];
        Object.keys(this.$props).forEach(function (key) {
          if (key === 'iportalData' || key === 'restData' || key === 'restMap') {
            _this.$props[key] && _this.$props[key].forEach(function (item) {
              item.name && _this.jobInfos.push({
                spaceFilter: 'currentMapBounds',
                queryParameter: item
              });
            }, _this);
          }
        }, this);
      }
    },
    queryButtonClicked: function queryButtonClicked(jobInfo, value) {
      // @ts-ignore
      _Message.default.destroy();
      if (this.jobInfo === jobInfo && this.selectValue === value && this.queryResult) {
        // @ts-ignore
        _Message.default.warning(this.$t('query.resultAlreadyExists'));
        return;
      }
      this.queryResult = null;
      this.popup && this.popup.remove() && (this.popup = null);
      this.isQuery = true;
      this.activeTab = 'result';
      this.jobInfo = jobInfo;
      this.selectValue = value;
      this.query(this.jobInfo, this.selectValue);
    },
    /**
     * 开始查询。
     * @param {iPortalDataParameter|RestDataParameter|RestMapParameter} parameter - 查询配置参数。
     * @param {String} [bounds='mapBounds'] - 查询范围，可选值为 mapBounds（地图全图范围），currentMapBounds（当前地图范围）。
     */
    query: function query(parameter, bounds) {
      this.viewModel.query(parameter, bounds);
    },
    queryResultListClicked: function queryResultListClicked(e, index) {
      this.activeResultIndex = index;
      this.popup && this.popup.remove() && (this.popup = null);
      var filter = e.target.innerHTML;
      var feature = this.viewModel.getFilterFeature(filter.split('：')[1].trim());
      this.addPopup(feature);
    },
    registerEvents: function registerEvents() {
      var _this2 = this;
      this.viewModel.on('querysucceeded', function (e) {
        _this2.isQuery = false;
        _this2.queryResult = e.result;
        /**
         * @event querySucceeded
         * @desc 查询成功后触发。
         * @property {Object} e  - 事件对象。
         */
        _this2.$emit('query-succeeded', e);
      });
      this.viewModel.on('queryfailed', function (e) {
        _this2.isQuery = false;
        _this2.clearResult();
        // @ts-ignore
        _Message.default.warning(e.message.toString());
        /**
         * @event queryFailed
         * @desc 查询失败后触发。
         * @property {Object} e  - 事件对象。
         */
        _this2.$emit('query-failed', e);
      });
      this.addPopupToFeature();
    },
    addPopupToFeature: function addPopupToFeature() {
      var _this3 = this;
      this.viewModel.on('getfeatureinfosucceeded', function (e) {
        var featuerInfo = e.featureInfo;
        _this3.addPopup(featuerInfo);
      });
    },
    addPopup: function addPopup(featuerInfo) {
      var _this4 = this;
      this.popup && this.popup.remove() && (this.popup = null);
      if (featuerInfo.info.length >= 1) {
        var state = {
          columns: [{
            title: this.$t('query.attribute'),
            dataIndex: 'attribute',
            width: 80
          }, {
            title: this.$t('query.attributeValue'),
            dataIndex: 'attributeValue',
            width: 150
          }],
          data: featuerInfo.info
        };
        this.tablePopupProps = (0, _extends2.default)({}, state);
        this.$nextTick(function () {
          _this4.popup = _this4.viewModel.addPopup(featuerInfo.coordinates, _this4.$refs.queryTablePopup.$el);
          (0, _util.setPopupArrowStyle)(_this4.tablePopupBgData);
        });
      }
    },
    getPopupContainer: function getPopupContainer(triggerNode) {
      return triggerNode.parentNode;
    },
    clearResult: function clearResult() {
      this.queryResult = null;
      this.popup && this.popup.remove() && (this.popup = null);
      this.jobInfo = null;
      this.activeResultIndex = null;
      this.viewModel && this.viewModel.removed();
    },
    getInfoOfSmid: function getInfoOfSmid(properties) {
      return "SmID\uFF1A" + (0, _util.getValueCaseInsensitive)(properties, 'smid');
    }
  }
};

/***/ }),

/***/ 3:
/***/ (function(module, exports) {

module.exports = require("@babel/runtime/helpers/inheritsLoose");

/***/ }),

/***/ 33:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/_types/CircleStyle.js");

/***/ }),

/***/ 34:
/***/ (function(module, exports) {

module.exports = require("@turf/bbox");

/***/ }),

/***/ 35:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/spin");

/***/ }),

/***/ 36:
/***/ (function(module, exports) {

module.exports = require("@babel/runtime/regenerator");

/***/ }),

/***/ 39:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/button");

/***/ }),

/***/ 398:
/***/ (function(module, exports) {

module.exports = require("@babel/runtime/helpers/asyncToGenerator");

/***/ }),

/***/ 399:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/empty");

/***/ }),

/***/ 4:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/_mixin/Theme.js");

/***/ }),

/***/ 40:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/_types/FillStyle.js");

/***/ }),

/***/ 41:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/_types/LineStyle.js");

/***/ }),

/***/ 42:
/***/ (function(module, exports) {

module.exports = require("@turf/transform-scale");

/***/ }),

/***/ 446:
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";

// EXPORTS
__webpack_require__.d(__webpack_exports__, "a", function() { return /* reexport */ render; });
__webpack_require__.d(__webpack_exports__, "b", function() { return /* reexport */ staticRenderFns; });

// CONCATENATED MODULE: ./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/vue-loader/lib??vue-loader-options!./src/mapboxgl/query/Query.vue?vue&type=template&id=2d552703&
var render = function () {
  var _vm = this
  var _h = _vm.$createElement
  var _c = _vm._self._c || _h
  return _c(
    "sm-collapse-card",
    {
      directives: [
        {
          name: "show",
          rawName: "v-show",
          value: _vm.isShow,
          expression: "isShow",
        },
      ],
      staticClass: "sm-component-query",
      attrs: {
        "icon-class": _vm.iconClass,
        "icon-position": _vm.position,
        "header-name": _vm.headerName,
        "auto-rotate": _vm.autoRotate,
        collapsed: _vm.collapsed,
        background: _vm.background,
        textColor: _vm.textColor,
        "split-line": _vm.splitLine,
      },
    },
    [
      _c(
        "div",
        {
          staticClass: "sm-component-query__body",
          style: _vm.getTextColorStyle,
        },
        [
          _c(
            "div",
            { staticClass: "sm-component-query__choose-panel clearfix" },
            [
              _c(
                "div",
                {
                  class: {
                    "sm-component-query__job-button": true,
                    "is-active": _vm.activeTab === "job",
                    disabled: _vm.isQuery,
                  },
                  attrs: { title: _vm.$t("query.queryJob") },
                  on: {
                    click: function ($event) {
                      _vm.activeTab = "job"
                    },
                  },
                },
                [
                  _vm._v(
                    "\n        " + _vm._s(_vm.$t("query.queryJob")) + "\n      "
                  ),
                ]
              ),
              _c(
                "div",
                {
                  class: {
                    "sm-component-query__result-button": true,
                    "is-active": _vm.activeTab === "result",
                  },
                  attrs: { title: _vm.$t("query.queryResult") },
                  on: {
                    click: function ($event) {
                      _vm.activeTab = "result"
                    },
                  },
                },
                [
                  _vm._v(
                    "\n        " +
                      _vm._s(_vm.$t("query.queryResult")) +
                      "\n      "
                  ),
                ]
              ),
            ]
          ),
          _vm.activeTab === "job"
            ? _c(
                "div",
                { staticClass: "sm-component-query__job-info" },
                _vm._l(_vm.jobInfos, function (jobInfo, index) {
                  return _c(
                    "div",
                    {
                      directives: [
                        {
                          name: "show",
                          rawName: "v-show",
                          value: _vm.jobInfos.length > 0,
                          expression: "jobInfos.length > 0",
                        },
                      ],
                      key: index,
                      staticClass: "sm-component-query__job-info-panel",
                      style: _vm.headingTextColorStyle,
                    },
                    [
                      _c(
                        "div",
                        {
                          staticClass: "sm-component-query__job-info-header",
                          on: {
                            click: function ($event) {
                              _vm.activePanelIndex =
                                _vm.activePanelIndex === index ? null : index
                            },
                          },
                        },
                        [
                          _c(
                            "span",
                            {
                              staticClass: "sm-component-query__job-info-name",
                              attrs: { title: jobInfo.queryParameter.name },
                            },
                            [_vm._v(_vm._s(jobInfo.queryParameter.name))]
                          ),
                          _c("i", {
                            class:
                              _vm.activePanelIndex !== index
                                ? "sm-components-icon-solid-triangle-right"
                                : "sm-components-icon-solid-triangle-down",
                          }),
                        ]
                      ),
                      jobInfo.queryParameter.attributeFilter
                        ? _c(
                            "div",
                            {
                              class: {
                                "sm-component-query__job-info-body": true,
                                hidden: _vm.activePanelIndex !== index,
                              },
                            },
                            [
                              _c(
                                "div",
                                {
                                  staticClass: "sm-component-query__attribute",
                                },
                                [
                                  _c("div", [
                                    _vm._v(
                                      _vm._s(_vm.$t("query.attributeCondition"))
                                    ),
                                  ]),
                                  _c(
                                    "div",
                                    {
                                      staticClass:
                                        "sm-component-query__attribute-name",
                                    },
                                    [
                                      _vm._v(
                                        "\n              " +
                                          _vm._s(
                                            jobInfo.queryParameter
                                              .attributeFilter
                                          ) +
                                          "\n            "
                                      ),
                                    ]
                                  ),
                                ]
                              ),
                              _c(
                                "div",
                                {
                                  staticClass:
                                    "sm-component-query__spatial-filter",
                                },
                                [
                                  _c("div", [
                                    _vm._v(
                                      _vm._s(_vm.$t("query.spatialFilter"))
                                    ),
                                  ]),
                                  _c(
                                    "sm-select",
                                    {
                                      staticClass:
                                        "sm-component-query__a-select",
                                      style: _vm.getTextColorStyle,
                                      attrs: {
                                        "get-popup-container":
                                          _vm.getPopupContainer,
                                      },
                                      model: {
                                        value: jobInfo.spaceFilter,
                                        callback: function ($$v) {
                                          _vm.$set(jobInfo, "spaceFilter", $$v)
                                        },
                                        expression: "jobInfo.spaceFilter",
                                      },
                                    },
                                    _vm._l(_vm.selectOptions, function (item) {
                                      return _c(
                                        "sm-select-option",
                                        {
                                          key: item.value,
                                          attrs: { value: item.value },
                                        },
                                        [
                                          _vm._v(
                                            "\n                " +
                                              _vm._s(item.label) +
                                              "\n              "
                                          ),
                                        ]
                                      )
                                    }),
                                    1
                                  ),
                                ],
                                1
                              ),
                              _c(
                                "div",
                                {
                                  staticClass:
                                    "sm-component-query__query-button",
                                },
                                [
                                  _c(
                                    "sm-button",
                                    {
                                      staticClass:
                                        "sm-component-query__a-button",
                                      attrs: { type: "primary", size: "small" },
                                      on: {
                                        click: function ($event) {
                                          return _vm.queryButtonClicked(
                                            jobInfo.queryParameter,
                                            jobInfo.spaceFilter
                                          )
                                        },
                                      },
                                    },
                                    [
                                      _vm._v(
                                        "\n              " +
                                          _vm._s(_vm.$t("query.applicate")) +
                                          "\n            "
                                      ),
                                    ]
                                  ),
                                ],
                                1
                              ),
                            ]
                          )
                        : _vm._e(),
                    ]
                  )
                }),
                0
              )
            : _c(
                "div",
                { staticClass: "sm-component-query__result-info" },
                [
                  _c(
                    "div",
                    {
                      directives: [
                        {
                          name: "show",
                          rawName: "v-show",
                          value: !_vm.queryResult && !_vm.isQuery,
                          expression: "!queryResult && !isQuery",
                        },
                      ],
                      staticClass: "sm-component-query__no-result",
                    },
                    [
                      _c("sm-empty", {
                        attrs: { description: _vm.$t("query.noResult") },
                      }),
                    ],
                    1
                  ),
                  _c(
                    "div",
                    {
                      directives: [
                        {
                          name: "show",
                          rawName: "v-show",
                          value: _vm.isQuery && !_vm.queryResult,
                          expression: "isQuery && !queryResult",
                        },
                      ],
                      staticClass: "sm-component-query__result-loading",
                    },
                    [
                      _c(
                        "sm-spin",
                        { attrs: { tip: _vm.$t("query.querying") } },
                        [
                          _c("sm-icon", {
                            staticStyle: { "font-size": "24px" },
                            attrs: {
                              slot: "indicator",
                              type: "loading",
                              spin: "",
                            },
                            slot: "indicator",
                          }),
                        ],
                        1
                      ),
                    ],
                    1
                  ),
                  _vm.queryResult
                    ? [
                        _c(
                          "div",
                          {
                            staticClass: "sm-component-query__result-header",
                            style: _vm.headingTextColorStyle,
                          },
                          [
                            _c(
                              "span",
                              {
                                staticClass: "sm-component-query__header-name",
                                attrs: { title: _vm.queryResult.name },
                              },
                              [_vm._v(_vm._s(_vm.queryResult.name))]
                            ),
                            _c("i", {
                              staticClass: "sm-components-icon-delete",
                              on: { click: _vm.clearResult },
                            }),
                          ]
                        ),
                        _c(
                          "div",
                          { staticClass: "sm-component-query__result-body" },
                          [
                            _c(
                              "ul",
                              _vm._l(
                                _vm.queryResult.result,
                                function (item, index) {
                                  return _c(
                                    "li",
                                    {
                                      key: index,
                                      attrs: {
                                        title: _vm.getInfoOfSmid(
                                          item.properties
                                        ),
                                        role: "option",
                                        "aria-selected":
                                          _vm.activeResultIndex === index,
                                      },
                                      on: {
                                        click: function ($event) {
                                          return _vm.queryResultListClicked(
                                            $event,
                                            index
                                          )
                                        },
                                      },
                                    },
                                    [
                                      _vm._v(
                                        "\n              " +
                                          _vm._s(
                                            _vm.getInfoOfSmid(item.properties)
                                          ) +
                                          "\n            "
                                      ),
                                    ]
                                  )
                                }
                              ),
                              0
                            ),
                          ]
                        ),
                      ]
                    : _vm._e(),
                ],
                2
              ),
        ]
      ),
      _c(
        "TablePopup",
        _vm._b(
          {
            directives: [
              {
                name: "show",
                rawName: "v-show",
                value: false,
                expression: "false",
              },
            ],
            ref: "queryTablePopup",
            attrs: {
              "split-line": _vm.splitLine,
              textColor: _vm.textColor,
              background: _vm.background,
            },
          },
          "TablePopup",
          _vm.tablePopupProps,
          false
        )
      ),
    ],
    1
  )
}
var staticRenderFns = []
render._withStripped = true


// CONCATENATED MODULE: ./src/mapboxgl/query/Query.vue?vue&type=template&id=2d552703&


/***/ }),

/***/ 5:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/static/libs/mapboxgl/mapbox-gl-enhance.js");

/***/ }),

/***/ 51:
/***/ (function(module, exports) {

module.exports = require("ant-design-vue/es/select");

/***/ }),

/***/ 53:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/icon");

/***/ }),

/***/ 6:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/_mixin/AntdRender.js");

/***/ }),

/***/ 691:
/***/ (function(module, exports, __webpack_require__) {

"use strict";


var _interopRequireDefault = __webpack_require__(0);
Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = void 0;
var _Query = _interopRequireDefault(__webpack_require__(692));
var _init = _interopRequireDefault(__webpack_require__(2));
_Query.default.install = function (Vue, opts) {
  (0, _init.default)(Vue, opts);
  Vue.component(_Query.default.options ? _Query.default.options.name : _Query.default.name, _Query.default);
};
var _default = exports.default = _Query.default;

/***/ }),

/***/ 692:
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _Query_vue_vue_type_template_id_2d552703___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(446);
/* harmony import */ var _Query_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(282);
/* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _Query_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__) if(["default"].indexOf(__WEBPACK_IMPORT_KEY__) < 0) (function(key) { __webpack_require__.d(__webpack_exports__, key, function() { return _Query_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__[key]; }) }(__WEBPACK_IMPORT_KEY__));
/* harmony import */ var _node_modules_vue_loader_lib_runtime_componentNormalizer_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(1);





/* normalize component */

var component = Object(_node_modules_vue_loader_lib_runtime_componentNormalizer_js__WEBPACK_IMPORTED_MODULE_2__[/* default */ "a"])(
  _Query_vue_vue_type_script_lang_js___WEBPACK_IMPORTED_MODULE_1__["default"],
  _Query_vue_vue_type_template_id_2d552703___WEBPACK_IMPORTED_MODULE_0__[/* render */ "a"],
  _Query_vue_vue_type_template_id_2d552703___WEBPACK_IMPORTED_MODULE_0__[/* staticRenderFns */ "b"],
  false,
  null,
  null,
  null
  
)

/* harmony default export */ __webpack_exports__["default"] = (component.exports);

/***/ }),

/***/ 693:
/***/ (function(module, exports, __webpack_require__) {

"use strict";


var _interopRequireDefault = __webpack_require__(0);
Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = void 0;
var _regenerator = _interopRequireDefault(__webpack_require__(36));
var _asyncToGenerator2 = _interopRequireDefault(__webpack_require__(398));
var _inheritsLoose2 = _interopRequireDefault(__webpack_require__(3));
var _mapboxGlEnhance = _interopRequireDefault(__webpack_require__(5));
var _index = __webpack_require__(16);
__webpack_require__(15);
var _util = __webpack_require__(12);
var _bbox = _interopRequireDefault(__webpack_require__(34));
var _envelope = _interopRequireDefault(__webpack_require__(87));
var _transformScale = _interopRequireDefault(__webpack_require__(42));
/**
 * @class QueryViewModel
 * @classdesc 查询组件功能类。
 * @category ViewModel
 * @param {Object} map - map 对象。
 * @param {Object} options - 可选参数。
 * @param {Object} [options.maxFeatures=200] - 查询最大返回要素个数。
 * @param {Object} [options.layerStyle] - 查询结果图层样式配置。
 * @param {Object} [options.layerStyle.line] - 线图层样式配置。
 * @param {Object} [options.layerStyle.circle] - 点图层样式配置。
 * @param {Object} [options.layerStyle.fill] - 面图层样式配置。
 * @param {Object} [options.layerStyle.stokeLine] - 面图层样式配置。
 * @extends mapboxgl.Evented
 * @fires QueryViewModel#querysucceeded
 * @fires QueryViewModel#queryfailed
 * @fires QueryViewModel#getfeatureinfosucceeded
 */
var QueryViewModel = exports.default = /*#__PURE__*/function (_mapboxgl$Evented) {
  (0, _inheritsLoose2.default)(QueryViewModel, _mapboxgl$Evented);
  function QueryViewModel(options) {
    var _this;
    _this = _mapboxgl$Evented.call(this) || this;
    _this.options = options || {};
    _this.maxFeatures = _this.options.maxFeatures || 200;
    _this.layerStyle = options.layerStyle || {};
    return _this;
  }
  var _proto = QueryViewModel.prototype;
  _proto.setMap = function setMap(mapInfo) {
    var map = mapInfo.map;
    this.map = map;
  };
  _proto.clearResultLayer = function clearResultLayer() {
    if (this.map) {
      this.strokeLayerID && this.map.getLayer(this.strokeLayerID) && this.map.removeLayer(this.strokeLayerID);
      this.layerID && this.map.getLayer(this.layerID) && this.map.removeLayer(this.layerID);
    }
  };
  _proto.removed = function removed() {
    this.bounds = null;
    this.clearResultLayer();
  }

  /**
   * @function QueryViewModel.prototype.query
   * @desc 开始查询。
   * @param {iPortalDataParameter|RestDataParameter|RestMapParameter} parameter - 查询配置参数。
   * @param {String} [queryBounds='mapBounds'] - 查询范围，可选值为 mapBounds（地图全图范围），currentMapBounds（当前地图范围）。
   */;
  _proto.query = function query(queryParameter, queryBounds) {
    if (!this.map) {
      return;
    }
    this.queryParameter = queryParameter;
    this.removed();
    this.queryBounds = queryBounds;
    if (queryBounds === 'currentMapBounds') {
      this.bounds = this.map.getBounds();
    }
    this.queryResult = null;
    if (queryParameter) {
      if (queryParameter.dataName) {
        this._queryByRestData(queryParameter);
      } else if (queryParameter.layerName) {
        this._queryByRestMap(queryParameter);
      } else {
        this._queryByIportalData(queryParameter);
      }
    }
    // if (queryParameter instanceof iPortalDataParameter) {
    //   this._queryByIportalData(queryParameter);
    // } else if (queryParameter instanceof RestDataParameter) {
    //   this._queryByRestData(queryParameter);
    // } else if (queryParameter instanceof RestMapParameter) {
    //   this._queryByRestMap(queryParameter);
    // }
  };
  _proto._queryByRestMap = function _queryByRestMap(restMapParameter) {
    var _this2 = this;
    var options = {
      withCredentials: restMapParameter.withCredentials || false
    };
    if (restMapParameter.proxy) {
      options.proxy = restMapParameter.proxy;
    }
    if (this.bounds) {
      var param = new SuperMap.QueryByGeometryParameters({
        queryParams: {
          name: restMapParameter.layerName,
          attributeFilter: restMapParameter.attributeFilter
        },
        prjCoordSys: {
          epsgCode: 4326
        },
        spatialQueryMode: SuperMap.SpatialQueryMode.INTERSECT,
        geometry: this.bounds,
        startRecord: 0,
        expectCount: restMapParameter.maxFeatures || this.maxFeatures
      });
      new _mapboxGlEnhance.default.supermap.QueryService(restMapParameter.url, options).queryByGeometry(param, function (serviceResult) {
        _this2._mapQuerySucceed(serviceResult, restMapParameter, options);
      });
    } else {
      var _param = new SuperMap.QueryBySQLParameters({
        queryParams: {
          name: restMapParameter.layerName,
          attributeFilter: restMapParameter.attributeFilter
        },
        prjCoordSys: {
          epsgCode: 4326
        },
        startRecord: 0,
        expectCount: restMapParameter.maxFeatures || this.maxFeatures
      });
      new _mapboxGlEnhance.default.supermap.QueryService(restMapParameter.url, options).queryBySQL(_param, function (serviceResult) {
        _this2._mapQuerySucceed(serviceResult, restMapParameter, options);
      });
    }
  };
  _proto._queryByRestData = function _queryByRestData(restDataParameter) {
    var _this3 = this;
    var maxFeatures = restDataParameter.maxFeatures || this.maxFeatures;
    var toIndex = maxFeatures === 1 ? 0 : maxFeatures - 1;
    var options = {
      withCredentials: restDataParameter.withCredentials || false
    };
    if (restDataParameter.proxy) {
      options.proxy = restDataParameter.proxy;
    }
    if (this.bounds) {
      var boundsParam = new SuperMap.GetFeaturesByBoundsParameters({
        attributeFilter: restDataParameter.attributeFilter,
        datasetNames: restDataParameter.dataName,
        spatialQueryMode: 'INTERSECT',
        geometry: this.bounds,
        targetPrj: {
          epsgCode: 4326
        },
        fromIndex: 0,
        toIndex: toIndex
      });
      new _mapboxGlEnhance.default.supermap.FeatureService(restDataParameter.url, options).getFeaturesByGeometry(boundsParam, function (serviceResult) {
        _this3._dataQuerySucceed(serviceResult, restDataParameter, options);
      });
    } else {
      var param = new SuperMap.GetFeaturesBySQLParameters({
        queryParameter: {
          attributeFilter: restDataParameter.attributeFilter
        },
        targetPrj: {
          epsgCode: 4326
        },
        datasetNames: restDataParameter.dataName,
        fromIndex: 0,
        toIndex: toIndex
      });
      new _mapboxGlEnhance.default.supermap.FeatureService(restDataParameter.url, options).getFeaturesBySQL(param, function (serviceResult) {
        _this3._dataQuerySucceed(serviceResult, restDataParameter, options);
      });
    }
  };
  _proto._mapQuerySucceed = /*#__PURE__*/function () {
    var _mapQuerySucceed2 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee(serviceResult, restMapParameter, options) {
      var result, resultFeatures;
      return _regenerator.default.wrap(function _callee$(_context) {
        while (1) switch (_context.prev = _context.next) {
          case 0:
            result = serviceResult.result;
            if (result && result.totalCount !== 0) {
              resultFeatures = result.recordsets[0].features.features;
              resultFeatures.length > 0 && (this.queryResult = {
                name: restMapParameter.name,
                result: resultFeatures
              });
              this._addResultLayer(this.queryResult);
              /**
               * @event QueryViewModel#querysucceeded
               * @description 查询成功后触发。
               * @property {Object} e  - 事件对象。
               */
              this.fire('querysucceeded', {
                result: this.queryResult
              });
            } else if (result && result.totalCount === 0) {
              /**
               * @event QueryViewModel#queryfailed
               * @description 查询失败后触发。
               * @property {Object} e  - 事件对象。
               */
              this.fire('queryfailed', {
                message: (0, _index.geti18n)().t('query.noResults')
              });
            } else {
              this.fire('queryfailed', {
                message: (0, _index.geti18n)().t('query.queryFailed')
              });
            }
          case 2:
          case "end":
            return _context.stop();
        }
      }, _callee, this);
    }));
    function _mapQuerySucceed(_x, _x2, _x3) {
      return _mapQuerySucceed2.apply(this, arguments);
    }
    return _mapQuerySucceed;
  }();
  _proto._dataQuerySucceed = /*#__PURE__*/function () {
    var _dataQuerySucceed2 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee2(serviceResult, restDataParameter, options) {
      var result, resultFeatures;
      return _regenerator.default.wrap(function _callee2$(_context2) {
        while (1) switch (_context2.prev = _context2.next) {
          case 0:
            result = serviceResult.result;
            if (result && result.totalCount !== 0) {
              resultFeatures = result.features.features;
              resultFeatures.length > 0 && (this.queryResult = {
                name: restDataParameter.name,
                result: resultFeatures
              });
              this._addResultLayer(this.queryResult);
              this.fire('querysucceeded', {
                result: this.queryResult
              });
            } else if (result && result.totalCount === 0) {
              this.fire('queryfailed', {
                message: (0, _index.geti18n)().t('query.noResults')
              });
            } else {
              this.fire('queryfailed', {
                message: (0, _index.geti18n)().t('query.queryFailed')
              });
            }
          case 2:
          case "end":
            return _context2.stop();
        }
      }, _callee2, this);
    }));
    function _dataQuerySucceed(_x4, _x5, _x6) {
      return _dataQuerySucceed2.apply(this, arguments);
    }
    return _dataQuerySucceed;
  }();
  _proto._queryByIportalData = function _queryByIportalData(iportalDataParameter) {
    var _this4 = this;
    var url = iportalDataParameter.url;
    var withCredentials = iportalDataParameter.withCredentials || false;
    SuperMap.FetchRequest.get(url, null, {
      withCredentials: withCredentials
    }).then(function (response) {
      return response.json();
    }).then(function (data) {
      if (data.succeed === false) {
        _this4.queryCount--;
        // 请求失败
        return;
      }
      // 是否有rest服务
      if (data.dataItemServices && data.dataItemServices.length > 0) {
        var dataItemServices = data.dataItemServices;
        var resultData = dataItemServices.find(function (item) {
          return (item.serviceType === 'RESTDATA' || item.serviceType === 'RESTMAP') && item.serviceStatus === 'PUBLISHED';
        });
        if (resultData) {
          // 如果有服务，获取数据源和数据集, 然后请求rest服务
          _this4._getDatafromRest(resultData.serviceType, resultData.address, iportalDataParameter);
        } else {
          _this4.fire('queryfailed', {
            message: (0, _index.geti18n)().t('query.seviceNotSupport')
          });
        }
      } else {
        _this4.fire('queryfailed', {
          message: (0, _index.geti18n)().t('query.seviceNotSupport')
        });
      }
    }).catch(function (error) {
      _this4.fire('queryfailed', {
        message: error
      });
      console.log(error);
    });
  };
  _proto._getDatafromRest = function _getDatafromRest(serviceType, address, iportalDataParameter) {
    var _this5 = this;
    if (serviceType === 'RESTDATA') {
      var url = address + "/data/datasources";
      var sourceName, datasetName; // 请求获取数据源名
      SuperMap.FetchRequest.get(url, null, {
        withCredentials: iportalDataParameter.withCredentials
      }).then(function (response) {
        return response.json();
      }).then(function (data) {
        sourceName = data.datasourceNames[0];
        url = address + "/data/datasources/" + sourceName + "/datasets";
        // 请求获取数据集名
        SuperMap.FetchRequest.get(url, null, {
          withCredentials: iportalDataParameter.withCredentials
        }).then(function (response) {
          return response.json();
        }).then(function (data) {
          datasetName = data.datasetNames[0];
          // 请求restdata服务
          _this5._queryByRestData({
            dataName: [sourceName + ':' + datasetName],
            url: address + "/data",
            name: iportalDataParameter.name,
            attributeFilter: iportalDataParameter.attributeFilter,
            maxFeatures: iportalDataParameter.maxFeatures,
            epsgCode: iportalDataParameter.epsgCode,
            withCredentials: iportalDataParameter.withCredentials
          });
        }).catch(function (error) {
          _this5.fire('queryfailed', {
            message: error
          });
          console.log(error);
        });
      }).catch(function (error) {
        _this5.fire('queryfailed', {
          message: error
        });
        console.log(error);
      });
    } else {
      // 如果是地图服务
      var _url = address + "/maps";
      var mapName, layerName, path; // 请求获取地图名
      SuperMap.FetchRequest.get(_url, null, {
        withCredentials: iportalDataParameter.withCredentials
      }).then(function (response) {
        return response.json();
      }).then(function (data) {
        mapName = data[0].name;
        path = data[0].path;
        _url = _url = address + "/maps/" + mapName + "/layers";
        // 请求获取图层名
        SuperMap.FetchRequest.get(_url, null, {
          withCredentials: iportalDataParameter.withCredentials
        }).then(function (response) {
          return response.json();
        }).then(function (data) {
          layerName = data[0].subLayers.layers[0].caption;
          // 请求restmap服务
          _this5._queryByRestMap({
            layerName: layerName,
            url: path,
            name: iportalDataParameter.name,
            attributeFilter: iportalDataParameter.attributeFilter,
            maxFeatures: iportalDataParameter.maxFeatures,
            epsgCode: iportalDataParameter.epsgCode,
            withCredentials: iportalDataParameter.withCredentials
          });
          return layerName;
        }).catch(function (error) {
          _this5.fire('queryfailed', {
            message: error
          });
          console.log(error);
        });
      }).catch(function (error) {
        _this5.fire('queryfailed', {
          message: error
        });
        console.log(error);
      });
    }
  };
  _proto._addResultLayer = function _addResultLayer() {
    this.layerID = this.queryParameter.name + new Date().getTime();
    var type = this.queryResult.result[0].geometry.type;
    var source = {
      type: 'geojson',
      data: {
        type: 'FeatureCollection',
        features: this.queryResult.result
      }
    };
    this._addOverlayToMap(type, source, this.layerID);
    var bounds = (0, _bbox.default)((0, _transformScale.default)((0, _envelope.default)(source.data), 1.7));
    this.map.fitBounds([[bounds[0], bounds[1]], [bounds[2], bounds[3]]], {
      maxZoom: 17
    });
    this.getPopupFeature();
  }

  /**
   * @function QueryViewModel.prototype.getFilterFeature
   * @desc 获取过滤后的要素。
   * @param {String|Number} filter - 过滤条件，值应为要素的 properties 中的某个值。
   * @returns {Object} 要素信息。
   */;
  _proto.getFilterFeature = function getFilterFeature(filter) {
    var features = this.queryResult.result;
    var feature;
    for (var i = 0; i < features.length; i++) {
      var propertiesValue = (0, _util.getValueCaseInsensitive)(features[i].properties, 'smid');
      if (filter === propertiesValue) {
        feature = this._getFeatrueInfo(features[i]);
        break;
      }
    }
    this.map.flyTo({
      center: feature.coordinates
    });
    return feature;
  };
  _proto._getFeatrueInfo = function _getFeatrueInfo(feature) {
    var featureInfo = {};
    var coordinates;
    var geometry = feature.geometry;
    if (geometry.type === 'MultiPolygon' || geometry.type === 'Polygon' || geometry.type === 'LineString' || geometry.type === 'MultiLineString') {
      coordinates = (0, _util.getFeatureCenter)(feature);
    } else {
      coordinates = geometry.coordinates;
    }
    featureInfo.coordinates = coordinates;
    featureInfo.info = [];
    for (var key in feature.properties) {
      feature.properties[key] && featureInfo.info.push({
        attribute: key,
        attributeValue: feature.properties[key]
      });
    }
    return featureInfo;
  }

  /**
   * @function QueryViewModel.prototype.getPopupFeature
   * @desc 获得地图点击位置的要素信息。调用此方法后，需要监听 'getfeatureinfosucceeded' 事件获得要素。
   */;
  _proto.getPopupFeature = function getPopupFeature() {
    var _this6 = this;
    this.map.on('click', this.layerID, function (e) {
      var feature = e.features[0];
      var featureInfo = _this6._getFeatrueInfo(feature);
      /**
       * @event QueryViewModel#getfeatureinfosucceeded
       * @description 获取要素信息成功后触发。
       * @property {Object} e  - 事件对象。
       */
      _this6.fire('getfeatureinfosucceeded', {
        featureInfo: featureInfo
      });
    });
  }

  /**
   * @function QueryViewModel.prototype.addPopup
   * @desc 添加弹窗。
   * @param {Array} coordinates - 弹窗坐标。
   * @param {HTMLElement} popupContainer - 弹窗 DOM 对象。
   */;
  _proto.addPopup = function addPopup(coordinates, popupContainer) {
    popupContainer.style.display = 'block';
    this.map.flyTo({
      center: coordinates
    });
    return new _mapboxGlEnhance.default.Popup({
      className: 'sm-mapboxgl-tabel-popup',
      closeOnClick: true,
      closeButton: false,
      maxWidth: 'none',
      anchor: 'bottom'
    }).setLngLat(coordinates).setDOMContent(popupContainer).addTo(this.map);
  };
  _proto._addOverlayToMap = function _addOverlayToMap(type, source, layerID) {
    var mbglStyle = {
      circle: {
        'circle-color': '#409eff',
        'circle-opacity': 0.6,
        'circle-radius': 8,
        'circle-stroke-width': 2,
        'circle-stroke-color': '#409eff',
        'circle-stroke-opacity': 1
      },
      line: {
        'line-width': 3,
        'line-color': '#409eff',
        'line-opacity': 1
      },
      fill: {
        'fill-color': '#409eff',
        'fill-opacity': 0.6,
        'fill-outline-color': '#409eff'
      }
    };
    var mbglTypeMap = {
      Point: 'circle',
      LineString: 'line',
      MultiLineString: 'line',
      Polygon: 'fill',
      MultiPolygon: 'fill'
    };
    type = mbglTypeMap[type];
    if (type === 'circle' || type === 'line' || type === 'fill') {
      var layerStyle = this.layerStyle[type];
      this.map.addLayer({
        id: layerID,
        type: type,
        source: source,
        paint: layerStyle && layerStyle.paint || mbglStyle[type],
        layout: layerStyle && layerStyle.layout || {}
      });
    }
    if (type === 'fill') {
      this.strokeLayerID = layerID + '-StrokeLine';
      var stokeLineStyle = this.layerStyle.stokeLine || {};
      var lineStyle = stokeLineStyle && stokeLineStyle.paint || {
        'line-width': 3,
        'line-color': '#409eff',
        'line-opacity': 1
      };
      this.map.addLayer({
        id: this.strokeLayerID,
        type: 'line',
        source: source,
        paint: lineStyle
      });
    }
  };
  return QueryViewModel;
}(_mapboxGlEnhance.default.Evented);

/***/ }),

/***/ 7:
/***/ (function(module, exports) {

module.exports = require("@supermap/vue-iclient-mapboxgl/lib/_mixin/map-getter.js");

/***/ }),

/***/ 8:
/***/ (function(module, exports, __webpack_require__) {

"use strict";


var _interopRequireDefault = __webpack_require__(0);
Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = void 0;
var _lodash = _interopRequireDefault(__webpack_require__(10));
var _utils = __webpack_require__(11);
var VuePropTypes = {
  get any() {
    return (0, _utils.toType)('any', {
      type: null
    });
  },
  get func() {
    return (0, _utils.toType)('function', {
      type: Function
    }).def(currentDefaults.func);
  },
  get bool() {
    return (0, _utils.toType)('boolean', {
      type: Boolean
    }).def(currentDefaults.bool);
  },
  get string() {
    return (0, _utils.toType)('string', {
      type: String
    }).def(currentDefaults.string);
  },
  get number() {
    return (0, _utils.toType)('number', {
      type: Number
    }).def(currentDefaults.number);
  },
  get array() {
    return (0, _utils.toType)('array', {
      type: Array
    }).def(currentDefaults.array);
  },
  get object() {
    return (0, _utils.toType)('object', {
      type: Object
    }).def(currentDefaults.object);
  },
  get integer() {
    return (0, _utils.toType)('integer', {
      type: Number,
      validator: function validator(value) {
        return (0, _utils.isInteger)(value);
      }
    }).def(currentDefaults.integer);
  },
  get symbol() {
    return (0, _utils.toType)('symbol', {
      type: null,
      validator: function validator(value) {
        return typeof value === 'symbol';
      }
    });
  },
  custom: function custom(validatorFn, warnMsg) {
    if (warnMsg === void 0) {
      warnMsg = 'custom validation failed';
    }
    if (typeof validatorFn !== 'function') {
      throw new TypeError('[VueTypes error]: You must provide a function as argument');
    }
    return (0, _utils.toType)(validatorFn.name || '<<anonymous function>>', {
      validator: function validator() {
        var valid = validatorFn.apply(void 0, arguments);
        if (!valid) (0, _utils.warn)(this._vueTypes_name + " - " + warnMsg);
        return valid;
      }
    });
  },
  oneOf: function oneOf(arr) {
    if (!(0, _utils.isArray)(arr)) {
      throw new TypeError('[VueTypes error]: You must provide an array as argument');
    }
    var msg = "oneOf - value should be one of \"" + arr.join('", "') + "\"";
    var allowedTypes = arr.reduce(function (ret, v) {
      if (v !== null && v !== undefined) {
        ret.indexOf(v.constructor) === -1 && ret.push(v.constructor);
      }
      return ret;
    }, []);
    return (0, _utils.toType)('oneOf', {
      type: allowedTypes.length > 0 ? allowedTypes : null,
      validator: function validator(value) {
        var valid = arr.indexOf(value) !== -1;
        if (!valid) (0, _utils.warn)(msg);
        return valid;
      }
    });
  },
  instanceOf: function instanceOf(instanceConstructor) {
    return (0, _utils.toType)('instanceOf', {
      type: instanceConstructor
    });
  },
  oneOfType: function oneOfType(arr) {
    if (!(0, _utils.isArray)(arr)) {
      throw new TypeError('[VueTypes error]: You must provide an array as argument');
    }
    var hasCustomValidators = false;
    var nativeChecks = arr.reduce(function (ret, type) {
      if ((0, _lodash.default)(type)) {
        if (type._vueTypes_name === 'oneOf') {
          return ret.concat(type.type || []);
        }
        if (type.type && !(0, _utils.isFunction)(type.validator)) {
          if ((0, _utils.isArray)(type.type)) return ret.concat(type.type);
          ret.push(type.type);
        } else if ((0, _utils.isFunction)(type.validator)) {
          hasCustomValidators = true;
        }
        return ret;
      }
      ret.push(type);
      return ret;
    }, []);
    if (!hasCustomValidators) {
      // we got just native objects (ie: Array, Object)
      // delegate to Vue native prop check
      return (0, _utils.toType)('oneOfType', {
        type: nativeChecks
      }).def(undefined);
    }
    var typesStr = arr.map(function (type) {
      if (type && (0, _utils.isArray)(type.type)) {
        return type.type.map(_utils.getType);
      }
      return (0, _utils.getType)(type);
    }).reduce(function (ret, type) {
      return ret.concat((0, _utils.isArray)(type) ? type : [type]);
    }, []).join('", "');
    return this.custom(function oneOfType(value) {
      var valid = arr.some(function (type) {
        if (type._vueTypes_name === 'oneOf') {
          return type.type ? (0, _utils.validateType)(type.type, value, true) : true;
        }
        return (0, _utils.validateType)(type, value, true);
      });
      if (!valid) (0, _utils.warn)("oneOfType - value type should be one of \"" + typesStr + "\"");
      return valid;
    }).def(undefined);
  },
  arrayOf: function arrayOf(type) {
    return (0, _utils.toType)('arrayOf', {
      type: Array,
      validator: function validator(values) {
        var valid = values.every(function (value) {
          return (0, _utils.validateType)(type, value);
        });
        if (!valid) (0, _utils.warn)("arrayOf - value must be an array of \"" + (0, _utils.getType)(type) + "\"");
        return valid;
      }
    });
  },
  objectOf: function objectOf(type) {
    return (0, _utils.toType)('objectOf', {
      type: Object,
      validator: function validator(obj) {
        var valid = Object.keys(obj).every(function (key) {
          return (0, _utils.validateType)(type, obj[key]);
        });
        if (!valid) (0, _utils.warn)("objectOf - value must be an object of \"" + (0, _utils.getType)(type) + "\"");
        return valid;
      }
    });
  },
  shape: function shape(obj) {
    var keys = Object.keys(obj);
    var requiredKeys = keys.filter(function (key) {
      return obj[key] && obj[key].required === true;
    });
    var type = (0, _utils.toType)('shape', {
      type: Object,
      validator: function validator(value) {
        var _this = this;
        if (!(0, _lodash.default)(value)) {
          return false;
        }
        var valueKeys = Object.keys(value);

        // check for required keys (if any)
        if (requiredKeys.length > 0 && requiredKeys.some(function (req) {
          return valueKeys.indexOf(req) === -1;
        })) {
          (0, _utils.warn)("shape - at least one of required properties \"" + requiredKeys.join('", "') + "\" is not present");
          return false;
        }
        return valueKeys.every(function (key) {
          if (keys.indexOf(key) === -1) {
            if (_this._vueTypes_isLoose === true) return true;
            (0, _utils.warn)("shape - object is missing \"" + key + "\" property");
            return false;
          }
          var type = obj[key];
          return (0, _utils.validateType)(type, value[key]);
        });
      }
    });
    Object.defineProperty(type, '_vueTypes_isLoose', {
      enumerable: false,
      writable: true,
      value: false
    });
    Object.defineProperty(type, 'loose', {
      get: function get() {
        this._vueTypes_isLoose = true;
        return this;
      },
      enumerable: false
    });
    return type;
  }
};
var typeDefaults = function typeDefaults() {
  return {
    func: undefined,
    bool: undefined,
    string: undefined,
    number: undefined,
    array: undefined,
    object: undefined,
    integer: undefined
  };
};
var currentDefaults = typeDefaults();
Object.defineProperty(VuePropTypes, 'sensibleDefaults', {
  enumerable: false,
  set: function set(value) {
    if (value === false) {
      currentDefaults = {};
    } else if (value === true) {
      currentDefaults = typeDefaults();
    } else if ((0, _lodash.default)(value)) {
      currentDefaults = value;
    }
  },
  get: function get() {
    return currentDefaults;
  }
});
var _default = exports.default = VuePropTypes;

/***/ }),

/***/ 84:
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _Option_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(27);
/* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _Option_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0__) if(["default"].indexOf(__WEBPACK_IMPORT_KEY__) < 0) (function(key) { __webpack_require__.d(__webpack_exports__, key, function() { return _Option_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0__[key]; }) }(__WEBPACK_IMPORT_KEY__));
/* harmony import */ var _node_modules_vue_loader_lib_runtime_componentNormalizer_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1);
var render, staticRenderFns




/* normalize component */

var component = Object(_node_modules_vue_loader_lib_runtime_componentNormalizer_js__WEBPACK_IMPORTED_MODULE_1__[/* default */ "a"])(
  _Option_vue_vue_type_script_lang_ts___WEBPACK_IMPORTED_MODULE_0__["default"],
  render,
  staticRenderFns,
  false,
  null,
  null,
  null
  
)

/* harmony default export */ __webpack_exports__["default"] = (component.exports);

/***/ }),

/***/ 87:
/***/ (function(module, exports) {

module.exports = require("@turf/envelope");

/***/ })

/******/ });