olp-table 7.2.47 → 7.2.49

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/olp-table.umd.js CHANGED
@@ -278,7 +278,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpac
278
278
  /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
279
279
 
280
280
  "use strict";
281
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var element_plus_dist_index_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! element-plus/dist/index.css */ \"./node_modules/element-plus/dist/index.css\");\n/* harmony import */ var element_plus_dist_index_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(element_plus_dist_index_css__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _smallwei_avue_lib_index_css__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @smallwei/avue/lib/index.css */ \"./node_modules/@smallwei/avue/lib/index.css\");\n/* harmony import */ var _smallwei_avue_lib_index_css__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_smallwei_avue_lib_index_css__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var vxe_table_lib_style_css__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! vxe-table/lib/style.css */ \"./node_modules/vxe-table/lib/style.css\");\n/* harmony import */ var vxe_table_lib_style_css__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(vxe_table_lib_style_css__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var _components_auto_height_index_vue__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @/components/auto-height/index.vue */ \"./src/components/auto-height/index.vue\");\n/* harmony import */ var _components_tree_index_vue__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @/components/tree/index.vue */ \"./src/components/tree/index.vue\");\n/* harmony import */ var _utils_http_httpUtil__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @/utils/http/httpUtil */ \"./src/utils/http/httpUtil.js\");\n/* harmony import */ var _components_table_model_model_index_vue__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @/components/table/model/model-index.vue */ \"./src/components/table/model/model-index.vue\");\n/* harmony import */ var _store_dict__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @/store/dict */ \"./src/store/dict.js\");\n/* harmony import */ var _store_dictType__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @/store/dictType */ \"./src/store/dictType.js\");\n/* harmony import */ var _components_ol_dialog_upload_file_vue__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @/components/ol-dialog-upload-file.vue */ \"./src/components/ol-dialog-upload-file.vue\");\n/* harmony import */ var _utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @/utils/http/httpUtils */ \"./src/utils/http/httpUtils.js\");\n/* harmony import */ var _components_ol_table_select_vue__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! @/components/ol-table-select.vue */ \"./src/components/ol-table-select.vue\");\n\n\n\n\n\n\n\n\n\n\n\n\n\nconst dict = (0,_store_dict__WEBPACK_IMPORTED_MODULE_7__.storeDict)();\nconst dictType = (0,_store_dictType__WEBPACK_IMPORTED_MODULE_8__.storeDictType)();\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: 'olTable',\n components: {\n OlTableSelect: _components_ol_table_select_vue__WEBPACK_IMPORTED_MODULE_11__[\"default\"],\n OlDialogUploadFile: _components_ol_dialog_upload_file_vue__WEBPACK_IMPORTED_MODULE_9__[\"default\"],\n ModelIndex: _components_table_model_model_index_vue__WEBPACK_IMPORTED_MODULE_6__[\"default\"],\n OlTree: _components_tree_index_vue__WEBPACK_IMPORTED_MODULE_4__[\"default\"],\n AutoHeight: _components_auto_height_index_vue__WEBPACK_IMPORTED_MODULE_3__[\"default\"]\n },\n provide() {\n return {\n http: _utils_http_httpUtil__WEBPACK_IMPORTED_MODULE_5__[\"default\"],\n tableAll: this.table\n };\n },\n data() {\n return {\n uuid: '1787452516924563456',\n treeUuid: '1815551679408418816',\n table: {},\n http: _utils_http_httpUtil__WEBPACK_IMPORTED_MODULE_5__[\"default\"],\n formConfig: undefined\n };\n },\n methods: {\n nodeClick(e) {\n console.log(e);\n this.uuid = undefined;\n this.$nextTick(() => {\n this.uuid = e.uuid;\n });\n },\n initOk({\n theme,\n table,\n customerForm\n }) {\n if (theme == 't1') {\n this.formConfig = table.formConfig; //给原有的自定义搜索\n //customerForm();//执行自定义表单,这个方法会隐藏table的表单,隐藏搜索按钮\n }\n console.log(this.formConfig);\n },\n //主子表更新或者保存\n testSave() {\n let params = {\n dbName: 'online',\n //数据库名称\n tableName: 'sys_dict_type',\n //主表名称\n subTableName: 'sys_dict_data',\n //子表名称\n mianColumnAndValueMap: {\n id: '1231564546',\n name: '韦邦杠',\n sex: ''\n },\n //保存主表的数据{表字段:value}\n //mainGenIdMap:{id: 'uuid'} //主表要自动生成的唯一字段 如果没有 可以忽略\n mainTableKey: ['code'],\n //主表的唯一字段\n subColumnAndValueList: [{\n dict_code: 'test_code_2',\n dict_value: '1',\n dict_label: 'label'\n }],\n //子表子主表的数据\n subGenIdMap: {\n id: 'uuid'\n },\n //子表要自动生成的唯一字段 如果没有 可以忽略\n subTableKey: ['id'],\n //子表的唯一字段\n subForeignKey: {\n 'code': 'dict_type'\n } //表的关联key,这里框架自动复制 {主表字段,子表的字段}\n };\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_10__.postAes)(this.http, \"/online/crudAes/saveMainAndSubs\", params);\n },\n //主子表删除\n testDelete() {\n let params = {\n dbName: 'online',\n //数据库名称\n tableName: 'sys_dict_type',\n //主表名称\n subTableName: 'sys_dict_data',\n //子表名称\n whereMap: {\n id: 'test_code'\n },\n //主表删除条件\n subForeignKey: {\n 'id': 'parent_id'\n } ////表的关联key,{主表字段,子表的字段}\n };\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_10__.postAes)(this.http, \"/online/crudAes/deleteMainAndSubs\", params);\n },\n //单表更新\n updateOne() {\n let params = {\n dbName: 'online',\n //数据库名称\n tableName: 'sys_dict_type',\n //主表名称\n columnAndValueMap: {\n code: 'test_code',\n sex: 'xxx'\n },\n //更新字段\n whereMap: {\n code: 'test_code'\n } //更新条件\n };\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_10__.postAes)(this.http, \"/online/crudAes/modify\", params);\n },\n //单表批量更新\n updateBatch() {\n let params = {\n dbName: 'online',\n //数据库名称\n tableName: 'sys_dict_type',\n //主表名称\n list: [{\n columnAndValueMap: {\n code: 'test_code'\n },\n //更新字段\n whereMap: {\n code: 'test_code'\n }\n } //更新条件}\n ]\n };\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_10__.postAes)(this.http, \"/online/crudAes/batchModify\", params);\n }\n },\n created() {\n dict.refresh();\n dictType.refresh();\n window.$onlineHttps = _utils_http_httpUtil__WEBPACK_IMPORTED_MODULE_5__[\"default\"];\n //this.testDelete();\n //this.nodeClick({uuid:'1787452516924563456'})\n //window.olpTableAxiosBaseURL = \"http://localhost:48090/\"\n }\n});\n\n//# sourceURL=webpack://olp-table/./src/App.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-82.use%5B0%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D");
281
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var element_plus_dist_index_css__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! element-plus/dist/index.css */ \"./node_modules/element-plus/dist/index.css\");\n/* harmony import */ var element_plus_dist_index_css__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(element_plus_dist_index_css__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _smallwei_avue_lib_index_css__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @smallwei/avue/lib/index.css */ \"./node_modules/@smallwei/avue/lib/index.css\");\n/* harmony import */ var _smallwei_avue_lib_index_css__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_smallwei_avue_lib_index_css__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var vxe_table_lib_style_css__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! vxe-table/lib/style.css */ \"./node_modules/vxe-table/lib/style.css\");\n/* harmony import */ var vxe_table_lib_style_css__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(vxe_table_lib_style_css__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var _components_auto_height_index_vue__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @/components/auto-height/index.vue */ \"./src/components/auto-height/index.vue\");\n/* harmony import */ var _components_tree_index_vue__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @/components/tree/index.vue */ \"./src/components/tree/index.vue\");\n/* harmony import */ var _utils_http_httpUtil__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @/utils/http/httpUtil */ \"./src/utils/http/httpUtil.js\");\n/* harmony import */ var _components_table_model_model_index_vue__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @/components/table/model/model-index.vue */ \"./src/components/table/model/model-index.vue\");\n/* harmony import */ var _store_dict__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @/store/dict */ \"./src/store/dict.js\");\n/* harmony import */ var _store_dictType__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @/store/dictType */ \"./src/store/dictType.js\");\n/* harmony import */ var _components_ol_dialog_upload_file_vue__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @/components/ol-dialog-upload-file.vue */ \"./src/components/ol-dialog-upload-file.vue\");\n/* harmony import */ var _utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @/utils/http/httpUtils */ \"./src/utils/http/httpUtils.js\");\n/* harmony import */ var _components_ol_table_select_vue__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! @/components/ol-table-select.vue */ \"./src/components/ol-table-select.vue\");\n\n\n\n\n\n\n\n\n\n\n\n\n\nconst dict = (0,_store_dict__WEBPACK_IMPORTED_MODULE_7__.storeDict)();\nconst dictType = (0,_store_dictType__WEBPACK_IMPORTED_MODULE_8__.storeDictType)();\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: 'olTable',\n components: {\n OlTableSelect: _components_ol_table_select_vue__WEBPACK_IMPORTED_MODULE_11__[\"default\"],\n OlDialogUploadFile: _components_ol_dialog_upload_file_vue__WEBPACK_IMPORTED_MODULE_9__[\"default\"],\n ModelIndex: _components_table_model_model_index_vue__WEBPACK_IMPORTED_MODULE_6__[\"default\"],\n OlTree: _components_tree_index_vue__WEBPACK_IMPORTED_MODULE_4__[\"default\"],\n AutoHeight: _components_auto_height_index_vue__WEBPACK_IMPORTED_MODULE_3__[\"default\"]\n },\n provide() {\n return {\n http: _utils_http_httpUtil__WEBPACK_IMPORTED_MODULE_5__[\"default\"],\n tableAll: this.table\n };\n },\n data() {\n return {\n uuid: '1999317182181076992',\n treeUuid: '1815551679408418816',\n table: {},\n http: _utils_http_httpUtil__WEBPACK_IMPORTED_MODULE_5__[\"default\"],\n formConfig: undefined\n };\n },\n methods: {\n nodeClick(e) {\n console.log(e);\n this.uuid = undefined;\n this.$nextTick(() => {\n this.uuid = e.uuid;\n });\n },\n initOk({\n theme,\n table,\n customerForm\n }) {\n if (theme == 't1') {\n this.formConfig = table.formConfig; //给原有的自定义搜索\n //customerForm();//执行自定义表单,这个方法会隐藏table的表单,隐藏搜索按钮\n }\n console.log(this.formConfig);\n },\n //主子表更新或者保存\n testSave() {\n let params = {\n dbName: 'online',\n //数据库名称\n tableName: 'sys_dict_type',\n //主表名称\n subTableName: 'sys_dict_data',\n //子表名称\n mianColumnAndValueMap: {\n id: '1231564546',\n name: '韦邦杠',\n sex: ''\n },\n //保存主表的数据{表字段:value}\n //mainGenIdMap:{id: 'uuid'} //主表要自动生成的唯一字段 如果没有 可以忽略\n mainTableKey: ['code'],\n //主表的唯一字段\n subColumnAndValueList: [{\n dict_code: 'test_code_2',\n dict_value: '1',\n dict_label: 'label'\n }],\n //子表子主表的数据\n subGenIdMap: {\n id: 'uuid'\n },\n //子表要自动生成的唯一字段 如果没有 可以忽略\n subTableKey: ['id'],\n //子表的唯一字段\n subForeignKey: {\n 'code': 'dict_type'\n } //表的关联key,这里框架自动复制 {主表字段,子表的字段}\n };\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_10__.postAes)(this.http, \"/online/crudAes/saveMainAndSubs\", params);\n },\n //主子表删除\n testDelete() {\n let params = {\n dbName: 'online',\n //数据库名称\n tableName: 'sys_dict_type',\n //主表名称\n subTableName: 'sys_dict_data',\n //子表名称\n whereMap: {\n id: 'test_code'\n },\n //主表删除条件\n subForeignKey: {\n 'id': 'parent_id'\n } ////表的关联key,{主表字段,子表的字段}\n };\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_10__.postAes)(this.http, \"/online/crudAes/deleteMainAndSubs\", params);\n },\n //单表更新\n updateOne() {\n let params = {\n dbName: 'online',\n //数据库名称\n tableName: 'sys_dict_type',\n //主表名称\n columnAndValueMap: {\n code: 'test_code',\n sex: 'xxx'\n },\n //更新字段\n whereMap: {\n code: 'test_code'\n } //更新条件\n };\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_10__.postAes)(this.http, \"/online/crudAes/modify\", params);\n },\n //单表批量更新\n updateBatch() {\n let params = {\n dbName: 'online',\n //数据库名称\n tableName: 'sys_dict_type',\n //主表名称\n list: [{\n columnAndValueMap: {\n code: 'test_code'\n },\n //更新字段\n whereMap: {\n code: 'test_code'\n }\n } //更新条件}\n ]\n };\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_10__.postAes)(this.http, \"/online/crudAes/batchModify\", params);\n }\n },\n created() {\n dict.refresh();\n dictType.refresh();\n window.$onlineHttps = _utils_http_httpUtil__WEBPACK_IMPORTED_MODULE_5__[\"default\"];\n //this.testDelete();\n //this.nodeClick({uuid:'1787452516924563456'})\n //window.olpTableAxiosBaseURL = \"http://localhost:48090/\"\n }\n});\n\n//# sourceURL=webpack://olp-table/./src/App.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-82.use%5B0%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D");
282
282
 
283
283
  /***/ }),
