From 2a120264875c70aefcb96327918898fda218c2f9 Mon Sep 17 00:00:00 2001
From: yangys <y_ys79@sina.com>
Date: 星期日, 24 八月 2025 13:50:04 +0800
Subject: [PATCH] Merge branch 'master' of http://www.beijingsoft.cn:9090/r/mdmweb
---
src/views/tasks/machinereturnfiles.vue | 54 +++++++++++++++++++++++++++++++++++++++++++-----------
1 files changed, 43 insertions(+), 11 deletions(-)
diff --git a/src/views/tasks/machinereturnfiles.vue b/src/views/tasks/machinereturnfiles.vue
index f5a8053..91f5f48 100644
--- a/src/views/tasks/machinereturnfiles.vue
+++ b/src/views/tasks/machinereturnfiles.vue
@@ -13,10 +13,12 @@
@current-change="currentChange"
@size-change="sizeChange"
@refresh-change="refreshChange"
+ @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" size="default" icon="el-icon-circle-plus" plain @click="handleExport">瀵煎嚭</el-button> -->
+ <el-button type="primary" size="default" icon="el-icon-circle-plus" plain @click="receiveBtn">鎵归噺鎺ユ敹</el-button>
</template>
<template #menu="scope">
<el-button type="primary" text size="default" icon="el-icon-document-delete" @click.stop="rejectBtn(scope.row, scope.index)">鎷掔粷</el-button>
@@ -27,6 +29,7 @@
</template>
<script>
+ import { ElMessage } from 'element-plus';
import { exportBlob } from '@/api/common';
import { downloadXls } from '@/utils/util';
import { getToken } from '@/utils/auth';
@@ -35,6 +38,7 @@
export default {
data() {
return {
+ selection: [],
search: {
keyword: "",
machineGroupCode: ""
@@ -47,6 +51,7 @@
},
option: {
index: true,
+ selection: true,
addBtn: false,
editBtn: false,
delBtn: false,
@@ -60,18 +65,15 @@
prop: 'programName',
hide: true
},
- {
- label: '鏂囦欢缂栧彿',
- prop: ''
+ {
+ label: '鏂囦欢鍚嶇О',
+ prop: 'name',
},
{
label: '鏈哄簥鍙�',
prop: 'machineCode',
},
- {
- label: '鏂囦欢鍚嶇О',
- prop: 'name',
- },
+
{
label: '鏂囦欢鍥哄寲鐘舵��',
prop: 'isCured',
@@ -79,11 +81,11 @@
{
label: '鏂囦欢鍒拌揪鏃堕棿',
prop: 'arrivedTime',
- },
+ },/*
{
label: '鏂囦欢鏁版嵁搴撶紪鍙�',
prop: '',
- },
+ },*/
{
label: '鍏抽敭淇℃伅',
prop: 'keyword',
@@ -109,6 +111,36 @@
};
},
methods: {
+ selectionChange(selection) {
+ this.selection = selection;
+ },
+ 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/machineback/file/accept',
+ method: 'post',
+ params: {ids: ids.join(',')},
+ }).then(
+ res => {
+ this.loading = false;
+ this.onLoad();
+ }
+ );
+ })
+ },
acceptBtn(row) {
this.$confirm('纭畾瑕佹帴鏀跺悧?', {
confirmButtonText: '鏄�',
@@ -120,7 +152,7 @@
axios({
url: '/blade-mdm/machineback/file/accept',
method: 'post',
- data: {ids: row.id},
+ params: {ids: row.id},
}).then(
res => {
this.loading = false;
--
Gitblit v1.9.3