Commit e27df32c authored by Hagsn3's avatar Hagsn3

修改刷新按钮颜色

parent 5a718114
......@@ -6,11 +6,14 @@
<div v-if="tabList[0].number == 0" class="oneButtion">
<div class="spanTest">
<div class="testContent">{{ tabList[0].label }}</div>
</div>
</div>
</div>
<div v-if="tabList[0].number > 0" class="oneButtion">
<el-button :class="actionIndex === 0 ? 'button_rowBtn_action' : 'button_rowBtn'" type="primary"
@click="handleToggle(tabList[0],0)">
<el-button
:class="actionIndex === 0 ? 'button_rowBtn_action' : 'button_rowBtn'"
type="primary"
@click="handleToggle(tabList[0],0)"
>
<div class="buttionText">
<span>{{ tabList[0].label }}</span>
<span style="color: red">({{ tabList[0].number }})</span>
......@@ -21,8 +24,11 @@
<div class="spanTest"><div class="testContent">{{ tabList[1].label }}</div></div>
</div>
<div v-if="tabList[1].number > 0" class="oneButtion">
<el-button :class="actionIndex === 1 ? 'button_rowBtn_action' : 'button_rowBtn'" type="primary"
@click="handleToggle(tabList[1],1)">
<el-button
:class="actionIndex === 1 ? 'button_rowBtn_action' : 'button_rowBtn'"
type="primary"
@click="handleToggle(tabList[1],1)"
>
<div class="buttionText">
<span>{{ tabList[1].label }}</span>
<span style="color: red">({{ tabList[1].number }})</span>
......@@ -35,8 +41,11 @@
<div class="spanTest"><div class="testContent">{{ tabList[2].label }}</div></div>
</div>
<div v-if="tabList[2].number > 0" class="oneButtion">
<el-button :class="actionIndex === 2 ? 'button_rowBtn_action' : 'button_rowBtn'" type="primary"
@click="handleToggle(tabList[2],2)">
<el-button
:class="actionIndex === 2 ? 'button_rowBtn_action' : 'button_rowBtn'"
type="primary"
@click="handleToggle(tabList[2],2)"
>
<div class="buttionText">
<span>{{ tabList[2].label }}</span>
<span style="color: red">({{ tabList[2].number }})</span>
......@@ -47,8 +56,11 @@
<div class="spanTest"><div class="testContent">{{ tabList[3].label }}</div></div>
</div>
<div v-if="tabList[3].number > 0" class="oneButtion">
<el-button :class="actionIndex === 3 ? 'button_rowBtn_action' : 'button_rowBtn'" type="primary"
@click="handleToggle(tabList[3],3)">
<el-button
:class="actionIndex === 3 ? 'button_rowBtn_action' : 'button_rowBtn'"
type="primary"
@click="handleToggle(tabList[3],3)"
>
<div class="buttionText">
<span>{{ tabList[3].label }}</span>
<span style="color: red">({{ tabList[3].number }})</span>
......@@ -59,16 +71,16 @@
</div>
<!-- 清空按钮 -->
<div class="clearRegion">
<el-button class="button_rowBtn" type="primary" @click="handleClear">刷新</el-button>
<el-button class="button_rowBtn" type="warning" @click="handleClear">刷新</el-button>
</div>
<!-- 第三部分-->
<div class="threeTable">
<hr class="tableHr">
<el-table :data="tableList">
<el-table-column type="index" label="序号" width="50"></el-table-column>
<el-table-column label="pn">
<el-table-column type="index" label="序号" width="50" />
<el-table-column label="pn">
<template slot-scope="scope">
<span>{{scope.row.pn || '-'}}</span>
<span>{{ scope.row.pn || '-' }}</span>
</template>
</el-table-column>
<el-table-column label="操作" width="80">
......@@ -83,20 +95,19 @@
:page.sync="queryparams.page"
:limit.sync="queryparams.rows"
@pagination="getList"
>
</app-pagination>
/>
</div>
</div>
</template>
<script>
import {handleOutWarehouse, outComeList, querykindsNumber, validNumber} from "@/api/setup/applicationTable";
import appPagination from "@/views/components/appPagination";
import AppPagination from "@/views/components/appPagination";
import { handleOutWarehouse, outComeList, querykindsNumber, validNumber } from '@/api/setup/applicationTable'
import appPagination from '@/views/components/appPagination'
import AppPagination from '@/views/components/appPagination'
export default {
name: "ApplicationTable",
components: {AppPagination},
name: 'ApplicationTable',
comments: [appPagination],
components: { AppPagination },
data() {
return {
loading: false,
......@@ -124,7 +135,7 @@ export default {
querykindsNumber().then(res => {
if (res.code === 200) {
this.tabList = res.data
this.getTableAndIndex(res.data).then(()=> {})
this.getTableAndIndex(res.data).then(() => {})
}
})
},
......@@ -149,18 +160,18 @@ export default {
* @param: list
**/
async getTableAndIndex(list) {
var tempIndexList = [];
var tempTypeList = [];
var tempIndexList = []
var tempTypeList = []
list.forEach((item, index) => {
if (item.number > 0) {
tempIndexList.push(index);
tempTypeList.push(item.type);
tempIndexList.push(index)
tempTypeList.push(item.type)
}
});
console.log('tempIndexList', tempIndexList);
console.log('tempTypeList', tempTypeList);
})
console.log('tempIndexList', tempIndexList)
console.log('tempTypeList', tempTypeList)
if (tempIndexList.length > 0) {
this.actionIndex = tempIndexList[0];
this.actionIndex = tempIndexList[0]
}
if (tempTypeList.length > 0) {
this.queryparams.ptype = tempTypeList[0]
......@@ -169,13 +180,13 @@ export default {
rows: 10,
ptype: tempTypeList[0],
dealStatus: '0'
};
}
try {
const res = await outComeList(obj);
this.tableList = res.rows;
this.total = res.total;
const res = await outComeList(obj)
this.tableList = res.rows
this.total = res.total
} catch (error) {
console.error('Error fetching data:', error);
console.error('Error fetching data:', error)
}
}
},
......@@ -189,11 +200,11 @@ export default {
},
// 处理
handleDispose(item) {
const obj ={
const obj = {
businessId: item.businessId
}
validNumber(obj).then(res => {
console.log('res',res)
console.log('res', res)
if (res.data) {
this.$router.push({
path: '/setup/dispose',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment