<template>
    <div class="modeBlock">
        <div class="modeBlock-title">
            <div>
                <div class="modeBlock-title-left">
                    <span class="text-leftIcon"></span>
                    <span class="text">上月告警数量</span>
                    <span class="text-rightIcon"></span>
                </div>
                <div class="modeBlock-title-right"></div>
            </div>
        </div>
        <div class="modeBlock-content">
            <div class="leftSun">
                <div class="content-text">
                    <h1>{{ datas.total || 0 }}</h1>
                    <div class="imgs"></div>
                    <div>单位：{{ datas.total || 0 }} 个</div>
                </div>
            </div>
            <div class="rightSun">
                <div class="top">
                    <h2>{{ datas.tongBi || 0 }}</h2>
                    <div>同比<span class="imgtop"></span></div>
                </div>
                <div class="buttom">
                    <h2>{{ datas.huanBi || 0 }}</h2>
                    <div>环比<span class="imgtop"></span></div>
                </div>
            </div>
        </div>
    </div>
</template>
<script>
import allcommunit from './allcommunit'
export default {
    mixins:[allcommunit],
    data() {
        return {
            mixins_query: {
                communityId: ''
            },
            datas: {}
        };
    },
    methods: {
        getData() {
            this.$http
                .get('/sc-community/countDeviceAlarmLastMonth', this.mixins_query)
                .then(({ status, data, msg }) => {
                    if (status == 0) {
                        this.datas = data;
                    }
                })
                .catch((err) => {});
        }
    },
    created() {
     
    }
};
</script>
<style lang="scss" scoped>
@import '@views/smallModule/style.scss';
</style>