ke_junjie
2025-06-04 84620534eb627e95811b971a4b552b6a177829bf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
<template>
    <div class="home-page-compontent-a" v-loading="loading">
        <div class="pannel-title">当前库存数量</div>
        <el-scrollbar>
            <div class="num-flex-containter">
                <div class="num-block-item" v-for="(item,index) in list" :key="index">
                    <div class="num-view"><span class="text">{{item.Count}}</span></div>
                    <div class="serious-view">{{item.SeriesName}}</div>
                    <div class="name-view">{{item.CargoTypeName}}</div>
                </div>
            </div>
        </el-scrollbar>
    </div>
</template>
 
<script>
export default {
    name:'homePageCompontentA',
    data(){
        return {
            loading:false,
            list:[]
        }
    },
    mounted() {
        this.init()
    },
    methods:{
        init(){
            this.getData()
        },
        getData(){
            this.loading = true;
            this.$api.post('HomePageGetVStoreGroupBy',{},{block:'home'}).then((d)=>{
                this.list = d.data || []
                this.loading = false;
            }).catch(()=>{
                this.loading = false;
            })
        }
    }
}
</script>
 
<style scoped lang="scss">
.home-page-compontent-a{
    height: 100%;
    padding: 24px 24px 1px 24px;
    box-sizing: border-box;
    .num-flex-containter{
        display: flex;
    }
    .num-block-item{
        display: flex;
        flex-direction: column;
        justify-content: center;
        padding: 40px 40px 24px 40px;
        flex-shrink: 0;
        &>*{
            display: flex;
            justify-content: center;
        }
        .num-view{
            font-size: 36px;
            .text{
                padding: 0 8px 4px 8px;
                border-bottom: 1px solid #797979;
            }
        }
        .serious-view{
            font-family: Arial Normal;
            font-size: 14px;
            padding-top: 2px;
        }
        .name-view{
            font-family: Arial Normal;
            font-size: 14px;
            color: #289bff;
            padding-top: 20px;
        }
    }
}
</style>