From 9a4505c3b54df6338a563979ba916f328542406d Mon Sep 17 00:00:00 2001
From: gaoshp <291585735@qq.com>
Date: 星期五, 20 六月 2025 21:17:34 +0800
Subject: [PATCH] 添加流程超时页面
---
src/api/tasks/timeouts.js | 18 ++++++
src/views/tasks/timeouts.vue | 124 +++++++++++++++++++++++++++++++++++++++-
2 files changed, 137 insertions(+), 5 deletions(-)
diff --git a/src/api/tasks/timeouts.js b/src/api/tasks/timeouts.js
new file mode 100644
index 0000000..51cea9b
--- /dev/null
+++ b/src/api/tasks/timeouts.js
@@ -0,0 +1,18 @@
+/*
+ * @Date: 2025-06-12 22:38:05
+ * @LastEditors: gaoshp
+ * @LastEditTime: 2025-06-20 21:11:25
+ * @FilePath: /mdmweb/src/api/tasks/timeouts.js
+ */
+import request from '@/axios';
+export const getList = (current, size, params) => {
+ return request({
+ url: '/blade-mdm/machineback/filehandle/page',
+ method: 'get',
+ params: {
+ ...params,
+ current,
+ size,
+ },
+ })
+};
\ No newline at end of file
diff --git a/src/views/tasks/timeouts.vue b/src/views/tasks/timeouts.vue
index ecd7aee..f1c1d34 100644
--- a/src/views/tasks/timeouts.vue
+++ b/src/views/tasks/timeouts.vue
@@ -1,28 +1,142 @@
<!--
* @Date: 2025-06-20 20:48:17
* @LastEditors: gaoshp
- * @LastEditTime: 2025-06-20 20:48:32
+ * @LastEditTime: 2025-06-20 21:14:47
* @FilePath: /mdmweb/src/views/tasks/timeouts.vue
-->
<template>
- <div>
-
- </div>
+ <basic-container>
+ <avue-crud :option="option" :table-loading="loading" :data="data" v-model:page="page" v-model="form" ref="crud" @current-change="currentChange"
+ @size-change="sizeChange" @refresh-change="refreshChange" @on-load="onLoad">
+ <template #menu-left>
+ <!-- <el-button type="primary" plain @click="exportWebSite">瀵煎嚭鍥炰紶娑夊瘑缃�</el-button>
+ <el-button type="primary" plain @click="reassign">鎸傝浇杞﹀簥绋嬪簭搴�</el-button>
+ <el-button type="primary" plain @click="exportExcel">瀵煎嚭鍒癊XCEL</el-button> -->
+ </template>
+ <template #menu="scope">
+ <el-button type="primary" text size="default"
+ @click.stop="handleAction(scope.row, scope.index)">澶勭悊鎰忚
+ </el-button>
+ </template>
+ </avue-crud>
+ </basic-container>
</template>
<script>
+ import { getList } from '@/api/tasks/machinereturnfileop.js';
export default {
name: 'Timeouts',
data() {
return {
// Define your data properties here
+ page: {
+ pageSize: 10,
+ currentPage: 1,
+ total: 0,
+ },
+ form: {},
+ query: {},
+ loading: true,
+ data: [],
+ option: {
+ addBtn: false,
+ editBtn: false,
+ delBtn: false,
+ viewBtn: true,
+ columnBtn: false,
+ tip: false,
+ // simplePage: true,
+ searchShow: true,
+ searchMenuSpan: 6,
+ dialogWidth: '60%',
+ // tree: true,
+ border: true,
+ index: true,
+ selection: true,
+ // viewBtn: true,
+ menuWidth: 200,
+ // menu: false,
+ dialogClickModal: false,
+ column: [
+ {
+ label: '鍛婅缂栧彿',
+ prop: '',
+ },
+ {
+ label: '娴佺▼鍚嶇О',
+ prop: '',
+ },
+ {
+ label: '鎵ц浜哄憳',
+ prop: '',
+ },
+ {
+ label: '浠诲姟鑺傜偣',
+ prop: '',
+ },
+
+ {
+ label: '浠诲姟鍒拌揪鏃堕棿',
+ prop: '',
+ type: 'datetime',
+ format: 'YYYY-MM-DD HH:mm:ss',
+ valueFormat: 'YYYY-MM-DD HH:mm:ss',
+ },
+ {
+ label: '瑕佹眰瀹屾垚鏃堕棿',
+ prop: '',
+ type: 'datetime',
+ format: 'YYYY-MM-DD HH:mm:ss',
+ valueFormat: 'YYYY-MM-DD HH:mm:ss',
+ },
+ ],
+ }
};
},
methods: {
// Define your methods here
+ currentChange(currentPage) {
+ this.page.currentPage = currentPage;
+ // this.onLoad();
+ },
+ sizeChange(pageSize) {
+ this.page.pageSize = pageSize;
+ },
+ refreshChange() {
+ this.onLoad(this.page, this.query);
+ },
+ /** * 椤甸潰鍔犺浇鏃惰幏鍙栨暟鎹�
+ */
+ onLoad(page, params = {}) {
+ console.log('onLoad', page, params);
+ const query = {
+ ...this.query,
+ // category: params.category ? flowCategory(params.category) : null,
+ mode: this.mode,
+ };
+ try {
+ delete query.confirmTime; // 鍒犻櫎涓嶅繀瑕佺殑鏌ヨ鏉′欢
+ } catch (error) {
+ console.error('鏃ユ湡鏍煎紡鍖栭敊璇�', error);
+ }
+
+ this.loading = true;
+ getList(page.currentPage, page.pageSize, Object.assign(query, params)).then(res => {
+ const data = res.data.data;
+ this.page.total = data.total;
+ this.data = data.records;
+ this.loading = false;
+ }, () => {
+ this.data = [];
+ this.loading = false;
+ }).catch(err => {
+ this.data = [];
+ this.loading = false;
+ });
+ }
},
mounted() {
-
+
}
}
</script>
--
Gitblit v1.9.3