{"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\\dataTemplate\\SortSetting.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\xq-web-bpm\\src\\components\\form\\dataTemplate\\SortSetting.vue","mtime":1675071992178},{"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/web.dom.iterable\";\nimport \"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//\nimport deepmerge from \"deepmerge\";\nexport default {\n name: \"sort-setting\",\n props: [\"data\"],\n data: function data() {\n return {\n dataTemplate: {},\n sortSettingFields: [],\n sortFields: [],\n tabHeight: \"\".concat(document.documentElement.clientHeight) - 245\n };\n },\n mounted: function mounted() {\n this.dataTemplate = this.data.bpmDataTemplate;\n\n if (this.data.fields) {\n var fields = deepmerge({}, this.data.fields, {\n clone: true\n });\n fields = fields.filter(function (item) {\n return !item.flowField;\n });\n this.sortSettingFields = fields;\n }\n\n this.templates = this.data.templates;\n this.initData();\n },\n methods: {\n //保存排序数据\n saveSortField: function saveSortField() {\n this.dataTemplate.sortField = this.sortFields ? JSON.stringify(this.sortFields) : null;\n },\n //初始化处理\n initData: function initData() {\n if (this.dataTemplate.sortField) {\n this.sortFields = JSON.parse(this.dataTemplate.sortField);\n }\n },\n columnFilter: function columnFilter(type) {\n return type != \"sub\" && type != \"tabs\";\n },\n //双击字段列表中的字段时将该字段加入到显示字段\n fillToSort: function fillToSort(row, event, column) {\n var isIn = this.isInsortFields(row.name);\n\n if (!isIn) {\n //row.sort = 'ASC';\n this.$set(row, \"sort\", \"ASC\");\n this.sortFields.push(row);\n }\n },\n //将字段列表中的已选字段加入到显示字段列表\n allFillToSort: function allFillToSort() {\n var _this = this;\n\n var selectrows = this.$refs.sortSettingTable.store.states.selection;\n\n if (!selectrows || selectrows.length < 1) {\n this.$message({\n message: \"请在左侧列表中选择要作为排序的字段\",\n type: \"warning\"\n });\n }\n\n selectrows.forEach(function (obj) {\n if (obj.type == 'clob') {\n _this.$message({\n message: \"大文本不能作为排序字段!\",\n type: \"warning\"\n });\n\n return;\n }\n\n if (!_this.isInsortFields(obj.name)) {\n //obj.sort = 'ASC';\n _this.$set(obj, \"sort\", \"ASC\");\n\n _this.sortFields.push(obj);\n }\n });\n },\n //显示字段排序\n sort: function sort(index, type) {\n if (\"up\" == type) {\n if (index === 0) {\n this.$message({\n message: \"已经是列表中第一位\",\n type: \"warning\"\n });\n } else {\n var temp = this.sortFields[index - 1];\n this.$set(this.sortFields, index - 1, this.sortFields[index]);\n this.$set(this.sortFields, index, temp);\n }\n } else {\n if (index === this.sortFields.length - 1) {\n this.$message({\n message: \"已经是列表中最后一位\",\n type: \"warning\"\n });\n } else {\n var i = this.sortFields[index + 1];\n this.$set(this.sortFields, index + 1, this.sortFields[index]);\n this.$set(this.sortFields, index, i);\n }\n }\n },\n //删除显示字段\n remove: function remove(index) {\n this.sortFields.splice(index, 1);\n },\n //判断字段是否已在显示字段列表中\n isInsortFields: function isInsortFields(name) {\n var isIn = false;\n\n if (this.sortFields && this.sortFields.length > 0) {\n this.sortFields.forEach(function (obj) {\n if (obj.name == name) {\n isIn = true;\n return;\n }\n });\n }\n\n return isIn;\n }\n }\n};",null]}