From 4bd9ecdb092c88d050e58d5a150b62e5e90b65b0 Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期五, 14 三月 2025 16:10:14 +0800
Subject: [PATCH] 删除无用代码
---
src/views/CNAS/externalService/serviceAndSupplyPro/component/ConsumableList.vue | 75 ++++++++++++++-----------------------
1 files changed, 28 insertions(+), 47 deletions(-)
diff --git a/src/views/CNAS/externalService/serviceAndSupplyPro/component/ConsumableList.vue b/src/views/CNAS/externalService/serviceAndSupplyPro/component/ConsumableList.vue
index d6d0f60..8e5ef0f 100644
--- a/src/views/CNAS/externalService/serviceAndSupplyPro/component/ConsumableList.vue
+++ b/src/views/CNAS/externalService/serviceAndSupplyPro/component/ConsumableList.vue
@@ -1,39 +1,31 @@
<template>
<div>
- <TableCard :showTitle="false">
- <template slot="form">
- <div class="action-box">
- <div></div>
- <div class="flex">
- <el-button icon="el-icon-plus" size="small" type="primary" @click="showDialog(undefined)">
- 鏂板缓
- </el-button>
- <el-button icon="el-icon-upload2" size="small" @click="exportExcel">
- 瀵煎嚭Excel
- </el-button>
- </div>
- </div>
+ <div class="flex">
+ <el-button icon="el-icon-plus" size="small" type="primary" @click="showDialog(undefined)">
+ 鏂板缓
+ </el-button>
+ <el-button icon="el-icon-upload2" size="small" @click="exportExcel">
+ 瀵煎嚭Excel
+ </el-button>
+ </div>
+ <limsTable :column="columns" :currentChange="rowClick" :height="'25vh'" :highlightCurrentRow="true"
+ :isSelection="false" :rowStyle="tableRowStyle" :table-data="tableData" rowKey="id"
+ style="margin-top: 18px;">
+ <template v-slot:consumablesTypeSlot="{ row }">
+ {{ findType(row.consumablesType) }}
</template>
- <template v-slot:table>
- <limsTable :column="columns" :currentChange="rowClick" :height="'25vh'" :highlightCurrentRow="true"
- :isSelection="false" :rowStyle="tableRowStyle" :table-data="tableData" rowKey="id"
- style="margin-top: 18px; padding: 0 15px;">
- <template v-slot:consumablesTypeSlot="{ row }">
- {{ findType(row.consumablesType) }}
- </template>
- <template v-slot:operation="scope">
- <el-button size="small" type="text" @click="showDialog(scope.row)">缂栬緫</el-button>
- <el-button size="small" style="color: #f56c6c" type="text" @click="handleDelete(scope.row)">鍒犻櫎</el-button>
- </template>
- </limsTable>
- <div class="pagination">
- <div></div>
- <el-pagination :page-size="pagination.pageSize" :page-sizes="[10, 20, 30, 40]" :total="pagination.total"
- layout="total, sizes, prev, pager, next, jumper" @current-change="handleCurrent" @size-change="handleSize">
- </el-pagination>
- </div>
+ <template v-slot:operation="scope">
+ <el-button size="small" type="text" @click="showDialog(scope.row)">缂栬緫</el-button>
+ <el-button size="small" style="color: #f56c6c" type="text" @click="handleDelete(scope.row)">鍒犻櫎</el-button>
</template>
- </TableCard>
+ </limsTable>
+ <div class="pagination">
+ <div></div>
+ <el-pagination :page-size="pagination.pageSize" :page-sizes="[10, 20, 30, 40]" :total="pagination.total"
+ background
+ layout="total, sizes, prev, pager, next, jumper" @current-change="handleCurrent" @size-change="handleSize">
+ </el-pagination>
+ </div>
<el-divider></el-divider>
<div>
<ConsumableProject ref="consumableProject"></ConsumableProject>
@@ -43,7 +35,6 @@
</template>
<script>
-import TableCard from './index.vue';
import Edit from "./Edit.vue"
import limsTable from '@/components/Table/lims-table.vue'
import {
@@ -55,9 +46,7 @@
export default {
dicts: ["consumables_type"],
- components: {
- TableCard, limsTable, Edit, ConsumableProject
- },
+ components: {limsTable, Edit, ConsumableProject},
props: {
contentsId: {
type: Number,
@@ -192,10 +181,10 @@
this.$refs.consumableProject.fetchListId(row)
},
tableRowStyle({ row }) {
- if (row.currentAmount <= row.lowerLimit) {
+ if(row.currentAmount <= row.lowerLimit) {
return { background: '#ffcaca' }
} else {
- return {}
+ return { background: '#fff' }
}
}
}
@@ -205,15 +194,7 @@
<style scoped>
.flex {
- display: flex;
-}
-
-.action-box {
- width: 100%;
- padding-top: 10px;
- display: flex;
- align-items: center;
- justify-content: space-between;
+ text-align: right;
}
.pagination {
--
Gitblit v1.9.3