284
284
 
@@ -355,7 +355,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var core
355
355
  /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
356
356
 
357
357
  "use strict";
358
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.iterator.constructor.js */ \"./node_modules/core-js/modules/es.iterator.constructor.js\");\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/es.iterator.filter.js */ \"./node_modules/core-js/modules/es.iterator.filter.js\");\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @/utils/http/httpUtils */ \"./src/utils/http/httpUtils.js\");\n/* harmony import */ var _utils_DateUtils__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @/utils/DateUtils */ \"./src/utils/DateUtils.js\");\n\n\n\n\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: 'olDialogExcel',\n inject: ['http'],\n props: {\n title: {\n default: '导出数据'\n },\n name: {\n default: undefined\n },\n selectData: {\n default: '1'\n }\n },\n data() {\n return {\n gridOptions: {\n border: true,\n keepSource: true,\n showOverflow: true,\n loading: false,\n height: 330,\n align: 'left',\n scrollX: {\n enabled: true,\n gt: 15\n },\n scrollY: {\n enabled: true,\n gt: 0\n },\n columnConfig: {\n resizable: true\n },\n rowConfig: {\n useKey: true,\n keyField: 'id'\n },\n expandConfig: {\n labelField: 'seq'\n },\n editConfig: {\n trigger: 'click',\n mode: 'row',\n showStatus: true\n },\n checkboxConfig: {\n labelField: 'title',\n reserve: true,\n highlight: true,\n range: true,\n checkAll: true\n },\n columns: [{\n type: 'checkbox',\n title: '全部字段'\n // width: 330\n }],\n toolbarConfig: {},\n data: [],\n url: '/online/tableConfigColumn/queryByParentId'\n },\n show: false,\n form: {\n selectData: ''\n }\n };\n },\n methods: {\n init(id) {\n this.gridOptions.loading = true;\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_2__.get)(this.http, this.gridOptions.url, {\n id: id\n }, true).then(res => {\n this.gridOptions.data = res;\n this.gridOptions.loading = false;\n });\n },\n cancelEvent() {\n this.show = false;\n },\n confirmEvent() {\n let columns = this.$refs.xGrid.getCheckboxRecords(true);\n let exportParam = {\n selectData: this.form.selectData,\n columns: columns,\n name: this.name || (0,_utils_DateUtils__WEBPACK_IMPORTED_MODULE_3__.getDateTime)(98)\n };\n this.$emit('emits', {\n m: 'exportData',\n v: {\n exportParam: exportParam,\n cancelEvent: this.cancelEvent\n }\n });\n },\n open({\n column,\n selectData\n }) {\n this.form.selectData = selectData;\n this.show = true;\n let columns = column.filter(o => o.columnAuth == 1 && o.visible == 1);\n this.gridOptions.data = columns;\n }\n }\n});\n\n//# sourceURL=webpack://olp-table/./src/components/ol-dialog-excel.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-82.use%5B0%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D");
358
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.iterator.constructor.js */ \"./node_modules/core-js/modules/es.iterator.constructor.js\");\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/es.iterator.filter.js */ \"./node_modules/core-js/modules/es.iterator.filter.js\");\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var _utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @/utils/http/httpUtils */ \"./src/utils/http/httpUtils.js\");\n/* harmony import */ var _utils_DateUtils__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @/utils/DateUtils */ \"./src/utils/DateUtils.js\");\n\n\n\n\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: 'olDialogExcel',\n inject: ['http'],\n props: {\n title: {\n default: '导出数据'\n },\n name: {\n default: undefined\n },\n selectData: {\n default: '1'\n }\n },\n data() {\n return {\n gridOptions: {\n border: true,\n keepSource: true,\n showOverflow: true,\n loading: false,\n height: 330,\n align: 'left',\n scrollX: {\n enabled: true,\n gt: 15\n },\n scrollY: {\n enabled: true,\n gt: 0\n },\n columnConfig: {\n resizable: true\n },\n rowConfig: {\n useKey: true,\n keyField: 'id'\n },\n expandConfig: {\n labelField: 'seq'\n },\n editConfig: {\n trigger: 'click',\n mode: 'row',\n showStatus: true\n },\n checkboxConfig: {\n labelField: 'title',\n reserve: true,\n highlight: true,\n range: true,\n checkAll: true\n },\n columns: [{\n type: 'checkbox',\n title: '全部字段'\n // width: 330\n }],\n toolbarConfig: {},\n data: [],\n url: '/online/tableConfigColumn/queryByParentId'\n },\n show: false,\n form: {\n selectData: ''\n }\n };\n },\n methods: {\n init(id) {\n this.gridOptions.loading = true;\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_2__.get)(this.http, this.gridOptions.url, {\n id: id\n }, true).then(res => {\n this.gridOptions.data = res;\n this.gridOptions.loading = false;\n });\n },\n cancelEvent() {\n this.show = false;\n this.$emit('emits', {});\n },\n confirmEvent() {\n let columns = this.$refs.xGrid.getCheckboxRecords(true);\n let exportParam = {\n selectData: this.form.selectData,\n columns: columns,\n name: this.name || (0,_utils_DateUtils__WEBPACK_IMPORTED_MODULE_3__.getDateTime)(98)\n };\n this.$emit('emits', {\n m: 'exportData',\n v: {\n exportParam: exportParam,\n cancelEvent: this.cancelEvent\n }\n });\n },\n open({\n column,\n selectData\n }) {\n this.form.selectData = selectData;\n this.show = true;\n let columns = column.filter(o => o.columnAuth == 1 && o.visible == 1);\n this.gridOptions.data = columns;\n }\n }\n});\n\n//# sourceURL=webpack://olp-table/./src/components/ol-dialog-excel.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-82.use%5B0%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D");
359
359
 
360
360
  /***/ }),
361
361
 
@@ -366,7 +366,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var core
366
366
  /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
367
367
 
368
368
  "use strict";
