b40d8e59 by zhangmeng

票务

1 parent b2619165
1 import request from '@/utils/request' 1 import request from '@/utils/request'
2
2 export function getHotelList(params) { 3 export function getHotelList(params) {
3 return request({ 4 return request({
4 url: `/ota/activityHotel/list`, 5 url: `/ota/activityHotel/list`,
...@@ -6,6 +7,7 @@ export function getHotelList(params) { ...@@ -6,6 +7,7 @@ export function getHotelList(params) {
6 params: params 7 params: params
7 }) 8 })
8 } 9 }
10
9 export function getStudioList(params) { 11 export function getStudioList(params) {
10 return request({ 12 return request({
11 url: `/ota/studio/list`, 13 url: `/ota/studio/list`,
...@@ -13,18 +15,21 @@ export function getStudioList(params) { ...@@ -13,18 +15,21 @@ export function getStudioList(params) {
13 params: params 15 params: params
14 }) 16 })
15 } 17 }
18
16 export function getHotelById(id) { 19 export function getHotelById(id) {
17 return request({ 20 return request({
18 url: `/ota/hotel/${id}`, 21 url: `/ota/hotel/${id}`,
19 method: 'get' 22 method: 'get'
20 }) 23 })
21 } 24 }
25
22 export function getStudioById(id) { 26 export function getStudioById(id) {
23 return request({ 27 return request({
24 url: `/ota/studio/${id}`, 28 url: `/ota/studio/${id}`,
25 method: 'get' 29 method: 'get'
26 }) 30 })
27 } 31 }
32
28 export function getHotelRooms(params) { 33 export function getHotelRooms(params) {
29 return request({ 34 return request({
30 url: `/ota/activityRoom/list`, 35 url: `/ota/activityRoom/list`,
...@@ -40,6 +45,7 @@ export function checkResidueRoom(data) { ...@@ -40,6 +45,7 @@ export function checkResidueRoom(data) {
40 data: data 45 data: data
41 }) 46 })
42 } 47 }
48
43 export function newsSubmitOrderHotel(data) { 49 export function newsSubmitOrderHotel(data) {
44 return request({ 50 return request({
45 url: `/ota/norder/submitOrderRoom`, 51 url: `/ota/norder/submitOrderRoom`,
...@@ -47,6 +53,7 @@ export function newsSubmitOrderHotel(data) { ...@@ -47,6 +53,7 @@ export function newsSubmitOrderHotel(data) {
47 data: data 53 data: data
48 }) 54 })
49 } 55 }
56
50 export function getRoomBilldetailbyId(params) { 57 export function getRoomBilldetailbyId(params) {
51 return request({ 58 return request({
52 url: `/ota/orderRoom/getRoomOrderInfoByOrderId`, 59 url: `/ota/orderRoom/getRoomOrderInfoByOrderId`,
...@@ -54,6 +61,7 @@ export function getRoomBilldetailbyId(params) { ...@@ -54,6 +61,7 @@ export function getRoomBilldetailbyId(params) {
54 params: params 61 params: params
55 }) 62 })
56 } 63 }
64
57 export function getCarBilldetailbyId(params) { 65 export function getCarBilldetailbyId(params) {
58 return request({ 66 return request({
59 url: `/ota/norder/getOrderByOrderId`, 67 url: `/ota/norder/getOrderByOrderId`,
...@@ -61,6 +69,7 @@ export function getCarBilldetailbyId(params) { ...@@ -61,6 +69,7 @@ export function getCarBilldetailbyId(params) {
61 params: params 69 params: params
62 }) 70 })
63 } 71 }
72
64 export function getFoodBilldetailbyId(params) { 73 export function getFoodBilldetailbyId(params) {
65 return request({ 74 return request({
66 url: `/ota/orderFood/getFoodOrderInfoByOrder`, 75 url: `/ota/orderFood/getFoodOrderInfoByOrder`,
...@@ -68,6 +77,7 @@ export function getFoodBilldetailbyId(params) { ...@@ -68,6 +77,7 @@ export function getFoodBilldetailbyId(params) {
68 params: params 77 params: params
69 }) 78 })
70 } 79 }
80
71 export function getActivityCarList(params) { 81 export function getActivityCarList(params) {
72 return request({ 82 return request({
73 url: `/ota/activityVehicle/wxList`, 83 url: `/ota/activityVehicle/wxList`,
...@@ -75,6 +85,7 @@ export function getActivityCarList(params) { ...@@ -75,6 +85,7 @@ export function getActivityCarList(params) {
75 params: params 85 params: params
76 }) 86 })
77 } 87 }
88
78 export function submitOrderCar(data) { 89 export function submitOrderCar(data) {
79 return request({ 90 return request({
80 url: `/ota/norder/submitOrderCar`, 91 url: `/ota/norder/submitOrderCar`,
...@@ -82,6 +93,7 @@ export function submitOrderCar(data) { ...@@ -82,6 +93,7 @@ export function submitOrderCar(data) {
82 data: data 93 data: data
83 }) 94 })
84 } 95 }
96
85 export function getActivityRestaurantList(params) { 97 export function getActivityRestaurantList(params) {
86 return request({ 98 return request({
87 url: `/ota/activityRestaurant/list`, 99 url: `/ota/activityRestaurant/list`,
...@@ -89,6 +101,7 @@ export function getActivityRestaurantList(params) { ...@@ -89,6 +101,7 @@ export function getActivityRestaurantList(params) {
89 params: params 101 params: params
90 }) 102 })
91 } 103 }
104
92 export function getMenuById(params) { 105 export function getMenuById(params) {
93 return request({ 106 return request({
94 url: `/ota/activityFood/list`, 107 url: `/ota/activityFood/list`,
...@@ -96,6 +109,7 @@ export function getMenuById(params) { ...@@ -96,6 +109,7 @@ export function getMenuById(params) {
96 params: params 109 params: params
97 }) 110 })
98 } 111 }
112
99 export function submitOrderFood(form) { 113 export function submitOrderFood(form) {
100 return request({ 114 return request({
101 url: `/ota/norder/submitOrderFood`, 115 url: `/ota/norder/submitOrderFood`,
...@@ -103,29 +117,33 @@ export function submitOrderFood(form) { ...@@ -103,29 +117,33 @@ export function submitOrderFood(form) {
103 data: form 117 data: form
104 }) 118 })
105 } 119 }
120
106 export function createWePay(data) { 121 export function createWePay(data) {
107 return request({ 122 return request({
108 url: `/ota/norder/wxPay`, 123 url: `/ota/norder/wxPay`,
109 method: 'post', 124 method: 'post',
110 data:data 125 data: data
111 }) 126 })
112 } 127 }
128
113 export function createPalPay(data) { 129 export function createPalPay(data) {
114 return request({ 130 return request({
115 url: `/ota/norder/palPay`, 131 url: `/ota/norder/palPay`,
116 method: 'post', 132 method: 'post',
117 data:data 133 data: data
118 }) 134 })
119 } 135 }
136
120 export function callbackPalPay(tradeNo) { 137 export function callbackPalPay(tradeNo) {
121 return request({ 138 return request({
122 url: `/ota/norder/palPay/callback`, 139 url: `/ota/norder/palPay/callback`,
123 method: 'post', 140 method: 'post',
124 data:{ 141 data: {
125 tradeNo:tradeNo 142 tradeNo: tradeNo
126 } 143 }
127 }) 144 })
128 } 145 }
146
129 export function getInvoiceByActiveId(query) { 147 export function getInvoiceByActiveId(query) {
130 return request({ 148 return request({
131 url: `/ota/invoice/list`, 149 url: `/ota/invoice/list`,
...@@ -133,6 +151,7 @@ export function getInvoiceByActiveId(query) { ...@@ -133,6 +151,7 @@ export function getInvoiceByActiveId(query) {
133 params: query 151 params: query
134 }) 152 })
135 } 153 }
154
136 export function getCanInvoiceBills(query) { 155 export function getCanInvoiceBills(query) {
137 return request({ 156 return request({
138 url: `/ota/norder/getOrderInvoiceList`, 157 url: `/ota/norder/getOrderInvoiceList`,
...@@ -140,6 +159,7 @@ export function getCanInvoiceBills(query) { ...@@ -140,6 +159,7 @@ export function getCanInvoiceBills(query) {
140 params: query 159 params: query
141 }) 160 })
142 } 161 }
162
143 export function getCanInvoiceBm(query) { 163 export function getCanInvoiceBm(query) {
144 return request({ 164 return request({
145 url: `/league/signOrder/getMyPayedCptOrder`, 165 url: `/league/signOrder/getMyPayedCptOrder`,
...@@ -147,6 +167,7 @@ export function getCanInvoiceBm(query) { ...@@ -147,6 +167,7 @@ export function getCanInvoiceBm(query) {
147 params: query 167 params: query
148 }) 168 })
149 } 169 }
170
150 export function getCanInvoiceTicket(query) { 171 export function getCanInvoiceTicket(query) {
151 return request({ 172 return request({
152 url: `/api/order/getOrderInvoiceList`, 173 url: `/api/order/getOrderInvoiceList`,
...@@ -154,6 +175,7 @@ export function getCanInvoiceTicket(query) { ...@@ -154,6 +175,7 @@ export function getCanInvoiceTicket(query) {
154 params: query 175 params: query
155 }) 176 })
156 } 177 }
178
157 export function cancelOrder(orderId) { 179 export function cancelOrder(orderId) {
158 return request({ 180 return request({
159 // url: `/logex/norder/unSubscribeOrderBack/${orderId}`, 181 // url: `/logex/norder/unSubscribeOrderBack/${orderId}`,
...@@ -162,6 +184,7 @@ export function cancelOrder(orderId) { ...@@ -162,6 +184,7 @@ export function cancelOrder(orderId) {
162 params: orderId 184 params: orderId
163 }) 185 })
164 } 186 }
187
165 // 取消 188 // 取消
166 export function cancelOrder2(orderId) { 189 export function cancelOrder2(orderId) {
167 return request({ 190 return request({
...@@ -170,6 +193,7 @@ export function cancelOrder2(orderId) { ...@@ -170,6 +193,7 @@ export function cancelOrder2(orderId) {
170 params: orderId 193 params: orderId
171 }) 194 })
172 } 195 }
196
173 export function addressList(userId) { 197 export function addressList(userId) {
174 return request({ 198 return request({
175 url: `/ota/invoiceInfo/list`, 199 url: `/ota/invoiceInfo/list`,
...@@ -179,12 +203,14 @@ export function addressList(userId) { ...@@ -179,12 +203,14 @@ export function addressList(userId) {
179 } 203 }
180 }) 204 })
181 } 205 }
206
182 export function getBaseInfoByActiveId(id) { 207 export function getBaseInfoByActiveId(id) {
183 return request({ 208 return request({
184 url: `/ota/activity/${id}`, 209 url: `/ota/activity/${id}`,
185 method: 'get' 210 method: 'get'
186 }) 211 })
187 } 212 }
213
188 export function checkRoomPayByUserId(id) { 214 export function checkRoomPayByUserId(id) {
189 return request({ 215 return request({
190 url: `/ota/norder/checkRoomPayByUserId`, 216 url: `/ota/norder/checkRoomPayByUserId`,
...@@ -194,6 +220,7 @@ export function checkRoomPayByUserId(id) { ...@@ -194,6 +220,7 @@ export function checkRoomPayByUserId(id) {
194 } 220 }
195 }) 221 })
196 } 222 }
223
197 export function submitInvoice(form) { 224 export function submitInvoice(form) {
198 return request({ 225 return request({
199 url: `/ota/invoice`, 226 url: `/ota/invoice`,
...@@ -201,6 +228,7 @@ export function submitInvoice(form) { ...@@ -201,6 +228,7 @@ export function submitInvoice(form) {
201 data: form 228 data: form
202 }) 229 })
203 } 230 }
231
204 export function submitCptInvoice(form) { 232 export function submitCptInvoice(form) {
205 return request({ 233 return request({
206 url: `/cpt/invoice`, 234 url: `/cpt/invoice`,
...@@ -216,6 +244,7 @@ export function editInvoice(form) { ...@@ -216,6 +244,7 @@ export function editInvoice(form) {
216 data: form 244 data: form
217 }) 245 })
218 } 246 }
247
219 export function editInvoiceMatch(form) { 248 export function editInvoiceMatch(form) {
220 return request({ 249 return request({
221 url: `/cpt/invoice`, 250 url: `/cpt/invoice`,
...@@ -231,6 +260,7 @@ export function editCptInvoice(form) { ...@@ -231,6 +260,7 @@ export function editCptInvoice(form) {
231 data: form 260 data: form
232 }) 261 })
233 } 262 }
263
234 export function addAddress(form) { 264 export function addAddress(form) {
235 return request({ 265 return request({
236 url: `/ota/invoiceInfo`, 266 url: `/ota/invoiceInfo`,
...@@ -238,6 +268,7 @@ export function addAddress(form) { ...@@ -238,6 +268,7 @@ export function addAddress(form) {
238 data: form 268 data: form
239 }) 269 })
240 } 270 }
271
241 export function delAddress(ids) { 272 export function delAddress(ids) {
242 return request({ 273 return request({
243 url: `/ota/invoiceInfo/${ids}`, 274 url: `/ota/invoiceInfo/${ids}`,
...@@ -249,7 +280,7 @@ export function getMakeUpList(data) { ...@@ -249,7 +280,7 @@ export function getMakeUpList(data) {
249 return request({ 280 return request({
250 url: `/ota/activityStudio/getStudioList`, 281 url: `/ota/activityStudio/getStudioList`,
251 method: 'get', 282 method: 'get',
252 params:data 283 params: data
253 }) 284 })
254 } 285 }
255 286
...@@ -257,7 +288,7 @@ export function makeUpDetail(data) { ...@@ -257,7 +288,7 @@ export function makeUpDetail(data) {
257 return request({ 288 return request({
258 url: `/ota/activityStudio/getComStudioVoById`, 289 url: `/ota/activityStudio/getComStudioVoById`,
259 method: 'get', 290 method: 'get',
260 params:data 291 params: data
261 }) 292 })
262 } 293 }
263 294
...@@ -265,7 +296,7 @@ export function getActivityMealVoListByStudioId(data) { ...@@ -265,7 +296,7 @@ export function getActivityMealVoListByStudioId(data) {
265 return request({ 296 return request({
266 url: `/ota/activityMeal/getActivityMealVoListByStudioId`, 297 url: `/ota/activityMeal/getActivityMealVoListByStudioId`,
267 method: 'get', 298 method: 'get',
268 params:data 299 params: data
269 }) 300 })
270 } 301 }
271 302
...@@ -273,7 +304,7 @@ export function getMealConfList(data) { ...@@ -273,7 +304,7 @@ export function getMealConfList(data) {
273 return request({ 304 return request({
274 url: `/ota/mealConfig/getMealConfList`, 305 url: `/ota/mealConfig/getMealConfList`,
275 method: 'get', 306 method: 'get',
276 params:data 307 params: data
277 }) 308 })
278 } 309 }
279 310
...@@ -289,7 +320,7 @@ export function getMealOrderInfo(data) { ...@@ -289,7 +320,7 @@ export function getMealOrderInfo(data) {
289 return request({ 320 return request({
290 url: `/ota/orderMeal/getMealOrderInfo`, 321 url: `/ota/orderMeal/getMealOrderInfo`,
291 method: 'get', 322 method: 'get',
292 params:data 323 params: data
293 }) 324 })
294 } 325 }
295 326
...@@ -298,7 +329,7 @@ export function getMealOrderInfoByLogex(data) { ...@@ -298,7 +329,7 @@ export function getMealOrderInfoByLogex(data) {
298 return request({ 329 return request({
299 url: `/ota/orderMeal/getMealOrderInfoByLogex`, 330 url: `/ota/orderMeal/getMealOrderInfoByLogex`,
300 method: 'get', 331 method: 'get',
301 params:data 332 params: data
302 }) 333 })
303 } 334 }
304 335
...@@ -306,7 +337,7 @@ export function getShootList(data) { ...@@ -306,7 +337,7 @@ export function getShootList(data) {
306 return request({ 337 return request({
307 url: `/ota/activityShoot/getShootList`, 338 url: `/ota/activityShoot/getShootList`,
308 method: 'get', 339 method: 'get',
309 params:data 340 params: data
310 }) 341 })
311 } 342 }
312 343
...@@ -314,7 +345,7 @@ export function getComShootVoById(data) { ...@@ -314,7 +345,7 @@ export function getComShootVoById(data) {
314 return request({ 345 return request({
315 url: `/ota/activityShoot/getComShootVoById`, 346 url: `/ota/activityShoot/getComShootVoById`,
316 method: 'get', 347 method: 'get',
317 params:data 348 params: data
318 }) 349 })
319 } 350 }
320 351
...@@ -322,7 +353,7 @@ export function getActivityPhotoVoListByShootId(data) { ...@@ -322,7 +353,7 @@ export function getActivityPhotoVoListByShootId(data) {
322 return request({ 353 return request({
323 url: `/ota/activityPhoto/getActivityPhotoVoListByShootId`, 354 url: `/ota/activityPhoto/getActivityPhotoVoListByShootId`,
324 method: 'get', 355 method: 'get',
325 params:data 356 params: data
326 }) 357 })
327 } 358 }
328 359
...@@ -330,7 +361,7 @@ export function getPhotoConfList(data) { ...@@ -330,7 +361,7 @@ export function getPhotoConfList(data) {
330 return request({ 361 return request({
331 url: `/ota/photoConfig/getPhotoConfList`, 362 url: `/ota/photoConfig/getPhotoConfList`,
332 method: 'get', 363 method: 'get',
333 params:data 364 params: data
334 }) 365 })
335 } 366 }
336 367
...@@ -346,7 +377,7 @@ export function getPhotoOrderInfo(data) { ...@@ -346,7 +377,7 @@ export function getPhotoOrderInfo(data) {
346 return request({ 377 return request({
347 url: `/ota/orderPhoto/getPhotoOrderInfo`, 378 url: `/ota/orderPhoto/getPhotoOrderInfo`,
348 method: 'get', 379 method: 'get',
349 params:data 380 params: data
350 }) 381 })
351 } 382 }
352 383
...@@ -354,39 +385,44 @@ export function getPhotoOrderInfoByLogex(data) { ...@@ -354,39 +385,44 @@ export function getPhotoOrderInfoByLogex(data) {
354 return request({ 385 return request({
355 url: `/ota/orderPhoto/getPhotoOrderInfoByLogex`, 386 url: `/ota/orderPhoto/getPhotoOrderInfoByLogex`,
356 method: 'get', 387 method: 'get',
357 params:data 388 params: data
358 }) 389 })
359 } 390 }
391
360 export function getInvoiceDetailBills(invoiceId) { 392 export function getInvoiceDetailBills(invoiceId) {
361 return request({ 393 return request({
362 url: `/ota/norder/list`, 394 url: `/ota/norder/list`,
363 method: 'get', 395 method: 'get',
364 params:{ 396 params: {
365 invoiceId:invoiceId 397 invoiceId: invoiceId
366 } 398 }
367 }) 399 })
368 } 400 }
401
369 export function getLeagueInvoiceDetail(invoiceId) { 402 export function getLeagueInvoiceDetail(invoiceId) {
370 return request({ 403 return request({
371 url: `/league/signOrder/list`, 404 url: `/league/signOrder/list`,
372 method: 'get', 405 method: 'get',
373 params:{ 406 params: {
374 invoiceId:invoiceId 407 invoiceId: invoiceId
375 } 408 }
376 }) 409 })
377 } 410 }
411
378 export function getLeagueInvoiceDetailPC(invoiceId) { 412 export function getLeagueInvoiceDetailPC(invoiceId) {
379 return request({ 413 return request({
380 url: `/league/signOrder/getByInvoiceId/${invoiceId}`, 414 url: `/league/signOrder/getByInvoiceId/${invoiceId}`,
381 method: 'get' 415 method: 'get'
382 }) 416 })
383 } 417 }
418
384 export function getInvoiceDetail(invoiceId) { 419 export function getInvoiceDetail(invoiceId) {
385 return request({ 420 return request({
386 url: `/ota/invoice/${invoiceId}`, 421 url: `/ota/invoice/${invoiceId}`,
387 method: 'get' 422 method: 'get'
388 }) 423 })
389 } 424 }
425
390 export function getInvoiceDetailMatch(invoiceId) { 426 export function getInvoiceDetailMatch(invoiceId) {
391 return request({ 427 return request({
392 url: `/cpt/invoice/${invoiceId}`, 428 url: `/cpt/invoice/${invoiceId}`,
...@@ -399,17 +435,19 @@ export function getReceipt(query) { ...@@ -399,17 +435,19 @@ export function getReceipt(query) {
399 return request({ 435 return request({
400 url: `/league/signOrder/getReceipt/${query.orderId}`, 436 url: `/league/signOrder/getReceipt/${query.orderId}`,
401 method: 'post', 437 method: 'post',
402 params:query 438 params: query
403 }) 439 })
404 } 440 }
441
405 export function ppOtaReceipt(query) { 442 export function ppOtaReceipt(query) {
406 // type 1是下载 2是发送到邮箱 443 // type 1是下载 2是发送到邮箱
407 return request({ 444 return request({
408 url: `/ota/norder/getReceipt/${query.orderId}`, 445 url: `/ota/norder/getReceipt/${query.orderId}`,
409 method: 'post', 446 method: 'post',
410 params:query 447 params: query
411 }) 448 })
412 } 449 }
450
413 // 获取票务信息 451 // 获取票务信息
414 export function getTicketInfoByActivityId(params) { 452 export function getTicketInfoByActivityId(params) {
415 return request({ 453 return request({
...@@ -463,3 +501,21 @@ export function delCustomer(id) { ...@@ -463,3 +501,21 @@ export function delCustomer(id) {
463 method: 'delete', 501 method: 'delete',
464 }) 502 })
465 } 503 }
504
505 // 获取价格
506 export function getTicketTotalApi(data) {
507 return request({
508 url: `/ota/orderTicket/getTicketTotal`,
509 method: 'POST',
510 data
511 })
512 }
513
514 // 下单
515 export function TicketOrderBoApi(data) {
516 return request({
517 url: `/ota/orderTicket/TicketOrderBo`,
518 method: 'POST',
519 data
520 })
521 }
......
1 <template> 1 <template>
2 <el-card class="container" > 2 <el-card class="container">
3 <div v-loading="loading" > 3 <div v-loading="loading">
4 <div class="title"> 4 <div class="title">
5 {{ languageFormat(language, "订单确认", "Order confirmation") }} 5 {{ languageFormat(language, "订单确认", "Order confirmation") }}
6 </div> 6 </div>
...@@ -23,38 +23,38 @@ ...@@ -23,38 +23,38 @@
23 <div class="form"> 23 <div class="form">
24 <el-form label-width="100px"> 24 <el-form label-width="100px">
25 <el-form-item 25 <el-form-item
26 :label="language == 0 ? '联系人' : 'contact'"
27 >
28 <el-input
29 v-model="orderForm.contacts"
30 :placeholder=" language == 0 ? '请输入联系人' : 'Please enter the contact'"
31 style="width: 320px"
32 />
33 </el-form-item>
34 <el-form-item
26 :label="language == 0 ? '联系人电话' : 'contact phone'" 35 :label="language == 0 ? '联系人电话' : 'contact phone'"
27 > 36 >
28 <el-input 37 <el-input
29 v-model="form.phone" 38 v-model="orderForm.phone"
30 :placeholder=" language == 0 ? '请输入联系电话' : 'Please enter the contact phone number'" style="width: 320px" 39 :placeholder=" language == 0 ? '请输入联系电话' : 'Please enter the contact phone number'"
40 style="width: 320px"
31 /> 41 />
32 </el-form-item> 42 </el-form-item>
33 <el-form-item :label="language == 0 ? '观看人' : 'Viewer'"> 43 <el-form-item :label="language == 0 ? '观看人' : 'Viewer'">
34 <div class="p_box"> 44 <div class="p_box">
35 <div class="people"> 45 <div class="people">
36 <el-checkbox-group 46 <el-checkbox-group v-model="orderForm.customerList" @change="changeGroup">
37 v-model="form.viewers"
38 :max="order.length"
39 >
40 <div 47 <div
41 v-for="(it, index) in cousList" 48 v-for="(it, index) in personnelList" :key="index" class="prople_item">
42 :key="index"
43 class="prople_item"
44 >
45 <div> 49 <div>
46 <div class="name">{{ it.name }}</div> 50 <div class="name">{{ it.name }}</div>
47 <div class="idcard">{{ it.idCard }}</div> 51 <div class="idcard">{{ it.idCard }}</div>
48 </div> 52 </div>
49 <el-checkbox :value="it.id" /> 53 <el-checkbox :value="it.id"/>
50 </div> 54 </div>
51 </el-checkbox-group> 55 </el-checkbox-group>
52 </div> 56 </div>
53 <!-- button --> 57 <div class="btn" @click="$router.push({ path: '/booking/ticket/peopleManage' })">
54 <div
55 class="btn"
56 @click="$router.push({ path: '/booking/ticket/peopleManage' })"
57 >
58 {{ languageFormat(language, "新增", "Add") }} 58 {{ languageFormat(language, "新增", "Add") }}
59 </div> 59 </div>
60 </div> 60 </div>
...@@ -96,11 +96,12 @@ ...@@ -96,11 +96,12 @@
96 <span v-if="it.venueId == 1" 96 <span v-if="it.venueId == 1"
97 >{{ it.area }}{{ languageFormat(language, "区", "Zones") }} 97 >{{ it.area }}{{ languageFormat(language, "区", "Zones") }}
98 </span> 98 </span>
99 {{ it.pai }}{{ languageFormat(language, "排", "Row") }} {{ 99 {{ it.pai }}
100 it.no 100 {{ languageFormat(language, "排", "Row") }}
101 }}{{ languageFormat(language, "座", "Seat") }} ({{ 101 {{ it.no }}
102 it.venueId == 1 ? "B6" : "B4" 102 {{ languageFormat(language, "座", "Seat") }}
103 }}{{ languageFormat(language, "馆", "Venue") }}) 103 ({{ it.venueId == 1 ? "B6" : "B4" }}
104 {{ languageFormat(language, "馆", "Venue") }})
104 </div> 105 </div>
105 </div> 106 </div>
106 <div class="detail_b"> 107 <div class="detail_b">
...@@ -109,7 +110,9 @@ ...@@ -109,7 +110,9 @@
109 </div> 110 </div>
110 <div class="price_num"> 111 <div class="price_num">
111 <span>{{ language == 0 ? "¥" : "€" }}</span> 112 <span>{{ language == 0 ? "¥" : "€" }}</span>
112 {{ order?.paymentAmount }} 113 {{
114 language == 0 ? price.total_cn : price.total_en
115 }}
113 </div> 116 </div>
114 </div> 117 </div>
115 </div> 118 </div>
...@@ -138,7 +141,7 @@ ...@@ -138,7 +141,7 @@
138 @closed="payment.handleCloce()" 141 @closed="payment.handleCloce()"
139 > 142 >
140 <div> 143 <div>
141 <img alt :src="payment.qrCodeData" class="qrcode"/> 144 <img :src="payment.qrCodeData" alt class="qrcode"/>
142 </div> 145 </div>
143 </el-dialog> 146 </el-dialog>
144 </div> 147 </div>
...@@ -148,12 +151,8 @@ ...@@ -148,12 +151,8 @@
148 151
149 <script setup> 152 <script setup>
150 import {ref} from 'vue' 153 import {ref} from 'vue'
151 import {customerListApi} from'@/apiPc/booking' 154 import {customerListApi, getTicketTotalApi, TicketOrderBoApi, listApi} from '@/apiPc/booking'
152 import {confirmOrder} from "@/viewsPc/seat/api/index.js";
153 import {ElMessage} from "element-plus"; 155 import {ElMessage} from "element-plus";
154 import {payOrder, viewPeopleList, checkPaySuccess} from "@/viewsPc/seat/api/index.js";
155 // import qrCodeDialog from "./components/qrCodeDialog.vue";
156 import qrcode from "qrcode";
157 import {languageFormat} from "@/viewsPc/seat/utils/language.js"; 156 import {languageFormat} from "@/viewsPc/seat/utils/language.js";
158 import {useStorage} from "@vueuse/core/index"; 157 import {useStorage} from "@vueuse/core/index";
159 158
...@@ -162,43 +161,30 @@ const loading = ref(false); ...@@ -162,43 +161,30 @@ const loading = ref(false);
162 const route = useRoute(); 161 const route = useRoute();
163 const router = useRouter(); 162 const router = useRouter();
164 const order = ref({ 163 const order = ref({
165 data:{} 164 data: {}
166 }) 165 })
167 const audience = ref({})
168 const payment = ref({}) 166 const payment = ref({})
169 const props = defineProps({ 167 const props = defineProps({
170 activityId: [String, Number], 168 activityId: [String, Number],
171 }); 169 });
172 const form = ref({}) 170 const form = ref({})
173 const cousList = ref([]) 171 const personnelList = ref([])
174 172 const orderForm = ref({
173 activeId: route.params.activeId,
174 atId: route.params.latId,
175 attId: route.params.attId,
176 orderId: null,
177 contacts: null,
178 phone: null,
179 remarks: null,
180 customerList: [],
181 num: 0,
182 total: null
183 })
184 const price = ref({})
185 const tickType = ref({})
175 let timer = null; 186 let timer = null;
176 187
177 const startCheckSuccessListener = (orderSn, actId) => {
178 timer = setInterval(() => {
179 checkPaySuccess({orderSn}).then((res) => {
180 if (res.data) {
181 clearInterval(timer);
182 timer = null;
183 // 支付成功
184 payment.showCodeDialog = false;
185 ElMessage({
186 type: "success",
187 message: languageFormat(
188 language.value,
189 "支付成功",
190 "Payment succeeded"
191 ),
192 });
193 router.replace({
194 path: "/seat/order",
195 });
196 } else {
197 return false;
198 }
199 });
200 }, 3000);
201 };
202 188
203 // const payment = reactive({ 189 // const payment = reactive({
204 // showCodeDialog: false, 190 // showCodeDialog: false,
...@@ -299,15 +285,45 @@ const startCheckSuccessListener = (orderSn, actId) => { ...@@ -299,15 +285,45 @@ const startCheckSuccessListener = (orderSn, actId) => {
299 // }, 285 // },
300 // }); 286 // });
301 287
302
303 // audience.fetchData(); 288 // audience.fetchData();
304 // order.fetchData(); 289 // order.fetchData();
305 290
306 291
307 customerList() 292 customerList()
308 async function customerList(){ 293
309 const res =await customerListApi() 294 function changeGroup() {
310 cousList.value=res.rows 295 orderForm.value.num = orderForm.value.customerList.length
296 getTicketTotal()
297 }
298
299 // 获取人员列表
300 async function customerList() {
301 const res = await customerListApi()
302 personnelList.value = res.rows
303 console.log(res)
304 }
305
306
307 // 获取价格
308 async function getTicketTotal() {
309 const res = await getTicketTotalApi(orderForm.value)
310 price.value = res.data
311 }
312
313 getTicketTotal()
314
315 // 获取票档信息
316 async function getTicketListType() {
317 const res = await listApi({latId: orderForm.value.latId})
318 tickType.value = res.rows.find(item => item.id == orderForm.value.attId)
319 }
320
321 getTicketListType()
322
323
324 // 下单
325 async function confirmOrder() {
326 const res = await TicketOrderBoApi(orderForm.value)
311 } 327 }
312 </script> 328 </script>
313 329
......
...@@ -95,14 +95,14 @@ import {ref, reactive, onMounted, watch} from "vue"; ...@@ -95,14 +95,14 @@ import {ref, reactive, onMounted, watch} from "vue";
95 import {listApi, getTicketInfoByActivityId, getTicketListApi} from '@/apiPc/booking' 95 import {listApi, getTicketInfoByActivityId, getTicketListApi} from '@/apiPc/booking'
96 96
97 import {dayjs} from "element-plus"; 97 import {dayjs} from "element-plus";
98 import useUserStore from "@/store/modules/user";
99 import {ElMessageBox, ElMessage} from "element-plus"; 98 import {ElMessageBox, ElMessage} from "element-plus";
100 import {languageFormat, getDayName} from "@/viewsPc/seat/utils/language"; 99 import {languageFormat, getDayName} from "@/viewsPc/seat/utils/language";
101 import {fillImgUrl} from "/@/utils/ruoyi"; 100 import {fillImgUrl} from "/@/utils/ruoyi";
101 import {useStorage} from "@vueuse/core/index";
102 102
103 const language = useStorage("language", 0);
103 const route = useRoute(); 104 const route = useRoute();
104 const router = useRouter(); 105 const router = useRouter();
105 const userStore = useUserStore();
106 const activeId = ref(route.params.activeId) 106 const activeId = ref(route.params.activeId)
107 const props = defineProps({ 107 const props = defineProps({
108 activityId: [String, Number], 108 activityId: [String, Number],
...@@ -150,14 +150,14 @@ function selectTick(v) { ...@@ -150,14 +150,14 @@ function selectTick(v) {
150 } 150 }
151 151
152 function toSelectSeat() { 152 function toSelectSeat() {
153 if (!selectForm.value.latId) return ElMessage.error("请选择票档") 153 if (!selectForm.value.latId) return ElMessage.error(language.value == 0 ? "请选择票档" : 'Please select a ticket file')
154 if (!selectForm.value.id) return ElMessage.error("请选择时间") 154 if (!selectForm.value.id) return ElMessage.error(language.value == 0 ? "请选择时间" : 'Please select time')
155 router.push({ 155 router.push({
156 name:'confirmOrder', 156 name: 'confirmOrder',
157 params: { 157 params: {
158 activeId: activeId.value, 158 activeId: activeId.value,
159 latId: selectForm.value.latId, 159 latId: selectForm.value.latId,
160 id: selectForm.value.id 160 attId: selectForm.value.id
161 } 161 }
162 }) 162 })
163 } 163 }
......
1 <template> 1 <template>
2 <el-card class="container"> 2 <el-card class="container">
3 <div class="title"> 3 <div class="title">
4 <div 4 <div class="add_btn" @click="addPeople">
5 class="add_btn"
6 @click="addPeople"
7 >
8 {{ languageFormat(language, "新增", "Add") }} 5 {{ languageFormat(language, "新增", "Add") }}
9 </div> 6 </div>
10 {{ languageFormat(language, "观影人管理", "Viewers") }} 7 {{ languageFormat(language, "观影人管理", "Viewers") }}
11 </div> 8 </div>
12 <div class="content"> 9 <div class="content">
13 <div class="people_box"> 10 <div class="people_box">
14 <div 11 <div v-for="(it, index) in personnelList" :key="index" class="people_item"
15 v-for="(it, index) in cousList"
16 :key="index"
17 class="people_item"
18 > 12 >
19 <div class="name">{{ it.name }}</div> 13 <div class="name">{{ it.name }}</div>
20 <div class="idcard"> 14 <div class="idcard">
21 {{ languageFormat(language, "证件号", "Identity Card") }}{{ 15 {{ languageFormat(language, "证件号", "ID number") }}{{ it.idCard }}
22 it.idCard
23 }}
24 </div> 16 </div>
25 <div class="btn" @click="deletePeople(it.id)"> 17 <div class="btn" @click="deletePeople(it.id)">
26 {{ languageFormat(language, "删除", "delete") }} 18 {{ languageFormat(language, "删除", "delete") }}
...@@ -31,16 +23,23 @@ ...@@ -31,16 +23,23 @@
31 23
32 <el-dialog 24 <el-dialog
33 v-model="show" 25 v-model="show"
26 :title="language==0?'新增观影人':'New moviegoers'"
34 center 27 center
35 title="新增观影人"
36 width="700" 28 width="700"
37 > 29 >
38 <el-form ref="formRef" :model="form" :rules="rules" label-width="80px" size="large" style="margin: 80px"> 30 <el-form ref="formRef" :model="form" :rules="rules" label-width="80px" size="large" style="margin: 80px">
39 <el-form-item label="姓名" required prop="name"> 31 <el-form-item :label="language==0?'姓名':'name'" prop="name" required>
40 <el-input v-model="form.name" size=""></el-input> 32 <el-input v-model="form.name" :placeholder="language==0?'请输入':'Please input'"/>
33 </el-form-item>
34 <el-form-item :label="language==0?'证件类型':'ID Type'" prop="idcType" required>
35 <el-select v-model="form.idcType" :placeholder="language==0?'请选择':'Please choose'">
36 <el-option :label="language==0?'身份证':'Identity card'" value="0"/>
37 <el-option :label="language==0?'护照':'Passport'" value="1"/>
38 <el-option :label="language==0?'其他':'Else'" value="2"/>
39 </el-select>
41 </el-form-item> 40 </el-form-item>
42 <el-form-item label="证件号" required prop="idCard"> 41 <el-form-item :label="language==0?'证件号':'ID number'" prop="idCard" required>
43 <el-input v-model="form.idCard"></el-input> 42 <el-input v-model="form.idCard" :placeholder="language==0?'请输入证件号':'Please enter the ID after ah'"/>
44 </el-form-item> 43 </el-form-item>
45 </el-form> 44 </el-form>
46 45
...@@ -48,8 +47,8 @@ ...@@ -48,8 +47,8 @@
48 <br> 47 <br>
49 <span slot="footer" class="dialog-footer"> 48 <span slot="footer" class="dialog-footer">
50 <div style="text-align: center"> 49 <div style="text-align: center">
51 <el-button class="can_pay" @click="show = false">取 消</el-button> 50 <el-button class="can_pay" @click="show = false">{{ language == 0 ? '取 消' : 'cancel' }}</el-button>
52 <el-button class="pay" type="primary" @click="submit">确 定</el-button> 51 <el-button class="pay" type="primary" @click="submit">{{ language == 0 ? '确 定' : 'confirm' }}</el-button>
53 </div> 52 </div>
54 </span> 53 </span>
55 <br> 54 <br>
...@@ -62,58 +61,15 @@ ...@@ -62,58 +61,15 @@
62 61
63 62
64 <script setup> 63 <script setup>
65 import {reactive, ref} from "vue"; 64 import {ref} from "vue";
66 import {customerListApi,aadCustomer,delCustomer} from '@/apiPc/booking' 65 import {aadCustomer, customerListApi, delCustomer} from '@/apiPc/booking'
67 66 import {ElMessage, ElMessageBox} from "element-plus";
68 import {deleteViewPeople, viewPeopleList} from "@/viewsPc/seat/api/index.js";
69 import {ElMessageBox, ElMessage} from "element-plus";
70 import {languageFormat} from "@/viewsPc/seat/utils/language.js"; 67 import {languageFormat} from "@/viewsPc/seat/utils/language.js";
71 import {useStorage} from "@vueuse/core/index"; 68 import {useStorage} from "@vueuse/core/index";
72 69
73 const language = useStorage("language", 0); 70 const language = useStorage("language", 0);
74 71
75 // const audience = reactive({ 72 const personnelList = ref([])
76 // data: [],
77 // fetchData() {
78 // viewPeopleList().then((res) => {
79 // audience.data = res.data;
80 // });
81 // },
82 //
83 // deletePeople(id) {
84 // ElMessageBox.confirm(
85 // languageFormat(
86 // language.value,
87 // "确认删除该观看人吗?",
88 // "Are you sure to delete this viewer?"
89 // ),
90 // languageFormat(language.value, "提示", "Reminder"),
91 // {
92 // confirmButtonText: languageFormat(language.value, "确认", "confirm"),
93 // cancelButtonText: languageFormat(language.value, "取消", "cancel"),
94 // type: "warning",
95 // draggable: true,
96 // }
97 // )
98 // .then(() => {
99 // deleteViewPeople({id}).then(() => {
100 // audience.fetchData();
101 // ElMessage({
102 // type: "success",
103 // message: languageFormat(
104 // language.value,
105 // "操作成功",
106 // "Operate successfully"
107 // ),
108 // });
109 // });
110 // })
111 // .catch(() => {
112 // });
113 // },
114 // });
115
116 const cousList = ref([])
117 const show = ref(false) 73 const show = ref(false)
118 const form = ref({}) 74 const form = ref({})
119 const formRef = ref(null) 75 const formRef = ref(null)
...@@ -124,13 +80,16 @@ const rules = ref({ ...@@ -124,13 +80,16 @@ const rules = ref({
124 idCard: [ 80 idCard: [
125 {required: true, message: "请输入证件号", trigger: "blur"}, 81 {required: true, message: "请输入证件号", trigger: "blur"},
126 ], 82 ],
83 idcType: [
84 {required: true, message: "请选择证件类型", trigger: "blur"},
85 ],
127 }) 86 })
128 87
129 customerList() 88 customerList()
89
130 async function customerList() { 90 async function customerList() {
131 const res = await customerListApi() 91 const res = await customerListApi()
132 cousList.value = res.rows 92 personnelList.value = res.rows
133 // cousList.value = [{},{}]
134 } 93 }
135 94
136 function addPeople() { 95 function addPeople() {
...@@ -141,20 +100,35 @@ function addPeople() { ...@@ -141,20 +100,35 @@ function addPeople() {
141 function submit() { 100 function submit() {
142 formRef.value.validate((valid) => { 101 formRef.value.validate((valid) => {
143 if (valid) { 102 if (valid) {
144 console.log(form.value); 103 aadCustomer(form.value).then(res => {
145 aadCustomer(form.value).then(res=>{ 104 if (res.data == -100) {
105 return ElMessageBox.confirm(language.value == 0 ? '该观影人已存在' : "The viewer already exists", language.value == 0 ? '提示' : 'Reminder', {
106 confirmButtonText: language.value == 0 ? '确认' : 'confirm',
107 cancelButtonText: language.value == 0 ? '取消' : 'cancel',
108 type: "warning",
109 draggable: true,
110 })
111 } else if (res.data == -101) {
112 return ElMessageBox.confirm(language.value == 0 ? '该观影人实名认证未通过' : 'The real name authentication of the moviegoer failed', language.value == 0 ? '提示' : 'Reminder', {
113 confirmButtonText: language.value == 0 ? '确认' : "confirm",
114 cancelButtonText: language.value == 0 ? '取消' : 'cancel',
115 type: "warning",
116 draggable: true,
117 })
118 } else {
146 show.value = false 119 show.value = false
147 customerList() 120 customerList()
148 ElMessage.success('添加成功') 121 ElMessage.success(language.value == 0 ? '添加成功' : 'successfully added')
122 }
149 }) 123 })
150 } else { 124 } else {
151 return ElMessage.waiting('请完善信息') 125 return ElMessage.waiting(language.value == 0 ? '请完善信息' : 'Please complete the information')
152 } 126 }
153 }) 127 })
154 } 128 }
155 129
156 async function deletePeople(v){ 130 async function deletePeople(v) {
157 await ElMessageBox .confirm( 131 await ElMessageBox.confirm(
158 languageFormat(language.value, "确认删除该观影人吗?", "Are you sure to delete this viewer?"), 132 languageFormat(language.value, "确认删除该观影人吗?", "Are you sure to delete this viewer?"),
159 languageFormat(language.value, "提示", "Reminder"), 133 languageFormat(language.value, "提示", "Reminder"),
160 { 134 {
...@@ -164,9 +138,9 @@ async function deletePeople(v){ ...@@ -164,9 +138,9 @@ async function deletePeople(v){
164 draggable: true, 138 draggable: true,
165 } 139 }
166 ) 140 )
167 .then(async () =>{ 141 .then(async () => {
168 const res =await delCustomer(v) 142 const res = await delCustomer(v)
169 if(res.code===200){ 143 if (res.code === 200) {
170 ElMessage.success('删除成功') 144 ElMessage.success('删除成功')
171 await customerList() 145 await customerList()
172 } 146 }
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!