<template>
    <ul class="count_con">
        <li>
            <span>任务总数:</span>
            <Count :count="dataNum.total" />
        </li>
        <li>
            <span>待办数:</span>
            <Count :count="dataNum.dbsl" />
        </li>
        <li>
            <span>已完成:</span>
            <Count :count="dataNum.ywcsl" />
        </li>
        <li>
            <span>未完成:</span>
            <Count :count="dataNum.wwcsl" />
        </li>
    </ul>
</template>
<script setup>
import Count from '@/components/Statistics.vue'
import { onMounted, ref } from 'vue'
const dataNum = ref({
    total: 200,
    dbsl: 100,
    ywcsl: 53,
    wwcsl: 20
})
onMounted(() => {
    setInterval(() => {
        dataNum.value.total = dataNum.value.total + 2
        dataNum.value.dbsl = dataNum.value.dbsl + 4
        dataNum.value.ywcsl = dataNum.value.ywcsl + 1
        dataNum.value.wwcsl = dataNum.value.wwcsl + 2
    }, 5000)
})
</script>
<style lang="scss" scoped>
.count_con {
    height: 50px;
    display: flex;
    justify-content: space-around;
    background: #FFFFFF;

    li {
        font-size: 12px;
        display: flex;
        font-weight: 400;
        color: var(--el-color-primary);
        line-height: 16px;

        >span {
            display: block;
            margin: auto 5px;
        }

        .count_span {
            display: flex;
            margin: 0 5px;


        }
    }
}
</style>