369
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.array.push.js */ \"./node_modules/core-js/modules/es.array.push.js\");\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/es.iterator.constructor.js */ \"./node_modules/core-js/modules/es.iterator.constructor.js\");\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! core-js/modules/es.iterator.filter.js */ \"./node_modules/core-js/modules/es.iterator.filter.js\");\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var core_js_modules_es_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! core-js/modules/es.iterator.for-each.js */ \"./node_modules/core-js/modules/es.iterator.for-each.js\");\n/* harmony import */ var core_js_modules_es_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_3__);\n/* harmony import */ var core_js_modules_es_iterator_map_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! core-js/modules/es.iterator.map.js */ \"./node_modules/core-js/modules/es.iterator.map.js\");\n/* harmony import */ var core_js_modules_es_iterator_map_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_map_js__WEBPACK_IMPORTED_MODULE_4__);\n/* harmony import */ var _utils_message__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @/utils/message */ \"./src/utils/message.js\");\n/* harmony import */ var _utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @/utils/http/httpUtils */ \"./src/utils/http/httpUtils.js\");\n/* harmony import */ var _utils_ExcelUtil__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @/utils/ExcelUtil */ \"./src/utils/ExcelUtil.js\");\n/* harmony import */ var _store_dict__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @/store/dict */ \"./src/store/dict.js\");\n/* harmony import */ var _utils_AESCRUDUtils__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @/utils/AESCRUDUtils */ \"./src/utils/AESCRUDUtils.js\");\n\n\n\n\n\n\n\n\n\n\nconst dict = (0,_store_dict__WEBPACK_IMPORTED_MODULE_8__.storeDict)();\nconst message = (0,_utils_message__WEBPACK_IMPORTED_MODULE_5__.useMessage)(); // 消息弹窗\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: 'olDialogImport',\n inject: ['http'],\n props: {\n title: {\n default: '导入数据'\n },\n name: {\n default: '导入数据'\n },\n width: {\n default: 800\n },\n draggable: {\n default: true\n },\n center: {\n default: false\n },\n selectData: {\n default: '1'\n }\n },\n data() {\n return {\n form: {\n selectData: ''\n },\n saveParams: {},\n show: '',\n formData: {},\n gridOptions: {\n border: true,\n keepSource: true,\n showOverflow: true,\n loading: false,\n height: 330,\n align: 'left',\n scrollX: {\n enabled: true,\n gt: 15\n },\n scrollY: {\n enabled: true,\n gt: 0\n },\n columnConfig: {\n resizable: true\n },\n rowConfig: {\n useKey: true,\n keyField: 'id'\n },\n expandConfig: {\n labelField: 'seq'\n },\n editConfig: {\n trigger: 'click',\n mode: 'row',\n showStatus: true\n },\n checkboxConfig: {\n labelField: 'title',\n reserve: true,\n highlight: true,\n range: true,\n checkAll: false\n },\n columns: [],\n data: [],\n toolbarConfig: {},\n initColumns: [{\n type: 'checkbox',\n width: 50,\n fixed: 'left'\n }, {\n type: 'seq',\n title: '序号',\n width: 50,\n fixed: 'left'\n }]\n },\n genIdMap: undefined,\n url: '/online/crud/batchSave'\n };\n },\n methods: {\n customUpload(param) {\n const formData = new FormData();\n // 添加文件\n formData.append('file', param.file);\n // 使用 axios 或其他 HTTP 客户端发送请求\n this.http.upload('/online/crud/upload', formData).then(response => {\n this.onChange(response);\n }).catch(error => {\n console.error('上传失败:', error);\n });\n },\n submit() {\n if (!this.gridOptions.data || this.gridOptions.data.length == 0) return message.error('导入数据为空!');\n let params = this.getParams();\n console.log(params);\n this.gridOptions.loading = true;\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_6__.request)(this.http, {\n url: '/online/crudAes/batchSave',\n method: 'post',\n data: (0,_utils_AESCRUDUtils__WEBPACK_IMPORTED_MODULE_9__.encryptWithCompress)(params),\n timeout: 1000 * 90 * 90\n }, false, false).then(({\n msg,\n code\n }) => {\n if (code == 200) {\n this.show = false;\n this.$emit('emits', {\n m: 'query'\n });\n message.success(msg);\n } else {\n message.error(msg);\n }\n }).finally(() => {\n this.gridOptions.loading = false;\n });\n },\n open({\n column,\n saveParams,\n json\n }) {\n if (json) {\n if (json.genIdMap) {\n this.genIdMap = json.genIdMap;\n }\n if (json.url) {\n this.url = json.url;\n }\n }\n this.saveParams = saveParams;\n this.show = true;\n let columns = column.filter(o => o.columnAuth == 1 && o.visible == 1);\n columns.push(...this.gridOptions.initColumns);\n this.gridOptions.columns = columns;\n this.$refs.xGrid.loadColumn(this.gridOptions.columns);\n },\n handleChange(title) {\n let que = [];\n for (let j = 0; j < this.gridOptions.data.length; j++) {\n let data = this.gridOptions.data[j];\n if (j == 0) {\n que.push(data[title]);\n break;\n }\n let index = que.index0f(data[title]);\n if (index != -1) {\n return message.warn('第' + (j + 1) + '行-第' + (index + 1) + '行数据不唯-:' + data[title]);\n }\n que.push(data[title]);\n }\n message.success(title + '无重复数据!');\n },\n selectRowChange() {\n this.formData.disabled = this.$refs.xGrid.getCheckboxRecords(true).length == 0;\n this.formData.selected_but = this.formData.disabled ? 'unselected_but' : 'selected_but';\n },\n batchRemove() {\n let records = this.$refs.xGrid.getCheckboxRecords(true);\n if (!records || records.length == 0) return message.error('未选中数据!');\n this.$refs.xGrid.removeCheckboxRow();\n },\n getParams() {\n return {\n ...this.saveParams,\n genIdMap: this.genIdMap,\n columnAndValueListMap: this.getDataByDict(this.gridOptions.data)\n };\n },\n onChange({\n data\n }) {\n data = this.getDataByTitle(data);\n this.gridOptions.data = data;\n },\n getDataByTitle(data) {\n if (data && data.length >= 1) {\n let rows = [];\n data.map(row => {\n let obj = {};\n for (let key in row) {\n this.gridOptions.columns.forEach(item => {\n if (item.title == key) {\n obj[item.field] = row[key];\n }\n });\n }\n rows.push(obj);\n });\n return rows;\n }\n },\n getDataByDict(data) {\n if (data && data.length >= 1) {\n let rows = [];\n data.map(row => {\n let obj = {};\n for (let key in row) {\n this.gridOptions.columns.forEach(item => {\n if (item.field == key) {\n obj[item.field] = this.getRowValue(item.dictCode, row[key]);\n }\n });\n }\n rows.push(obj);\n });\n return rows;\n }\n },\n download() {\n (0,_utils_ExcelUtil__WEBPACK_IMPORTED_MODULE_7__.exportExcel)({\n data: [],\n name: '模板下载',\n columns: this.gridOptions.columns.filter(o => o.field),\n option: {\n align: 'center'\n }\n });\n },\n init(id) {\n this.gridOptions.loading = true;\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_6__.get)(this.http, this.gridOptions.url, {\n id: id\n }, true).then(res => {\n for (const data of res) {\n data.width = 100;\n }\n res.push(...this.gridOptions.initColumns);\n this.gridOptions.columns = res;\n this.gridOptions.loading = false;\n });\n },\n getRowValue(dictCode, val) {\n if (dictCode) {\n return this.getDictValueByCode(dictCode, val);\n }\n return val;\n },\n getDictValueByCode(dictCode, val) {\n for (const option of dict.val(dictCode)) {\n if (option.label == val) {\n return option;\n }\n }\n return val;\n },\n close() {\n this.show = false;\n }\n },\n created() {\n this.formData = {\n action: this.http.axios().defaults.baseURL + '/online/crud/upload',\n uniCode: '',\n headers: this.http.axios().defaults.headers,\n disabled: true,\n selected_but: 'unselected_but'\n };\n }\n});\n\n//# sourceURL=webpack://olp-table/./src/components/ol-dialog-import.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-82.use%5B0%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D");
369
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.array.push.js */ \"./node_modules/core-js/modules/es.array.push.js\");\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/es.iterator.constructor.js */ \"./node_modules/core-js/modules/es.iterator.constructor.js\");\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! core-js/modules/es.iterator.filter.js */ \"./node_modules/core-js/modules/es.iterator.filter.js\");\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var core_js_modules_es_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! core-js/modules/es.iterator.for-each.js */ \"./node_modules/core-js/modules/es.iterator.for-each.js\");\n/* harmony import */ var core_js_modules_es_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_3__);\n/* harmony import */ var core_js_modules_es_iterator_map_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! core-js/modules/es.iterator.map.js */ \"./node_modules/core-js/modules/es.iterator.map.js\");\n/* harmony import */ var core_js_modules_es_iterator_map_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_map_js__WEBPACK_IMPORTED_MODULE_4__);\n/* harmony import */ var _utils_message__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @/utils/message */ \"./src/utils/message.js\");\n/* harmony import */ var _utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @/utils/http/httpUtils */ \"./src/utils/http/httpUtils.js\");\n/* harmony import */ var _utils_ExcelUtil__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @/utils/ExcelUtil */ \"./src/utils/ExcelUtil.js\");\n/* harmony import */ var _store_dict__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @/store/dict */ \"./src/store/dict.js\");\n/* harmony import */ var _utils_AESCRUDUtils__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @/utils/AESCRUDUtils */ \"./src/utils/AESCRUDUtils.js\");\n\n\n\n\n\n\n\n\n\n\nconst dict = (0,_store_dict__WEBPACK_IMPORTED_MODULE_8__.storeDict)();\nconst message = (0,_utils_message__WEBPACK_IMPORTED_MODULE_5__.useMessage)(); // 消息弹窗\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: 'olDialogImport',\n inject: ['http'],\n props: {\n title: {\n default: '导入数据'\n },\n name: {\n default: '导入数据'\n },\n width: {\n default: 800\n },\n draggable: {\n default: true\n },\n center: {\n default: false\n },\n selectData: {\n default: '1'\n }\n },\n data() {\n return {\n form: {\n selectData: ''\n },\n saveParams: {},\n show: '',\n formData: {},\n gridOptions: {\n border: true,\n keepSource: true,\n showOverflow: true,\n loading: false,\n height: 330,\n align: 'left',\n scrollX: {\n enabled: true,\n gt: 15\n },\n scrollY: {\n enabled: true,\n gt: 0\n },\n columnConfig: {\n resizable: true\n },\n rowConfig: {\n useKey: true,\n keyField: 'id'\n },\n expandConfig: {\n labelField: 'seq'\n },\n editConfig: {\n trigger: 'click',\n mode: 'row',\n showStatus: true\n },\n checkboxConfig: {\n labelField: 'title',\n reserve: true,\n highlight: true,\n range: true,\n checkAll: false\n },\n columns: [],\n data: [],\n toolbarConfig: {},\n initColumns: [{\n type: 'checkbox',\n width: 50,\n fixed: 'left'\n }, {\n type: 'seq',\n title: '序号',\n width: 50,\n fixed: 'left'\n }]\n },\n genIdMap: undefined,\n defaultValue: undefined,\n url: '/online/crud/batchSave'\n };\n },\n methods: {\n customUpload(param) {\n const formData = new FormData();\n // 添加文件\n formData.append('file', param.file);\n // 使用 axios 或其他 HTTP 客户端发送请求\n this.http.upload('/online/crud/upload', formData).then(response => {\n this.onChange(response);\n }).catch(error => {\n console.error('上传失败:', error);\n });\n },\n submit() {\n if (!this.gridOptions.data || this.gridOptions.data.length == 0) return message.error('导入数据为空!');\n let params = this.getParams();\n console.log(params);\n this.gridOptions.loading = true;\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_6__.request)(this.http, {\n url: '/online/crudAes/batchSave',\n method: 'post',\n data: (0,_utils_AESCRUDUtils__WEBPACK_IMPORTED_MODULE_9__.encryptWithCompress)(params),\n timeout: 1000 * 90 * 90\n }, false, false).then(({\n msg,\n code\n }) => {\n if (code == 200) {\n this.show = false;\n this.$emit('emits', {\n m: 'query'\n });\n message.success(msg);\n } else {\n message.error(msg);\n }\n }).finally(() => {\n this.gridOptions.loading = false;\n });\n },\n open({\n column,\n saveParams,\n json,\n defaultValue\n }) {\n if (json) {\n if (json.genIdMap) {\n this.genIdMap = json.genIdMap;\n }\n if (json.url) {\n this.url = json.url;\n }\n }\n this.defaultValue = defaultValue;\n this.saveParams = saveParams;\n this.show = true;\n let columns = column.filter(o => o.columnAuth == 1 && o.visible == 1);\n columns.push(...this.gridOptions.initColumns);\n this.gridOptions.columns = columns;\n this.$refs.xGrid.loadColumn(this.gridOptions.columns);\n },\n handleChange(title) {\n let que = [];\n for (let j = 0; j < this.gridOptions.data.length; j++) {\n let data = this.gridOptions.data[j];\n if (j == 0) {\n que.push(data[title]);\n break;\n }\n let index = que.index0f(data[title]);\n if (index != -1) {\n return message.warn('第' + (j + 1) + '行-第' + (index + 1) + '行数据不唯-:' + data[title]);\n }\n que.push(data[title]);\n }\n message.success(title + '无重复数据!');\n },\n selectRowChange() {\n this.formData.disabled = this.$refs.xGrid.getCheckboxRecords(true).length == 0;\n this.formData.selected_but = this.formData.disabled ? 'unselected_but' : 'selected_but';\n },\n batchRemove() {\n let records = this.$refs.xGrid.getCheckboxRecords(true);\n if (!records || records.length == 0) return message.error('未选中数据!');\n this.$refs.xGrid.removeCheckboxRow();\n },\n getParams() {\n return {\n ...this.saveParams,\n genIdMap: this.genIdMap,\n columnAndValueListMap: this.getDataByDict(this.gridOptions.data)\n };\n },\n onChange({\n data\n }) {\n data = this.getDataByTitle(data);\n if (this.defaultValue) {\n for (let key of Object.keys(this.defaultValue)) {\n for (let datum of data) {\n datum[key] = this.defaultValue[key];\n }\n }\n }\n this.gridOptions.data = data;\n },\n getDataByTitle(data) {\n if (data && data.length >= 1) {\n let rows = [];\n data.map(row => {\n let obj = {};\n for (let key in row) {\n this.gridOptions.columns.forEach(item => {\n if (item.title == key) {\n obj[item.field] = row[key];\n }\n });\n }\n rows.push(obj);\n });\n return rows;\n }\n },\n getDataByDict(data) {\n if (data && data.length >= 1) {\n let rows = [];\n data.map(row => {\n let obj = {};\n for (let key in row) {\n this.gridOptions.columns.forEach(item => {\n if (item.field == key) {\n obj[item.field] = this.getRowValue(item.dictCode, row[key]);\n }\n });\n }\n rows.push(obj);\n });\n return rows;\n }\n },\n download() {\n (0,_utils_ExcelUtil__WEBPACK_IMPORTED_MODULE_7__.exportExcel)({\n data: [],\n name: '模板下载',\n columns: this.gridOptions.columns.filter(o => o.field),\n option: {\n align: 'center'\n }\n });\n },\n init(id) {\n this.gridOptions.loading = true;\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_6__.get)(this.http, this.gridOptions.url, {\n id: id\n }, true).then(res => {\n for (const data of res) {\n data.width = 100;\n }\n res.push(...this.gridOptions.initColumns);\n this.gridOptions.columns = res;\n this.gridOptions.loading = false;\n });\n },\n getRowValue(dictCode, val) {\n if (dictCode) {\n return this.getDictValueByCode(dictCode, val);\n }\n return val;\n },\n getDictValueByCode(dictCode, val) {\n for (const option of dict.val(dictCode)) {\n if (option.label == val) {\n return option;\n }\n }\n return val;\n },\n close() {\n this.$emit('emits', {});\n this.show = false;\n }\n },\n created() {\n this.formData = {\n action: this.http.axios().defaults.baseURL + '/online/crud/upload',\n uniCode: '',\n headers: this.http.axios().defaults.headers,\n disabled: true,\n selected_but: 'unselected_but'\n };\n }\n});\n\n//# sourceURL=webpack://olp-table/./src/components/ol-dialog-import.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-82.use%5B0%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D");
370
370
 
371
371
  /***/ }),
372
372
 
@@ -388,7 +388,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var vue_
388
388
  /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
389
389
 
390
390
  "use strict";
391
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _components_table_model_model_index_vue__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @/components/table/model/model-index.vue */ \"./src/components/table/model/model-index.vue\");\n\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: 'olDialogTable',\n components: {\n ModelIndex: _components_table_model_model_index_vue__WEBPACK_IMPORTED_MODULE_0__[\"default\"]\n },\n inject: ['http'],\n props: {\n name: {\n default: undefined\n }\n },\n data() {\n return {\n title: undefined,\n show: false,\n uuid: undefined,\n fullscreen: false,\n width: '80%',\n js: undefined,\n style: 'height:70vh',\n selectionMode: 'multiple',\n // 'single' | 'multiple' | 'none'\n showFooter: true\n };\n },\n computed: {\n https() {\n return this.http;\n }\n },\n methods: {\n init({\n uuid,\n title,\n width,\n height,\n fullscreen,\n js,\n mode = 'multiple'\n }) {\n this.show = true;\n this.uuid = uuid;\n this.js = js;\n if (width) {\n this.width = width;\n }\n this.showFooter = mode !== 'none';\n this.title = title;\n this.fullscreen = fullscreen == true;\n if (height) {\n this.style = 'height:' + height + \"px\";\n }\n },\n ok() {\n this.$emit('emits', {\n js: this.js,\n v: this.$refs.table.getTableRefs().$refs.tableModel.getSelectRows()\n });\n },\n cancelEvent() {\n this.show = false;\n },\n handleCurrentChange(row) {\n if (this.showFooter) return;\n // 在这里执行您需要的逻辑\n // 例如,如果是单选模式,可以直接关闭对话框\n this.$emit('emits', {\n js: this.js,\n v: [row]\n });\n // 延迟关闭对话框,让用户看到选择反馈\n setTimeout(() => {\n this.cancelEvent();\n }, 300);\n }\n }\n});\n\n//# sourceURL=webpack://olp-table/./src/components/ol-dialog-table.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-82.use%5B0%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D");
391
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _components_table_model_model_index_vue__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @/components/table/model/model-index.vue */ \"./src/components/table/model/model-index.vue\");\n\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: 'olDialogTable',\n components: {\n ModelIndex: _components_table_model_model_index_vue__WEBPACK_IMPORTED_MODULE_0__[\"default\"]\n },\n inject: ['http'],\n props: {\n name: {\n default: undefined\n }\n },\n data() {\n return {\n title: undefined,\n show: false,\n uuid: undefined,\n fullscreen: false,\n width: '80%',\n js: undefined,\n style: 'height:70vh',\n selectionMode: 'multiple',\n // 'single' | 'multiple' | 'none'\n showFooter: true\n };\n },\n computed: {\n https() {\n return this.http;\n }\n },\n methods: {\n init({\n uuid,\n title,\n width,\n height,\n fullscreen,\n js,\n mode = 'multiple'\n }) {\n this.show = true;\n this.uuid = uuid;\n this.js = js;\n if (width) {\n this.width = width;\n }\n this.showFooter = mode !== 'none';\n this.title = title;\n this.fullscreen = fullscreen == true;\n if (height) {\n this.style = 'height:' + height + \"px\";\n }\n },\n ok() {\n this.$emit('emits', {\n js: this.js,\n v: this.$refs.table.getTableRefs().$refs.tableModel.getSelectRows()\n });\n },\n cancelEvent() {\n this.show = false;\n this.$emit('emits', {});\n },\n handleCurrentChange(row) {\n if (this.showFooter) return;\n // 在这里执行您需要的逻辑\n // 例如,如果是单选模式,可以直接关闭对话框\n this.$emit('emits', {\n js: this.js,\n v: [row]\n });\n // 延迟关闭对话框,让用户看到选择反馈\n setTimeout(() => {\n this.cancelEvent();\n }, 300);\n }\n }\n});\n\n//# sourceURL=webpack://olp-table/./src/components/ol-dialog-table.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-82.use%5B0%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D");
392
392
 
393
393
  /***/ }),
394
394
 
@@ -729,7 +729,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var _mix
729
729
  /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
730
730
 
731
731
  "use strict";
