<template>
|
<div class="rightContent">
|
<div class="top">
|
<SearchCommonView :show-add="false" :placeholder="'请输入产品名称'" :amount-view="false" @searchClick="getList" />
|
</div>
|
<div class="content">
|
<div class="list-view">
|
<div
|
class="overview-box"
|
v-for="item in tableList"
|
:key="item.id"
|
:class="{
|
overview_active: item.baseOperationType === 1,
|
overview_done: item.baseOperationType === 2,
|
overview_todo: item.baseOperationType === 3
|
}"
|
>
|
<div class="top">
|
<div class="label">
|
<span style="cursor: pointer" @click="labelClick(item)">{{ item.name }}</span>
|
</div>
|
<div class="set">...</div>
|
</div>
|
<div class="bottom">
|
<div class="left">
|
<div class="left_view">
|
<span>2</span>
|
<span style="margin-left: 5px">待处理</span>
|
</div>
|
</div>
|
<div class="right">
|
<div class="right_status">
|
<span style="cursor: pointer">2 正在等待</span>
|
</div>
|
<div class="right_status" style="margin-top: 5px">
|
<span style="cursor: pointer">4 延期</span>
|
</div>
|
</div>
|
</div>
|
</div>
|
</div>
|
<div class="btn-pager">
|
<PagerView class="page" :pager-options="pagerOptions" v-on="pagerEvents" />
|
</div>
|
</div>
|
</div>
|
</template>
|
|
<script>
|
import pageMixin from "@/components/makepager/pager/mixin/pageMixin"
|
import { getOperationType } from "@/api/overview/overview"
|
|
export default {
|
name: "OverView",
|
mixins: [pageMixin],
|
props: {},
|
components: {},
|
computed: {},
|
data() {
|
return {
|
tableList: [],
|
editConfig: {
|
visible: false,
|
title: "新建",
|
infomation: {}
|
}
|
}
|
},
|
created() {
|
this.getData()
|
},
|
methods: {
|
getList(val) {
|
console.log(val)
|
},
|
labelClick(item) {
|
console.log(item)
|
this.$router.push({
|
name: "overviewList",
|
params: { name: item.name, workType: item.baseOperationType, id: item.id }
|
})
|
},
|
async getData() {
|
await getOperationType({
|
keyword: "",
|
page: this.pagerOptions.currPage,
|
pageSize: this.pagerOptions.pageSize
|
}).then((res) => {
|
console.log(res.data.data)
|
if (res.data.code === 200) {
|
const list = res.data.data.map((item) => {
|
return {
|
...item
|
}
|
})
|
this.tableList = list || []
|
this.pagerOptions.totalCount = res.data.total
|
}
|
})
|
}
|
}
|
}
|
</script>
|
|
<!-- Add "scoped" attribute to limit CSS to this component only -->
|
<style lang="scss" scoped>
|
.content {
|
height: calc(100% - 130px);
|
background: #fff;
|
border-radius: 12px;
|
.list-view {
|
padding: 20px 0 0px 20px;
|
height: calc(100% - 70px);
|
overflow: auto;
|
display: flex;
|
flex-wrap: wrap;
|
justify-content: flex-start;
|
align-content: flex-start;
|
.overview-box {
|
min-width: 308px;
|
height: 140px;
|
margin-bottom: 10px;
|
margin-right: 20px;
|
border: 1px solid #dee2e6;
|
box-shadow: inset 0 0 2px #dee2e6;
|
-moz-box-shadow: inset 0 0 2px #dee2e6;
|
-webkit-box-shadow: inset 0 0 2px #dee2e6;
|
.top {
|
height: 35px;
|
line-height: 35px;
|
display: flex;
|
.label {
|
margin-left: 20px;
|
}
|
.set {
|
margin-left: auto;
|
margin-right: 20px;
|
font-size: 20px;
|
cursor: no-drop;
|
color: #000;
|
transform: rotate(-90deg);
|
-moz-transform: rotate(-90deg);
|
-webkit-transform: rotate(-90deg);
|
}
|
}
|
.bottom {
|
display: flex;
|
font-size: 13px;
|
.left {
|
width: 50%;
|
// background: #1d80e2;
|
.left_view {
|
margin-left: 20px;
|
height: 30px;
|
line-height: 30px;
|
padding: 0 5px;
|
width: 70px;
|
text-align: center;
|
color: #fff;
|
background: #081e44;
|
border-radius: 4px;
|
cursor: pointer;
|
}
|
}
|
.right {
|
width: 50%;
|
.right_status {
|
}
|
}
|
}
|
}
|
.overview_active {
|
border-left: 4px solid #1d80e2;
|
}
|
.overview_done {
|
border-left: 4px solid #1de27f;
|
}
|
.overview_todo {
|
border-left: 4px solid #e2441d;
|
}
|
}
|
}
|
</style>
|