This commit is contained in:
2023-10-08 15:58:29 +08:00
parent b4ffb20ba8
commit 51f101ea4e
77 changed files with 1378 additions and 947 deletions

View File

@@ -2,7 +2,7 @@
* @Author: zwq
* @Date: 2023-08-21 14:26:23
* @LastEditors: zwq
* @LastEditTime: 2023-08-31 14:36:15
* @LastEditTime: 2023-10-07 16:45:47
* @Description:
-->
<template>
@@ -11,92 +11,97 @@
:formConfigs="formConfig"
ref="searchBarForm"
@headBtnClick="buttonClick" />
<div class="mainbody">
<div v-for="a in 3" :key="a">
<el-row type="flex" justify="space-around">
<el-col :span="5" v-for="i in 4" :key="i">
<el-row type="flex" justify="space-between">
<el-col :span="12" v-for="j in 2" :key="j">
<div
class="dashboard-layout-item"
v-for="z in 2"
:key="z"
style="background: #ffd781; float: left">
<div
class="dashboard-layout-item-cricle"
style="background: #16dc09" />
{{ i + '+' + j + '+' + z }}
</div>
</el-col>
</el-row>
<el-row type="flex" justify="space-between">
<el-col :span="12" v-for="j in 2" :key="j">
<div
class="dashboard-layout-item"
v-for="z in 2"
:key="z"
style="background: #ffd781; float: left">
<div
class="dashboard-layout-item-cricle"
style="background: #16dc09" />
{{ i + '+' + j + '+' + z }}
</div>
</el-col>
</el-row>
</el-col>
</el-row>
<el-divider class="divider"></el-divider>
<el-row type="flex" justify="space-around">
<el-col :span="5" v-for="i in 4" :key="i">
<el-row type="flex" justify="space-between">
<el-col :span="12" v-for="j in 2" :key="j">
<div
class="dashboard-layout-item"
v-for="z in 2"
:key="z"
style="background: #ffd781; float: left">
<div
class="dashboard-layout-item-cricle"
style="background: #16dc09" />
{{ i + '+' + j + '+' + z }}
</div>
</el-col>
</el-row>
<el-row type="flex" justify="space-between">
<el-col :span="12" v-for="j in 2" :key="j">
<div
class="dashboard-layout-item"
v-for="z in 2"
:key="z"
style="background: #ffd781; float: left">
<div
class="dashboard-layout-item-cricle"
style="background: #16dc09" />
{{ i + '+' + j + '+' + z }}
</div>
</el-col>
</el-row>
</el-col>
</el-row>
<div class="tips">
<el-tag effect="dark"></el-tag>
<el-tag type="success" effect="dark"></el-tag>
<el-tag type="warning" effect="dark"></el-tag>
</div>
<div class="mainbody">
<div v-for="a in listQuery.total" :key="a">
<el-row>
<el-col :span="24">
<el-row>
<div
class="dashboard-layout-item"
v-for="a in wareData.one"
:key="a.id+a.warehouseStorehouseCode"
:style="{background: bgColor[a.warehouseStorehouseState], float: 'left'}">
<!-- <div
class="dashboard-layout-item-cricle"
style="background: #16dc09" /> -->
{{ a.warehouseStorehouseCode }}
</div>
</el-row>
<el-row>
<div
class="dashboard-layout-item"
v-for="b in wareData.two"
:key="b.id+b.warehouseStorehouseCode"
:style="{background: bgColor[b.warehouseStorehouseState], float: 'left'}">
<!-- <div
class="dashboard-layout-item-cricle"
style="background: #16dc09" /> -->
{{ b.warehouseStorehouseCode }}
</div>
</el-row>
</el-col>
</el-row>
<el-divider class="divider"></el-divider>
<el-row>
<el-col :span="24">
<el-row>
<div
class="dashboard-layout-item"
v-for="c in wareData.there"
:key="c.id+c.warehouseStorehouseCode"
:style="{background: bgColor[c.warehouseStorehouseState], float: 'left'}">
<!-- <div
class="dashboard-layout-item-cricle"
style="background: #16dc09" /> -->
{{ c.warehouseStorehouseCode }}
</div>
</el-row>
<el-row>
<div
class="dashboard-layout-item"
v-for="d in wareData.four"
:key="d.id+d.warehouseStorehouseCode"
:style="{background: bgColor[d.warehouseStorehouseState], float: 'left'}">
<!-- <div
class="dashboard-layout-item-cricle"
style="background: #16dc09" /> -->
{{ d.warehouseStorehouseCode }}
</div>
</el-row>
</el-col>
</el-row>
</div>
</div>
</div>
</div>
</template>
<script>
import basicPage from '../mixins/basic-page';
import { getWarehouseStorehousePage } from '@/api/asrs/warehouseStorehouse';
import { getWarehouseStorehouseList } from '@/api/asrs/warehouseStorehouse';
export default {
mixins: [basicPage],
data() {
return {
urlOptions: {
getDataListURL: getWarehouseStorehousePage,
getDataListURL: getWarehouseStorehouseList,
},
listQuery: {
wareLayer: 1,
total: 0,
},
wareData: {
one: [],
two: [],
there: [],
four: [],
},
bgColor:['#37d97f','#ffbd02','#0b58ff'],
formConfig: [
{
type: 'select',
@@ -122,8 +127,34 @@ export default {
};
},
components: {},
created() {},
created() {
},
methods: {
// 获取数据列表
getDataList() {
this.dataListLoading = true;
this.wareData= {
one: [],
two: [],
there: [],
four: [],
},
this.urlOptions.getDataListURL(this.listQuery).then((response) => {
response.data.forEach((a, b) => {
if (b % 4 === 0) {
this.wareData.one.push(a);
} else if (b % 4 === 1) {
this.wareData.two.push(a);
} else if (b % 4 === 2) {
this.wareData.there.push(a);
} else if (b % 4 === 3) {
this.wareData.four.push(a);
}
});
this.listQuery.total = Math.ceil(response.data.length / 120);
this.dataListLoading = false;
});
},
buttonClick(val) {
switch (val.btnName) {
case 'search':
@@ -139,18 +170,19 @@ export default {
</script>
<style lang="scss" scoped>
.mainbody{
.mainbody {
display: flex;
gap: 50px;
flex-direction: column;
gap: 50px;
flex-direction: column;
}
.dashboard-layout-item {
width: 80px;
color: white;
width: 3.3%;
text-align: center;
height: 32px;
height: 40px;
box-shadow: 0px 3px 6px 0px rgba(166, 174, 190, 0.8);
border-radius: 2px 4px 4px 2px;
margin-bottom: 8px;
margin-bottom: 4px;
display: flex;
align-items: center;
justify-content: center;
@@ -161,11 +193,22 @@ export default {
border-radius: 6px;
margin-right: 6px;
}
&:hover {
background-color: rgba(85, 136, 253, 0.8) !important;
color: #ffffff;
cursor: pointer;
transform: scaleY(1.3) translateZ(0);
}
}
.el-divider--horizontal {
margin: 10px 0;
}
.el-divider{
background-color: black;
.el-divider {
background-color: black;
}
.tips {
position: absolute;
top: 22px;
left: 370px;
}
</style>

View File

@@ -2,7 +2,7 @@
* @Author: zwq
* @Date: 2023-08-21 14:26:23
* @LastEditors: zwq
* @LastEditTime: 2023-09-05 14:53:46
* @LastEditTime: 2023-10-07 16:45:37
* @Description:
-->
<template>
@@ -11,92 +11,97 @@
:formConfigs="formConfig"
ref="searchBarForm"
@headBtnClick="buttonClick" />
<div class="mainbody">
<div v-for="a in 3" :key="a">
<el-row type="flex" justify="space-around">
<el-col :span="5" v-for="i in 4" :key="i">
<el-row type="flex" justify="space-between">
<el-col :span="12" v-for="j in 2" :key="j">
<div
class="dashboard-layout-item"
v-for="z in 2"
:key="z"
style="background: #ffd781; float: left">
<div
class="dashboard-layout-item-cricle"
style="background: #16dc09" />
{{ i + '+' + j + '+' + z }}
</div>
</el-col>
</el-row>
<el-row type="flex" justify="space-between">
<el-col :span="12" v-for="j in 2" :key="j">
<div
class="dashboard-layout-item"
v-for="z in 2"
:key="z"
style="background: #ffd781; float: left">
<div
class="dashboard-layout-item-cricle"
style="background: #16dc09" />
{{ i + '+' + j + '+' + z }}
</div>
</el-col>
</el-row>
</el-col>
</el-row>
<el-divider class="divider"></el-divider>
<el-row type="flex" justify="space-around">
<el-col :span="5" v-for="i in 4" :key="i">
<el-row type="flex" justify="space-between">
<el-col :span="12" v-for="j in 2" :key="j">
<div
class="dashboard-layout-item"
v-for="z in 2"
:key="z"
style="background: #ffd781; float: left">
<div
class="dashboard-layout-item-cricle"
style="background: #16dc09" />
{{ i + '+' + j + '+' + z }}
</div>
</el-col>
</el-row>
<el-row type="flex" justify="space-between">
<el-col :span="12" v-for="j in 2" :key="j">
<div
class="dashboard-layout-item"
v-for="z in 2"
:key="z"
style="background: #ffd781; float: left">
<div
class="dashboard-layout-item-cricle"
style="background: #16dc09" />
{{ i + '+' + j + '+' + z }}
</div>
</el-col>
</el-row>
</el-col>
</el-row>
<div class="tips">
<el-tag effect="dark"></el-tag>
<el-tag type="success" effect="dark"></el-tag>
<el-tag type="warning" effect="dark"></el-tag>
</div>
<div class="mainbody">
<div v-for="a in listQuery.total" :key="a">
<el-row>
<el-col :span="24">
<el-row>
<div
class="dashboard-layout-item"
v-for="a in wareData.one"
:key="a.id+a.warehouseStorehouseCode"
:style="{background: bgColor[a.warehouseStorehouseState], float: 'left'}">
<!-- <div
class="dashboard-layout-item-cricle"
style="background: #16dc09" /> -->
{{ a.warehouseStorehouseCode }}
</div>
</el-row>
<el-row>
<div
class="dashboard-layout-item"
v-for="b in wareData.two"
:key="b.id+b.warehouseStorehouseCode"
:style="{background: bgColor[b.warehouseStorehouseState], float: 'left'}">
<!-- <div
class="dashboard-layout-item-cricle"
style="background: #16dc09" /> -->
{{ b.warehouseStorehouseCode }}
</div>
</el-row>
</el-col>
</el-row>
<el-divider class="divider"></el-divider>
<el-row>
<el-col :span="24">
<el-row>
<div
class="dashboard-layout-item"
v-for="c in wareData.there"
:key="c.id+c.warehouseStorehouseCode"
:style="{background: bgColor[c.warehouseStorehouseState], float: 'left'}">
<!-- <div
class="dashboard-layout-item-cricle"
style="background: #16dc09" /> -->
{{ c.warehouseStorehouseCode }}
</div>
</el-row>
<el-row>
<div
class="dashboard-layout-item"
v-for="d in wareData.four"
:key="d.id+d.warehouseStorehouseCode"
:style="{background: bgColor[d.warehouseStorehouseState], float: 'left'}">
<!-- <div
class="dashboard-layout-item-cricle"
style="background: #16dc09" /> -->
{{ d.warehouseStorehouseCode }}
</div>
</el-row>
</el-col>
</el-row>
</div>
</div>
</div>
</div>
</template>
<script>
import basicPage from '../mixins/basic-page';
import { getWarehouseStorehousePage } from '@/api/asrs/warehouseStorehouse';
import { getWarehouseStorehouseList } from '@/api/asrs/warehouseStorehouse';
export default {
mixins: [basicPage],
data() {
return {
urlOptions: {
getDataListURL: getWarehouseStorehousePage,
getDataListURL: getWarehouseStorehouseList,
},
listQuery: {
wareLayer: 1,
total: 0,
},
wareData: {
one: [],
two: [],
there: [],
four: [],
},
bgColor:['#37d97f','#ffbd02','#0b58ff'],
formConfig: [
{
type: 'select',
@@ -124,8 +129,33 @@ export default {
components: {},
created() {
this.listQuery.warehouseId = this.bId;
},
},
methods: {
// 获取数据列表
getDataList() {
this.dataListLoading = true;
this.wareData= {
one: [],
two: [],
there: [],
four: [],
},
this.urlOptions.getDataListURL(this.listQuery).then((response) => {
response.data.forEach((a, b) => {
if (b % 4 === 0) {
this.wareData.one.push(a);
} else if (b % 4 === 1) {
this.wareData.two.push(a);
} else if (b % 4 === 2) {
this.wareData.there.push(a);
} else if (b % 4 === 3) {
this.wareData.four.push(a);
}
});
this.listQuery.total = Math.ceil(response.data.length / 120);
this.dataListLoading = false;
});
},
buttonClick(val) {
switch (val.btnName) {
case 'search':
@@ -141,18 +171,19 @@ export default {
</script>
<style lang="scss" scoped>
.mainbody{
.mainbody {
display: flex;
gap: 50px;
flex-direction: column;
gap: 50px;
flex-direction: column;
}
.dashboard-layout-item {
width: 80px;
color: white;
width: 3.3%;
text-align: center;
height: 32px;
height: 40px;
box-shadow: 0px 3px 6px 0px rgba(166, 174, 190, 0.8);
border-radius: 2px 4px 4px 2px;
margin-bottom: 8px;
margin-bottom: 4px;
display: flex;
align-items: center;
justify-content: center;
@@ -163,11 +194,22 @@ export default {
border-radius: 6px;
margin-right: 6px;
}
&:hover {
background-color: rgba(85, 136, 253, 0.8) !important;
color: #ffffff;
cursor: pointer;
transform: scaleY(1.3) translateZ(0);
}
}
.el-divider--horizontal {
margin: 10px 0;
}
.el-divider{
background-color: black;
.el-divider {
background-color: black;
}
.tips {
position: absolute;
top: 22px;
left: 370px;
}
</style>