732
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.array.push.js */ \"./node_modules/core-js/modules/es.array.push.js\");\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/es.iterator.constructor.js */ \"./node_modules/core-js/modules/es.iterator.constructor.js\");\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! core-js/modules/es.iterator.filter.js */ \"./node_modules/core-js/modules/es.iterator.filter.js\");\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var _components_table_ol_table_operate_index_vue__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @/components/table/ol-table-operate/index.vue */ \"./src/components/table/ol-table-operate/index.vue\");\n/* harmony import */ var _utils_tree__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @/utils/tree */ \"./src/utils/tree.js\");\n/* harmony import */ var _utils_message__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @/utils/message */ \"./src/utils/message.js\");\n/* harmony import */ var _utils_object__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @/utils/object */ \"./src/utils/object.js\");\n/* harmony import */ var _components_table_ol_form_index_vue__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @/components/table/ol-form/index.vue */ \"./src/components/table/ol-form/index.vue\");\n/* harmony import */ var _utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @/utils/http/httpUtils */ \"./src/utils/http/httpUtils.js\");\n/* harmony import */ var vxe_table__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! vxe-table */ \"vxe-table\");\n/* harmony import */ var vxe_table__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(vxe_table__WEBPACK_IMPORTED_MODULE_9__);\n\n\n\n\n\n\n\n\n\n\nconst {\n error\n} = (0,_utils_message__WEBPACK_IMPORTED_MODULE_5__.useMessage)(); // 消息弹窗\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: \"oTree\",\n components: {\n olForm: _components_table_ol_form_index_vue__WEBPACK_IMPORTED_MODULE_7__[\"default\"],\n olTableOperate: _components_table_ol_table_operate_index_vue__WEBPACK_IMPORTED_MODULE_3__[\"default\"]\n },\n props: {\n treeConfig: {},\n deleteParameter: {},\n toolButOptions: {},\n formMainList: {}\n },\n inject: ['tableAll', 'http'],\n computed: {\n props() {\n return {\n key: this.treeConfig.value,\n label: this.treeConfig.label,\n children: this.treeConfig.children\n };\n }\n },\n data() {\n return {\n data: [],\n search: '关键字搜索',\n filterText: \"\",\n loading: false,\n value: '',\n clickBtn: false\n };\n },\n methods: {\n nodeClick(params) {\n if (this.clickBtn) {\n return;\n }\n if (this.treeConfig.optionJson.eventsValue && this.treeConfig.optionJson.eventsValue['node-click']) {\n eval(this.treeConfig.optionJson.eventsValue['node-click']);\n } else if (this.treeConfig.tableQueryParams) {\n this.doRightTable(params);\n }\n },\n doGetParams(param, v, getParams) {\n let kv = param.split(\":\");\n if (kv.length == 1) {\n this.doSet(getParams, kv[0], v[kv[0]]);\n } else {\n if (param.indexOf(\"$\") != -1) {\n this.doSet(getParams, kv[0], (0,_utils_object__WEBPACK_IMPORTED_MODULE_6__.fillTemplate)(kv[1], v));\n } else {\n this.doSet(getParams, kv[0], v[kv[1]]);\n }\n }\n if (this.treeConfig.selectChildren === \"1\") {\n this.doChildren(param, v, getParams);\n }\n },\n doSet(obj, k, v) {\n if (obj[k]) {\n if (obj[k] instanceof Array) {\n obj[k].push(v);\n } else {\n obj[k] = [obj[k], v];\n }\n } else {\n obj[k] = v;\n }\n },\n doChildren(param, v, getParams) {\n if (v && v.children) {\n for (let child of v.children) {\n this.doGetParams(param, child, getParams);\n }\n }\n },\n doRightTable(v) {\n let getParams = {};\n let paramsStr = this.treeConfig.tableQueryParams.trim();\n if (paramsStr.indexOf(\",\") != -1) {\n let params = paramsStr.split(\",\");\n for (let param of params) {\n this.doGetParams(param, v, getParams);\n }\n } else {\n this.doGetParams(paramsStr, v, getParams);\n }\n this.tableAll.t1['dbName'] = v.dict_value;\n this.tableAll.t1.queryParams(getParams, true);\n },\n async handleOperationClick(e) {\n this.clickBtn = true;\n setTimeout(() => {\n this.clickBtn = false;\n }, 100);\n let {\n obj,\n row\n } = e;\n if (obj.customFunction && obj.customFunction.toString().trim().length != 0) {\n eval(obj.customFunction);\n } else if (obj.code == \"refresh\") {\n this.doQuery();\n } else if (obj.code == \"delete\") {\n await this.remove(e);\n } else if (obj.code == 'edit' || obj.code == 'add') {\n let form = {};\n if (obj.code == 'edit') {\n form = this.formMainList.edit;\n } else if (obj.code == 'add') {\n form = this.formMainList.add;\n }\n let formJsonStr = form.formJson[form.formMain.designer == 0 ? 'optionJson' : 'customJson'];\n let data = {\n type: form.formMain.designer,\n saveUrl: form.formMain.saveUrl,\n requestType: form.formMain.requestType,\n updateKey: form.formMain.updateKey,\n otherProp: form.formMain.otherProp,\n formData: row,\n theme: this.theme,\n form: JSON.parse(formJsonStr),\n tableConfigId: this.treeConfig.id,\n dbName: this.treeConfig.dbName,\n tableName: this.treeConfig.mainTable,\n code: obj.code,\n disabled: false\n };\n data.form = JSON.parse(form.formJson[data.type == 0 ? 'optionJson' : 'customJson']);\n if (obj.code == 'edit') {\n data.updateKey = form.formMain.updateKey;\n this.$refs[\"form\"].init(data, true);\n }\n if (obj.code == 'add') {\n data.formData = {};\n this.$refs[\"form\"].init(data);\n }\n }\n this.$emit(\"handleOperationClick\", e);\n },\n /**\r\n * 内置确认框\r\n * @param content\r\n * @param title\r\n * @param status\r\n * @returns {Promise<\"model\"|\"mask\"|\"close\"|\"confirm\"|\"cancel\"|\"exit\"|\"exist\">}\r\n */\n async confirm(content, title, status) {\n return await vxe_table__WEBPACK_IMPORTED_MODULE_9___default().modal.confirm({\n content: content,\n title: title,\n status: status\n });\n },\n /**\r\n * 内置删除方法\r\n * @param o\r\n * @returns {Promise<void>}\r\n */\n async remove(o) {\n let {\n row\n } = o;\n this.confirm('数据删除后不可恢复,您确定要删除吗?', '删除提示', 'error').then(type => {\n if (type != \"cancel\") {\n if (row && row.children) {\n return error('存在包含子数据的记录,禁止删除!');\n }\n let params = {};\n for (let key of Object.keys(this.deleteParameter)) {\n if (key != '$parentId') {\n params[key] = row[key];\n }\n }\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_8__.postAes)(this.http, '/online/crudAes/delete', {\n where: params,\n dbName: this.treeConfig.dbName,\n tableName: this.treeConfig.mainTable\n }).then(r => {\n if (r != false) {\n this.doQuery();\n }\n });\n }\n });\n },\n load(node, resolve) {\n if (node.level === 0) {\n return;\n } else {\n this.value = node.data[this.treeConfig.value];\n }\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_8__.postAes)(this.http, '/online/crudAes/query', this.getParams(), false, false).then(({\n data,\n code,\n msg\n }) => {\n if (code != 200) {\n error(msg);\n return;\n }\n resolve(data.listData);\n });\n },\n getParams(params) {\n if (!params) {\n params = {\n id: this.treeConfig.uuid,\n queryType: 1,\n enablePage: false\n };\n }\n if (this.value) {\n let lazyValue = this.value.trim();\n if (lazyValue.indexOf(\"=\") != -1) {\n params.executeWhere = lazyValue;\n } else {\n params.executeWhere = this.treeConfig.treeParentId.trim() + \"='\" + lazyValue + \"'\";\n }\n }\n return params;\n },\n doQuery(params) {\n this.loading = true;\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_8__.postAes)(this.http, '/online/crudAes/query', this.getParams(params), false, false).then(({\n data,\n code,\n msg\n }) => {\n if (code != 200) {\n error(msg);\n return;\n }\n if (this.treeConfig.convertTree == 1) {\n this.data = (0,_utils_tree__WEBPACK_IMPORTED_MODULE_4__.handleTree)(data.listData, this.treeConfig.treeId, this.treeConfig.treeParentId);\n } else {\n this.data = data.listData;\n }\n }).finally(() => {\n this.loading = false;\n });\n },\n filterNode(value, data) {\n if (!this.treeShow) {\n this.treeShow = value;\n }\n if (!value) return true;\n return data[this.treeConfig.label].indexOf(value) !== -1;\n }\n },\n watch: {\n filterText(val) {\n this.$refs.treeBox.filter(val);\n }\n },\n created() {\n this.$nextTick(() => {\n if (this.treeConfig.autoInit == 1) {\n if (this.treeConfig.lazy == 1 && this.treeConfig.firstLazyValue != '' && this.treeConfig.firstLazyValue != undefined) {\n this.value = this.treeConfig.firstLazyValue.toString().trim();\n }\n this.doQuery();\n }\n this.$emit(\"initOk\");\n });\n }\n});\n\n//# sourceURL=webpack://olp-table/./src/components/tree/components/o-tree.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-82.use%5B0%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D");
732
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.array.push.js */ \"./node_modules/core-js/modules/es.array.push.js\");\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/es.iterator.constructor.js */ \"./node_modules/core-js/modules/es.iterator.constructor.js\");\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! core-js/modules/es.iterator.filter.js */ \"./node_modules/core-js/modules/es.iterator.filter.js\");\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var _components_table_ol_table_operate_index_vue__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @/components/table/ol-table-operate/index.vue */ \"./src/components/table/ol-table-operate/index.vue\");\n/* harmony import */ var _utils_tree__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @/utils/tree */ \"./src/utils/tree.js\");\n/* harmony import */ var _utils_message__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @/utils/message */ \"./src/utils/message.js\");\n/* harmony import */ var _utils_object__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @/utils/object */ \"./src/utils/object.js\");\n/* harmony import */ var _components_table_ol_form_index_vue__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @/components/table/ol-form/index.vue */ \"./src/components/table/ol-form/index.vue\");\n/* harmony import */ var _utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @/utils/http/httpUtils */ \"./src/utils/http/httpUtils.js\");\n/* harmony import */ var vxe_table__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! vxe-table */ \"vxe-table\");\n/* harmony import */ var vxe_table__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(vxe_table__WEBPACK_IMPORTED_MODULE_9__);\n\n\n\n\n\n\n\n\n\n\nconst {\n error\n} = (0,_utils_message__WEBPACK_IMPORTED_MODULE_5__.useMessage)(); // 消息弹窗\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: \"oTree\",\n components: {\n olForm: _components_table_ol_form_index_vue__WEBPACK_IMPORTED_MODULE_7__[\"default\"],\n olTableOperate: _components_table_ol_table_operate_index_vue__WEBPACK_IMPORTED_MODULE_3__[\"default\"]\n },\n props: {\n treeConfig: {},\n deleteParameter: {},\n toolButOptions: {},\n formMainList: {}\n },\n inject: ['tableAll', 'http'],\n computed: {\n props() {\n return {\n key: this.treeConfig.value,\n label: this.treeConfig.label,\n children: this.treeConfig.children\n };\n }\n },\n data() {\n return {\n data: [],\n search: '关键字搜索',\n filterText: \"\",\n loading: false,\n value: '',\n clickBtn: false\n };\n },\n methods: {\n nodeClick(params) {\n if (this.clickBtn) {\n return;\n }\n if (this.treeConfig.optionJson.eventsValue && this.treeConfig.optionJson.eventsValue['node-click']) {\n eval(this.treeConfig.optionJson.eventsValue['node-click']);\n } else if (this.treeConfig.tableQueryParams) {\n this.doRightTable(params);\n }\n },\n doGetParams(param, v, getParams) {\n let kv = param.split(\":\");\n if (kv.length == 1) {\n this.doSet(getParams, kv[0], v[kv[0]]);\n } else {\n if (param.indexOf(\"$\") != -1) {\n this.doSet(getParams, kv[0], (0,_utils_object__WEBPACK_IMPORTED_MODULE_6__.fillTemplate)(kv[1], v));\n } else {\n this.doSet(getParams, kv[0], v[kv[1]]);\n }\n }\n if (this.treeConfig.selectChildren === \"1\") {\n this.doChildren(param, v, getParams);\n }\n },\n doSet(obj, k, v) {\n if (obj[k]) {\n if (obj[k] instanceof Array) {\n obj[k].push(v);\n } else {\n obj[k] = [obj[k], v];\n }\n } else {\n obj[k] = v;\n }\n },\n doChildren(param, v, getParams) {\n if (v && v.children) {\n for (let child of v.children) {\n this.doGetParams(param, child, getParams);\n }\n }\n },\n doRightTable(v) {\n let getParams = {};\n let paramsStr = this.treeConfig.tableQueryParams.trim();\n if (paramsStr.indexOf(\",\") != -1) {\n let params = paramsStr.split(\",\");\n for (let param of params) {\n this.doGetParams(param, v, getParams);\n }\n } else {\n this.doGetParams(paramsStr, v, getParams);\n }\n this.tableAll.t1['dbName'] = v.dict_value;\n this.tableAll.t1.queryParams(getParams, true);\n },\n async handleOperationClick(e) {\n this.clickBtn = true;\n setTimeout(() => {\n this.clickBtn = false;\n }, 100);\n let {\n obj,\n row\n } = e;\n if (obj.customFunction && obj.customFunction.toString().trim().length != 0) {\n eval(obj.customFunction);\n } else if (obj.code == \"refresh\") {\n this.doQuery();\n } else if (obj.code == \"delete\") {\n await this.remove(e);\n } else if (obj.code == 'edit' || obj.code == 'add') {\n let form = {};\n if (obj.code == 'edit') {\n form = this.formMainList.edit;\n } else if (obj.code == 'add') {\n form = this.formMainList.add;\n }\n let formJsonStr = form.formJson[form.formMain.designer == 0 ? 'optionJson' : 'customJson'];\n let data = {\n type: form.formMain.designer,\n saveUrl: form.formMain.saveUrl,\n requestType: form.formMain.requestType,\n updateKey: form.formMain.updateKey,\n otherProp: form.formMain.otherProp,\n formData: row,\n theme: this.theme,\n form: JSON.parse(formJsonStr),\n tableConfigId: this.treeConfig.id,\n dbName: this.treeConfig.dbName,\n tableName: this.treeConfig.mainTable,\n code: obj.code,\n disabled: false\n };\n data.form = JSON.parse(form.formJson[data.type == 0 ? 'optionJson' : 'customJson']);\n if (obj.code == 'edit') {\n data.updateKey = form.formMain.updateKey;\n this.$refs[\"form\"].init(data, true);\n }\n if (obj.code == 'add') {\n data.formData = {};\n data.formData[this.treeConfig.treeParentId] = row[this.treeConfig.treeId];\n this.$refs[\"form\"].init(data);\n }\n }\n this.$emit(\"handleOperationClick\", e);\n },\n /**\r\n * 内置确认框\r\n * @param content\r\n * @param title\r\n * @param status\r\n * @returns {Promise<\"model\"|\"mask\"|\"close\"|\"confirm\"|\"cancel\"|\"exit\"|\"exist\">}\r\n */\n async confirm(content, title, status) {\n return await vxe_table__WEBPACK_IMPORTED_MODULE_9___default().modal.confirm({\n content: content,\n title: title,\n status: status\n });\n },\n /**\r\n * 内置删除方法\r\n * @param o\r\n * @returns {Promise<void>}\r\n */\n async remove(o) {\n let {\n row\n } = o;\n this.confirm('数据删除后不可恢复,您确定要删除吗?', '删除提示', 'error').then(type => {\n if (type != \"cancel\") {\n if (row && row.children) {\n return error('存在包含子数据的记录,禁止删除!');\n }\n let params = {};\n for (let key of Object.keys(this.deleteParameter)) {\n if (key != '$parentId') {\n params[key] = row[key];\n }\n }\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_8__.postAes)(this.http, '/online/crudAes/delete', {\n where: params,\n dbName: this.treeConfig.dbName,\n tableName: this.treeConfig.mainTable\n }).then(r => {\n if (r != false) {\n this.doQuery();\n }\n });\n }\n });\n },\n load(node, resolve) {\n if (node.level === 0) {\n return;\n } else {\n this.value = node.data[this.treeConfig.value];\n }\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_8__.postAes)(this.http, '/online/crudAes/query', this.getParams(), false, false).then(({\n data,\n code,\n msg\n }) => {\n if (code != 200) {\n error(msg);\n return;\n }\n resolve(data.listData);\n });\n },\n getParams(params) {\n if (!params) {\n params = {\n id: this.treeConfig.uuid,\n queryType: 1,\n enablePage: false\n };\n }\n if (this.value) {\n let lazyValue = this.value.trim();\n if (lazyValue.indexOf(\"=\") != -1) {\n params.executeWhere = lazyValue;\n } else {\n params.executeWhere = this.treeConfig.treeParentId.trim() + \"='\" + lazyValue + \"'\";\n }\n }\n return params;\n },\n doQuery(params) {\n this.loading = true;\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_8__.postAes)(this.http, '/online/crudAes/query', this.getParams(params), false, false).then(({\n data,\n code,\n msg\n }) => {\n if (code != 200) {\n error(msg);\n return;\n }\n if (this.treeConfig.convertTree == 1) {\n this.data = (0,_utils_tree__WEBPACK_IMPORTED_MODULE_4__.handleTree)(data.listData, this.treeConfig.treeId, this.treeConfig.treeParentId);\n } else {\n this.data = data.listData;\n }\n }).finally(() => {\n this.loading = false;\n });\n },\n filterNode(value, data) {\n if (!this.treeShow) {\n this.treeShow = value;\n }\n if (!value) return true;\n return data[this.treeConfig.label].indexOf(value) !== -1;\n }\n },\n watch: {\n filterText(val) {\n this.$refs.treeBox.filter(val);\n }\n },\n created() {\n this.$nextTick(() => {\n if (this.treeConfig.autoInit == 1) {\n if (this.treeConfig.lazy == 1 && this.treeConfig.firstLazyValue != '' && this.treeConfig.firstLazyValue != undefined) {\n this.value = this.treeConfig.firstLazyValue.toString().trim();\n }\n this.doQuery();\n }\n this.$emit(\"initOk\");\n });\n }\n});\n\n//# sourceURL=webpack://olp-table/./src/components/tree/components/o-tree.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-82.use%5B0%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D");
733
733
 
