<template>
    <div>
        <el-form ref="form" :model="form" label-width="80px">
            <el-form-item label="订单编号">
                <el-col :span='12'>
                    <span>{{form.orderNumber}}</span>
                </el-col>
            </el-form-item>
            <el-form-item label="申请内容">
                <el-select v-model="form.reasonCancel" placeholder="请选择申请内容">
                <el-option label="分开发货" value="0"></el-option>
                <el-option label="改运费" value="1"></el-option>
                </el-select>
            </el-form-item>
            <el-form-item>
                <el-button type="primary" @click="submitForm()">提交</el-button>
            </el-form-item>
        </el-form>
    </div>
</template>
<script>
import { getOrder, } from '@/api/orderManagement/orderList'
export default {
    props: {
        rowid: {
        type: String,
        default: ''
        },
    },
    data(){
        return{
            form:{
                orderNumber:'',//订单编号
                reasonCancel:'',//取消原因
            }
        }
    },
    created() {
        console.log(this.rowid)
        if (this.rowid) {
        this.getDetail(this.rowid)
        }
    },
    methods: {
        submitForm(){

        },
        // 详情
        getDetail(rid) {
            getOrder(rid).then(response => {
                if (response.state.toLowerCase() === 'success') {
                const res = response.data.model
                this.form.orderNumber=res.ordercode
                }
            })
        },
    },
}
</script>
<style lang="scss" scoped>
</style>