f0d79bc2 by zhangmeng

购票修改

1 parent 4bbbfe9b
...@@ -239,15 +239,21 @@ async function getTicketList() { ...@@ -239,15 +239,21 @@ async function getTicketList() {
239 239
240 // 根据票档获取场次 240 // 根据票档获取场次
241 async function getTicketListType() { 241 async function getTicketListType() {
242 let arr = []
242 const res = await listApi({latId: selectForm.value.latId}) 243 const res = await listApi({latId: selectForm.value.latId})
243 tickList.value = res.rows 244 tickList.value = res.rows
244 flag.value = tickList.value.some((item) => { 245 for (const v of res.rows) {
245 return item.isView == 0 246 if (v.isView == 0) arr.push(v)
246 }) 247 }
247 tickList.value.forEach(v => { 248 for (const v of res.rows) {
248 if (flag.value && v.ticketType == 1) v.isView = 0 249 if (arr.length > 0 && v.ticketType == 1) {
249 }) 250 for (const c of arr) {
250 251 if ((c.ticketStart >= v.ticketStart) && (c.ticketStart <= v.ticketEnd)) {
252 v.isView = 0
253 }
254 }
255 }
256 }
251 } 257 }
252 258
253 function select(v) { 259 function select(v) {
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!