<!--pages/writeReading/components/meterInfo/index.wxml-->
<view class="wrapper">
    <view class="title" style="display: flex; justify-content: space-between; align-items: center;">
        <text> 电表详情 </text>
        <view class="time">
            <!-- 2025年9月5日 -->
            <van-button size="small" type="info" bind:click="jumpToHistory">
                历史记录
            </van-button>
        </view>
    </view>
    <view class="info">
        <view class="title">
            <view class="address">
                {{ meterInfo.address }}
            </view>
            <view class="meterType">
                <van-tag type="primary">华昌宝能收费</van-tag> 
            </view>
            
        </view>
        <view class="detail">
            <van-row gutter="20">
                <van-col span="12">
                    <view class="text">
                        <view class="titleText">
                            编号
                        </view>
                        <view>
                            {{meterInfo.meterSn}}
                        </view>
                    </view>
                </van-col>
                <van-col span="12">
                    <view class="text">
                        <view class="titleText">
                            类型
                        </view>
                        <view wx:if="{{meterInfo.meterBelongType === 0}}">
                            商户电表
                        </view>
                        <view wx:elif="{{meterInfo.meterBelongType === 1}}">
                            公区电表
                        </view>
                        <view wx:elif="{{meterInfo.meterBelongType === 2}}">
                            公摊电表
                        </view>
                    </view>
                </van-col>
                <van-col span="12">
                    <view class="text">
                        <view class="titleText">
                            状态
                        </view>
                        <view wx:if="{{meterInfo.enabled}}">
                            正常
                        </view>
                        <view wx:else>
                            停用
                        </view>
                    </view>
                </van-col>
                <van-col span="12">
                    <view class="text">
                        <view class="titleText">
                            读数
                        </view>
                        <view>
                            {{meterInfo.overall}}
                        </view>
                    </view>
                </van-col>
            </van-row>
        </view>
    </view>
</view>