6bbdee8b by 杨炀

no message

1 parent f0f90c51
...@@ -628,6 +628,13 @@ export function createWePay(data) { ...@@ -628,6 +628,13 @@ export function createWePay(data) {
628 data:data 628 data:data
629 }) 629 })
630 } 630 }
631 export function createWePayPhone(data) {
632 return request({
633 url: `/league/signOrder/wxH5Pay`,
634 method: 'post',
635 data:data
636 })
637 }
631 export function createPalPay(data) { 638 export function createPalPay(data) {
632 return request({ 639 return request({
633 url: `/league/signOrder/palPay`, 640 url: `/league/signOrder/palPay`,
......
...@@ -602,9 +602,10 @@ function removeCurproject() { ...@@ -602,9 +602,10 @@ function removeCurproject() {
602 projectIds.value = _.without(projectIds.value, currProjectId.value) 602 projectIds.value = _.without(projectIds.value, currProjectId.value)
603 } 603 }
604 function checkTwo(a,b) { 604 function checkTwo(a,b) {
605 match.checkMate({per1Id:a,per2Id:b,cptId:matchId.value}).then(res=>{ 605 match.checkMate({per1Id:a.id,per2Id:b.id,cptId:matchId.value}).then(res=>{
606 if(!res.data){ 606 if(!res.data){
607 ElMessage.warning(language.value == 0 ? '他们不是固定组合':'They\'re not a couple') 607 // ElMessage.warning(language.value == 0 ? '他们不是固定组合':'They\'re not a couple')
608 ElMessage.warning(language.value == 0 ? `${a.realName} 已经和其他人组成舞伴,无法报名:请重新选择`:`${a.realName} has already formed a dancer with another person, cannot sign up: please select again`)
608 } 609 }
609 }) 610 })
610 } 611 }
...@@ -614,7 +615,7 @@ watch(choosedchoosed, (newVal, oldVal) => { ...@@ -614,7 +615,7 @@ watch(choosedchoosed, (newVal, oldVal) => {
614 //如果一男一女,判断是否舞伴 615 //如果一男一女,判断是否舞伴
615 if(choosed2List.value.length==2){ 616 if(choosed2List.value.length==2){
616 if(choosed2List.value[0].sex!=choosed2List.value[1].sex){ 617 if(choosed2List.value[0].sex!=choosed2List.value[1].sex){
617 checkTwo(newVal[0],newVal[1]) 618 checkTwo(choosed2List.value[0],choosed2List.value[1])
618 } 619 }
619 } 620 }
620 } 621 }
......
...@@ -214,7 +214,7 @@ function handleSelectionChange(val) { ...@@ -214,7 +214,7 @@ function handleSelectionChange(val) {
214 //判断是否队友 214 //判断是否队友
215 if(val.length==2){ 215 if(val.length==2){
216 if(val[0].sex!=val[1].sex){ 216 if(val[0].sex!=val[1].sex){
217 checkTwo(val[0].id,val[1].id) 217 checkTwo(val[0],val[1])
218 } 218 }
219 } 219 }
220 if(val.length>0){ 220 if(val.length>0){
...@@ -232,9 +232,9 @@ function handleSelectionChange(val) { ...@@ -232,9 +232,9 @@ function handleSelectionChange(val) {
232 } 232 }
233 } 233 }
234 function checkTwo(a,b) { 234 function checkTwo(a,b) {
235 match.checkMate({per1Id:a,per2Id:b,cptId:matchId}).then(res=>{ 235 match.checkMate({per1Id:a.id,per2Id:b.id,cptId:matchId}).then(res=>{
236 if(!res.data){ 236 if(!res.data){
237 ElMessage.warning(language.value == 0 ? '他们不是固定组合':'They\'re not a couple') 237 ElMessage.warning(language.value == 0 ? `${a.realName} 已经和其他人组成舞伴,无法报名:请重新选择`:`${a.realName} has already formed a dancer with another person, cannot sign up: please select again`)
238 proxy.$refs['allSportmenTable'].clearSelection() 238 proxy.$refs['allSportmenTable'].clearSelection()
239 } 239 }
240 }) 240 })
......
...@@ -383,8 +383,9 @@ onMounted(() => { ...@@ -383,8 +383,9 @@ onMounted(() => {
383 language.value = 1 383 language.value = 1
384 } 384 }
385 } 385 }
386 console.log(navigator.userAgent)
387 var is_mobile = navigator.userAgent.toLowerCase().match(/(ipod|ipad|iphone|android|coolpad|mmp|smartphone|midp|wap|xoom|symbian|j2me|blackberry|wince)/i) != null; 386 var is_mobile = navigator.userAgent.toLowerCase().match(/(ipod|ipad|iphone|android|coolpad|mmp|smartphone|midp|wap|xoom|symbian|j2me|blackberry|wince)/i) != null;
387 console.log(is_mobile)
388
388 if (is_mobile) { 389 if (is_mobile) {
389 isphone.value = true 390 isphone.value = true
390 } else { 391 } else {
...@@ -462,13 +463,18 @@ function changePaytype() { ...@@ -462,13 +463,18 @@ function changePaytype() {
462 function goPay(){ 463 function goPay(){
463 if(payType.value=='2' && form.value.payTypeArr.indexOf('2')>-1){ 464 if(payType.value=='2' && form.value.payTypeArr.indexOf('2')>-1){
464 if(isphone.value){ 465 if(isphone.value){
465 //移动支付 466 //拉起移动支付
466 } 467 match.createWePayPhone({orderId:orderId.value}).then(res=>{
467 match.createWePay({orderId:orderId.value}).then(res=>{ 468 hideconfirmbtn.value = true
469 window.location.href = res.data
470 })
471 } else {
472 match.createWePay({orderId:orderId.value}).then(res=>{
468 wePayCodeUrl.value = res.data 473 wePayCodeUrl.value = res.data
469 hideconfirmbtn.value = true 474 hideconfirmbtn.value = true
470 startforGetData() 475 startforGetData()
471 }) 476 })
477 }
472 } else if(payType.value=='2' && form.value.payTypeArr.indexOf('2')==-1){ 478 } else if(payType.value=='2' && form.value.payTypeArr.indexOf('2')==-1){
473 ElMessage.warning(language.value == 0 ? '请选择支付方式' : 'Please select payment method') 479 ElMessage.warning(language.value == 0 ? '请选择支付方式' : 'Please select payment method')
474 return 480 return
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!