{"remainingRequest":"D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\thread-loader\\dist\\cjs.js!D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\babel-loader\\lib\\index.js!D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\cache-loader\\dist\\cjs.js??ref--0-0!D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\jenkins\\workspace\\xq-web-bpm\\src\\components\\form\\WidgetSubDivLayout.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\src\\components\\form\\WidgetSubDivLayout.vue","mtime":1675071992038},{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\thread-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\babel-loader\\lib\\index.js","mtime":315532800000},{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\node_modules\\vue-loader\\lib\\index.js","mtime":499162500000}],"contextDependencies":[],"result":["import \"core-js/modules/es6.function.name\";\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\nimport Draggable from \"vuedraggable\";\nimport WidgetFormItem from \"@/components/form/WidgetFormItem.vue\";\nimport WidgetGridLayout from \"@/components/form/WidgetGridLayout.vue\";\nimport WidgetSuntableLayout from \"@/components/form/WidgetSuntableLayout.vue\";\nimport WidgetSundivLayout from \"@/components/form/WidgetSunDivLayout.vue\";\nimport controlsApi from \"@/api/controlsConfig.js\";\nimport deepmerge from \"deepmerge\";\nexport default {\n  name: \"widget-subdiv-layout\",\n  components: {\n    Draggable: Draggable,\n    WidgetFormItem: WidgetFormItem,\n    WidgetGridLayout: WidgetGridLayout,\n    WidgetSuntableLayout: WidgetSuntableLayout,\n    WidgetSundivLayout: WidgetSundivLayout\n  },\n  props: [\"element\", \"select\", \"index\", \"data\", \"selectWidgetList\"],\n  data: function data() {\n    return {\n      selectWidget: this.select\n    };\n  },\n  methods: {\n    handleMoveStart: function handleMoveStart(evt) {\n      // 新增控件时  将控件属性切断联系\n      evt.item._underlying_vm_ = deepmerge({}, evt.item._underlying_vm_, {\n        clone: true\n      });\n      var key = Date.parse(new Date()) + \"_\" + Math.ceil(Math.random() * 99999);\n      evt.item._underlying_vm_.key = key;\n    },\n    handleSelectWidget: function handleSelectWidget(index) {\n      this.selectWidget = this.data.list[index];\n    },\n    handleMoveEnd: function handleMoveEnd(evt, element) {\n      if (evt.to.__vue__) {\n        if (element.name == evt.item._underlying_vm_.boSubEntity) {\n          //子表栅格布局放入到主表内，绑定是子表字段问题\n          evt.item._underlying_vm_.boSubEntity = \"\";\n          evt.item._underlying_vm_.parentNodeType = \"\";\n          evt.item._underlying_vm_.parentType = \"\";\n        }\n      } else {\n        for (var a = 0; a < this.element.list.length; a++) {\n          //判断是否是孙表DIV布局\n          if (this.element.list[a].ctrlType == \"sunDiv\") {\n            for (var b = 0; b < this.element.list[a].list.length; b++) {\n              //判断孙表DIV布局是否存在栅格布局\n              if (this.element.list[a].list[b].ctrlType == \"grid\") {\n                //判断孙表DIV布局中的栅格布局是否是sub拖拽过来的\n                if (this.element.list[a].list[b].parentNodeType == \"sub\") {\n                  //修复子表栅格布局放入到其他的孙表内，绑定是子表字段问题\n                  evt.item._underlying_vm_.boSubEntity = this.element.list[a].name;\n                  evt.item._underlying_vm_.parentNodeType = \"sun\";\n                  evt.item._underlying_vm_.parentType = \"sunDiv\";\n                  break;\n                }\n              }\n            }\n          }\n        }\n      }\n    },\n    handleWidgetColAdd: function handleWidgetColAdd($event, element) {\n      var newIndex = $event.newIndex;\n      var oldIndex = $event.oldIndex;\n      var item = $event.item;\n\n      if (item.innerText == \"二维码\") {\n        this.$message.warning(\"子表不允许存在二维码\");\n        element.list.splice(newIndex, 1);\n        return false;\n      }\n\n      if (item.innerText == \"里程碑\") {\n        this.$message.warning(\"子表不允许存在里程碑\");\n        element.list.splice(newIndex, 1);\n        return false;\n      }\n\n      if (item.innerText == \"表格布局\") {\n        this.$message.warning(\"子表不允许存在表格布局\");\n        element.list.splice(newIndex, 1);\n        return false;\n      }\n\n      if (item.innerText == \"高德地图\") {\n        this.$message.warning(\"子表不允许存在高德地图\");\n        element.list.splice(newIndex, 1);\n        return false;\n      }\n\n      if (item.innerText == \"相关流程\") {\n        this.$message.warning(\"子表不允许存在相关流程\");\n        element.list.splice(newIndex, 1);\n        return false;\n      }\n\n      if (item.innerText === \"数据视图\") {\n        this.$message.warning(\"子表不允许存在数据视图\");\n        element.list.splice(newIndex, 1);\n        return false;\n      }\n\n      if (!controlsApi.handleLayoutComponents(this, element, element.list, newIndex)) {\n        return;\n      }\n\n      if (!element.options.boSubEntity) {\n        this.$message.warning(\"请先绑定子表\");\n        return false;\n      } // 防止布局元素的嵌套拖拽\n\n\n      if (item.isLayout) {\n        element.list.list.splice(newIndex, 1);\n        return false;\n      }\n\n      this.selectWidget = element.list[newIndex];\n      this.selectWidget.parentNodeType = \"sub\";\n      this.selectWidget.parentType = \"subDiv\";\n      this.selectWidget.boSubEntity = element.options.boSubEntity;\n    },\n    handleWidgetDelete: function handleWidgetDelete(index) {\n      var _this = this;\n\n      if (this.data.list.length - 1 === index) {\n        if (index === 0) {\n          this.selectWidget = {\n            options: {\n              validateType: \"\"\n            }\n          };\n        } else {\n          this.selectWidget = this.data.list[index - 1];\n        }\n      } else {\n        this.selectWidget = this.data.list[index + 1];\n      }\n\n      this.$nextTick(function () {\n        _this.data.list.splice(index, 1);\n      });\n    }\n  },\n  watch: {\n    select: function select(val) {\n      this.selectWidget = val;\n    },\n    selectWidget: {\n      handler: function handler(val, oldVal) {\n        this.$emit(\"update:select\", val);\n      },\n      deep: true\n    }\n  }\n};",null]}