734
734
  /***/ }),
735
735
 
@@ -1433,7 +1433,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpac
1433
1433
  /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
1434
1434
 
1435
1435
  "use strict";
1436
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ render: function() { return /* binding */ render; }\n/* harmony export */ });\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.iterator.constructor.js */ \"./node_modules/core-js/modules/es.iterator.constructor.js\");\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/es.iterator.filter.js */ \"./node_modules/core-js/modules/es.iterator.filter.js\");\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! vue */ \"vue\");\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(vue__WEBPACK_IMPORTED_MODULE_2__);\n\n\n\nconst _hoisted_1 = {\n class: \"static-content-item\"\n};\nconst _hoisted_2 = {\n class: \"static-content-item\"\n};\nconst _hoisted_3 = {\n class: \"static-content-item\"\n};\nconst _hoisted_4 = {\n class: \"static-content-item\"\n};\nfunction render(_ctx, _cache, $props, $setup, $data, $options) {\n const _component_Upload = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"Upload\");\n const _component_el_icon = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-icon\");\n const _component_el_button = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-button\");\n const _component_el_upload = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-upload\");\n const _component_el_col = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-col\");\n const _component_Download = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"Download\");\n const _component_Delete = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"Delete\");\n const _component_el_option = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-option\");\n const _component_el_select = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-select\");\n const _component_el_form_item = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-form-item\");\n const _component_el_row = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-row\");\n const _component_vxe_grid = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"vxe-grid\");\n const _component_el_form = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-form\");\n const _component_el_Dialog = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-Dialog\");\n return (0,vue__WEBPACK_IMPORTED_MODULE_2__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createBlock)(_component_el_Dialog, {\n modelValue: $data.show,\n \"onUpdate:modelValue\": _cache[1] || (_cache[1] = $event => $data.show = $event),\n \"destroy-on-close\": \"\",\n title: $props.title,\n width: $props.width,\n center: $props.center,\n draggable: $props.draggable,\n \"show-footer\": \"\"\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_form, {\n model: $data.formData,\n ref: \"formRef\",\n \"label-width\": \"80px\",\n class: \"el-form-globals\"\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_row, null, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_col, {\n xs: 24,\n sm: 4,\n md: 4,\n lg: 4\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createElementVNode)(\"div\", _hoisted_1, [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_upload, {\n ref: \"uploadRef\",\n action: $data.formData.action,\n \"http-request\": $options.customUpload,\n \"show-file-list\": false\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_button, null, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [_cache[2] || (_cache[2] = (0,vue__WEBPACK_IMPORTED_MODULE_2__.createTextVNode)(\"上传预览 \")), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_icon, {\n class: \"el-icon--right\"\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_Upload)]),\n _: 1 /* STABLE */\n })]),\n _: 1 /* STABLE */,\n __: [2]\n })]),\n _: 1 /* STABLE */\n }, 8 /* PROPS */, [\"action\", \"http-request\"])])]),\n _: 1 /* STABLE */\n }), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_col, {\n xs: 24,\n sm: 4,\n md: 4,\n lg: 4\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createElementVNode)(\"div\", _hoisted_2, [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_button, {\n onClick: $options.submit\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [_cache[3] || (_cache[3] = (0,vue__WEBPACK_IMPORTED_MODULE_2__.createTextVNode)(\"立即上传 \")), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_icon, {\n class: \"el-icon--right\"\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_Upload)]),\n _: 1 /* STABLE */\n })]),\n _: 1 /* STABLE */,\n __: [3]\n }, 8 /* PROPS */, [\"onClick\"])])]),\n _: 1 /* STABLE */\n }), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_col, {\n xs: 24,\n sm: 4,\n md: 4,\n lg: 4\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createElementVNode)(\"div\", _hoisted_3, [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_button, {\n onClick: $options.download\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [_cache[4] || (_cache[4] = (0,vue__WEBPACK_IMPORTED_MODULE_2__.createTextVNode)(\"下载模板 \")), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_icon, {\n class: \"el-icon--right\"\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_Download)]),\n _: 1 /* STABLE */\n })]),\n _: 1 /* STABLE */,\n __: [4]\n }, 8 /* PROPS */, [\"onClick\"])])]),\n _: 1 /* STABLE */\n }), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_col, {\n xs: 24,\n sm: 4,\n md: 4,\n lg: 4\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createElementVNode)(\"div\", _hoisted_4, [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_button, {\n disabled: $data.formData.disabled,\n class: (0,vue__WEBPACK_IMPORTED_MODULE_2__.normalizeClass)($data.formData.selected_but),\n onClick: $options.batchRemove\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [_cache[5] || (_cache[5] = (0,vue__WEBPACK_IMPORTED_MODULE_2__.createTextVNode)(\"批量删除 \")), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_icon, {\n class: \"el-icon--right\"\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_Delete)]),\n _: 1 /* STABLE */\n })]),\n _: 1 /* STABLE */,\n __: [5]\n }, 8 /* PROPS */, [\"disabled\", \"class\", \"onClick\"])])]),\n _: 1 /* STABLE */\n }), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_col, {\n xs: 24,\n sm: 8,\n md: 8,\n lg: 8\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_form_item, {\n label: \"校验唯一\",\n prop: \"uniCode\"\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_select, {\n modelValue: $data.formData.uniCode,\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = $event => $data.formData.uniCode = $event),\n onChange: $options.handleChange,\n class: \"full-width-input\",\n clearable: \"\"\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [((0,vue__WEBPACK_IMPORTED_MODULE_2__.openBlock)(true), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createElementBlock)(vue__WEBPACK_IMPORTED_MODULE_2__.Fragment, null, (0,vue__WEBPACK_IMPORTED_MODULE_2__.renderList)($data.gridOptions.columns.filter(o => o.field), (item, index) => {\n return (0,vue__WEBPACK_IMPORTED_MODULE_2__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createBlock)(_component_el_option, {\n key: index,\n label: item.title,\n value: item.title,\n disabled: item.disabled\n }, null, 8 /* PROPS */, [\"label\", \"value\", \"disabled\"]);\n }), 128 /* KEYED_FRAGMENT */))]),\n _: 1 /* STABLE */\n }, 8 /* PROPS */, [\"modelValue\", \"onChange\"])]),\n _: 1 /* STABLE */\n })]),\n _: 1 /* STABLE */\n })]),\n _: 1 /* STABLE */\n }), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_row, null, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_vxe_grid, (0,vue__WEBPACK_IMPORTED_MODULE_2__.mergeProps)({\n style: {\n \"width\": \"100%\"\n },\n ref: \"xGrid\"\n }, $data.gridOptions, {\n onCheckboxChange: $options.selectRowChange,\n onCheckboxAll: $options.selectRowChange\n }), null, 16 /* FULL_PROPS */, [\"onCheckboxChange\", \"onCheckboxAll\"])]),\n _: 1 /* STABLE */\n })]),\n _: 1 /* STABLE */\n }, 8 /* PROPS */, [\"model\"])]),\n footer: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_button, {\n onClick: $options.close\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => _cache[6] || (_cache[6] = [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createTextVNode)(\"关闭\")])),\n _: 1 /* STABLE */,\n __: [6]\n }, 8 /* PROPS */, [\"onClick\"])]),\n _: 1 /* STABLE */\n }, 8 /* PROPS */, [\"modelValue\", \"title\", \"width\", \"center\", \"draggable\"]);\n}\n\n//# sourceURL=webpack://olp-table/./src/components/ol-dialog-import.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-82.use%5B0%5D!./node_modules/vue-loader/dist/templateLoader.js??ruleSet%5B1%5D.rules%5B3%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D");
1436
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ render: function() { return /* binding */ render; }\n/* harmony export */ });\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.iterator.constructor.js */ \"./node_modules/core-js/modules/es.iterator.constructor.js\");\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/es.iterator.filter.js */ \"./node_modules/core-js/modules/es.iterator.filter.js\");\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! vue */ \"vue\");\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(vue__WEBPACK_IMPORTED_MODULE_2__);\n\n\n\nconst _hoisted_1 = {\n class: \"static-content-item\"\n};\nconst _hoisted_2 = {\n class: \"static-content-item\"\n};\nconst _hoisted_3 = {\n class: \"static-content-item\"\n};\nconst _hoisted_4 = {\n class: \"static-content-item\"\n};\nfunction render(_ctx, _cache, $props, $setup, $data, $options) {\n const _component_Upload = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"Upload\");\n const _component_el_icon = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-icon\");\n const _component_el_button = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-button\");\n const _component_el_upload = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-upload\");\n const _component_el_col = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-col\");\n const _component_Download = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"Download\");\n const _component_Delete = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"Delete\");\n const _component_el_option = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-option\");\n const _component_el_select = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-select\");\n const _component_el_form_item = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-form-item\");\n const _component_el_row = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-row\");\n const _component_vxe_grid = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"vxe-grid\");\n const _component_el_form = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-form\");\n const _component_el_dialog = (0,vue__WEBPACK_IMPORTED_MODULE_2__.resolveComponent)(\"el-dialog\");\n return (0,vue__WEBPACK_IMPORTED_MODULE_2__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createBlock)(_component_el_dialog, {\n modelValue: $data.show,\n \"onUpdate:modelValue\": _cache[1] || (_cache[1] = $event => $data.show = $event),\n \"destroy-on-close\": \"\",\n title: $props.title,\n width: $props.width,\n center: $props.center,\n \"close-on-press-escape\": false,\n draggable: $props.draggable,\n \"show-footer\": \"\"\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_form, {\n model: $data.formData,\n ref: \"formRef\",\n \"label-width\": \"80px\",\n class: \"el-form-globals\"\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_row, null, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_col, {\n xs: 24,\n sm: 4,\n md: 4,\n lg: 4\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createElementVNode)(\"div\", _hoisted_1, [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_upload, {\n ref: \"uploadRef\",\n action: $data.formData.action,\n \"http-request\": $options.customUpload,\n \"show-file-list\": false\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_button, null, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [_cache[2] || (_cache[2] = (0,vue__WEBPACK_IMPORTED_MODULE_2__.createTextVNode)(\"上传预览 \")), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_icon, {\n class: \"el-icon--right\"\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_Upload)]),\n _: 1 /* STABLE */\n })]),\n _: 1 /* STABLE */,\n __: [2]\n })]),\n _: 1 /* STABLE */\n }, 8 /* PROPS */, [\"action\", \"http-request\"])])]),\n _: 1 /* STABLE */\n }), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_col, {\n xs: 24,\n sm: 4,\n md: 4,\n lg: 4\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createElementVNode)(\"div\", _hoisted_2, [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_button, {\n onClick: $options.submit\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [_cache[3] || (_cache[3] = (0,vue__WEBPACK_IMPORTED_MODULE_2__.createTextVNode)(\"立即上传 \")), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_icon, {\n class: \"el-icon--right\"\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_Upload)]),\n _: 1 /* STABLE */\n })]),\n _: 1 /* STABLE */,\n __: [3]\n }, 8 /* PROPS */, [\"onClick\"])])]),\n _: 1 /* STABLE */\n }), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_col, {\n xs: 24,\n sm: 4,\n md: 4,\n lg: 4\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createElementVNode)(\"div\", _hoisted_3, [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_button, {\n onClick: $options.download\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [_cache[4] || (_cache[4] = (0,vue__WEBPACK_IMPORTED_MODULE_2__.createTextVNode)(\"下载模板 \")), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_icon, {\n class: \"el-icon--right\"\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_Download)]),\n _: 1 /* STABLE */\n })]),\n _: 1 /* STABLE */,\n __: [4]\n }, 8 /* PROPS */, [\"onClick\"])])]),\n _: 1 /* STABLE */\n }), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_col, {\n xs: 24,\n sm: 4,\n md: 4,\n lg: 4\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createElementVNode)(\"div\", _hoisted_4, [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_button, {\n disabled: $data.formData.disabled,\n class: (0,vue__WEBPACK_IMPORTED_MODULE_2__.normalizeClass)($data.formData.selected_but),\n onClick: $options.batchRemove\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [_cache[5] || (_cache[5] = (0,vue__WEBPACK_IMPORTED_MODULE_2__.createTextVNode)(\"批量删除 \")), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_icon, {\n class: \"el-icon--right\"\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_Delete)]),\n _: 1 /* STABLE */\n })]),\n _: 1 /* STABLE */,\n __: [5]\n }, 8 /* PROPS */, [\"disabled\", \"class\", \"onClick\"])])]),\n _: 1 /* STABLE */\n }), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_col, {\n xs: 24,\n sm: 8,\n md: 8,\n lg: 8\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_form_item, {\n label: \"校验唯一\",\n prop: \"uniCode\"\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_select, {\n modelValue: $data.formData.uniCode,\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = $event => $data.formData.uniCode = $event),\n onChange: $options.handleChange,\n class: \"full-width-input\",\n clearable: \"\"\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [((0,vue__WEBPACK_IMPORTED_MODULE_2__.openBlock)(true), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createElementBlock)(vue__WEBPACK_IMPORTED_MODULE_2__.Fragment, null, (0,vue__WEBPACK_IMPORTED_MODULE_2__.renderList)($data.gridOptions.columns.filter(o => o.field), (item, index) => {\n return (0,vue__WEBPACK_IMPORTED_MODULE_2__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createBlock)(_component_el_option, {\n key: index,\n label: item.title,\n value: item.title,\n disabled: item.disabled\n }, null, 8 /* PROPS */, [\"label\", \"value\", \"disabled\"]);\n }), 128 /* KEYED_FRAGMENT */))]),\n _: 1 /* STABLE */\n }, 8 /* PROPS */, [\"modelValue\", \"onChange\"])]),\n _: 1 /* STABLE */\n })]),\n _: 1 /* STABLE */\n })]),\n _: 1 /* STABLE */\n }), (0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_row, null, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_vxe_grid, (0,vue__WEBPACK_IMPORTED_MODULE_2__.mergeProps)({\n style: {\n \"width\": \"100%\"\n },\n ref: \"xGrid\"\n }, $data.gridOptions, {\n onCheckboxChange: $options.selectRowChange,\n onCheckboxAll: $options.selectRowChange\n }), null, 16 /* FULL_PROPS */, [\"onCheckboxChange\", \"onCheckboxAll\"])]),\n _: 1 /* STABLE */\n })]),\n _: 1 /* STABLE */\n }, 8 /* PROPS */, [\"model\"])]),\n footer: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createVNode)(_component_el_button, {\n onClick: $options.close\n }, {\n default: (0,vue__WEBPACK_IMPORTED_MODULE_2__.withCtx)(() => _cache[6] || (_cache[6] = [(0,vue__WEBPACK_IMPORTED_MODULE_2__.createTextVNode)(\"关闭\")])),\n _: 1 /* STABLE */,\n __: [6]\n }, 8 /* PROPS */, [\"onClick\"])]),\n _: 1 /* STABLE */\n }, 8 /* PROPS */, [\"modelValue\", \"title\", \"width\", \"center\", \"draggable\"]);\n}\n\n//# sourceURL=webpack://olp-table/./src/components/ol-dialog-import.vue?./node_modules/babel-loader/lib/index.js??clonedRuleSet-82.use%5B0%5D!./node_modules/vue-loader/dist/templateLoader.js??ruleSet%5B1%5D.rules%5B3%5D!./node_modules/vue-loader/dist/index.js??ruleSet%5B0%5D.use%5B0%5D");
1437
1437
 
