reservation.vue
5.51 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
<template>
<div>
<auth :model="'suggest'" @onLogin="userLogin" ref="auth"></auth>
<modal-comp :visible="modalVisiable" :show-confirm="false" :icon="modalIcon" :content="modalContent" :confirm="modalCallback" :overlay="modalCallback"></modal-comp>
<div class="reservation-container">
<div class="gird-g form">
<div class="pure-u-1 pure-u-md-1-2 form-item">
<div class="label">
<div class="icon"><img src="@/assets/images/reservation/icon-re-name.png"></div> {{$t('reservation.name')}}
</div>
<div class="ipt-wrap">
<input class="ipt" :class="{err : errorTips.e1.length > 0}" type="text" v-model="data.name">
</div>
<div class="validator" v-if="errorTips.e1.length > 0">
<img src="@/assets/images/common/icon-notice.png" alt="">{{errorTips.e1}}
</div>
</div>
<div class="pure-u-1 pure-u-md-1-2 form-item">
<div class="label">
<div class="icon"><img src="@/assets/images/reservation/icon-re-contact.png"></div>{{$t('reservation.contactType')}}
</div>
<div class="ipt-wrap">
<div class="down-arrow"></div>
<el-select class="ipt" v-model="data.contactType">
<el-option v-for="(item,index) in contactTypes" :key="index" :value="item.value" :label="item.name"></el-option>
</el-select>
</div>
</div>
<div class="pure-u-1 pure-u-md-1-2 form-item">
<div class="label">
<div class="icon"><img src="@/assets/images/reservation/icon-re-phone.png"></div>{{$t('reservation.contact')}}
</div>
<div class="ipt-wrap">
<input :placeholder="$t('reservation.contactPlaceholder')" class="ipt" :class="{err : errorTips.e3.length > 0}" type="text" v-model="data.contactMethod">
</div>
<div class="validator" v-if="errorTips.e3.length > 0">
<img src="@/assets/images/common/icon-notice.png" alt="">{{errorTips.e3}}
</div>
</div>
<div class="pure-u-1 pure-u-md-1-2 form-item">
<div class="label">
<div class="icon"><img src="@/assets/images/reservation/icon-re-clock.png"></div>{{$t('reservation.reservationType')}}
</div>
<div class="ipt-wrap">
<div class="down-arrow"></div>
<el-select class="ipt" v-model="data.reservationType">
<el-option v-for="(item,index) in reservationTypes" :key="index" :value="item.value" :label="item.name"></el-option>
</el-select>
</div>
</div>
<div class="pure-u-1 form-item">
<div class="label">
<div class="icon"><img src="@/assets/images/reservation/icon-re-arrow-reservation.png"></div>{{$t('reservation.reservationRemark')}}
</div>
<div class="ipt-wrap">
<textarea :placeholder="$t('reservation.reservationRemarkPlaceholder')" class="ipt textarea" :class="{err : errorTips.e5.length > 0}" v-model="data.instruction"></textarea>
</div>
<div class="validator" v-if="errorTips.e5.length > 0">
<img src="@/assets/images/common/icon-notice.png" alt="">{{errorTips.e5}}
</div>
</div>
<div class="pure-u-1 form-item form-item2">
<div class="label">
<div class="icon"><img src="@/assets/images/reservation/icon-re-custom.png"></div>{{$t('reservation.hkClient')}}
</div>
<div class="cont">
<div class="boo-btn pointer" :class="{active:isHkCus}" @click="isHkCus=true">{{$t('reservation.yes')}}</div>
<div class="boo-btn pointer" :class="{active:!isHkCus}" @click="isHkCus=false">{{$t('reservation.no')}}</div>
</div>
</div>
<!-- 联络时间 -->
<div class="pure-u-1 form-item">
<div class="form-item3">
<div class="label">
<div class="icon"><img src="@/assets/images/reservation/icon-re-calendar.png"></div>{{$t('reservation.contactTime')}}
</div>
<div class="ipt-wrap" :class="{err:errorTips.e7.length>0}">
<!-- <input class="ipt" type="date" v-model="data.contactDate" :class="{err : errorTips.e7.length > 0}"> -->
<date-picker v-model="data.contactDate" :check="checkDate" :filtModel="['history']"></date-picker>
</div>
<div class="validator" v-if="errorTips.e7.length > 0">
<img src="@/assets/images/common/icon-notice.png" alt="">{{errorTips.e7}}
</div>
<div class="mt8">
<div class="label">
</div>
<!-- <div class="calendar">
<img src="@/assets/images/reservation/re-calendar.png">
</div> -->
</div>
</div>
</div>
</div>
<div class="box notice">
<p class="notice-item text-jtf">
<img class="notice-item-icon" src="@/assets/images/reservation/icon-re-notice.png"> {{$t('reservation.notice1')}}
</p>
<p class="notice-item pointer" @click="checked = !checked">
<!-- <img v-if="!checked" class="notice-item-icon" src="@/assets/images/reservation/un-check.png">
<img v-else class="notice-item-icon" src="@/assets/images/reservation/check.png"> -->
<img v-if="!checked" class="notice-item-icon" src="@/assets/images/login/uncheck.png">
<img v-else class="notice-item-icon" src="@/assets/images/login/check.png"> {{$t('reservation.notice2')}}
</p>
</div>
<div class="submit-btn flex-center" :class="{disabled : submitBtnDisabled}" @click="submitHandler">
<van-loading v-if="isSubmit" />
<span>{{$t('reservation.submitBtn')}}</span>
</div>
<div class="flex-center validator" v-if="errorTips.e8.length > 0">
<img src="@/assets/images/common/icon-notice.png" alt=""> {{errorTips.e8}}
</div>
</div>
</div>
</template>
<script src="./reservation.js"></script>
<style lang="scss" scoped>
@import "./reservation.scss";
</style>