<template>
    <!-- 砼申请表单信息，5+个地方复用 -->
    <uni-section title="申请信息" type="line">
        <tui-list-cell :unlined="true" :hover="false" :arrow="false">
            <view class="base-item">
                <view class="label"> 工程申请编号： </view>
                <view class="content"> {{ applicationData.number }} </view>
            </view>
        </tui-list-cell>
        <tui-list-cell :unlined="true" :hover="false" :arrow="false" >
            <view class="base-item">
                <view class="label"> 混凝土类型： </view>
                <view class="content"> {{ applicationData.type_name }} </view>
            </view>
        </tui-list-cell>
        <tui-list-cell :unlined="true" :hover="false" :arrow="false">
            <view class="base-item">
                <!-- <view class="label"> 工队： </view> -->
                <view class="label"> 供应单位名称： </view>
                <view class="content"> {{ applicationData.supplier_name }} </view>
            </view>
        </tui-list-cell>
        <tui-list-cell :unlined="true" :hover="false" :arrow="false">
            <view class="base-item">
                <view class="label"> 部位1： </view>
                <view class="content"> {{ applicationData.usedpart_full_name }} </view>
            </view>
        </tui-list-cell>
        <tui-list-cell :unlined="true" :hover="false" :arrow="false">
            <view class="base-item">
                <view class="label"> 部位1百分比：</view>
                <view class="content"> {{ !applicationData.usedpart_percent ? 100 : applicationData.usedpart_percent }}%
                </view>
            </view>
        </tui-list-cell>
        <tui-list-cell v-if="applicationData.usedpart2_full_name" :unlined="true" :hover="false" :arrow="false">
            <view class="base-item">
                <view class="label"> 部位2： </view>
                <view class="content"> {{ applicationData.usedpart2_full_name }} </view>
            </view>
        </tui-list-cell>
        <tui-list-cell v-if="applicationData.usedpart2_full_name" :unlined="true" :hover="false" :arrow="false">
            <view class="base-item">
                <view class="label"> 部位2百分比： </view>
                <view class="content"> {{ applicationData.usedpart2_percent }} %</view>
            </view>
        </tui-list-cell>
        <tui-list-cell v-if="applicationData.usedlist_full_name" :unlined="true" :hover="false" :arrow="false">
            <view class="base-item">
                <view class="label"> 清单: </view>
                <view class="content"> {{ applicationData.usedlist_full_name }} %</view>
            </view>
        </tui-list-cell>
        <tui-list-cell :unlined="true" :hover="false" :arrow="false">
            <view class="base-item">
                <view class="label"> 是否有计划： </view>
                <view class="content"> 是 </view>
            </view>
        </tui-list-cell>
        <tui-list-cell :unlined="true" :hover="false" :arrow="false">
            <view class="base-item">
                <view class="label"> 规格型号： </view>
                <view class="content"> {{ applicationData.material_name }} </view>
            </view>
        </tui-list-cell>
        <tui-list-cell :unlined="true" :hover="false" :arrow="false">
            <view class="base-item">
                <!-- <view class="label"> 供应单位： </view> -->
                <view class="label"> 用料单位名称： </view>
                <view class="content"> {{ applicationData.user_name }} </view>
            </view>
        </tui-list-cell>
        <tui-list-cell :unlined="true" :hover="false" :arrow="false">
            <view class="base-item">
                <view class="label"> 是否按工程量申请： </view>
                <view class="content"> {{ applicationData.is_according_project ? "是" : "否" }} </view>
            </view>
        </tui-list-cell>
        <tui-list-cell :unlined="true" :hover="false" :arrow="false">
            <view class="base-item">
                <view class="label"> 是否泵送： </view>
                <view class="content"> {{ applicationData.is_pump ? "是" : "否" }} </view>
            </view>
        </tui-list-cell>
        <tui-list-cell :unlined="true" :hover="false" :arrow="false">
            <view class="base-item">
                <view class="label"> 工号长度： </view>
                <view class="content">
                    {{ isNaN(applicationData.end_position - applicationData.start_position) ? 0 :
                        applicationData.end_position - applicationData.start_position }}m</view>
            </view>
        </tui-list-cell>
        <tui-list-cell :unlined="true" :hover="false" :arrow="false">
            <view class="base-item">
                <view class="label"> 塌落度： </view>
                <view class="content"> {{ applicationData.slump }} </view>
            </view>
        </tui-list-cell>
        <tui-list-cell :unlined="true" :hover="false" :arrow="false">
            <view class="base-item">
                <view class="label"> 计划量： </view>
                <view class="content"> {{ applicationData.plan_quantity }} m³ </view>
            </view>
        </tui-list-cell>
        <tui-list-cell :unlined="true" :hover="false" :arrow="false">
            <view class="base-item">
                <view class="label"> 申请量： </view>
                <view class="content"> {{ applicationData.apply_quantity }} m³</view>
            </view>
        </tui-list-cell>
        <view style="border-top: 1px solid #eee; margin-top: 10px;">
            <!-- <tui-list-cell :unlined="true" :hover="false" :arrow="false">
                <view class="base-item">
                    <view class="label"> 要求： </view>
                    <view class="content"> {{ applicationData.request }} </view>
                </view>
            </tui-list-cell> -->
            <tui-list-cell :unlined="true" :hover="false" :arrow="false">
                <view class="base-item">
                    <view class="label"> 到场时间： </view>
                    <view class="content"> {{ applicationData.plan_time }} </view>
                </view>
            </tui-list-cell>
            <tui-list-cell :unlined="true" :hover="false" :arrow="false">
                <view class="base-item">
                    <view class="label"> 备注： </view>
                    <view class="content"> {{ applicationData.remark }} </view>
                </view>
            </tui-list-cell>
            <tui-list-cell :unlined="true" :hover="false" :arrow="false">
                <view class="base-item">
                    <view class="label"> 申请人： </view>
                    <view class="content"> {{ applicationData.creator_name }} </view>
                </view>
            </tui-list-cell>
            <tui-list-cell :unlined="true" :hover="false" :arrow="false">
                <view class="base-item">
                    <view class="label"> 申请时间： </view>
                    <view class="content"> {{ applicationData.create_time }} </view>
                </view>
            </tui-list-cell>
        </view>
        <view style="border-top: 1px solid #eee; margin-top: 10px;">
            <tui-list-cell :unlined="true" :hover="false" :arrow="false">
                <view class="base-item">
                    <view class="label"> 工队名称： </view>
                    <view class="content"> {{ applicationData.team_name }} </view>
                </view>
            </tui-list-cell>
            <tui-list-cell :unlined="true" :hover="false" :arrow="false">
                <view class="base-item">
                    <view class="label"> 联系人： </view>
                    <view class="content"> {{ applicationData.contact_name }} </view>
                </view>
            </tui-list-cell>
            <tui-list-cell :unlined="true" :hover="false" :arrow="false">
                <view class="base-item">
                    <view class="label"> 联系电话： </view>
                    <view class="content"> {{ applicationData.contact_phone }} </view>
                </view>
            </tui-list-cell>
        </view>
    </uni-section>
</template>
<script>
export default {
    props: ["applicationData"],
};
</script>
<style lang="scss" scoped>
::v-deep .uni-section {
    margin: 20rpx auto;
    padding-bottom: 20rpx;
    width: 95%;
}

::v-deep .tui-list-cell {
    // height: 60rpx;
    padding-top: 0rpx !important;
    padding-bottom: 0rpx !important;
}
.base-item {
    .label {
      display: inline-block;
        width: 30vw;
        font-size: 30rpx;
    }
    .content {
      display: inline-block;
      width: 55vw;
      font-size: 30rpx;
      vertical-align: text-top;
      // padding-bottom: 20rpx;
    }
}

::v-deep .tui-btn {
    margin: 20rpx auto !important;
    width: 95% !important;
    height: 80rpx !important;
    line-height: 80rpx !important;
    font-size: 28rpx !important;
}
</style>