1438
1438
  /***/ }),
1439
1439
 
@@ -12721,7 +12721,7 @@ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpac
12721
12721
  /***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
12722
12722
 
12723
12723
  "use strict";
12724
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ OTMixinBodyMethods: function() { return /* binding */ OTMixinBodyMethods; }\n/* harmony export */ });\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.array.push.js */ \"./node_modules/core-js/modules/es.array.push.js\");\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/es.iterator.constructor.js */ \"./node_modules/core-js/modules/es.iterator.constructor.js\");\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! core-js/modules/es.iterator.filter.js */ \"./node_modules/core-js/modules/es.iterator.filter.js\");\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var core_js_modules_es_iterator_some_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! core-js/modules/es.iterator.some.js */ \"./node_modules/core-js/modules/es.iterator.some.js\");\n/* harmony import */ var core_js_modules_es_iterator_some_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_some_js__WEBPACK_IMPORTED_MODULE_3__);\n/* harmony import */ var _store_dict__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @/store/dict */ \"./src/store/dict.js\");\n/* harmony import */ var _store_dictType__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @/store/dictType */ \"./src/store/dictType.js\");\n/* harmony import */ var _utils_util__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @/utils/util */ \"./src/utils/util.js\");\n/* harmony import */ var _utils_message__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @/utils/message */ \"./src/utils/message.js\");\n/* harmony import */ var _utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @/utils/http/httpUtils */ \"./src/utils/http/httpUtils.js\");\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! vue */ \"vue\");\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(vue__WEBPACK_IMPORTED_MODULE_9__);\n/* harmony import */ var _utils_TableSortUtil__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @/utils/TableSortUtil */ \"./src/utils/TableSortUtil.js\");\n/* harmony import */ var _mixins_VTMixin_DefaultMethods__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! @/mixins/VTMixin/DefaultMethods */ \"./src/mixins/VTMixin/DefaultMethods.js\");\n/* harmony import */ var _directives_permission_hasPermi__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! @/directives/permission/hasPermi */ \"./src/directives/permission/hasPermi.js\");\n\n\n\n\n\n\n\n\n\n\n\n\n\nconst message = (0,_utils_message__WEBPACK_IMPORTED_MODULE_7__.useMessage)(); // 消息弹窗\nconst dict = (0,_store_dict__WEBPACK_IMPORTED_MODULE_4__.storeDict)();\nconst dictType = (0,_store_dictType__WEBPACK_IMPORTED_MODULE_5__.storeDictType)();\nconst OTMixinBodyMethods = {\n mixins: [_mixins_VTMixin_DefaultMethods__WEBPACK_IMPORTED_MODULE_11__.DefaultMethods],\n emits: ['handleOperationClick', 'toolbarBtnClick', 'initComponents', 'selectRowChange'],\n methods: {\n /**\r\n * 自定义表单方法\r\n * @returns {*}\r\n */\n customerForm(show) {\n this.toggleFormDisplay();\n this.table.formConfig.show = show == true;\n return this.table.formConfig;\n },\n /**\r\n * 搜索隐藏/显示\r\n */\n toggleFormDisplay() {\n // 获取组件的根 DOM 元素\n const rootEl = this.$refs[this.table.ref].$el;\n\n // 查询第一个子标签是否为 vxe-grid--form-wrapper\n const formWrapperEl = rootEl.querySelector('.vxe-grid--form-wrapper');\n if (formWrapperEl) {\n // 查询 formWrapperEl 下的第一个 form 标签\n const formEl = formWrapperEl.querySelector('form');\n if (formEl) {\n // 获取 form 标签的当前 display 样式\n const currentDisplay = window.getComputedStyle(formEl).display;\n\n // 根据当前 display 样式设置新的样式\n if (currentDisplay === 'none') {\n // 如果当前是 none,则移除 display 样式(设置为空字符串)\n formEl.style.display = '';\n } else {\n // 否则设置为 none\n formEl.style.display = 'none';\n }\n }\n }\n },\n /**\r\n * 选中回调\r\n */\n selectRowChange() {\n let rows = this.getSelectRows();\n if (!rows) {\n return;\n }\n this.pagination.selectionRowsLength = rows.length;\n this.setToolBtn('batchDelete', 'disabled', rows.length == 0);\n rows = this.selectBox == 1 ? rows[0] : rows;\n if (this.events['selectRowChange']) {\n this.events['selectRowChange'](rows);\n }\n this.$emit(\"selectRowChange\", rows);\n },\n /**\r\n * 切换表格最大化/还原\r\n */\n zoomEvent() {\n if (this.$table) {\n this.$table.zoom();\n this.isMaximized = this.$table.isMaximized();\n }\n },\n initToolBtn(toolBut) {\n let obj = undefined;\n for (let i = 0; i < toolBut.length; i++) {\n let toolButElement = toolBut[i];\n toolButElement.disabled = toolButElement.defaultDisabled == 1;\n toolButElement.show = toolButElement.defaultShow == 1;\n if (toolButElement.code == 'sortable') {\n toolButElement.values = false;\n obj = JSON.parse(JSON.stringify(toolButElement));\n obj.id = obj.id + \"_sortable\";\n obj.name = \"调整完成\";\n obj.code = \"sortableOk\";\n obj.icon = \"vxe-icon-check\";\n obj.show = false;\n obj.disabled = true;\n obj.index = i + 1;\n }\n }\n if (obj) {\n toolBut.splice(obj.index, 0, obj);\n }\n this.toolBtn = toolBut;\n },\n initOperationBtn(operationBtn) {\n this.operationBtn = operationBtn;\n let permissEx = 0;\n for (let i = 0; i < this.operationBtn.length; i++) {\n let operationBtnElement = this.operationBtn[i];\n let flag = (0,_directives_permission_hasPermi__WEBPACK_IMPORTED_MODULE_12__.doPermission)({\n parentNode: false\n }, [this.uuid + ':' + this.theme + ':' + operationBtnElement.code]);\n if (!flag) {\n operationBtnElement.permission = false;\n permissEx++;\n }\n }\n let length = this.operationBtn.length - permissEx;\n let width = 35;\n if (length != 0) {\n if (this.table.operationWidth) {\n width = this.table.operationWidth;\n } else {\n for (let o of this.operationBtn.filter(o => o.permission !== false)) {\n width += o.name.length * (35 - length) + (o.icon !== undefined ? 5 : 0);\n }\n }\n const hasOperateColumn = this.table.columns.some(col => ['操作'].includes(col.title));\n if (!hasOperateColumn) {\n this.table.columns.push({\n title: '操作',\n width: width,\n fixed: \"right\",\n slots: {\n default: 'operate'\n }\n });\n }\n }\n },\n initTree({\n tree,\n treeId,\n treeParentId\n }) {\n if (tree == 1) {\n this.table.treeConfig = {\n show: true,\n transform: false,\n indent: 15,\n reserve: tree,\n rowField: treeId,\n parentField: treeParentId,\n treeId: treeId,\n treeParentId: treeParentId,\n iconClose: \"vxe-icon-arrow-right\",\n iconOpen: \"vxe-icon-arrow-down\"\n };\n this.table.rowConfig.keyField = treeId;\n }\n },\n initFormMainList(formMainList) {\n this.formMainList = formMainList;\n },\n async doSetComponents(customUrl, method, props, multipleProps) {\n this.customUrl = (0,vue__WEBPACK_IMPORTED_MODULE_9__.markRaw)(customUrl);\n await this.$nextTick(async () => {\n if (multipleProps == '1' || multipleProps == true) {\n doCallback(this.$refs.components[method], props);\n } else if (multipleProps == '2') {\n doCallback2(this.$refs.components[method], props);\n } else {\n this.$refs.components[method](props);\n }\n });\n },\n setComponent(url, method, props, multipleProps) {\n if (url.indexOf(\"@\") == 0) {\n this.$emit('initComponents', {\n url: url,\n method: method,\n props: props,\n multipleProps: multipleProps,\n doSetComponents: this.doSetComponents\n });\n } else {\n this.doSetComponents(__webpack_require__(\"./src sync recursive ^\\\\.\\\\/.*$\")(`./${url}`).default, method, props, multipleProps);\n }\n },\n async toolbarBtnClick(code) {\n if (code == \"batchDelete\") {\n this.batchRemove();\n this.$emit('toolbarBtnClick', code);\n return;\n } else if (code == 'download') {\n this.setComponent(\"components/ol-dialog-excel\", \"open\", {\n column: JSON.parse(JSON.stringify(this.table.columnSource)),\n selectData: this.pagination.selectionRowsLength >= 1 ? '2' : '1'\n });\n return;\n } else if (code == 'upload') {\n let {\n json\n } = this.getToolBtn(code);\n if (json) {\n json = json.replace(/([{,]\\s*)([a-zA-Z0-9_]+)(\\s*:)/g, '$1\"$2\"$3').replace(/:(\\s*)'([^']+)'(\\s*[,}])/g, ':$1\"$2\"$3'); // 修正字符串值\n json = JSON.parse(json);\n }\n this.setComponent(\"components/ol-dialog-import\", \"open\", {\n column: JSON.parse(JSON.stringify(this.table.columnSource)),\n tableConfigId: this.tableConfig.id,\n json: json,\n saveParams: {\n dbName: this.tableConfig.dbName,\n tableName: this.tableConfig.mainTable,\n tableConfigId: this.tableConfig.id\n }\n });\n return;\n } else if (code == 'sortable') {\n this.sortableClick();\n return;\n } else if (code == 'sortableOk') {\n this.loading['sortableOk'] = true;\n this.sortableOkClick();\n return;\n }\n let customFunction = this.getToolBtn(code).customFunction;\n if (customFunction != undefined && customFunction.toString().trim().length > 0) {\n eval(customFunction);\n } else if (code == 'add') {\n this.showForm(code);\n }\n this.$emit('toolbarBtnClick', code);\n },\n getBtnJson(code) {\n for (const toolBtn of this.operationBtn) {\n if (toolBtn.code == code) {\n return this.getSubParam(toolBtn.json);\n }\n }\n for (const toolBtn of this.toolBtn) {\n if (toolBtn.code == code) {\n return this.getSubParam(toolBtn.json);\n }\n }\n },\n getDeleteId(param) {\n for (let key of Object.keys(param)) {\n if (key != '$parentId') {\n return key;\n }\n }\n },\n sortableClick() {\n for (let toolBtn of this.toolBtn) {\n if (toolBtn.code == 'sortable') {\n toolBtn.values = !toolBtn.values;\n this.loading['sortableOk'] = false;\n this.setToolBtn('sortableOk', 'show', toolBtn.values);\n toolBtn.start = 999999;\n toolBtn.end = -1;\n if (toolBtn.values) {\n if (toolBtn.beforeFunction == undefined || toolBtn.beforeFunction == '' || toolBtn.beforeFunction.split(\",\") < 2) {\n message.error(\"排序字段未配置,请在做工具栏按钮配置中配置参数1(sort,id)\");\n return;\n }\n toolBtn.updateData = {};\n toolBtn.$elm = (0,_utils_TableSortUtil__WEBPACK_IMPORTED_MODULE_10__.updateSortRowCall)(this.$table, (oldIndex, newIndex) => {\n let start = Math.min(oldIndex, newIndex);\n let end = Math.max(oldIndex, newIndex);\n toolBtn.start = Math.min(start, toolBtn.start);\n toolBtn.end = Math.max(end, toolBtn.end);\n this.setToolBtn('sortableOk', 'disabled', false);\n this.table.data = (0,_utils_TableSortUtil__WEBPACK_IMPORTED_MODULE_10__.getNewArrDataToolBtn)(oldIndex, newIndex, this.table.data, toolBtn);\n });\n } else if (toolBtn.$elm) {\n this.setToolBtn('sortableOk', 'disabled', true);\n toolBtn.$elm.destroy();\n toolBtn.$elm = undefined;\n this.query();\n }\n return;\n }\n }\n },\n sortableOkClick() {\n for (let toolBtn of this.toolBtn) {\n if (toolBtn.code == 'sortable') {\n let url;\n this.loading['sortableOk'] = true;\n this.table.loading = true;\n let params = {\n updateList: []\n };\n //sort,id 排序字段,更新主键\n let kw = toolBtn.beforeFunction.split(\",\");\n if (toolBtn.alterFunction) {\n url = toolBtn.alterFunction;\n } else {\n url = '/online/crud/batchModify';\n params.tableConfigId = this.tableConfig.id;\n }\n //这里肯定只有一个值\n for (let key of Object.keys(toolBtn.updateData)) {\n if (toolBtn.alterFunction) {\n let kv = {};\n kv[kw[1]] = key;\n kv[kw[0]] = toolBtn.updateData[key];\n params.updateList.push(kv);\n } else {\n let columnAndValueMap = {};\n let whereMap = {};\n whereMap[kw[1]] = key;\n columnAndValueMap[kw[0]] = toolBtn.updateData[key];\n params.updateList.push({\n columnAndValueMap,\n whereMap\n });\n }\n }\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_8__.post)(this.http, url, params).then(status => {\n if (status) {\n this.query();\n this.setToolBtn('sortableOk', 'disabled', true);\n }\n }).finally(() => {\n this.loading['sortableOk'] = false;\n this.table.loading = false;\n });\n }\n }\n },\n showRender(descCode, url, title) {\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_8__.get)(this.http, '/online/formDesigner/getOne', {\n descCode: descCode\n }, undefined, true).then(d => {\n let data = {\n type: 1,\n saveUrl: url,\n title: title,\n form: JSON.parse(d.formJson),\n tableConfigId: this.tableConfig.id\n };\n this.$refs[\"form\"].init(data, false);\n });\n },\n showForm(code, formData) {\n if (!formData) {\n formData = {};\n }\n let disabled = false;\n let btnJson = this.getBtnJson(code);\n //详情\n if (code == 'details') {\n disabled = true;\n code = 'edit';\n let btnJson2 = this.getBtnJson(code);\n if (btnJson2) {\n btnJson = {\n ...btnJson,\n ...btnJson2\n };\n } else if (btnJson2 !== undefined) {\n btnJson = btnJson2;\n }\n if (!btnJson || !btnJson.title) {\n btnJson.title = '详情';\n }\n }\n let form = this.formMainList[code];\n if (!form) {\n return;\n }\n let formJsonStr = form.formJson[form.formMain.designer == 0 ? 'optionJson' : 'customJson'];\n let data = {\n type: form.formMain.designer,\n saveUrl: form.formMain.saveUrl,\n requestType: form.formMain.requestType,\n updateKey: form.formMain.updateKey,\n otherProp: form.formMain.otherProp,\n formData,\n theme: this.theme,\n form: JSON.parse(formJsonStr),\n tableConfigId: this.tableConfig.id,\n dbName: this.tableConfig.dbName,\n tableName: this.tableConfig.mainTable,\n code,\n disabled\n };\n if (btnJson && btnJson.type == 1) {\n data.uuid = btnJson.subUuid;\n data.title = btnJson.title;\n data.deleteId = btnJson.deleteId;\n data.foreignKey = btnJson.subForeignKey;\n data.exBtnDisabled = btnJson.exBtnDisabled;\n this.$refs[\"subForm\"].init(data);\n } else {\n this.$nextTick(() => {\n data.title = btnJson.title;\n this.$refs[\"form\"].init(data);\n });\n }\n },\n async handleOperationClick(o) {\n let {\n obj,\n row\n } = o;\n if (obj.customFunction) {\n eval(obj.customFunction);\n } else if (obj.code == \"delete\") {\n this.remove(o);\n } else if (obj.code == 'edit' || obj.code == 'details' || obj.isForm == 1) {\n this.showForm(obj.code, row);\n }\n this.$emit(\"handleOperationClick\", o);\n },\n getSubParam(json) {\n let obj = {\n deleteId: this.getDeleteId(this.deleteParameter)\n }; // 初始化为空对象\n if (json) {\n return {\n ...obj,\n ...JSON.parse(json)\n };\n }\n return {\n ...obj\n };\n }\n },\n created() {\n dict.init(this.http);\n dictType.init(this.http);\n }\n};\nfunction rowCamelCase(o) {\n let obj = {};\n for (let key of Object.keys(o)) {\n if (key == 'XROWKEY') {\n continue;\n }\n let k = key;\n if (re(key)) {\n k = key.substring(3);\n }\n obj[(0,_utils_util__WEBPACK_IMPORTED_MODULE_6__.toCamelCase)(k)] = o[key];\n }\n return obj;\n}\nfunction re(k) {\n let reg = /^t\\d_/;\n return reg.test(k);\n}\nfunction doCallback(fn, args) {\n for (let arg of args) {\n fn.apply(this, arg);\n }\n}\nfunction doCallback2(fn, args) {\n fn.apply(this, args);\n}\n\n//# sourceURL=webpack://olp-table/./src/mixins/VTMixin/OTMixinBodyMethods.js?");
12724
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ OTMixinBodyMethods: function() { return /* binding */ OTMixinBodyMethods; }\n/* harmony export */ });\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! core-js/modules/es.array.push.js */ \"./node_modules/core-js/modules/es.array.push.js\");\n/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/es.iterator.constructor.js */ \"./node_modules/core-js/modules/es.iterator.constructor.js\");\n/* harmony import */ var core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! core-js/modules/es.iterator.filter.js */ \"./node_modules/core-js/modules/es.iterator.filter.js\");\n/* harmony import */ var core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var core_js_modules_es_iterator_some_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! core-js/modules/es.iterator.some.js */ \"./node_modules/core-js/modules/es.iterator.some.js\");\n/* harmony import */ var core_js_modules_es_iterator_some_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_iterator_some_js__WEBPACK_IMPORTED_MODULE_3__);\n/* harmony import */ var _store_dict__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @/store/dict */ \"./src/store/dict.js\");\n/* harmony import */ var _store_dictType__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @/store/dictType */ \"./src/store/dictType.js\");\n/* harmony import */ var _utils_util__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @/utils/util */ \"./src/utils/util.js\");\n/* harmony import */ var _utils_message__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! @/utils/message */ \"./src/utils/message.js\");\n/* harmony import */ var _utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @/utils/http/httpUtils */ \"./src/utils/http/httpUtils.js\");\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! vue */ \"vue\");\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(vue__WEBPACK_IMPORTED_MODULE_9__);\n/* harmony import */ var _utils_TableSortUtil__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(/*! @/utils/TableSortUtil */ \"./src/utils/TableSortUtil.js\");\n/* harmony import */ var _mixins_VTMixin_DefaultMethods__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(/*! @/mixins/VTMixin/DefaultMethods */ \"./src/mixins/VTMixin/DefaultMethods.js\");\n/* harmony import */ var _directives_permission_hasPermi__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(/*! @/directives/permission/hasPermi */ \"./src/directives/permission/hasPermi.js\");\n\n\n\n\n\n\n\n\n\n\n\n\n\nconst message = (0,_utils_message__WEBPACK_IMPORTED_MODULE_7__.useMessage)(); // 消息弹窗\nconst dict = (0,_store_dict__WEBPACK_IMPORTED_MODULE_4__.storeDict)();\nconst dictType = (0,_store_dictType__WEBPACK_IMPORTED_MODULE_5__.storeDictType)();\nconst OTMixinBodyMethods = {\n mixins: [_mixins_VTMixin_DefaultMethods__WEBPACK_IMPORTED_MODULE_11__.DefaultMethods],\n emits: ['handleOperationClick', 'toolbarBtnClick', 'initComponents', 'selectRowChange'],\n methods: {\n /**\r\n * 自定义表单方法\r\n * @returns {*}\r\n */\n customerForm(show) {\n this.toggleFormDisplay();\n this.table.formConfig.show = show == true;\n return this.table.formConfig;\n },\n /**\r\n * 搜索隐藏/显示\r\n */\n toggleFormDisplay() {\n // 获取组件的根 DOM 元素\n const rootEl = this.$refs[this.table.ref].$el;\n\n // 查询第一个子标签是否为 vxe-grid--form-wrapper\n const formWrapperEl = rootEl.querySelector('.vxe-grid--form-wrapper');\n if (formWrapperEl) {\n // 查询 formWrapperEl 下的第一个 form 标签\n const formEl = formWrapperEl.querySelector('form');\n if (formEl) {\n // 获取 form 标签的当前 display 样式\n const currentDisplay = window.getComputedStyle(formEl).display;\n\n // 根据当前 display 样式设置新的样式\n if (currentDisplay === 'none') {\n // 如果当前是 none,则移除 display 样式(设置为空字符串)\n formEl.style.display = '';\n } else {\n // 否则设置为 none\n formEl.style.display = 'none';\n }\n }\n }\n },\n /**\r\n * 选中回调\r\n */\n selectRowChange() {\n let rows = this.getSelectRows();\n if (!rows) {\n return;\n }\n this.pagination.selectionRowsLength = rows.length;\n this.setToolBtn('batchDelete', 'disabled', rows.length == 0);\n rows = this.selectBox == 1 ? rows[0] : rows;\n if (this.events['selectRowChange']) {\n this.events['selectRowChange'](rows);\n }\n this.$emit(\"selectRowChange\", rows);\n },\n /**\r\n * 切换表格最大化/还原\r\n */\n zoomEvent() {\n if (this.$table) {\n this.$table.zoom();\n this.isMaximized = this.$table.isMaximized();\n }\n },\n initToolBtn(toolBut) {\n let obj = undefined;\n for (let i = 0; i < toolBut.length; i++) {\n let toolButElement = toolBut[i];\n toolButElement.disabled = toolButElement.defaultDisabled == 1;\n toolButElement.show = toolButElement.defaultShow == 1;\n if (toolButElement.code == 'sortable') {\n toolButElement.values = false;\n obj = JSON.parse(JSON.stringify(toolButElement));\n obj.id = obj.id + \"_sortable\";\n obj.name = \"调整完成\";\n obj.code = \"sortableOk\";\n obj.icon = \"vxe-icon-check\";\n obj.show = false;\n obj.disabled = true;\n obj.index = i + 1;\n }\n }\n if (obj) {\n toolBut.splice(obj.index, 0, obj);\n }\n this.toolBtn = toolBut;\n },\n initOperationBtn(operationBtn) {\n this.operationBtn = operationBtn;\n let permissEx = 0;\n for (let i = 0; i < this.operationBtn.length; i++) {\n let operationBtnElement = this.operationBtn[i];\n let flag = (0,_directives_permission_hasPermi__WEBPACK_IMPORTED_MODULE_12__.doPermission)({\n parentNode: false\n }, [this.uuid + ':' + this.theme + ':' + operationBtnElement.code]);\n if (!flag) {\n operationBtnElement.permission = false;\n permissEx++;\n }\n }\n let length = this.operationBtn.length - permissEx;\n let width = 35;\n if (length != 0) {\n if (this.table.operationWidth) {\n width = this.table.operationWidth;\n } else {\n for (let o of this.operationBtn.filter(o => o.permission !== false)) {\n width += o.name.length * (35 - length) + (o.icon !== undefined ? 5 : 0);\n }\n }\n const hasOperateColumn = this.table.columns.some(col => ['操作'].includes(col.title));\n if (!hasOperateColumn) {\n this.table.columns.push({\n title: '操作',\n width: width,\n fixed: \"right\",\n slots: {\n default: 'operate'\n }\n });\n }\n }\n },\n initTree({\n tree,\n treeId,\n treeParentId\n }) {\n if (tree == 1) {\n this.table.treeConfig = {\n show: true,\n transform: false,\n indent: 15,\n reserve: tree,\n rowField: treeId,\n parentField: treeParentId,\n treeId: treeId,\n treeParentId: treeParentId,\n iconClose: \"vxe-icon-arrow-right\",\n iconOpen: \"vxe-icon-arrow-down\"\n };\n this.table.rowConfig.keyField = treeId;\n }\n },\n initFormMainList(formMainList) {\n this.formMainList = formMainList;\n },\n async doSetComponents(customUrl, method, props, multipleProps) {\n this.customUrl = (0,vue__WEBPACK_IMPORTED_MODULE_9__.markRaw)(customUrl);\n await this.$nextTick(async () => {\n if (multipleProps == '1' || multipleProps == true) {\n doCallback(this.$refs.components[method], props);\n } else if (multipleProps == '2') {\n doCallback2(this.$refs.components[method], props);\n } else {\n this.$refs.components[method](props);\n }\n });\n },\n setComponent(url, method, props, multipleProps) {\n if (url.indexOf(\"@\") == 0) {\n this.$emit('initComponents', {\n url: url,\n method: method,\n props: props,\n multipleProps: multipleProps,\n doSetComponents: this.doSetComponents\n });\n } else {\n this.doSetComponents(__webpack_require__(\"./src sync recursive ^\\\\.\\\\/.*$\")(`./${url}`).default, method, props, multipleProps);\n }\n },\n async toolbarBtnClick(code) {\n if (code == \"batchDelete\") {\n this.batchRemove();\n this.$emit('toolbarBtnClick', code);\n return;\n } else if (code == 'download') {\n this.setComponent(\"components/ol-dialog-excel\", \"open\", {\n column: JSON.parse(JSON.stringify(this.table.columnSource)),\n selectData: this.pagination.selectionRowsLength >= 1 ? '2' : '1'\n });\n return;\n } else if (code == 'upload') {\n let toolBtn = this.getToolBtn(code);\n console.log(toolBtn);\n let {\n json,\n beforeFunction\n } = toolBtn;\n if (json) {\n json = json.replace(/([{,]\\s*)([a-zA-Z0-9_]+)(\\s*:)/g, '$1\"$2\"$3').replace(/:(\\s*)'([^']+)'(\\s*[,}])/g, ':$1\"$2\"$3'); // 修正字符串值\n json = JSON.parse(json);\n }\n let defaultValue = {};\n if (beforeFunction) {\n // 第一次分割:按逗号分割成键值对\n //\"department_id=#{department_id},sex=1\"\n let pairs = beforeFunction.split(',');\n for (const pair of pairs) {\n // 第二次分割:按等号分割键和值\n let [key, value] = pair.split('=');\n if (value != undefined) {\n let value2 = value.toString().trim();\n if (value2.trim().startsWith('#{') && value2.endsWith('}')) {\n // 处理 #{department_id} 格式的值\n let key2 = value.slice(2, -1).trim(); // 去掉 #{ 和 }\n this.setParamsValue(defaultValue, key2);\n } else {\n defaultValue[key] = value;\n }\n } else {\n this.setParamsValue(defaultValue, key);\n }\n }\n }\n this.setComponent(\"components/ol-dialog-import\", \"open\", {\n column: JSON.parse(JSON.stringify(this.table.columnSource)),\n tableConfigId: this.tableConfig.id,\n json: json,\n defaultValue: defaultValue,\n saveParams: {\n dbName: this.tableConfig.dbName,\n tableName: this.tableConfig.mainTable,\n tableConfigId: this.tableConfig.id\n }\n });\n return;\n } else if (code == 'sortable') {\n this.sortableClick();\n return;\n } else if (code == 'sortableOk') {\n this.loading['sortableOk'] = true;\n this.sortableOkClick();\n return;\n }\n let customFunction = this.getToolBtn(code).customFunction;\n if (customFunction != undefined && customFunction.toString().trim().length > 0) {\n eval(customFunction);\n } else if (code == 'add') {\n this.showForm(code);\n }\n this.$emit('toolbarBtnClick', code);\n },\n setParamsValue(params, key) {\n key = key.trim();\n let v = this.table.formConfig.data[key];\n if (v == undefined) {\n v = this.parameter[key];\n }\n if (v != undefined) {\n params[key] = v;\n }\n },\n getBtnJson(code) {\n for (const toolBtn of this.operationBtn) {\n if (toolBtn.code == code) {\n return this.getSubParam(toolBtn.json);\n }\n }\n for (const toolBtn of this.toolBtn) {\n if (toolBtn.code == code) {\n return this.getSubParam(toolBtn.json);\n }\n }\n },\n getDeleteId(param) {\n for (let key of Object.keys(param)) {\n if (key != '$parentId') {\n return key;\n }\n }\n },\n sortableClick() {\n for (let toolBtn of this.toolBtn) {\n if (toolBtn.code == 'sortable') {\n toolBtn.values = !toolBtn.values;\n this.loading['sortableOk'] = false;\n this.setToolBtn('sortableOk', 'show', toolBtn.values);\n toolBtn.start = 999999;\n toolBtn.end = -1;\n if (toolBtn.values) {\n if (toolBtn.beforeFunction == undefined || toolBtn.beforeFunction == '' || toolBtn.beforeFunction.split(\",\") < 2) {\n message.error(\"排序字段未配置,请在做工具栏按钮配置中配置参数1(sort,id)\");\n return;\n }\n toolBtn.updateData = {};\n toolBtn.$elm = (0,_utils_TableSortUtil__WEBPACK_IMPORTED_MODULE_10__.updateSortRowCall)(this.$table, (oldIndex, newIndex) => {\n let start = Math.min(oldIndex, newIndex);\n let end = Math.max(oldIndex, newIndex);\n toolBtn.start = Math.min(start, toolBtn.start);\n toolBtn.end = Math.max(end, toolBtn.end);\n this.setToolBtn('sortableOk', 'disabled', false);\n this.table.data = (0,_utils_TableSortUtil__WEBPACK_IMPORTED_MODULE_10__.getNewArrDataToolBtn)(oldIndex, newIndex, this.table.data, toolBtn);\n });\n } else if (toolBtn.$elm) {\n this.setToolBtn('sortableOk', 'disabled', true);\n toolBtn.$elm.destroy();\n toolBtn.$elm = undefined;\n this.query();\n }\n return;\n }\n }\n },\n sortableOkClick() {\n for (let toolBtn of this.toolBtn) {\n if (toolBtn.code == 'sortable') {\n let url;\n this.loading['sortableOk'] = true;\n this.table.loading = true;\n let params = {\n updateList: []\n };\n //sort,id 排序字段,更新主键\n let kw = toolBtn.beforeFunction.split(\",\");\n if (toolBtn.alterFunction) {\n url = toolBtn.alterFunction;\n } else {\n url = '/online/crud/batchModify';\n params.tableConfigId = this.tableConfig.id;\n }\n //这里肯定只有一个值\n for (let key of Object.keys(toolBtn.updateData)) {\n if (toolBtn.alterFunction) {\n let kv = {};\n kv[kw[1]] = key;\n kv[kw[0]] = toolBtn.updateData[key];\n params.updateList.push(kv);\n } else {\n let columnAndValueMap = {};\n let whereMap = {};\n whereMap[kw[1]] = key;\n columnAndValueMap[kw[0]] = toolBtn.updateData[key];\n params.updateList.push({\n columnAndValueMap,\n whereMap\n });\n }\n }\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_8__.post)(this.http, url, params).then(status => {\n if (status) {\n this.query();\n this.setToolBtn('sortableOk', 'disabled', true);\n }\n }).finally(() => {\n this.loading['sortableOk'] = false;\n this.table.loading = false;\n });\n }\n }\n },\n showRender(descCode, url, title) {\n (0,_utils_http_httpUtils__WEBPACK_IMPORTED_MODULE_8__.get)(this.http, '/online/formDesigner/getOne', {\n descCode: descCode\n }, undefined, true).then(d => {\n let data = {\n type: 1,\n saveUrl: url,\n title: title,\n form: JSON.parse(d.formJson),\n tableConfigId: this.tableConfig.id\n };\n this.$refs[\"form\"].init(data, false);\n });\n },\n showForm(code, formData) {\n if (!formData) {\n formData = {};\n }\n let disabled = false;\n let btnJson = this.getBtnJson(code);\n //详情\n if (code == 'details') {\n disabled = true;\n code = 'edit';\n let btnJson2 = this.getBtnJson(code);\n if (btnJson2) {\n btnJson = {\n ...btnJson,\n ...btnJson2\n };\n } else if (btnJson2 !== undefined) {\n btnJson = btnJson2;\n }\n if (!btnJson || !btnJson.title) {\n btnJson.title = '详情';\n }\n }\n let form = this.formMainList[code];\n if (!form) {\n return;\n }\n let formJsonStr = form.formJson[form.formMain.designer == 0 ? 'optionJson' : 'customJson'];\n let data = {\n type: form.formMain.designer,\n saveUrl: form.formMain.saveUrl,\n requestType: form.formMain.requestType,\n updateKey: form.formMain.updateKey,\n otherProp: form.formMain.otherProp,\n formData,\n theme: this.theme,\n form: JSON.parse(formJsonStr),\n tableConfigId: this.tableConfig.id,\n dbName: this.tableConfig.dbName,\n tableName: this.tableConfig.mainTable,\n code,\n disabled\n };\n if (btnJson && btnJson.type == 1) {\n data.uuid = btnJson.subUuid;\n data.title = btnJson.title;\n data.deleteId = btnJson.deleteId;\n data.foreignKey = btnJson.subForeignKey;\n data.exBtnDisabled = btnJson.exBtnDisabled;\n this.$refs[\"subForm\"].init(data);\n } else {\n this.$nextTick(() => {\n data.title = btnJson.title;\n this.$refs[\"form\"].init(data);\n });\n }\n },\n async handleOperationClick(o) {\n let {\n obj,\n row\n } = o;\n if (obj.customFunction) {\n eval(obj.customFunction);\n } else if (obj.code == \"delete\") {\n this.remove(o);\n } else if (obj.code == 'edit' || obj.code == 'details' || obj.isForm == 1) {\n this.showForm(obj.code, row);\n }\n this.$emit(\"handleOperationClick\", o);\n },\n getSubParam(json) {\n let obj = {\n deleteId: this.getDeleteId(this.deleteParameter)\n }; // 初始化为空对象\n if (json) {\n return {\n ...obj,\n ...JSON.parse(json)\n };\n }\n return {\n ...obj\n };\n }\n },\n created() {\n dict.init(this.http);\n dictType.init(this.http);\n }\n};\nfunction rowCamelCase(o) {\n let obj = {};\n for (let key of Object.keys(o)) {\n if (key == 'XROWKEY') {\n continue;\n }\n let k = key;\n if (re(key)) {\n k = key.substring(3);\n }\n obj[(0,_utils_util__WEBPACK_IMPORTED_MODULE_6__.toCamelCase)(k)] = o[key];\n }\n return obj;\n}\nfunction re(k) {\n let reg = /^t\\d_/;\n return reg.test(k);\n}\nfunction doCallback(fn, args) {\n for (let arg of args) {\n fn.apply(this, arg);\n }\n}\nfunction doCallback2(fn, args) {\n fn.apply(this, args);\n}\n\n//# sourceURL=webpack://olp-table/./src/mixins/VTMixin/OTMixinBodyMethods.js?");
12725
12725
 
12726
12726
  /***/ }),
12727
12727