From 288369dd7487adc61fe45f24d6d141152f5492df Mon Sep 17 00:00:00 2001
From: yangys <y_ys79@sina.com>
Date: 星期三, 08 十月 2025 10:06:58 +0800
Subject: [PATCH] 翻页问题修复
---
src/views/tasks/machinebacktask.vue | 81 +++++++++++-----------------------------
1 files changed, 23 insertions(+), 58 deletions(-)
diff --git a/src/views/tasks/machinebacktask.vue b/src/views/tasks/machinebacktask.vue
index 4dc46c4..3bc7eb7 100644
--- a/src/views/tasks/machinebacktask.vue
+++ b/src/views/tasks/machinebacktask.vue
@@ -16,17 +16,9 @@
@selection-change="selectionChange"
@on-load="onLoad"
>
- <template #menu-left>
- <!-- el-button type="primary" size="default" icon="el-icon-circle-plus" plain @click="handleExport">瀵煎嚭</el-button>
- <el-button type="primary" v-if="this.search.dirType!='REC'" :disabled="this.selection.length==0" size="default" icon="el-icon-circle-plus" plain @click="receiveBtn">鎺ユ敹宸查��</el-button>
--->
- </template>
- <!--
<template #menu="scope">
- <el-button type="primary" v-if="scope.row.dirType==='TEMP'" text size="default" icon="el-icon-document-delete" @click.stop="rejectBtn(scope.row, scope.index)">鎷掔粷</el-button>
- <el-button type="primary" v-if="scope.row.dirType==='TEMP'" text size="default" icon="el-icon-document-add" @click.stop="acceptBtn(scope.row, scope.index)">鎺ユ敹</el-button>
+ <el-button type="primary" v-if="scope.row.status==1" text size="default" icon="el-icon-delete" @click.stop="handleDel(scope.row)">鍒犻櫎</el-button>
</template>
- -->
</avue-crud>
</basic-container>
</template>
@@ -67,7 +59,7 @@
emptyBtn: false,
searchLabelWidth: "80",
searchSpan: 4,
- menu:false,
+ menu:true,
width:'100%',
column: [
{
@@ -143,55 +135,28 @@
this.selection = selection;
},
- receiveAll() {
- //鎺ユ敹绗﹀悎鏉′欢鐨勬墍鏈夋暟鎹�
- this.$confirm('纭畾瑕佹帴鏀剁鍚堟潯浠剁殑鎵�鏈夋枃浠跺悧?', { //鍚屾帴鏀舵帴鍙g浉鍚�
- confirmButtonText: '鏄�',
- cancelButtonText: '鍚�',
- type: 'warning',
- }).then(() => {
- //璋冪敤鎺ュ彛
- this.loading = true;
- axios({
- url: '/blade-mdm/machinefile/file/temp-accept-all',
- method: 'post',
- params: {}
- }).then(
- res => {
- this.loading = false;
- this.onLoad();
- }
- );
- })
+ handleDel(row) {
+ this.loading = true;
+ axios({
+ url: '/blade-mdm/gkw/machinebacktask/remove',
+ method: 'post',
+ params: {ids: row.id},
+ }).then(
+ res => {
+ this.loading = false;
+ this.$message({
+ type: 'success',
+ message: '鎿嶄綔鎴愬姛!',
+ });
+ this.onLoad();
+ done();
+ },
+ error => {
+ this.loading = false;
+ }
+ );
},
-
- receiveBtn() {
- if(this.selection.length == 0) {
- ElMessage({message: '璇烽�夋嫨鏁版嵁',type: 'error'})
- }
- var ids = [];
- this.selection.forEach(item=> {
- ids.push(item.id);
- })
- this.$confirm('纭畾瑕佹帴鏀跺悧?', { //鍚屾帴鏀舵帴鍙g浉鍚�
- confirmButtonText: '鏄�',
- cancelButtonText: '鍚�',
- type: 'warning',
- }).then(() => {
- //璋冪敤鎺ュ彛
- this.loading = true;
- axios({
- url: '/blade-mdm/machinefile/collect/temp-accept',
- method: 'post',
- params: {ids: ids.join(',')},
- }).then(
- res => {
- this.loading = false;
- this.onLoad();
- }
- );
- })
- },
+
searchReset() {
//this.onLoad(this.mypage);
--
Gitblit v1.9.3