<!--
 * @Author: euzhi
 * @Description: 新增车辆
-->
<template>
<view class="appCotent">
<div class="editCar">
    <div class="add__content">
        <div class="add__title">
            填写车辆信息
        </div>
        <div>
            <u--form labelPosition="left" :model="model1" :rules="rules" ref="form1" labelWidth="100">
                <u-form-item label="品牌" prop="userInfo.name" borderBottom ref="item1">
                    <u--input v-model="model1.userInfo.name" placeholder="请输入" border="none"></u--input>
                </u-form-item>
                <u-form-item label="车型" prop="userInfo.name" borderBottom ref="item1">
                    <u--input v-model="model1.userInfo.name" placeholder="请输入" border="none"></u--input>
                </u-form-item>
                <u-form-item label="行驶里程" prop="userInfo.name" borderBottom ref="item1">
                    <div class="self__input__km">
                     <u--input v-model="model1.userInfo.name" placeholder="请输入" border="none"></u--input>KM
                    </div>
                </u-form-item>
                <u-form-item label="车牌号" ref="item1"> </u-form-item>
                <car-number v-model="carNumber"></car-number>
            </u--form>
        </div>
    </div>

    <div class="add__btn add__no__bind">
        保存
    </div>
    <div class="add__btn add__back" @click="goBack">
        删除
    </div>
</div>
</view>
</template>

<script>
import CarNumber from "@/common/codecook-carnumber/codecook-carnumber.vue";
export default {
    components: {
        CarNumber,
    },
    data() {
        return {
            model1: {
                userInfo: {
                    name: "",
                    sex: "",
                },
            },
            rules: {
                "userInfo.name": {
                    type: "string",
                    required: true,
                    message: "请填写姓品牌",
                    trigger: ["blur", "change"],
                },
            },
            items: [{
                    title: "挪车码编号",
                    value: "NC683723293239"
                },
                {
                    title: "车牌号",
                    value: "京A123456"
                },
                {
                    title: "品牌",
                    value: "宝马"
                },
                {
                    title: "车型",
                    value: "SUV"
                }, {
                    title: "绑定手机号",
                    value: "156****9633"
                }
            ]
        };
    },
    methods: {
        goBack() {
            uni.navigateBack({
                delta: 1
            })
        }
    },
}
</script>

<style lang="scss" scoped>
.editCar {
    padding: 40rpx 0rpx;
   /deep/ .u-input__content__field-wrapper__field{
        text-align: right !important;
        padding-right: 30rpx;
        justify-content: space-evenly;
    }
    .u-checkbox-group {
        display: inline-block !important;
    }
   /deep/.u-checkbox-group--row {
        display: inline-block !important;
    }

    .add__content {
        background: #FFFFFF;
        box-shadow: 0rpx 0rpx 28rpx 1rpx rgba(232, 232, 232, 0.2);
        border-radius: 20rpx;
        padding: 40rpx;

        .add__title {
            font-size: 32rpx;
            font-family: PingFang SC;
            font-weight: bold;
            color: #333333;
            margin-bottom: 20rpx;
        }
    }

    .add__btn {
        width: 670rpx;
        height: 76rpx;
        text-align: center;
        line-height: 76rpx;
        margin: 0 auto;
        font-size: 32rpx;
    }

    .add__no__bind {
        background: url('@/static/move-car/move-car-view2.png') no-repeat;
        margin-bottom: 30rpx;
        background-size: contain;
        color: rgba(255, 255, 255, 1);
    }

    .add__back {
        background: url('@/static/move-car/move-car-view1.png') no-repeat;
        background-size: contain;
        color: rgba(153, 153, 153, 1);
    }
}
</style>
