{"remainingRequest":"D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\thread-loader\\dist\\cjs.js!D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\babel-loader\\lib\\index.js!D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\cache-loader\\dist\\cjs.js??ref--0-0!D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\vue-loader\\lib\\index.js??vue-loader-options!D:\\jenkins\\workspace\\bbsl-fvue\\src\\views\\infoManagement\\collocation.vue?vue&type=script&lang=js&","dependencies":[{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\src\\views\\infoManagement\\collocation.vue","mtime":1684458239152},{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\thread-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\babel-loader\\lib\\index.js","mtime":315532800000},{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\cache-loader\\dist\\cjs.js","mtime":499162500000},{"path":"D:\\jenkins\\workspace\\bbsl-fvue\\node_modules\\vue-loader\\lib\\index.js","mtime":499162500000}],"contextDependencies":[],"result":["import \"core-js/modules/web.dom.iterable\";\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//\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 FormDialog from \"./components/taskForm-dialog.vue\";\nimport { TableMixin } from '@/mixins/tableMixin';\nimport collocation from '@/api/collocation.js';\nexport default {\n name: 'collocation',\n components: {\n FormDialog: FormDialog\n },\n mixins: [TableMixin],\n data: function data() {\n return {\n pageBean: {\n pageSize: 20,\n page: 1\n },\n params: {\n taskName: '',\n taskType: undefined\n },\n total: 0,\n taskClass: '',\n //任务执行类\n taskRate: null,\n //任务调用频率\n taskRateUnit: '',\n //任务调用频率单位(m:分钟,h:小时,d:天,w:周,M:月,Y:年)\n sourceCode: '',\n //数据源\n sourceTable: '',\n //源表名\n taskMemo: '',\n //任务说明\n tableData: [],\n taskTypes: [{\n value: 1,\n label: '定时任务'\n }, {\n value: 2,\n label: '非定时任务'\n }],\n operation: '操作',\n logQuery: '日志查询',\n taskStatus: '',\n //NONE停止任务 NORMAL运行任务 PAUSED暂停任务\n loading: false,\n multipleSelection: [],\n // 复选框\n showFormDia: false,\n title: '',\n pId: ''\n };\n },\n created: function created() {\n this.getDateList(true);\n },\n methods: {\n // 搜索\n onClickSearch: function onClickSearch() {\n this.pageBean.page = 1;\n this.getDateList();\n },\n // 重置\n resetQuery: function resetQuery() {\n this.params.taskName = '';\n this.params.taskType = undefined;\n this.pageBean.page = 1;\n this.getDateList();\n },\n // 新增\n openFormDiao: function openFormDiao() {\n this.title = '新增';\n this.showFormDia = true;\n },\n handleSizeChange: function handleSizeChange(val) {\n this.pageBean.pageSize = val;\n this.getDateList();\n },\n handleCurrentChange: function handleCurrentChange(val) {\n this.pageBean.page = val;\n this.getDateList();\n },\n closeFormDiao: function closeFormDiao() {\n this.showFormDia = false;\n },\n // 获取分页数据\n getDateList: function getDateList() {\n var _this = this;\n\n var data = {\n pageBean: this.pageBean,\n querys: [{\n property: 'taskName',\n operation: 'LIKE',\n value: this.params.taskName,\n group: 'filter',\n relation: 'AND'\n }]\n };\n var data1 = {\n property: 'taskType',\n operation: 'EQUAL',\n value: this.params.taskType,\n group: 'filter',\n relation: 'AND'\n };\n\n if (this.params.taskType) {\n data.querys.push(data1);\n }\n\n collocation.listQuery(data, function (res) {\n if (res.state && res.rows) {\n res.rows.forEach(function (ii) {\n console.log(ii);\n\n _this.taskTypes.forEach(function (ee) {\n if (ee.value === ii.taskType) {\n ii['taskType'] = ee.label;\n }\n });\n });\n }\n\n _this.total = res.total;\n _this.tableData = res.rows;\n _this.loading = false;\n });\n },\n // 批量删除\n deleteSelect: function deleteSelect() {\n var _this2 = this;\n\n this.$confirm('确定删除选中数据?', '提示', {\n confirmButtonText: '确 定',\n cancelButtonText: '取 消',\n type: 'warning'\n }).then(function () {\n collocation.remove(_this2.multipleSelection, function (res) {\n if (res.state) {\n _this2.$notify({\n type: 'success',\n message: '删除成功',\n duration: 2000 // offset: 80\n\n }); // this.multipleSelection = [];\n\n\n _this2.$refs.multipleSelection.clearSelection();\n\n _this2.pageBean.page = 1;\n\n _this2.getDateList();\n }\n }).catch(function (res) {\n _this2.$notify({\n type: 'error',\n message: res.message,\n duration: 2000,\n offset: 80\n });\n\n _this2.getDateList();\n });\n }).catch(function () {});\n },\n // 删除单个数据\n handleDelete: function handleDelete(row) {\n var _this3 = this;\n\n this.$confirm('确定删除选中数据?', '提示', {\n confirmButtonText: '确 定',\n cancelButtonText: '取 消',\n type: 'warning'\n }).then(function () {\n collocation.remove(row.id, function (res) {\n if (res.state) {\n _this3.$notify({\n type: 'success',\n message: '删除成功',\n duration: 2000 // offset: 80\n\n });\n }\n\n _this3.pageBean.page = 1;\n\n _this3.getDateList();\n }).catch(function (res) {\n _this3.$notify({\n type: 'error',\n message: res.message,\n duration: 2000,\n offset: 80\n });\n\n _this3.getDateList();\n });\n }).catch(function () {});\n },\n // 任务启动状态\n startUpJob: function startUpJob(row) {\n var _this4 = this;\n\n console.log(row.id);\n var taskId = row.id;\n\n if (row.taskStatus === 'NONE') {\n console.log(row.taskStatus);\n collocation.startUpJob(taskId, function (res) {\n if (res.state) {\n console.log(res);\n row.taskStatus = 'NORMAL';\n }\n });\n }\n\n if (row.taskStatus === 'PAUSED') {\n console.log(row.taskStatus);\n collocation.startUpJob(taskId, function (res) {\n if (res.state) {\n console.log(res);\n row.taskStatus = 'NORMAL';\n\n _this4.$message({\n message: '开启成功',\n type: 'success',\n duration: 2000\n });\n }\n });\n }\n\n if (row.taskStatus === 'NORMAL') {\n console.log(row.taskStatus);\n collocation.stopJob(taskId, function (res) {\n if (res.state) {\n console.log(res);\n row.taskStatus = 'PAUSED';\n\n _this4.$message({\n message: '暂停成功',\n type: 'success',\n duration: 2000\n });\n }\n });\n }\n },\n // 修改\n handleUpdate: function handleUpdate(row) {\n this.title = '修改';\n this.pId = row.id;\n this.showFormDia = true;\n },\n handleSelectionChange: function handleSelectionChange(val) {\n this.multipleSelection = val.map(function (item) {\n return item.id;\n });\n },\n // 指定一个key标识这一行的数据\n getRowKey: function getRowKey(row) {\n return row.id;\n },\n // 跳转日志查询\n toLogQuery: function toLogQuery(row) {\n console.log(row);\n this.$router.push({\n path: 'LogQuery',\n query: {\n id: row.id,\n taskName: row.taskName\n }\n });\n }\n }\n};",null]}