no message
Showing
19 changed files
with
1550 additions
and
172 deletions
| ... | @@ -563,6 +563,13 @@ export function checkNoRepeat(query) { | ... | @@ -563,6 +563,13 @@ export function checkNoRepeat(query) { |
| 563 | }) | 563 | }) |
| 564 | } | 564 | } |
| 565 | 565 | ||
| 566 | export function saveWdsfMin(obj,groupId) { | ||
| 567 | return request({ | ||
| 568 | url: `systemj/personInfo/bindWdsfForGroup/${groupId}`, | ||
| 569 | method: 'post', | ||
| 570 | data:obj | ||
| 571 | }) | ||
| 572 | } | ||
| 566 | //todo | 573 | //todo |
| 567 | export function bindWdsf(perId,card) { | 574 | export function bindWdsf(perId,card) { |
| 568 | return request({ | 575 | return request({ | ... | ... |
| ... | @@ -4,22 +4,22 @@ | ... | @@ -4,22 +4,22 @@ |
| 4 | <img class="logo" src="/img/logoArr.png"> | 4 | <img class="logo" src="/img/logoArr.png"> |
| 5 | </router-link> | 5 | </router-link> |
| 6 | 6 | ||
| 7 | <div class="flex-right" style="display:none;"> | 7 | <div class="flex-right"> |
| 8 | <div class="ml20 forPc" > | 8 | <div class="ml20" > |
| 9 | <el-button v-if="!isLogin" style="border-radius: 20px;" class="loginBtn"> | 9 | <el-button v-if="!isLogin" style="border-radius: 20px;" class="loginBtn"> |
| 10 | <span @click="goLogin">{{ language==0?'登录':'LOGIN' }}</span> | 10 | <span @click="goLogin">{{ language==0?'登录':'LOGIN' }}</span> |
| 11 | <!-- | <span @click="goRegister">注册</span>--> | ||
| 12 | </el-button> | 11 | </el-button> |
| 13 | 12 | ||
| 14 | <el-button v-if="isLogin" style="border-radius: 20px;" class="loginBtn"> | 13 | <el-button v-if="isLogin" style="border-radius: 20px;" class="loginBtn"> |
| 15 | <span @click="router.push('/center/myInfo')">{{ language==0?'个人中心':'Personal' }}</span> | 14 | <span @click="router.push('/center/myInfo')">{{ language==0?'个人中心':'Personal' }}</span> |
| 16 | | <span @click="logout()">{{language==0?'退出':'Exit'}}</span> | 15 | | |
| 16 | <span @click="logout()">{{language==0?'退出':'Exit'}}</span> | ||
| 17 | </el-button> | 17 | </el-button> |
| 18 | </div> | 18 | </div> |
| 19 | </div> | 19 | </div> |
| 20 | <a class="ropenbtn" @click="showDrawer"> | 20 | <!-- <a class="ropenbtn" @click="showDrawer">--> |
| 21 | <img src="@/assets/v1/menu.png"> | 21 | <!-- <img src="@/assets/v1/menu.png">--> |
| 22 | </a> | 22 | <!-- </a>--> |
| 23 | </div> | 23 | </div> |
| 24 | 24 | ||
| 25 | <el-drawer | 25 | <el-drawer |
| ... | @@ -277,9 +277,6 @@ function getCode() { | ... | @@ -277,9 +277,6 @@ function getCode() { |
| 277 | } | 277 | } |
| 278 | } | 278 | } |
| 279 | @media (max-width: 1340px) { | 279 | @media (max-width: 1340px) { |
| 280 | .loginBtn { | ||
| 281 | display: none; | ||
| 282 | } | ||
| 283 | .home-menu .el-menu--horizontal > .el-menu-item{margin: 0; } | 280 | .home-menu .el-menu--horizontal > .el-menu-item{margin: 0; } |
| 284 | } | 281 | } |
| 285 | @media (max-width: 1000px) { | 282 | @media (max-width: 1000px) { | ... | ... |
| ... | @@ -2,11 +2,15 @@ | ... | @@ -2,11 +2,15 @@ |
| 2 | <div class=""> | 2 | <div class=""> |
| 3 | 3 | ||
| 4 | <div class="box ph-30"> | 4 | <div class="box ph-30"> |
| 5 | <el-card> | 5 | <el-card v-if="user"> |
| 6 | <single-sign-step v-if="user.utype=='1'" activeStep="1" :language="language"/> | 6 | <single-sign-step v-if="user.utype=='1'" activeStep="1" :language="language"/> |
| 7 | <team-sign-step v-if="user.utype=='2'" activeStep="2" :language="language"/> | 7 | <team-sign-step v-if="user.utype=='2'" activeStep="2" :language="language"/> |
| 8 | </el-card> | 8 | </el-card> |
| 9 | 9 | ||
| 10 | <el-card class="mt20"> | ||
| 11 | <h3 class="text-center text-danger">如果没有随行人员,点击【下一步】跳过此步骤</h3> | ||
| 12 | </el-card> | ||
| 13 | |||
| 10 | <el-row class="mt20" :gutter="20"> | 14 | <el-row class="mt20" :gutter="20"> |
| 11 | <el-col :lg="12"> | 15 | <el-col :lg="12"> |
| 12 | <el-card v-loading="loading"> | 16 | <el-card v-loading="loading"> |
| ... | @@ -14,8 +18,8 @@ | ... | @@ -14,8 +18,8 @@ |
| 14 | <div class="card-header"> | 18 | <div class="card-header"> |
| 15 | <img src="@/assets/sign/tag01.png"/> | 19 | <img src="@/assets/sign/tag01.png"/> |
| 16 | {{ language==0?'教练':'Coach' }} | 20 | {{ language==0?'教练':'Coach' }} |
| 17 | <span class="tip" v-if="language==0">(教练/领队,至少选择一项)</span> | 21 | <!-- <span class="tip" v-if="language==0">(教练/领队,至少选择一项)</span>--> |
| 18 | <span class="tip" v-else>(Coach/Team Leader, select at least one)</span> | 22 | <!-- <span class="tip" v-else>(Coach/Team Leader, select at least one)</span>--> |
| 19 | </div> | 23 | </div> |
| 20 | </template> | 24 | </template> |
| 21 | <div class="chooseForm"> | 25 | <div class="chooseForm"> |
| ... | @@ -42,8 +46,8 @@ | ... | @@ -42,8 +46,8 @@ |
| 42 | <div class="card-header"> | 46 | <div class="card-header"> |
| 43 | <img src="@/assets/sign/tag02.png"/> | 47 | <img src="@/assets/sign/tag02.png"/> |
| 44 | {{ language==0?'领队':'Team leader' }} | 48 | {{ language==0?'领队':'Team leader' }} |
| 45 | <span class="tip" v-if="language==0">(教练/领队,至少选择一项)</span> | 49 | <!-- <span class="tip" v-if="language==0">(教练/领队,至少选择一项)</span>--> |
| 46 | <span class="tip" v-else>(Coach/Team Leader, select at least one)</span> | 50 | <!-- <span class="tip" v-else>(Coach/Team Leader, select at least one)</span>--> |
| 47 | </div> | 51 | </div> |
| 48 | </template> | 52 | </template> |
| 49 | <div class="chooseForm"> | 53 | <div class="chooseForm"> |
| ... | @@ -175,6 +179,7 @@ | ... | @@ -175,6 +179,7 @@ |
| 175 | </div> | 179 | </div> |
| 176 | 180 | ||
| 177 | <dialogAddCoach ref="dialogAddCoachRef" @submitForm="getList"/> | 181 | <dialogAddCoach ref="dialogAddCoachRef" @submitForm="getList"/> |
| 182 | <dialogAddCoach_En ref="dialogAddCoachRef_En" @submitForm="getList"/> | ||
| 178 | 183 | ||
| 179 | </div> | 184 | </div> |
| 180 | </template> | 185 | </template> |
| ... | @@ -185,8 +190,8 @@ import SingleSignStep from './components/singleSignStep' | ... | @@ -185,8 +190,8 @@ import SingleSignStep from './components/singleSignStep' |
| 185 | import {ref, reactive,toRefs} from 'vue' | 190 | import {ref, reactive,toRefs} from 'vue' |
| 186 | import {getCurrentInstance, onMounted} from '@vue/runtime-core' | 191 | import {getCurrentInstance, onMounted} from '@vue/runtime-core' |
| 187 | import * as match from '@/apiPc/match' | 192 | import * as match from '@/apiPc/match' |
| 188 | import dialogAddCoach from './components/addCoach' | 193 | import DialogAddCoach from './components/addCoach' |
| 189 | import cache from "@/plugins/cache" | 194 | import DialogAddCoach_En from './components/addCoach_en' |
| 190 | const {proxy} = getCurrentInstance() | 195 | const {proxy} = getCurrentInstance() |
| 191 | const router = useRouter() | 196 | const router = useRouter() |
| 192 | const route = useRoute() | 197 | const route = useRoute() |
| ... | @@ -222,6 +227,10 @@ onMounted(() => { | ... | @@ -222,6 +227,10 @@ onMounted(() => { |
| 222 | matchId = route.query.matchId | 227 | matchId = route.query.matchId |
| 223 | groupId.value = group.id | 228 | groupId.value = group.id |
| 224 | signType.value = route.query.signType || '' | 229 | signType.value = route.query.signType || '' |
| 230 | if(!user){ | ||
| 231 | router.push({name: 'home'}) | ||
| 232 | return | ||
| 233 | } | ||
| 225 | getList() | 234 | getList() |
| 226 | }) | 235 | }) |
| 227 | 236 | ||
| ... | @@ -299,10 +308,10 @@ function chooseDone() { | ... | @@ -299,10 +308,10 @@ function chooseDone() { |
| 299 | 308 | ||
| 300 | function goNext() { | 309 | function goNext() { |
| 301 | console.log(form.value) | 310 | console.log(form.value) |
| 302 | if ((form.value.coachs.length < 1) && (form.value.leader.length < 1)) { | 311 | // if ((form.value.coachs.length < 1) && (form.value.leader.length < 1)) { |
| 303 | ElMessage.warning(language.value==0?'至少选一个教练或领队':'Coach/Team Leader, select at least one') | 312 | // ElMessage.warning(language.value==0?'至少选一个教练或领队':'Coach/Team Leader, select at least one') |
| 304 | return | 313 | // return |
| 305 | } | 314 | // } |
| 306 | var obj = { | 315 | var obj = { |
| 307 | cptId: matchId, | 316 | cptId: matchId, |
| 308 | coachIds: form.value.coachs?.toString() || '', | 317 | coachIds: form.value.coachs?.toString() || '', |
| ... | @@ -358,20 +367,30 @@ function goPrev() { | ... | @@ -358,20 +367,30 @@ function goPrev() { |
| 358 | } | 367 | } |
| 359 | 368 | ||
| 360 | function editPerson(id) { | 369 | function editPerson(id) { |
| 361 | proxy.$refs['dialogAddCoachRef'].open({ | 370 | var obj = { |
| 362 | title: language.value==0?'编辑人员':'Edit', | 371 | title: language.value==0?'编辑人员':'Edit', |
| 363 | id: id, | 372 | id: id, |
| 364 | groupId: groupId.value || 0 | 373 | groupId: groupId.value || 0 |
| 365 | }) | 374 | } |
| 375 | if(language.value==0){ | ||
| 376 | proxy.$refs['dialogAddCoachRef'].open(obj) | ||
| 377 | }else { | ||
| 378 | proxy.$refs['dialogAddCoachRef_En'].open(obj) | ||
| 379 | } | ||
| 366 | } | 380 | } |
| 367 | 381 | ||
| 368 | function addCoach(n) { | 382 | function addCoach(n) { |
| 369 | proxy.$refs['dialogAddCoachRef'].open({ | 383 | var obj = { |
| 370 | title: language.value==0?'新建人员':'Add', | 384 | title: language.value==0?'新建人员':'Add', |
| 371 | id: 0, | 385 | id: 0, |
| 372 | label: n, | 386 | label: n, |
| 373 | groupId: groupId.value | 387 | groupId: groupId.value |
| 374 | }) | 388 | } |
| 389 | if(language.value==0){ | ||
| 390 | proxy.$refs['dialogAddCoachRef'].open(obj) | ||
| 391 | }else { | ||
| 392 | proxy.$refs['dialogAddCoachRef_En'].open(obj) | ||
| 393 | } | ||
| 375 | } | 394 | } |
| 376 | </script> | 395 | </script> |
| 377 | 396 | ... | ... |
| ... | @@ -7,13 +7,13 @@ | ... | @@ -7,13 +7,13 @@ |
| 7 | 7 | ||
| 8 | <el-card :body-style="{'padding-top': '0'}"> | 8 | <el-card :body-style="{'padding-top': '0'}"> |
| 9 | <el-row class="mt20" :gutter="20"> | 9 | <el-row class="mt20" :gutter="20"> |
| 10 | <el-col :lg="24"> | 10 | <el-col :lg="10"> |
| 11 | <div class="panel border"> | 11 | <div class="panel border"> |
| 12 | <div class="panel-header "> | 12 | <div class="panel-header "> |
| 13 | <h3 class="panel-title" v-if="language==0">选择参赛运动员清单</h3> | 13 | <h3 class="panel-title" v-if="language==0">选择参赛运动员清单</h3> |
| 14 | <h3 class="panel-title" v-else>Select list of participating athletes</h3> | 14 | <h3 class="panel-title" v-else>Select list of participating athletes</h3> |
| 15 | <!-- <a class="fr" @click="emptyChoosed">{{ language == 0 ? '清空' : 'Empty' }}</a>--> | 15 | <!-- <a class="fr" @click="emptyChoosed">{{ language == 0 ? '清空' : 'Empty' }}</a>--> |
| 16 | <el-button type="primary" plain class="fr" @click="chooseSportman">选手管理</el-button> | 16 | <el-button type="primary" plain class="fr" @click="chooseSportman">{{ language == 0 ? '选手管理' : 'Player Management' }}</el-button> |
| 17 | </div> | 17 | </div> |
| 18 | <div class="panel-body" style="padding: 10px"> | 18 | <div class="panel-body" style="padding: 10px"> |
| 19 | <div style="margin: 0 4px 10px;display: flex"> | 19 | <div style="margin: 0 4px 10px;display: flex"> |
| ... | @@ -28,15 +28,14 @@ | ... | @@ -28,15 +28,14 @@ |
| 28 | -{{ c.age }} | 28 | -{{ c.age }} |
| 29 | </div> | 29 | </div> |
| 30 | </el-option> | 30 | </el-option> |
| 31 | <template #tag> | 31 | <!-- <template #tag>--> |
| 32 | <el-tag v-for="v in choosed2List" :key="v.value" type="primary"> | 32 | <!-- <el-tag v-for="v in choosed2List" :key="v.value" type="primary">--> |
| 33 | {{ v.xing + v.ming }} | 33 | <!-- {{ v.xing + v.ming }}--> |
| 34 | </el-tag> | 34 | <!-- </el-tag>--> |
| 35 | </template> | 35 | <!-- </template>--> |
| 36 | </el-select> | 36 | </el-select> |
| 37 | <el-button type="primary" @click="emptychoosedchoosed">{{ | 37 | <el-button type="primary" @click="emptychoosedchoosed"> |
| 38 | language == 0 ? '重选' : 'Re-select' | 38 | {{language == 0 ? '重选' : 'Re-select' }} |
| 39 | }} | ||
| 40 | </el-button> | 39 | </el-button> |
| 41 | </div> | 40 | </div> |
| 42 | <!-- <div class="noPicChooseForm" id="chooseArr">--> | 41 | <!-- <div class="noPicChooseForm" id="chooseArr">--> |
| ... | @@ -53,7 +52,7 @@ | ... | @@ -53,7 +52,7 @@ |
| 53 | </div> | 52 | </div> |
| 54 | </div> | 53 | </div> |
| 55 | </el-col> | 54 | </el-col> |
| 56 | <el-col :lg="24"> | 55 | <el-col :lg="14"> |
| 57 | <div class="panel border"> | 56 | <div class="panel border"> |
| 58 | <div class="panel-header "> | 57 | <div class="panel-header "> |
| 59 | <h3 class="panel-title" v-if="language==0">可参与报名的项目</h3> | 58 | <h3 class="panel-title" v-if="language==0">可参与报名的项目</h3> |
| ... | @@ -132,7 +131,8 @@ | ... | @@ -132,7 +131,8 @@ |
| 132 | </div> | 131 | </div> |
| 133 | 132 | ||
| 134 | <dialogAddCoach ref="dialogAddCoachRef"/> | 133 | <dialogAddCoach ref="dialogAddCoachRef"/> |
| 135 | <dialogAllSportsmanList ref="dialogAllSportsmanListRef" @transfer="getChoosed" @submitForm="getSignInfoList"/> | 134 | <!-- <dialogAllSportsmanList ref="dialogAllSportsmanListRef" @transfer="getChoosed" @submitForm="getSignInfoList"/>--> |
| 135 | <dialogAllSportsmanList ref="dialogAllSportsmanListRef" @submitForm="getAthletesList"/> | ||
| 136 | <dialogImport ref="dialogImportProps" @submitForm="getMySignInfo"/> | 136 | <dialogImport ref="dialogImportProps" @submitForm="getMySignInfo"/> |
| 137 | <el-dialog v-model="showResult" :close-on-click-modal="false" :show-close="false"> | 137 | <el-dialog v-model="showResult" :close-on-click-modal="false" :show-close="false"> |
| 138 | <el-result icon="success" :title="language==0?'报名成功':'Sign up successful'"> | 138 | <el-result icon="success" :title="language==0?'报名成功':'Sign up successful'"> |
| ... | @@ -144,7 +144,7 @@ | ... | @@ -144,7 +144,7 @@ |
| 144 | 144 | ||
| 145 | </el-dialog> | 145 | </el-dialog> |
| 146 | <dialogExtraForm ref="popExtraForm" @submitForm="getSignInfoList"/> | 146 | <dialogExtraForm ref="popExtraForm" @submitForm="getSignInfoList"/> |
| 147 | <dialogWdsf ref="popWdsf" @submitForm="getProjectList" @cancel="removeCurproject"/> | 147 | <dialogWdsf ref="popWdsf" @submitForm="getAthletesList" @cancel="removeCurproject"/> |
| 148 | <el-tour v-model="openTour" :current="tourCurrent"> | 148 | <el-tour v-model="openTour" :current="tourCurrent"> |
| 149 | <el-tour-step target="#addRef" title="第一步" description="点击选择运动员" :next-button-props="nextButtonProps"/> | 149 | <el-tour-step target="#addRef" title="第一步" description="点击选择运动员" :next-button-props="nextButtonProps"/> |
| 150 | <el-tour-step v-if="choosedList.length>0" target="#chooseArr" title="第二步" description="勾选报项运动员"/> | 150 | <el-tour-step v-if="choosedList.length>0" target="#chooseArr" title="第二步" description="勾选报项运动员"/> |
| ... | @@ -434,7 +434,7 @@ function addCoach() { | ... | @@ -434,7 +434,7 @@ function addCoach() { |
| 434 | }) | 434 | }) |
| 435 | } | 435 | } |
| 436 | const params = { | 436 | const params = { |
| 437 | title: language.value == 0 ? '提新增运动员' : 'Add', | 437 | title: language.value == 0 ? '新增运动员' : 'Add', |
| 438 | id: 0, | 438 | id: 0, |
| 439 | groupId: groupId.value | 439 | groupId: groupId.value |
| 440 | } | 440 | } |
| ... | @@ -473,6 +473,7 @@ function removeThis(id) { | ... | @@ -473,6 +473,7 @@ function removeThis(id) { |
| 473 | // 重新获取已报名信息 | 473 | // 重新获取已报名信息 |
| 474 | ElMessage.success(language.value == 0 ? '已移除该报项' : 'success') | 474 | ElMessage.success(language.value == 0 ? '已移除该报项' : 'success') |
| 475 | getSignInfoList() | 475 | getSignInfoList() |
| 476 | getProjectList() | ||
| 476 | }) | 477 | }) |
| 477 | }) | 478 | }) |
| 478 | } | 479 | } |
| ... | @@ -502,15 +503,6 @@ function goMySign() { | ... | @@ -502,15 +503,6 @@ function goMySign() { |
| 502 | } | 503 | } |
| 503 | 504 | ||
| 504 | const goPersonInfo = (row) => { | 505 | const goPersonInfo = (row) => { |
| 505 | if (signInfoType == '1') { | ||
| 506 | ElMessageBox.alert('已报项,前往我的报项', '提示', { | ||
| 507 | confirmButtonText: 'OK', | ||
| 508 | callback: (Action) => { | ||
| 509 | router.push({name: 'myMatch'}) | ||
| 510 | } | ||
| 511 | }) | ||
| 512 | return | ||
| 513 | } | ||
| 514 | // 完善补充信息 | 506 | // 完善补充信息 |
| 515 | console.log(row) | 507 | console.log(row) |
| 516 | // debugger | 508 | // debugger |
| ... | @@ -565,14 +557,14 @@ function changeProject(e) { | ... | @@ -565,14 +557,14 @@ function changeProject(e) { |
| 565 | //循环choosed2List 检查是否存在WDSF号 | 557 | //循环choosed2List 检查是否存在WDSF号 |
| 566 | let n = 0 | 558 | let n = 0 |
| 567 | for(var cc of choosed2List.value){ | 559 | for(var cc of choosed2List.value){ |
| 568 | if(!cc.wdsf){ | 560 | if(!cc.wdsfMin){ |
| 569 | n++ | 561 | n++ |
| 570 | } | 562 | } |
| 571 | } | 563 | } |
| 572 | //obj需要wdsf 且 currProjectId非空 | 564 | //obj需要wdsf 且 currProjectId非空 |
| 573 | if (obj.checkMemberFlag == '1'&&currProjectId.value != ''&& n>0) { | 565 | if (obj.checkMemberFlag == '1'&&currProjectId.value != ''&& n>0) { |
| 574 | const params = { | 566 | const params = { |
| 575 | title: '验证WDSF', | 567 | title: language.value == 0 ? '验证WDSF' :'Verify WDSF', |
| 576 | groupId: groupId.value, | 568 | groupId: groupId.value, |
| 577 | matchId: matchId.value, | 569 | matchId: matchId.value, |
| 578 | list: choosed2List.value | 570 | list: choosed2List.value | ... | ... |
| ... | @@ -15,7 +15,8 @@ | ... | @@ -15,7 +15,8 @@ |
| 15 | /> | 15 | /> |
| 16 | </el-form-item> | 16 | </el-form-item> |
| 17 | <el-form-item v-if="language!=0" label="WDSF code" prop="wdsfMin"> | 17 | <el-form-item v-if="language!=0" label="WDSF code" prop="wdsfMin"> |
| 18 | <el-input v-model="form.wdsfMin" type="number"/> | 18 | <span v-if="form.wdsfMin">{{form.wdsfMin}}</span> |
| 19 | <el-input v-else v-model="form.wdsfMin" type="number"/> | ||
| 19 | </el-form-item> | 20 | </el-form-item> |
| 20 | <el-form-item :label="language==0?'姓氏':'surname'" prop="xing" required> | 21 | <el-form-item :label="language==0?'姓氏':'surname'" prop="xing" required> |
| 21 | <el-input v-model="form.xing"/> | 22 | <el-input v-model="form.xing"/> |
| ... | @@ -36,6 +37,9 @@ | ... | @@ -36,6 +37,9 @@ |
| 36 | <el-form-item :label="language==0?'证件号码':'ID NO'" prop="idcCode" required> | 37 | <el-form-item :label="language==0?'证件号码':'ID NO'" prop="idcCode" required> |
| 37 | <el-input v-model="form.idcCode" @blur="checkCode" :disabled="editgay"/> | 38 | <el-input v-model="form.idcCode" @blur="checkCode" :disabled="editgay"/> |
| 38 | </el-form-item> | 39 | </el-form-item> |
| 40 | <el-form-item label="上传证件照" required :required="form.idcType!='0'"> | ||
| 41 | <file-upload v-model="form.passportUrl" :limit="1" :is-show-tip="false" /> | ||
| 42 | </el-form-item> | ||
| 39 | <el-form-item :label="language==0?'性别':'sex'" prop="sex"> | 43 | <el-form-item :label="language==0?'性别':'sex'" prop="sex"> |
| 40 | <el-radio-group v-model="form.sex" :disabled="form.idcType=='0'"> | 44 | <el-radio-group v-model="form.sex" :disabled="form.idcType=='0'"> |
| 41 | <el-radio value="0">{{ language==0?'女':'female' }}</el-radio> | 45 | <el-radio value="0">{{ language==0?'女':'female' }}</el-radio> |
| ... | @@ -56,13 +60,13 @@ | ... | @@ -56,13 +60,13 @@ |
| 56 | <el-option v-for="l in labels" :key="l.value" :value="l.value" :label="language==0?l.label:l.enlabel"/> | 60 | <el-option v-for="l in labels" :key="l.value" :value="l.value" :label="language==0?l.label:l.enlabel"/> |
| 57 | </el-select> | 61 | </el-select> |
| 58 | </el-form-item> | 62 | </el-form-item> |
| 59 | <el-form-item :label="language==0?'手机号码':'Phone'" prop="phone" required> | 63 | <el-form-item :label="language==0?'手机号码':'Phone'" prop="phone"> |
| 60 | <el-input v-model="form.phone" type="number"/> | 64 | <el-input v-model="form.phone" type="number"/> |
| 61 | </el-form-item> | 65 | </el-form-item> |
| 62 | 66 | ||
| 63 | 67 | ||
| 64 | <el-form-item :label="language==0?'所属国家/地区':'Country'" prop="countryId"> | 68 | <el-form-item :label="language==0?'所属国家/地区':'Country'" prop="countryId" required> |
| 65 | <el-select :disabled="language==0" filterable v-model="form.countryId" style="width: 100%;" @change="changeCountryId"> | 69 | <el-select filterable v-model="form.countryId" style="width: 100%;" @change="changeCountryId"> |
| 66 | <el-option v-for="item in countryList" :key="item.id" :label="language==0?item.name:item.enName" :value="item.id"/> | 70 | <el-option v-for="item in countryList" :key="item.id" :label="language==0?item.name:item.enName" :value="item.id"/> |
| 67 | </el-select> | 71 | </el-select> |
| 68 | </el-form-item> | 72 | </el-form-item> |
| ... | @@ -78,7 +82,8 @@ | ... | @@ -78,7 +82,8 @@ |
| 78 | 82 | ||
| 79 | </el-form-item> | 83 | </el-form-item> |
| 80 | <el-form-item v-if="language=='0'" :label="language==0?'WDSF会员号':'WDSF code'" prop="wdsfMin"> | 84 | <el-form-item v-if="language=='0'" :label="language==0?'WDSF会员号':'WDSF code'" prop="wdsfMin"> |
| 81 | <el-input v-model="form.wdsfMin" type="number"/> | 85 | <span v-if="form.wdsfMin">{{form.wdsfMin}}</span> |
| 86 | <el-input v-else v-model="form.wdsfMin" type="number"/> | ||
| 82 | </el-form-item> | 87 | </el-form-item> |
| 83 | 88 | ||
| 84 | 89 | ... | ... |
src/viewsPc/match/components/addCoach_en.vue
0 → 100644
| 1 | <template> | ||
| 2 | <el-dialog | ||
| 3 | v-model="show" :title="title" width="1100px" append-to-body close-icon="CircleClose" center | ||
| 4 | :close-on-click-modal="false" class="pcloginpop" | ||
| 5 | destroy-on-close | ||
| 6 | > | ||
| 7 | <el-form ref="dialogRef" :model="form" :rules="language==0?rules:rules_cn" label-width="120px" inline> | ||
| 8 | <el-row :gutter="30" class="mt30"> | ||
| 9 | <el-col :lg="12" class="touxiang"> | ||
| 10 | |||
| 11 | <el-form-item prop="picUrl" :label="language==0?'个人照片':'Photo'"> | ||
| 12 | <ImageUpload2 | ||
| 13 | v-model="form.picUrl" :crop-height="280" :crop-width="200" class="threeFour" :limit="1" | ||
| 14 | :is-show-tip="false" | ||
| 15 | /> | ||
| 16 | </el-form-item> | ||
| 17 | <el-form-item :label="language==0?'WDSF会员号':'WDSF MIN'" v-if="form.id"> | ||
| 18 | {{ form.wdsfMin }} | ||
| 19 | </el-form-item> | ||
| 20 | <el-form-item :label="language==0?'WDSF会员号':'WDSF MIN'" required v-else> | ||
| 21 | <el-input type="text" v-model="form.wdsfMin" @change="resetCode" > | ||
| 22 | <template #append> | ||
| 23 | <el-button type="primary" plain style="width: 110px" @click="checkCard"> | ||
| 24 | <el-icon v-if="isCodeTrue" size="16" color="#67C23A"> | ||
| 25 | <CircleCheckFilled/> | ||
| 26 | </el-icon> | ||
| 27 | <span v-else>{{ language == 0 ? '校验卡号' : 'Check Code' }}</span> | ||
| 28 | </el-button> | ||
| 29 | </template> | ||
| 30 | </el-input> | ||
| 31 | </el-form-item> | ||
| 32 | <el-form-item :label="language==0?'姓氏':'Surname'" prop="xing" required> | ||
| 33 | <el-input v-model="form.xing"/> | ||
| 34 | </el-form-item> | ||
| 35 | <el-form-item :label="language==0?'名':'Name'" prop="ming" required> | ||
| 36 | <el-input v-model="form.ming"/> | ||
| 37 | </el-form-item> | ||
| 38 | <el-form-item :label="language==0?'证件类型':'ID Type'" prop="idcType" required> | ||
| 39 | <el-select v-model="form.idcType" style="width: 100%;" :disabled="editgay"> | ||
| 40 | <el-option | ||
| 41 | v-for="item in certificates" | ||
| 42 | :key="item.value" | ||
| 43 | :label="item.label" | ||
| 44 | :value="item.value" | ||
| 45 | /> | ||
| 46 | </el-select> | ||
| 47 | </el-form-item> | ||
| 48 | <el-form-item :label="language==0?'证件号码':'ID NO'" prop="idcCode" required> | ||
| 49 | <el-input v-model="form.idcCode" @blur="checkCode" :disabled="editgay"/> | ||
| 50 | </el-form-item> | ||
| 51 | <el-form-item label="Passport File" required v-if="form.idcType=='1'"> | ||
| 52 | <file-upload v-model="form.passportUrl" :limit="1" :is-show-tip="false" :button-text="'Upload'"/> | ||
| 53 | </el-form-item> | ||
| 54 | </el-col> | ||
| 55 | <el-col :lg="12"> | ||
| 56 | <el-form-item :label="language==0?'性别':'Gender'" prop="sex"> | ||
| 57 | <el-radio-group v-model="form.sex" :disabled="form.idcType=='0'"> | ||
| 58 | <el-radio value="0">{{ language == 0 ? '女' : 'female' }}</el-radio> | ||
| 59 | <el-radio value="1">{{ language == 0 ? '男' : 'male' }}</el-radio> | ||
| 60 | </el-radio-group> | ||
| 61 | </el-form-item> | ||
| 62 | <el-form-item :label="language==0?'出生日期':'Birth'" prop="birth"> | ||
| 63 | <el-date-picker | ||
| 64 | v-model="form.birth" :disabled="form.idcType=='0'" | ||
| 65 | style="width: 100%;" | ||
| 66 | type="date" format="YYYY-MM-DD" value-format="YYYY-MM-DD" | ||
| 67 | /> | ||
| 68 | </el-form-item> | ||
| 69 | <el-form-item :label="language==0?'主要会员角色':'Roles'" prop="labelArr"> | ||
| 70 | <el-select v-model="form.labelArr" multiple> | ||
| 71 | <el-option v-for="l in labels" :key="l.value" :value="l.value" :label="language==0?l.label:l.enlabel"/> | ||
| 72 | </el-select> | ||
| 73 | </el-form-item> | ||
| 74 | <el-form-item :label="language==0?'手机号码':'Phone'" prop="phone"> | ||
| 75 | <el-input v-model="form.phone" type="number"/> | ||
| 76 | </el-form-item> | ||
| 77 | |||
| 78 | |||
| 79 | <el-form-item :label="language==0?'所属国家/地区':'Country'" prop="countryId" required> | ||
| 80 | <el-select :disabled="language==0" filterable v-model="form.countryId" style="width: 100%;" | ||
| 81 | @change="changeCountryId"> | ||
| 82 | <el-option v-for="item in countryList" :key="item.id" :label="language==0?item.name:item.enName" | ||
| 83 | :value="item.id"/> | ||
| 84 | </el-select> | ||
| 85 | </el-form-item> | ||
| 86 | |||
| 87 | <el-form-item :label="language==0?'详细地址':'Address'" prop="address"> | ||
| 88 | <el-cascader v-if="form.countryId == 240" | ||
| 89 | v-model="form.regionId" | ||
| 90 | style="width: 100%;margin-bottom: 15px" | ||
| 91 | :options="regionsList" | ||
| 92 | :props="{ label:'text' }" | ||
| 93 | /> | ||
| 94 | <el-input v-model="form.address" type="textarea" :rows="4"/> | ||
| 95 | |||
| 96 | </el-form-item> | ||
| 97 | |||
| 98 | <!-- <el-form-item :label="language==0?'邮箱':'Email'" prop="email" required>--> | ||
| 99 | <!-- <el-input v-model="form.email"/>--> | ||
| 100 | <!-- </el-form-item>--> | ||
| 101 | |||
| 102 | |||
| 103 | </el-col> | ||
| 104 | </el-row> | ||
| 105 | </el-form> | ||
| 106 | <template #footer> | ||
| 107 | <div class="dialog-footer text-center"> | ||
| 108 | <el-button type="primary" class="btn-lineG w200px" round @click="submitForm">{{ | ||
| 109 | language == 0 ? '确定' : 'Save' | ||
| 110 | }} | ||
| 111 | </el-button> | ||
| 112 | </div> | ||
| 113 | </template> | ||
| 114 | </el-dialog> | ||
| 115 | </template> | ||
| 116 | |||
| 117 | <script setup> | ||
| 118 | import {reactive, ref, toRefs, watch} from 'vue' | ||
| 119 | import {getCurrentInstance, nextTick, onMounted} from '@vue/runtime-core' | ||
| 120 | import * as match from '@/apiPc/match' | ||
| 121 | import {ElMessage} from 'element-plus' | ||
| 122 | import _ from 'lodash' | ||
| 123 | import {useStorage} from "@vueuse/core/index"; | ||
| 124 | |||
| 125 | const language = useStorage('language', 0) | ||
| 126 | const certificates = ref([ | ||
| 127 | // { | ||
| 128 | // value: '0', | ||
| 129 | // label: language.value == 0 ? '居民身份证' : 'Resident ID card' | ||
| 130 | // }, | ||
| 131 | { | ||
| 132 | value: '1', | ||
| 133 | label: language.value == 0 ? '护照' : 'Passport' | ||
| 134 | }, | ||
| 135 | { | ||
| 136 | value: '2', | ||
| 137 | label: language.value == 0 ? '其他' : 'Other' | ||
| 138 | } | ||
| 139 | ]) | ||
| 140 | const {proxy} = getCurrentInstance() | ||
| 141 | const emit = defineEmits(['submitForm']) | ||
| 142 | const data = reactive({ | ||
| 143 | form: { | ||
| 144 | // countryId: 240 | ||
| 145 | sex: '0' | ||
| 146 | }, | ||
| 147 | rules: { | ||
| 148 | xing: [{required: true, message: '必填', trigger: 'blur'}], | ||
| 149 | ming: [{required: true, message: '必填', trigger: 'blur'}], | ||
| 150 | // countryId: [{required: true, message: '必填', trigger: 'change'}], | ||
| 151 | idcType: [{required: true, message: '必填', trigger: 'change'}], | ||
| 152 | idcCode: [{required: true, message: '必填', trigger: 'blur'}], | ||
| 153 | phone: [{required: true, message: '必填', trigger: 'blur'}], | ||
| 154 | // regionId: [{ required: true, message: '必填', trigger: 'change' }], | ||
| 155 | birth: [{required: true, message: '必填', trigger: 'change'}], | ||
| 156 | // address: [{ required: true, message: '必填', trigger: 'blur' }], | ||
| 157 | // picUrl: [{required: true, message: '必填', trigger: 'blur'}], | ||
| 158 | sex: [{required: true, message: '必填', trigger: 'change'}], | ||
| 159 | labelArr: [{required: true, message: '必填', trigger: 'change'}] | ||
| 160 | }, | ||
| 161 | rules_cn: { | ||
| 162 | xing: [{required: true, message: 'required', trigger: 'blur'}], | ||
| 163 | ming: [{required: true, message: 'required', trigger: 'blur'}], | ||
| 164 | countryId: [{required: true, message: 'required', trigger: 'change'}], | ||
| 165 | idcType: [{required: true, message: 'required', trigger: 'change'}], | ||
| 166 | idcCode: [{required: true, message: 'required', trigger: 'blur'}], | ||
| 167 | // phone: [{required: true, message: 'required', trigger: 'blur'}], | ||
| 168 | // regionId: [{ required: true, message: 'required', trigger: 'change' }], | ||
| 169 | birth: [{required: true, message: 'required', trigger: 'change'}], | ||
| 170 | // address: [{ required: true, message: 'required', trigger: 'blur' }], | ||
| 171 | // picUrl: [{required: true, message: 'required', trigger: 'blur'}], | ||
| 172 | sex: [{required: true, message: 'required', trigger: 'change'}], | ||
| 173 | labelArr: [{required: true, message: 'required', trigger: 'change'}] | ||
| 174 | }, | ||
| 175 | show: false, | ||
| 176 | countryList: [], | ||
| 177 | regionsList: [], | ||
| 178 | labels: [ | ||
| 179 | {value: '0', label: '运动员', enlabel: 'Sportsman'}, | ||
| 180 | {value: '1', label: '教练', enlabel: 'Coach'}, | ||
| 181 | {value: '2', label: '领队', enlabel: 'Leader'}, | ||
| 182 | {value: '4', label: '队医', enlabel: 'Nurse'}, | ||
| 183 | {value: '5', label: '翻译', enlabel: 'Translator'}, | ||
| 184 | {value: '6', label: '官员', enlabel: 'Official'}, | ||
| 185 | {value: '3', label: '其他', enlabel: 'Other'} | ||
| 186 | ], | ||
| 187 | title: '添加选手信息', | ||
| 188 | groupId: '0', | ||
| 189 | showRequire: false, | ||
| 190 | isMe: false | ||
| 191 | }) | ||
| 192 | const { | ||
| 193 | showRequire, | ||
| 194 | form, | ||
| 195 | rules, | ||
| 196 | rules_cn, | ||
| 197 | show, | ||
| 198 | countryList, | ||
| 199 | regionsList, | ||
| 200 | title, | ||
| 201 | groupId, | ||
| 202 | labels, | ||
| 203 | uType, | ||
| 204 | isMe | ||
| 205 | } = toRefs(data) | ||
| 206 | onMounted(() => { | ||
| 207 | getCountryList() | ||
| 208 | getRegionsList() | ||
| 209 | |||
| 210 | }) | ||
| 211 | const editgay = ref(false) | ||
| 212 | const open = (params) => { | ||
| 213 | console.log(params.label) | ||
| 214 | show.value = true | ||
| 215 | title.value = params.title | ||
| 216 | groupId.value = params.groupId || '0' | ||
| 217 | if (params.label) { | ||
| 218 | form.value.labelArr = [params.label] | ||
| 219 | } | ||
| 220 | if (params.id != 0) { // 编辑 | ||
| 221 | editgay.value = true | ||
| 222 | match.getPersonInfoById(params.id).then(res => { | ||
| 223 | form.value = res.data | ||
| 224 | form.value.id = params.id | ||
| 225 | if (form.value.label) { | ||
| 226 | // {0:0,1:1,2:3} | ||
| 227 | form.value.labelArr = form.value.label.split(',') | ||
| 228 | } | ||
| 229 | }) | ||
| 230 | } else { | ||
| 231 | editgay.value = false | ||
| 232 | } | ||
| 233 | |||
| 234 | } | ||
| 235 | defineExpose({open}) | ||
| 236 | watch(show, (value) => { | ||
| 237 | if (!value) { | ||
| 238 | form.value = { | ||
| 239 | sex: '0' | ||
| 240 | } | ||
| 241 | if (language.value == 0) { | ||
| 242 | form.value.countryId = 240 | ||
| 243 | } | ||
| 244 | } | ||
| 245 | nextTick(() => { | ||
| 246 | // proxy.$refs['dialogRef'].clearValidate() | ||
| 247 | }) | ||
| 248 | }) | ||
| 249 | |||
| 250 | function getCountryList() { | ||
| 251 | match.countryList().then(res => { | ||
| 252 | countryList.value = res.data | ||
| 253 | }) | ||
| 254 | } | ||
| 255 | |||
| 256 | function changeCountryId() { | ||
| 257 | if (form.value.countryId != 240) { | ||
| 258 | form.value.nation = '其他' | ||
| 259 | } | ||
| 260 | } | ||
| 261 | |||
| 262 | function getRegionsList() { | ||
| 263 | match.regionsList().then(res => { | ||
| 264 | regionsList.value = res.data | ||
| 265 | }) | ||
| 266 | } | ||
| 267 | |||
| 268 | function checkCode() { | ||
| 269 | |||
| 270 | if (form.value.idcType == '0' && form.value.idcCode) { | ||
| 271 | giveBirthDay() | ||
| 272 | var obj = { | ||
| 273 | idcType: form.value.idcType, | ||
| 274 | idcCode: form.value.idcCode | ||
| 275 | } | ||
| 276 | // match.checkPerson(obj).then(res => { | ||
| 277 | // if (res.data.idcCode != null) { | ||
| 278 | // form.value = res.data | ||
| 279 | // if (form.value.label != null) { | ||
| 280 | // form.value.labelArr = form.value.label.split(',') | ||
| 281 | // } | ||
| 282 | // form.value.groupId = groupId.value | ||
| 283 | // } | ||
| 284 | // }) | ||
| 285 | } | ||
| 286 | } | ||
| 287 | |||
| 288 | function giveBirthDay() { | ||
| 289 | // 判断身份证正确性/赋值生日 | ||
| 290 | if (form.value.idcType == 0) { | ||
| 291 | if (!(/(^\d{15}$)|(^\d{17}([0-9]|X)$)/.test(form.value.idcCode))) { | ||
| 292 | ElMessage.warning('请输入正确的身份证号码') | ||
| 293 | } else { | ||
| 294 | let tmpStr = '' | ||
| 295 | if (form.value.idcCode.length == 15) { | ||
| 296 | tmpStr = form.value.idcCode.substring(6, 12) | ||
| 297 | tmpStr = '19' + tmpStr | ||
| 298 | tmpStr = tmpStr.substring(0, 4) + '-' + tmpStr.substring(4, 6) + '-' + tmpStr.substring(6) | ||
| 299 | } else { | ||
| 300 | tmpStr = form.value.idcCode.substring(6, 14) | ||
| 301 | tmpStr = tmpStr.substring(0, 4) + '-' + tmpStr.substring(4, 6) + '-' + tmpStr.substring(6) | ||
| 302 | } | ||
| 303 | form.value.birth = tmpStr | ||
| 304 | |||
| 305 | const res = /^(\d{6})(\d{4})(\d{2})(\d{2})(\d{3})([0-9]|X)$/ | ||
| 306 | if (form.value.idcCode && res.test(form.value.idcCode)) { | ||
| 307 | const genderCode = form.value.idcCode.charAt(16) | ||
| 308 | if (parseInt(genderCode) % 2 == 0) { | ||
| 309 | form.value.sex = '0' | ||
| 310 | } else { | ||
| 311 | form.value.sex = '1' | ||
| 312 | } | ||
| 313 | } | ||
| 314 | } | ||
| 315 | } | ||
| 316 | } | ||
| 317 | |||
| 318 | function submitForm() { | ||
| 319 | proxy.$refs['dialogRef'].validate((valid) => { | ||
| 320 | if (valid) { | ||
| 321 | // 验证身份证号 | ||
| 322 | if (form.value.idcType == 0 && !(/(^\d{15}$)|(^\d{17}([0-9]|X)$)/.test(form.value.idcCode))) { | ||
| 323 | ElMessage.warning('请输入正确的身份证号码') | ||
| 324 | return | ||
| 325 | } | ||
| 326 | // 验证手机号 | ||
| 327 | if (showRequire.value) { | ||
| 328 | var pattern = /^1[3456789]\d{9}$/ | ||
| 329 | if (!pattern.test(form.value.phone)) { | ||
| 330 | ElMessage.warning(language.value == 0 ? '请输入正确的手机号' : 'Please enter the correct mobile phone number') | ||
| 331 | return | ||
| 332 | } | ||
| 333 | } | ||
| 334 | |||
| 335 | if (typeof (form.value.regionId) === 'object') { | ||
| 336 | form.value.regionId = _.last(form.value.regionId) | ||
| 337 | } | ||
| 338 | form.value.label = form.value.labelArr.toString() | ||
| 339 | |||
| 340 | if (groupId.value != 0) { | ||
| 341 | // 团队 | ||
| 342 | form.value.groupId = groupId.value | ||
| 343 | match.savePersonForMyGroup(form.value).then(res => { | ||
| 344 | ElMessage.success(language.value == 0 ? '保存成功' : 'Save successful') | ||
| 345 | show.value = false | ||
| 346 | emit('submitForm') | ||
| 347 | }) | ||
| 348 | } else { | ||
| 349 | if (editgay.value) { | ||
| 350 | // id不是0 | ||
| 351 | match.editPersonInfo(form.value).then(res => { | ||
| 352 | ElMessage.success(language.value == 0 ? '保存成功' : 'Save successful') | ||
| 353 | show.value = false | ||
| 354 | emit('submitForm') | ||
| 355 | }) | ||
| 356 | } else { | ||
| 357 | if (isMe.value) { | ||
| 358 | match.saveMyBaseInfo(form.value).then(res => { | ||
| 359 | ElMessage.success(language.value == 0 ? '保存成功' : 'Save successful') | ||
| 360 | show.value = false | ||
| 361 | emit('submitForm') | ||
| 362 | }) | ||
| 363 | } else { | ||
| 364 | match.savePersonForMyPerson(form.value).then(res => { | ||
| 365 | ElMessage.success(language.value == 0 ? '保存成功' : 'Save successful') | ||
| 366 | show.value = false | ||
| 367 | emit('submitForm') | ||
| 368 | }) | ||
| 369 | } | ||
| 370 | } | ||
| 371 | } | ||
| 372 | } | ||
| 373 | }) | ||
| 374 | } | ||
| 375 | |||
| 376 | function cancel() { | ||
| 377 | show.value = false | ||
| 378 | } | ||
| 379 | </script> | ||
| 380 | |||
| 381 | <style lang="scss"> | ||
| 382 | .threeFour { | ||
| 383 | width: 100%; | ||
| 384 | |||
| 385 | .el-upload--picture-card { | ||
| 386 | width: 120px; | ||
| 387 | height: 160px; | ||
| 388 | } | ||
| 389 | |||
| 390 | .el-upload-list--picture-card .el-upload-list__item { | ||
| 391 | width: 120px; | ||
| 392 | height: 160px; | ||
| 393 | } | ||
| 394 | } | ||
| 395 | |||
| 396 | .tip { | ||
| 397 | font-size: 13px; | ||
| 398 | color: #999; | ||
| 399 | margin: 10px 0; | ||
| 400 | |||
| 401 | i { | ||
| 402 | color: red; | ||
| 403 | margin: 0 4px 0 0; | ||
| 404 | } | ||
| 405 | } | ||
| 406 | |||
| 407 | .shenfen { | ||
| 408 | .el-upload--picture-card { | ||
| 409 | width: 320px; | ||
| 410 | height: 200px; | ||
| 411 | } | ||
| 412 | |||
| 413 | .el-upload-list--picture-card .el-upload-list__item { | ||
| 414 | width: 320px; | ||
| 415 | height: 200px; | ||
| 416 | } | ||
| 417 | } | ||
| 418 | |||
| 419 | .touxiang { | ||
| 420 | :deep(.el-upload--picture-card ) { | ||
| 421 | width: 140px; | ||
| 422 | height: 200px; | ||
| 423 | } | ||
| 424 | } | ||
| 425 | |||
| 426 | .touxiang { | ||
| 427 | :deep(.el-upload-list__item ) { | ||
| 428 | width: 140px; | ||
| 429 | height: 200px; | ||
| 430 | } | ||
| 431 | |||
| 432 | } | ||
| 433 | |||
| 434 | .el-form--inline .el-form-item { | ||
| 435 | width: 100% | ||
| 436 | } | ||
| 437 | |||
| 438 | |||
| 439 | .boxDialog { | ||
| 440 | .el-dialog__header { | ||
| 441 | background: linear-gradient(#ed2c22, #fe6d45); | ||
| 442 | margin-right: 0; | ||
| 443 | height: 52px; | ||
| 444 | |||
| 445 | span { | ||
| 446 | color: #fff; | ||
| 447 | } | ||
| 448 | } | ||
| 449 | } | ||
| 450 | |||
| 451 | </style> |
| 1 | <template> | ||
| 2 | <el-dialog | ||
| 3 | v-model="show" :title="title" width="1100px" append-to-body close-icon="CircleClose" center | ||
| 4 | :close-on-click-modal="false" class="pcloginpop" | ||
| 5 | destroy-on-close | ||
| 6 | > | ||
| 7 | <el-form ref="dialogRef" :model="form" :rules="language==0?rules:rules_cn" label-width="120px" inline> | ||
| 8 | <el-row :gutter="30" class="mt30"> | ||
| 9 | <el-col :lg="12" class="touxiang"> | ||
| 10 | |||
| 11 | <el-form-item prop="picUrl" :label="language==0?'个人照片':'Photo'"> | ||
| 12 | <ImageUpload2 | ||
| 13 | v-model="form.picUrl" :crop-height="280" :crop-width="200" class="threeFour" :limit="1" | ||
| 14 | :is-show-tip="false" | ||
| 15 | /> | ||
| 16 | </el-form-item> | ||
| 17 | <el-form-item :label="language==0?'WDSF会员号':'WDSF MIN'" v-if="form.id"> | ||
| 18 | {{ form.wdsfMin }} | ||
| 19 | </el-form-item> | ||
| 20 | <el-form-item :label="language==0?'WDSF会员号':'WDSF MIN'" required v-else> | ||
| 21 | <el-input type="text" v-model="form.wdsfMin" @change="resetCode" > | ||
| 22 | <template #append> | ||
| 23 | <el-button type="primary" plain style="width: 110px" @click="checkCard"> | ||
| 24 | <el-icon v-if="isCodeTrue" size="16" color="#67C23A"> | ||
| 25 | <CircleCheckFilled/> | ||
| 26 | </el-icon> | ||
| 27 | <span v-else>{{ language == 0 ? '校验卡号' : 'Check Code' }}</span> | ||
| 28 | </el-button> | ||
| 29 | </template> | ||
| 30 | </el-input> | ||
| 31 | </el-form-item> | ||
| 32 | <el-form-item :label="language==0?'姓氏':'Surname'" prop="xing"> | ||
| 33 | <el-input v-model="form.xing" disabled/> | ||
| 34 | </el-form-item> | ||
| 35 | <el-form-item :label="language==0?'名':'Name'" prop="ming" required> | ||
| 36 | <el-input v-model="form.ming" disabled/> | ||
| 37 | </el-form-item> | ||
| 38 | <el-form-item :label="language==0?'证件类型':'ID Type'" prop="idcType" required> | ||
| 39 | <el-select v-model="form.idcType" style="width: 100%;" :disabled="editgay"> | ||
| 40 | <el-option | ||
| 41 | v-for="item in certificates" | ||
| 42 | :key="item.value" | ||
| 43 | :label="item.label" | ||
| 44 | :value="item.value" | ||
| 45 | /> | ||
| 46 | </el-select> | ||
| 47 | </el-form-item> | ||
| 48 | <el-form-item :label="language==0?'证件号码':'ID NO'" prop="idcCode" required> | ||
| 49 | <el-input v-model="form.idcCode" @blur="checkCode" :disabled="editgay"/> | ||
| 50 | </el-form-item> | ||
| 51 | <el-form-item :label="language==0?'性别':'Gender'" prop="sex"> | ||
| 52 | <el-radio-group v-model="form.sex" :disabled="form.idcType=='0'"> | ||
| 53 | <el-radio value="0">{{ language==0?'女':'female' }}</el-radio> | ||
| 54 | <el-radio value="1">{{ language==0?'男':'male' }}</el-radio> | ||
| 55 | </el-radio-group> | ||
| 56 | </el-form-item> | ||
| 57 | </el-col> | ||
| 58 | <el-col :lg="12"> | ||
| 59 | <el-form-item :label="language==0?'出生日期':'Birth'" prop="birth"> | ||
| 60 | <el-date-picker | ||
| 61 | v-model="form.birth" :disabled="form.idcType=='0'" | ||
| 62 | style="width: 100%;" | ||
| 63 | type="date" format="YYYY-MM-DD" value-format="YYYY-MM-DD" | ||
| 64 | /> | ||
| 65 | </el-form-item> | ||
| 66 | <el-form-item :label="language==0?'主要会员角色':'Roles'" prop="labelArr"> | ||
| 67 | <el-select v-model="form.labelArr" multiple> | ||
| 68 | <el-option v-for="l in labels" :key="l.value" :value="l.value" :label="language==0?l.label:l.enlabel"/> | ||
| 69 | </el-select> | ||
| 70 | </el-form-item> | ||
| 71 | <el-form-item :label="language==0?'手机号码':'Phone'" prop="phone"> | ||
| 72 | <el-input v-model="form.phone" type="number"/> | ||
| 73 | </el-form-item> | ||
| 74 | |||
| 75 | |||
| 76 | <el-form-item :label="language==0?'所属国家/地区':'Country'" prop="countryId" required> | ||
| 77 | <el-select disabled filterable v-model="form.countryId" style="width: 100%;" @change="changeCountryId"> | ||
| 78 | <el-option v-for="item in countryList" :key="item.id" :label="language==0?item.name:item.enName" :value="item.id"/> | ||
| 79 | </el-select> | ||
| 80 | </el-form-item> | ||
| 81 | |||
| 82 | <el-form-item :label="language==0?'详细地址':'Address'" prop="address"> | ||
| 83 | <el-cascader v-if="form.countryId == 240" | ||
| 84 | v-model="form.regionId" | ||
| 85 | style="width: 100%;margin-bottom: 15px" | ||
| 86 | :options="regionsList" | ||
| 87 | :props="{ label:'text' }" | ||
| 88 | /> | ||
| 89 | <el-input v-model="form.address" type="textarea" :rows="4"/> | ||
| 90 | |||
| 91 | </el-form-item> | ||
| 92 | |||
| 93 | </el-col> | ||
| 94 | </el-row> | ||
| 95 | </el-form> | ||
| 96 | <Vcode :show="isShow" :z-index="3000" @success="codeSuccess()"></Vcode> | ||
| 97 | |||
| 98 | <template #footer> | ||
| 99 | <div class="dialog-footer text-center"> | ||
| 100 | <el-button type="primary" class="btn-lineG w200px" round @click="submitForm">{{ language==0?'确定':'Save' }}</el-button> | ||
| 101 | </div> | ||
| 102 | </template> | ||
| 103 | </el-dialog> | ||
| 104 | </template> | ||
| 105 | |||
| 106 | <script setup> | ||
| 107 | import {reactive, ref, toRefs, watch} from 'vue' | ||
| 108 | import {getCurrentInstance, nextTick, onMounted} from '@vue/runtime-core' | ||
| 109 | import * as match from '@/apiPc/match' | ||
| 110 | import {ElMessage} from 'element-plus' | ||
| 111 | import _ from 'lodash' | ||
| 112 | import {useStorage} from "@vueuse/core/index"; | ||
| 113 | import {checkWdsf, getCaptchaSms} from "@/apiPc/match"; | ||
| 114 | const language= useStorage('language',0) | ||
| 115 | const certificates = ref([ | ||
| 116 | { | ||
| 117 | value: '0', | ||
| 118 | label: language.value == 0 ? '居民身份证' : 'Resident ID card' | ||
| 119 | }, | ||
| 120 | { | ||
| 121 | value: '1', | ||
| 122 | label: language.value == 0 ? '护照' : 'Passport' | ||
| 123 | }, | ||
| 124 | { | ||
| 125 | value: '2', | ||
| 126 | label: language.value == 0 ? '其他' : 'Other' | ||
| 127 | } | ||
| 128 | ]) | ||
| 129 | const {proxy} = getCurrentInstance() | ||
| 130 | const emit = defineEmits(['submitForm']) | ||
| 131 | const data = reactive({ | ||
| 132 | form: { | ||
| 133 | // countryId: 240 | ||
| 134 | sex:'0' | ||
| 135 | }, | ||
| 136 | rules_cn:{ | ||
| 137 | // xing: [{required: true, message: 'required', trigger: 'blur'}], | ||
| 138 | ming: [{required: true, message: 'required', trigger: 'blur'}], | ||
| 139 | // countryId: [{required: true, message: 'required', trigger: 'change'}], | ||
| 140 | idcType: [{required: true, message: 'required', trigger: 'change'}], | ||
| 141 | idcCode: [{required: true, message: 'required', trigger: 'blur'}], | ||
| 142 | // phone: [{required: true, message: 'required', trigger: 'blur'}], | ||
| 143 | // regionId: [{ required: true, message: 'required', trigger: 'change' }], | ||
| 144 | // birth: [{required: true, message: 'required', trigger: 'change'}], | ||
| 145 | // address: [{ required: true, message: 'required', trigger: 'blur' }], | ||
| 146 | // picUrl: [{required: true, message: 'required', trigger: 'blur'}], | ||
| 147 | sex: [{required: true, message: 'required', trigger: 'change'}], | ||
| 148 | labelArr: [{required: true, message: 'required', trigger: 'change'}] | ||
| 149 | }, | ||
| 150 | show: false, | ||
| 151 | countryList: [], | ||
| 152 | regionsList: [], | ||
| 153 | labels: [ | ||
| 154 | {value: '0', label: '运动员', enlabel: 'Sportsman'}, | ||
| 155 | {value: '1', label: '教练', enlabel: 'Coach'}, | ||
| 156 | {value: '2', label: '领队', enlabel: 'Leader'}, | ||
| 157 | {value: '4', label: '队医', enlabel: 'Nurse'}, | ||
| 158 | {value: '5', label: '翻译', enlabel: 'Translator'}, | ||
| 159 | {value: '6', label: '官员', enlabel: 'Official'}, | ||
| 160 | {value: '3', label: '其他', enlabel: 'Other'} | ||
| 161 | ], | ||
| 162 | title: '添加选手信息', | ||
| 163 | groupId: '0', | ||
| 164 | showRequire: false, | ||
| 165 | isMe:false | ||
| 166 | }) | ||
| 167 | const {showRequire, form, rules,rules_cn, show, countryList, regionsList, title, groupId, labels,uType,isMe} = toRefs(data) | ||
| 168 | const isShow = ref(false) | ||
| 169 | onMounted(() => { | ||
| 170 | getCountryList() | ||
| 171 | getRegionsList() | ||
| 172 | |||
| 173 | }) | ||
| 174 | const editgay = ref(false) | ||
| 175 | const open = (params) => { | ||
| 176 | console.log(params.label) | ||
| 177 | show.value = true | ||
| 178 | title.value = params.title | ||
| 179 | groupId.value = params.groupId || '0' | ||
| 180 | isMe.value = params.isMe | ||
| 181 | if(params.label){ | ||
| 182 | form.value.labelArr= [params.label] | ||
| 183 | } | ||
| 184 | if(language.value == 0){ | ||
| 185 | form.value.countryId = 240 | ||
| 186 | form.value.idcType = '0' | ||
| 187 | } | ||
| 188 | if(isMe.value){ | ||
| 189 | //个人 | ||
| 190 | match.getMyPersonInfo().then(res => { | ||
| 191 | form.value = res.data | ||
| 192 | form.value.id = res.data.id | ||
| 193 | if (form.value.label) { | ||
| 194 | // {0:0,1:1,2:3} | ||
| 195 | form.value.labelArr = form.value.label.split(',') | ||
| 196 | } else { | ||
| 197 | form.value.labelArr = ['0'] | ||
| 198 | } | ||
| 199 | }) | ||
| 200 | } else { | ||
| 201 | if (params.id != 0) { // 编辑 | ||
| 202 | editgay.value = true | ||
| 203 | match.getPersonInfoById(params.id).then(res => { | ||
| 204 | form.value = res.data | ||
| 205 | form.value.id = params.id | ||
| 206 | if (form.value.label) { | ||
| 207 | // {0:0,1:1,2:3} | ||
| 208 | form.value.labelArr = form.value.label.split(',') | ||
| 209 | } | ||
| 210 | }) | ||
| 211 | } else { | ||
| 212 | editgay.value = false | ||
| 213 | } | ||
| 214 | } | ||
| 215 | } | ||
| 216 | defineExpose({open}) | ||
| 217 | watch(show, (value) => { | ||
| 218 | if (!value) { | ||
| 219 | form.value = { | ||
| 220 | sex:'0' | ||
| 221 | } | ||
| 222 | if(language.value == 0){ | ||
| 223 | form.value.countryId = 240 | ||
| 224 | } | ||
| 225 | } | ||
| 226 | nextTick(() => { | ||
| 227 | // proxy.$refs['dialogRef'].clearValidate() | ||
| 228 | }) | ||
| 229 | }) | ||
| 230 | function checkCard() { | ||
| 231 | if (!form.value.card) { | ||
| 232 | if (language.value == 0) { | ||
| 233 | ElMessage.warning('请填写WDSF会员号') | ||
| 234 | } else { | ||
| 235 | ElMessage.warning('Please fill in your WDSF MIN') | ||
| 236 | } | ||
| 237 | return | ||
| 238 | } | ||
| 239 | isShow.value = true | ||
| 240 | } | ||
| 241 | function codeSuccess(msg) { | ||
| 242 | console.log('验证通过' + msg); | ||
| 243 | isShow.value = false | ||
| 244 | checkWdsf({card: form.value.wdsfMin}).then(res => { | ||
| 245 | form.value = res.data | ||
| 246 | if(form.value.passportUrl){ | ||
| 247 | |||
| 248 | } | ||
| 249 | if (!form.value.sex) { | ||
| 250 | form.value.sex = '0' | ||
| 251 | } | ||
| 252 | if (form.value.wdsfFlag == '0') { | ||
| 253 | form.value = 0 | ||
| 254 | if (language.value == 0) { | ||
| 255 | ElMessage.warning('WDSF卡号错误') | ||
| 256 | } else { | ||
| 257 | ElMessage.warning('WDSF ID is Error') | ||
| 258 | } | ||
| 259 | } | ||
| 260 | }) | ||
| 261 | } | ||
| 262 | |||
| 263 | |||
| 264 | function getCountryList() { | ||
| 265 | match.countryList().then(res => { | ||
| 266 | countryList.value = res.data | ||
| 267 | }) | ||
| 268 | } | ||
| 269 | |||
| 270 | function changeCountryId() { | ||
| 271 | if (form.value.countryId != 240) { | ||
| 272 | form.value.nation = '其他' | ||
| 273 | } | ||
| 274 | } | ||
| 275 | |||
| 276 | function getRegionsList() { | ||
| 277 | match.regionsList().then(res => { | ||
| 278 | regionsList.value = res.data | ||
| 279 | }) | ||
| 280 | } | ||
| 281 | |||
| 282 | function checkCode() { | ||
| 283 | if (form.value.idcType=='0' && form.value.idcCode) { | ||
| 284 | giveBirthDay() | ||
| 285 | var obj = { | ||
| 286 | idcType: form.value.idcType, | ||
| 287 | idcCode: form.value.idcCode | ||
| 288 | } | ||
| 289 | // match.checkPerson(obj).then(res => { | ||
| 290 | // if (res.data.idcCode != null) { | ||
| 291 | // form.value = res.data | ||
| 292 | // if (form.value.label != null) { | ||
| 293 | // form.value.labelArr = form.value.label.split(',') | ||
| 294 | // } | ||
| 295 | // form.value.groupId = groupId.value | ||
| 296 | // } | ||
| 297 | // }) | ||
| 298 | } | ||
| 299 | } | ||
| 300 | |||
| 301 | function giveBirthDay() { | ||
| 302 | // 判断身份证正确性/赋值生日 | ||
| 303 | if (form.value.idcType == 0) { | ||
| 304 | if (!(/(^\d{15}$)|(^\d{17}([0-9]|X)$)/.test(form.value.idcCode))) { | ||
| 305 | ElMessage.warning('请输入正确的身份证号码') | ||
| 306 | } else { | ||
| 307 | let tmpStr = '' | ||
| 308 | if (form.value.idcCode.length == 15) { | ||
| 309 | tmpStr = form.value.idcCode.substring(6, 12) | ||
| 310 | tmpStr = '19' + tmpStr | ||
| 311 | tmpStr = tmpStr.substring(0, 4) + '-' + tmpStr.substring(4, 6) + '-' + tmpStr.substring(6) | ||
| 312 | } else { | ||
| 313 | tmpStr = form.value.idcCode.substring(6, 14) | ||
| 314 | tmpStr = tmpStr.substring(0, 4) + '-' + tmpStr.substring(4, 6) + '-' + tmpStr.substring(6) | ||
| 315 | } | ||
| 316 | form.value.birth = tmpStr | ||
| 317 | |||
| 318 | const res = /^(\d{6})(\d{4})(\d{2})(\d{2})(\d{3})([0-9]|X)$/ | ||
| 319 | if (form.value.idcCode && res.test(form.value.idcCode)) { | ||
| 320 | const genderCode = form.value.idcCode.charAt(16) | ||
| 321 | if (parseInt(genderCode) % 2 == 0) { | ||
| 322 | form.value.sex = '0' | ||
| 323 | } else { | ||
| 324 | form.value.sex = '1' | ||
| 325 | } | ||
| 326 | } | ||
| 327 | } | ||
| 328 | } | ||
| 329 | } | ||
| 330 | |||
| 331 | function submitForm() { | ||
| 332 | proxy.$refs['dialogRef'].validate((valid) => { | ||
| 333 | if (valid) { | ||
| 334 | // 验证身份证号 | ||
| 335 | if (form.value.idcType == 0 && !(/(^\d{15}$)|(^\d{17}([0-9]|X)$)/.test(form.value.idcCode))) { | ||
| 336 | ElMessage.warning('请输入正确的身份证号码') | ||
| 337 | return | ||
| 338 | } | ||
| 339 | // 验证手机号 | ||
| 340 | if (showRequire.value) { | ||
| 341 | var pattern = /^1[3456789]\d{9}$/ | ||
| 342 | if (!pattern.test(form.value.phone)) { | ||
| 343 | ElMessage.warning(language.value == 0 ?'请输入正确的手机号':'Please enter the correct mobile phone number') | ||
| 344 | return | ||
| 345 | } | ||
| 346 | } | ||
| 347 | |||
| 348 | if (typeof (form.value.regionId) === 'object') { | ||
| 349 | form.value.regionId = _.last(form.value.regionId) | ||
| 350 | } | ||
| 351 | form.value.label = form.value.labelArr.toString() | ||
| 352 | |||
| 353 | if (groupId.value != 0) { | ||
| 354 | // 团队 | ||
| 355 | form.value.groupId = groupId.value | ||
| 356 | match.savePersonForMyGroup(form.value).then(res => { | ||
| 357 | ElMessage.success(language.value == 0 ?'保存成功':'Save successful') | ||
| 358 | show.value = false | ||
| 359 | emit('submitForm') | ||
| 360 | }) | ||
| 361 | } else { | ||
| 362 | if (editgay.value) { | ||
| 363 | // id不是0 | ||
| 364 | match.editPersonInfo(form.value).then(res => { | ||
| 365 | ElMessage.success(language.value == 0 ?'保存成功':'Save successful') | ||
| 366 | show.value = false | ||
| 367 | emit('submitForm') | ||
| 368 | }) | ||
| 369 | } else { | ||
| 370 | if(isMe.value){ | ||
| 371 | match.saveMyBaseInfo(form.value).then(res => { | ||
| 372 | ElMessage.success(language.value == 0 ?'保存成功':'Save successful') | ||
| 373 | show.value = false | ||
| 374 | emit('submitForm') | ||
| 375 | }) | ||
| 376 | } else { | ||
| 377 | match.savePersonForMyPerson(form.value).then(res => { | ||
| 378 | ElMessage.success(language.value == 0 ?'保存成功':'Save successful') | ||
| 379 | show.value = false | ||
| 380 | emit('submitForm') | ||
| 381 | }) | ||
| 382 | } | ||
| 383 | } | ||
| 384 | } | ||
| 385 | } | ||
| 386 | }) | ||
| 387 | } | ||
| 388 | |||
| 389 | function cancel() { | ||
| 390 | show.value = false | ||
| 391 | } | ||
| 392 | </script> | ||
| 393 | |||
| 394 | <style lang="scss"> | ||
| 395 | .threeFour { | ||
| 396 | width: 100%; | ||
| 397 | |||
| 398 | .el-upload--picture-card { | ||
| 399 | width: 120px; | ||
| 400 | height: 160px; | ||
| 401 | } | ||
| 402 | |||
| 403 | .el-upload-list--picture-card .el-upload-list__item { | ||
| 404 | width: 120px; | ||
| 405 | height: 160px; | ||
| 406 | } | ||
| 407 | } | ||
| 408 | |||
| 409 | .tip { | ||
| 410 | font-size: 13px; | ||
| 411 | color: #999; | ||
| 412 | margin: 10px 0; | ||
| 413 | |||
| 414 | i { | ||
| 415 | color: red; | ||
| 416 | margin: 0 4px 0 0; | ||
| 417 | } | ||
| 418 | } | ||
| 419 | |||
| 420 | .shenfen { | ||
| 421 | .el-upload--picture-card { | ||
| 422 | width: 320px; | ||
| 423 | height: 200px; | ||
| 424 | } | ||
| 425 | |||
| 426 | .el-upload-list--picture-card .el-upload-list__item { | ||
| 427 | width: 320px; | ||
| 428 | height: 200px; | ||
| 429 | } | ||
| 430 | } | ||
| 431 | |||
| 432 | .touxiang { | ||
| 433 | :deep(.el-upload--picture-card ) { | ||
| 434 | width: 140px; | ||
| 435 | height: 200px; | ||
| 436 | } | ||
| 437 | } | ||
| 438 | |||
| 439 | .touxiang { | ||
| 440 | :deep(.el-upload-list__item ) { | ||
| 441 | width: 140px; | ||
| 442 | height: 200px; | ||
| 443 | } | ||
| 444 | |||
| 445 | } | ||
| 446 | |||
| 447 | .el-form--inline .el-form-item { | ||
| 448 | width: 100% | ||
| 449 | } | ||
| 450 | |||
| 451 | |||
| 452 | .boxDialog { | ||
| 453 | .el-dialog__header { | ||
| 454 | background: linear-gradient(#ed2c22, #fe6d45); | ||
| 455 | margin-right: 0; | ||
| 456 | height: 52px; | ||
| 457 | |||
| 458 | span { | ||
| 459 | color: #fff; | ||
| 460 | } | ||
| 461 | } | ||
| 462 | } | ||
| 463 | |||
| 464 | </style> |
| 1 | <template> | 1 | <template> |
| 2 | <el-dialog v-model="show" :title="title" width="1000px" append-to-body> | 2 | <el-dialog v-model="show" :title="title" width="1000px" append-to-body @close="close"> |
| 3 | <div class="funcBtns"> | 3 | <div class="funcBtns"> |
| 4 | <el-button type="primary" @click="addMember"> | 4 | <el-button type="primary" @click="addMember"> |
| 5 | {{ language == 0 ? '添加选手' : 'Add Player' }} | 5 | {{ language == 0 ? '添加选手' : 'Add Player' }} |
| 6 | </el-button> | 6 | </el-button> |
| 7 | <el-button type="primary" plain @click="importSportman"> | 7 | <el-button type="primary" plain @click="importSportman" v-if="language == 0"> |
| 8 | {{language == 0 ? '导入选手' : 'Import Player'}} | 8 | {{language == 0 ? '导入选手' : 'Import Player'}} |
| 9 | </el-button> | 9 | </el-button> |
| 10 | </div> | 10 | </div> |
| ... | @@ -38,7 +38,7 @@ | ... | @@ -38,7 +38,7 @@ |
| 38 | <el-table ref="allSportmenTable" v-loading="loading" :data="tableData" height="60vh" | 38 | <el-table ref="allSportmenTable" v-loading="loading" :data="tableData" height="60vh" |
| 39 | @selection-change="handleSelectionChange"> | 39 | @selection-change="handleSelectionChange"> |
| 40 | <!-- <el-table-column type="selection" :label="language==0?'选择':'Selection'" :selectable="selectable"/>--> | 40 | <!-- <el-table-column type="selection" :label="language==0?'选择':'Selection'" :selectable="selectable"/>--> |
| 41 | <el-table-column type="index" :label="language==0?'序号':'Index'" width="50" :selectable="selectable"/> | 41 | <el-table-column type="index" :label="language==0?'序号':'Index'" width="60" :selectable="selectable"/> |
| 42 | <el-table-column :label="language==0?'姓氏':'Last Name'" prop="xing" min-width="100"/> | 42 | <el-table-column :label="language==0?'姓氏':'Last Name'" prop="xing" min-width="100"/> |
| 43 | <el-table-column :label="language==0?'名':'First Name'" prop="ming" min-width="100"/> | 43 | <el-table-column :label="language==0?'名':'First Name'" prop="ming" min-width="100"/> |
| 44 | <el-table-column :label="language==0?'所属国家/地区':'Country'" prop="countryName" min-width="100"/> | 44 | <el-table-column :label="language==0?'所属国家/地区':'Country'" prop="countryName" min-width="100"/> |
| ... | @@ -88,6 +88,7 @@ | ... | @@ -88,6 +88,7 @@ |
| 88 | </el-dialog> | 88 | </el-dialog> |
| 89 | 89 | ||
| 90 | <addCoach ref="dialogAddCoach" @submitForm="getList"/> | 90 | <addCoach ref="dialogAddCoach" @submitForm="getList"/> |
| 91 | <addMan_en ref="dialogSportman_En" @submitForm="getList"/> | ||
| 91 | <Import ref="dialogImportProps" @submitForm="getList"/> | 92 | <Import ref="dialogImportProps" @submitForm="getList"/> |
| 92 | </template> | 93 | </template> |
| 93 | 94 | ||
| ... | @@ -95,7 +96,8 @@ | ... | @@ -95,7 +96,8 @@ |
| 95 | import {reactive, ref, toRefs, watch} from 'vue' | 96 | import {reactive, ref, toRefs, watch} from 'vue' |
| 96 | import {getCurrentInstance, nextTick, onMounted} from '@vue/runtime-core' | 97 | import {getCurrentInstance, nextTick, onMounted} from '@vue/runtime-core' |
| 97 | import * as match from '@/apiPc/match' | 98 | import * as match from '@/apiPc/match' |
| 98 | import addCoach from '../components/addCoach' | 99 | import AddCoach from '../components/addCoach' |
| 100 | import AddMan_en from '../components/addSportman_en' | ||
| 99 | import Import from '../components/import' | 101 | import Import from '../components/import' |
| 100 | import {useStorage} from "@vueuse/core/index"; | 102 | import {useStorage} from "@vueuse/core/index"; |
| 101 | const language= useStorage('language',0) | 103 | const language= useStorage('language',0) |
| ... | @@ -182,7 +184,9 @@ function submit() { | ... | @@ -182,7 +184,9 @@ function submit() { |
| 182 | // emit('submitForm', choosedList) | 184 | // emit('submitForm', choosedList) |
| 183 | show.value = false | 185 | show.value = false |
| 184 | } | 186 | } |
| 185 | 187 | function close() { | |
| 188 | emit('submitForm') | ||
| 189 | } | ||
| 186 | function cancel() { | 190 | function cancel() { |
| 187 | show.value = false | 191 | show.value = false |
| 188 | } | 192 | } |
| ... | @@ -193,16 +197,25 @@ function editPerson(row) { | ... | @@ -193,16 +197,25 @@ function editPerson(row) { |
| 193 | title: language.value == 0 ?'编辑人员':'Edit Person', | 197 | title: language.value == 0 ?'编辑人员':'Edit Person', |
| 194 | groupId: groupId | 198 | groupId: groupId |
| 195 | } | 199 | } |
| 200 | if (language.value == 0 ){ | ||
| 196 | proxy.$refs['dialogAddCoach'].open(params) | 201 | proxy.$refs['dialogAddCoach'].open(params) |
| 202 | } else { | ||
| 203 | proxy.$refs['dialogSportman_En'].open(params) | ||
| 204 | } | ||
| 197 | } | 205 | } |
| 198 | 206 | ||
| 199 | function addMember() { | 207 | function addMember() { |
| 200 | const params = { | 208 | const params = { |
| 201 | title: language.value == 0 ?'添加人员':'Add', | 209 | title: language.value == 0 ?'添加人员':'Add', |
| 202 | id: 0, | 210 | id: 0, |
| 203 | groupId: groupId | 211 | groupId: groupId, |
| 212 | label: '0' | ||
| 204 | } | 213 | } |
| 214 | if (language.value == 0 ){ | ||
| 205 | proxy.$refs['dialogAddCoach'].open(params) | 215 | proxy.$refs['dialogAddCoach'].open(params) |
| 216 | } else { | ||
| 217 | proxy.$refs['dialogSportman_En'].open(params) | ||
| 218 | } | ||
| 206 | } | 219 | } |
| 207 | 220 | ||
| 208 | function importSportman() { | 221 | function importSportman() { | ... | ... |
| ... | @@ -57,10 +57,16 @@ const props = defineProps({ | ... | @@ -57,10 +57,16 @@ const props = defineProps({ |
| 57 | const names = ref({}) | 57 | const names = ref({}) |
| 58 | const loading = ref(true) | 58 | const loading = ref(true) |
| 59 | import {useStorage} from "@vueuse/core/index"; | 59 | import {useStorage} from "@vueuse/core/index"; |
| 60 | import {useRouter} from "vue-router"; | ||
| 60 | const user = useUserStore().user | 61 | const user = useUserStore().user |
| 61 | const group = useUserStore().group || {} | 62 | const group = useUserStore().group || {} |
| 62 | const language= useStorage('language',0) | 63 | const language= useStorage('language',0) |
| 64 | const router = useRouter() | ||
| 63 | onMounted(() => { | 65 | onMounted(() => { |
| 66 | if(!user){ | ||
| 67 | router.push({name: 'home'}) | ||
| 68 | return | ||
| 69 | } | ||
| 64 | if (user.utype == '2') { | 70 | if (user.utype == '2') { |
| 65 | tuandui() | 71 | tuandui() |
| 66 | } | 72 | } | ... | ... |
| ... | @@ -3,17 +3,22 @@ | ... | @@ -3,17 +3,22 @@ |
| 3 | <div class="matchItem" v-for="n in list" :key="n.id" @click="goDetail(n.id)"> | 3 | <div class="matchItem" v-for="n in list" :key="n.id" @click="goDetail(n.id)"> |
| 4 | <el-row :gutter="15"> | 4 | <el-row :gutter="15"> |
| 5 | <el-col :lg="7" :md="24" :xl="6"> | 5 | <el-col :lg="7" :md="24" :xl="6"> |
| 6 | <div class="popo"> | ||
| 7 | <el-tag v-if="n.signType==0">个人</el-tag> | ||
| 8 | <el-tag v-if="n.signType==1">团体</el-tag> | ||
| 9 | <el-tag v-if="n.signType==2">个人+团体</el-tag> | ||
| 10 | </div> | ||
| 6 | <img class="mauto mw100 coverLimitHeight" :src="fillImgUrl(n.coverUrl)"> | 11 | <img class="mauto mw100 coverLimitHeight" :src="fillImgUrl(n.coverUrl)"> |
| 7 | </el-col> | 12 | </el-col> |
| 8 | <el-col :lg="9" :md="12" :xl="12"> | 13 | <el-col :lg="9" :md="12" :xl="12"> |
| 9 | <div class="info"> | 14 | <div class="info"> |
| 10 | <h3>{{ n.name }}</h3> | 15 | <h3 class="esp">{{ n.name }}</h3> |
| 11 | <p class="ppl"><label>{{ language==0?'比赛时间':'Playing Time' }}:</label>{{n.beginTime?.slice(0,10)}} ~ {{ n.endTime?.slice(0,10) }}</p> | 16 | <p class="ppl"><label>{{ language==0?'比赛时间':'Playing Time' }}:</label>{{n.beginTime?.slice(0,10)}} ~ {{ n.endTime?.slice(0,10) }}</p> |
| 12 | <!-- <p class="ppl"><label>{{ language==0?'地    点':'Location' }}:</label>{{ n.address }}</p>--> | 17 | <p class="ppl esp"><label>{{ language==0?'地    点':'Location' }}:</label>{{ n.address }}</p> |
| 18 | <p class="ppl"><label>{{language==0?'赛事级别':'Level'}}:</label>{{n.level}}</p> | ||
| 13 | <p class="ppl"><label>{{ language==0?'报名截止':'Registration Deadline' }}:</label>{{ n.signEndTime?.slice(0,10) }}</p> | 19 | <p class="ppl"><label>{{ language==0?'报名截止':'Registration Deadline' }}:</label>{{ n.signEndTime?.slice(0,10) }}</p> |
| 14 | |||
| 15 | <p class="ppl" v-if="n.contactPerson"><label>{{ language==0?'联系人员':'Contact Person' }}:</label>{{ n.contactPerson }}</p> | 20 | <p class="ppl" v-if="n.contactPerson"><label>{{ language==0?'联系人员':'Contact Person' }}:</label>{{ n.contactPerson }}</p> |
| 16 | <p class="ppl"><label>{{ language==0?'联系电话':'Phone' }}:</label>{{ n.contactTelno }}</p> | 21 | <p class="ppl"><label>{{ language==0?'联系电话':'Phone' }}:</label>086-{{ n.contactTelno }}</p> |
| 17 | <p class="ppl" v-if="n.contactEmail"><label>{{ language==0?'邮    箱':'E-mail' }}:</label>{{ n.contactEmail }}</p> | 22 | <p class="ppl" v-if="n.contactEmail"><label>{{ language==0?'邮    箱':'E-mail' }}:</label>{{ n.contactEmail }}</p> |
| 18 | 23 | ||
| 19 | </div> | 24 | </div> |
| ... | @@ -83,6 +88,7 @@ function goDetail(id) { | ... | @@ -83,6 +88,7 @@ function goDetail(id) { |
| 83 | <style scoped lang="scss"> | 88 | <style scoped lang="scss"> |
| 84 | .pv20{padding: 0 20px;} | 89 | .pv20{padding: 0 20px;} |
| 85 | .mt60{margin-top: 60px} | 90 | .mt60{margin-top: 60px} |
| 91 | .popo{position: absolute;left: 0;} | ||
| 86 | .matchItem { | 92 | .matchItem { |
| 87 | cursor: pointer;padding: 0 0 20px; | 93 | cursor: pointer;padding: 0 0 20px; |
| 88 | background: #FFFFFF;border-bottom: 1px solid #e5e5e5; | 94 | background: #FFFFFF;border-bottom: 1px solid #e5e5e5; | ... | ... |
| 1 | <template> | 1 | <template> |
| 2 | <el-dialog | 2 | <el-dialog |
| 3 | v-model="show" :title="title" width="500px" append-to-body :close-on-click-modal="false" | 3 | v-model="show" :title="title" width="500px" append-to-body :close-on-click-modal="false" |
| 4 | destroy-on-close @close="cancel" | 4 | destroy-on-close :show-close="false" |
| 5 | > | 5 | > |
| 6 | <el-form label-width="120"> | 6 | <el-form label-width="120" v-model="list"> |
| 7 | <el-form-item required :label="item.realName" v-for="item in list"> | 7 | <el-form-item required :label="item.realName" v-for="item in list"> |
| 8 | <el-input :disabled="item.checked" | 8 | <div v-show="item.checked==2">{{ item.wdsfMin }}</div> |
| 9 | v-model="item.wdsfMin" placeholder="输入WDSF会员号" | 9 | <el-input :disabled="item.checked==1" type="number" v-show="item.checked!=2" |
| 10 | v-model="item.wdsfMin" :placeholder="language==0?'绑定WDSF会员号':'Bind WDSF Number'" | ||
| 10 | > | 11 | > |
| 11 | <template #append> | 12 | <template #append> |
| 12 | <view @click="checkCode(item)" class="checkbb"> | 13 | <view @click="checkCode(item)" class="checkbb"> |
| 13 | <el-icon v-if="item.checked" color="#13ce66" size="24"><CircleCheck /></el-icon> | 14 | <el-icon v-if="item.checked==1" color="#13ce66" size="24"> |
| 14 | <text class="text-primary" v-else>验证</text> | 15 | <CircleCheck/> |
| 16 | </el-icon> | ||
| 17 | <text class="text-primary" v-else-if="item.checked==0">{{ language == 0 ? '验证' : 'Check' }}</text> | ||
| 15 | </view> | 18 | </view> |
| 16 | </template> | 19 | </template> |
| 17 | </el-input> | 20 | </el-input> |
| ... | @@ -19,27 +22,28 @@ | ... | @@ -19,27 +22,28 @@ |
| 19 | </el-form> | 22 | </el-form> |
| 20 | <template #footer> | 23 | <template #footer> |
| 21 | <div class="dialog-footer text-center"> | 24 | <div class="dialog-footer text-center"> |
| 22 | <el-button type="primary" @click="submitForm">保 存</el-button> | 25 | <el-button type="primary" @click="submitForm">{{ language == 0 ? '保 存' : 'Save' }}</el-button> |
| 23 | <el-button @click="cancel">取 消</el-button> | 26 | <el-button @click="cancel">{{ language == 0 ? '取 消' : 'Cancel' }}</el-button> |
| 24 | </div> | 27 | </div> |
| 25 | </template> | 28 | </template> |
| 26 | </el-dialog> | 29 | </el-dialog> |
| 27 | </template> | 30 | </template> |
| 28 | 31 | ||
| 29 | <script setup> | 32 | <script setup> |
| 30 | import { reactive, ref, toRefs, watch } from 'vue' | 33 | import {reactive, ref, toRefs, watch} from 'vue' |
| 31 | import { getCurrentInstance, nextTick, onMounted } from '@vue/runtime-core' | 34 | import {getCurrentInstance, nextTick, onMounted} from '@vue/runtime-core' |
| 32 | import * as match from '@/apiPc/match' | 35 | import * as match from '@/apiPc/match' |
| 33 | import { SuccessFilled } from '@element-plus/icons-vue' | 36 | import {SuccessFilled} from '@element-plus/icons-vue' |
| 34 | import { ElMessage } from 'element-plus' | 37 | import {ElMessage} from 'element-plus' |
| 35 | import { useRoute } from 'vue-router' | 38 | import {useRoute} from 'vue-router' |
| 36 | 39 | ||
| 37 | const { proxy } = getCurrentInstance() | 40 | const {proxy} = getCurrentInstance() |
| 38 | const emit = defineEmits(['submitForm', 'cancel']) | 41 | const emit = defineEmits(['submitForm', 'cancel']) |
| 39 | const uploadUrl = ref('/upload/upLoadToFileServer') | 42 | const uploadUrl = ref('/upload/upLoadToFileServer') |
| 40 | const route = useRoute() | 43 | const route = useRoute() |
| 41 | import {useStorage} from "@vueuse/core/index"; | 44 | import {useStorage} from "@vueuse/core/index"; |
| 42 | const language= useStorage('language',0) | 45 | |
| 46 | const language = useStorage('language', 0) | ||
| 43 | 47 | ||
| 44 | const data = reactive({ | 48 | const data = reactive({ |
| 45 | form: {}, | 49 | form: {}, |
| ... | @@ -48,21 +52,20 @@ const data = reactive({ | ... | @@ -48,21 +52,20 @@ const data = reactive({ |
| 48 | title: '', | 52 | title: '', |
| 49 | groupId: '0' | 53 | groupId: '0' |
| 50 | }) | 54 | }) |
| 51 | const { form, show, countryList, list, title, groupId } = toRefs(data) | 55 | const {form, show, countryList, list, title, groupId} = toRefs(data) |
| 52 | let extraId = 0 | 56 | let extraId = 0 |
| 53 | let personId | 57 | let personId |
| 54 | let matchId | 58 | let matchId |
| 55 | 59 | ||
| 56 | const open = (params) => { | 60 | const open = (params) => { |
| 57 | console.log(params) | ||
| 58 | show.value = true | 61 | show.value = true |
| 59 | title.value = params.title | 62 | title.value = params.title |
| 60 | matchId = params.matchId | 63 | matchId = params.matchId |
| 61 | groupId.value= params.groupId | 64 | groupId.value = params.groupId |
| 62 | list.value = params.list | 65 | list.value = params.list |
| 63 | init() | 66 | init() |
| 64 | } | 67 | } |
| 65 | defineExpose({ open }) | 68 | defineExpose({open}) |
| 66 | watch(show, (value) => { | 69 | watch(show, (value) => { |
| 67 | if (!value) { | 70 | if (!value) { |
| 68 | form.value = {} | 71 | form.value = {} |
| ... | @@ -71,14 +74,16 @@ watch(show, (value) => { | ... | @@ -71,14 +74,16 @@ watch(show, (value) => { |
| 71 | }) | 74 | }) |
| 72 | 75 | ||
| 73 | function init() { | 76 | function init() { |
| 74 | for (let n of list.value){ | 77 | for (let n of list.value) { |
| 75 | if (n.wdsfMin) { | 78 | if (n.wdsfMin) { |
| 76 | n.checked = true | 79 | n.checked = 2 |
| 80 | console.log(n.checked) | ||
| 77 | } else { | 81 | } else { |
| 78 | n.checked = false | 82 | n.checked = 0 |
| 79 | } | 83 | } |
| 80 | } | 84 | } |
| 81 | } | 85 | } |
| 86 | |||
| 82 | function checkCode(item) { | 87 | function checkCode(item) { |
| 83 | if (!item.wdsfMin) { | 88 | if (!item.wdsfMin) { |
| 84 | if (language.value == 0) { | 89 | if (language.value == 0) { |
| ... | @@ -88,34 +93,43 @@ function checkCode(item) { | ... | @@ -88,34 +93,43 @@ function checkCode(item) { |
| 88 | } | 93 | } |
| 89 | return | 94 | return |
| 90 | } | 95 | } |
| 91 | 96 | for (var n of list.value) { | |
| 92 | match.checkNoRepeat({card: item.wdsfMin,groupId: groupId.value}).then(res => { | 97 | if (n.wdsfMin == item.wdsfMin && n.id != item.id) { |
| 93 | if(res.data.wdsfFlag=='0'){ | 98 | ElMessage.warning(language.value == 0 ? '不能重复绑定' : 'Cannot be bound repeatedly') |
| 94 | if (language.value == 0) { | ||
| 95 | ElMessage.warning('验证失败,卡号不存在') | ||
| 96 | } else { | ||
| 97 | ElMessage.warning('Verification failed, card number does not exist') | ||
| 98 | } | ||
| 99 | return | 99 | return |
| 100 | } | 100 | } |
| 101 | if(res.data.wdsfFlag=='1'){ | 101 | } |
| 102 | item.checked = true | 102 | match.checkNoRepeat({card: item.wdsfMin, groupId: groupId.value}).then(res => { |
| 103 | if (res.data) { | ||
| 104 | item.checked = 1 | ||
| 105 | } else { | ||
| 106 | ElMessage.warning(language.value == 0 ? '不满足绑定条件' : 'Not meet the binding conditions') | ||
| 107 | return | ||
| 103 | } | 108 | } |
| 104 | }) | 109 | }) |
| 105 | } | 110 | } |
| 111 | |||
| 106 | function submitForm() { | 112 | function submitForm() { |
| 107 | var arr = [] | 113 | var obj = {} |
| 108 | for(var n of list.value){ | 114 | for (var n of list.value) { |
| 109 | arr.push({ | 115 | if (n.checked == 0) { |
| 110 | id: n.id, | 116 | ElMessage.warning(language.value == 0 ? `请点击验证${n.realName}的WDSF卡号` : `Please verify ${n.realName}'s card number`) |
| 111 | wdsfMin: n.wdsfMin | 117 | return |
| 112 | }) | ||
| 113 | } | 118 | } |
| 114 | // match.saveWdsfMin(arr).then(res=>{ | 119 | if (n.checked == 1) { |
| 115 | // show.value = false | 120 | obj[n.id] = n.wdsfMin |
| 116 | // }) | 121 | } |
| 117 | 122 | } | |
| 118 | // emit('submitForm') | 123 | console.log(obj) |
| 124 | if(obj=={}){ | ||
| 125 | return | ||
| 126 | } | ||
| 127 | match.saveWdsfMin(obj, groupId.value).then(res => { | ||
| 128 | if (res.data) { | ||
| 129 | show.value = false | ||
| 130 | emit('submitForm') | ||
| 131 | } | ||
| 132 | }) | ||
| 119 | } | 133 | } |
| 120 | 134 | ||
| 121 | function cancel() { | 135 | function cancel() { |
| ... | @@ -153,5 +167,11 @@ function cancel() { | ... | @@ -153,5 +167,11 @@ function cancel() { |
| 153 | .red { | 167 | .red { |
| 154 | color: #f56c6c; | 168 | color: #f56c6c; |
| 155 | } | 169 | } |
| 156 | .checkbb{width: 30px;display: flex;align-items: center;text-align: center;} | 170 | |
| 171 | .checkbb { | ||
| 172 | width: 40px; | ||
| 173 | display: flex; | ||
| 174 | align-items: center; | ||
| 175 | text-align: center; | ||
| 176 | } | ||
| 157 | </style> | 177 | </style> | ... | ... |
| ... | @@ -17,28 +17,38 @@ | ... | @@ -17,28 +17,38 @@ |
| 17 | <img class="mauto w100" :src="fillImgUrl(matchData.coverUrl)"> | 17 | <img class="mauto w100" :src="fillImgUrl(matchData.coverUrl)"> |
| 18 | </el-col> | 18 | </el-col> |
| 19 | <el-col :lg="9" :md="12" :xl="10" style="position: relative"> | 19 | <el-col :lg="9" :md="12" :xl="10" style="position: relative"> |
| 20 | <h3 class="m0"> | 20 | <h3 class="m0">{{ matchData.name }}</h3> |
| 21 | {{ matchData.name }} | 21 | <div v-if="matchData.type=='1'"> |
| 22 | </h3> | 22 | <p class="ppl"><label class="bm2">Event Level:</label>{{ matchData.level }}</p> |
| 23 | <p class="ppl"><label class="bm1">Playing Time:</label>{{ matchData.beginTime?.slice(0, 10) }} ~ | 23 | <p class="ppl"><label class="bm1">Playing Time:</label>{{ matchData.beginTime?.slice(0, 10) }} ~ |
| 24 | {{ matchData.endTime?.slice(0, 10) }}</p> | 24 | {{ matchData.endTime?.slice(0, 10) }}</p> |
| 25 | <p class="ppl"><label class="bm2">Event Level:</label>{{ matchData.level }}</p> | ||
| 26 | <p class="ppl" v-if="matchData.address"><label class="bm3">Location:</label>{{ matchData.address }}</p> | 25 | <p class="ppl" v-if="matchData.address"><label class="bm3">Location:</label>{{ matchData.address }}</p> |
| 27 | <p class="ppl" v-if="matchData.signEndTime"><label class="bm4">Registration | 26 | <!-- <p class="ppl" v-if="matchData.signEndTime"><label class="bm4">Registration Deadline:</label>{{ matchData.signEndTime?.slice(0, 10) }}</p>--> |
| 28 | Deadline:</label>{{ matchData.signEndTime?.slice(0, 10) }}</p> | 27 | <p class="ppl"> |
| 29 | |||
| 30 | <p class="ppl" v-if="matchData.type=='1'"> | ||
| 31 | <label> | 28 | <label> |
| 32 | <svg style="position: relative;top: 2px;" t="1711707785514" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="6578" | 29 | <svg style="position: relative;top: 2px;" t="1711707785514" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="6578" |
| 33 | width="18" height="18"> | 30 | width="18" height="18"> |
| 34 | <path d="M780 68H256c-71.6 0-130.2 55.5-130.2 123.2v711.2c1.5 42.8 50 69.3 90.6 50.6l227.2-105c38.5-17.8 83.4-18.5 122.6-1.9l255.4 108.6c34.8 14.8 76.1-2.7 86.3-37.6 1.6-5.4 2.4-11 2.4-16.9v-709C910.2 123.5 851.6 68 780 68zM276.9 231.3h255.9c23.9 0 43.3 18.4 43.3 41s-19.4 41-43.3 41H276.9c-23.9 0-43.3-18.4-43.3-41s19.4-41 43.3-41z m386.8 464H276.9c-23.9 0-43.3-18.4-43.3-41s19.4-41 43.3-41h386.8c23.9 0 43.3 18.4 43.3 41s-19.4 41-43.3 41z m0-191H276.9c-23.9 0-43.3-18.4-43.3-41s19.4-41 43.3-41h386.8c23.9 0 43.3 18.4 43.3 41s-19.4 41-43.3 41z" p-id="6579" fill="#d3d8d9"></path></svg> | 31 | <path d="M780 68H256c-71.6 0-130.2 55.5-130.2 123.2v711.2c1.5 42.8 50 69.3 90.6 50.6l227.2-105c38.5-17.8 83.4-18.5 122.6-1.9l255.4 108.6c34.8 14.8 76.1-2.7 86.3-37.6 1.6-5.4 2.4-11 2.4-16.9v-709C910.2 123.5 851.6 68 780 68zM276.9 231.3h255.9c23.9 0 43.3 18.4 43.3 41s-19.4 41-43.3 41H276.9c-23.9 0-43.3-18.4-43.3-41s19.4-41 43.3-41z m386.8 464H276.9c-23.9 0-43.3-18.4-43.3-41s19.4-41 43.3-41h386.8c23.9 0 43.3 18.4 43.3 41s-19.4 41-43.3 41z m0-191H276.9c-23.9 0-43.3-18.4-43.3-41s19.4-41 43.3-41h386.8c23.9 0 43.3 18.4 43.3 41s-19.4 41-43.3 41z" p-id="6579" fill="#d3d8d9"></path></svg> |
| 35 | Station race:</label>{{matchData.cpts.length}} | 32 | Station race:</label>{{matchData.cpts.length}} |
| 36 | </p> | 33 | </p> |
| 37 | <p class="ppl" v-if="matchData.type=='1'"> | 34 | <p class="ppl"> |
| 38 | <label> | 35 | <label> |
| 39 | <svg style="position: relative;top: 2px;" t="1711708779620" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="7920" width="20" height="20"><path d="M398.652952 165.692952c-32.280381-46.006857-58.172952-61.318095-92.867047-54.808381-14.969905 2.80381-24.210286 7.850667-41.20381 22.528l-12.946285 11.361524-25.185524 20.894476-6.582857 5.753905c-3.705905 3.413333-6.38781 6.217143-9.825524 10.118095-64 72.46019-81.724952 185.782857-44.470857 292.327619 26.794667 76.55619 74.605714 152.624762 142.774857 228.644572 72.289524 80.62781 133.046857 131.364571 202.922666 168.374857 54.857143 29.013333 96.865524 41.74019 145.676191 43.227429 59.001905 1.828571 110.957714-11.50781 153.648762-39.15581a162.133333 162.133333 0 0 0 19.553524-15.189333l8.289523-7.558095 16.335239-15.213715 5.534476-4.924952 10.922666-9.435429c22.040381-19.651048 29.184-31.939048 30.646858-51.370666 2.194286-29.647238-11.215238-52.736-49.737143-85.699048l-26.063238-21.820952-12.117334-10.581334-11.459047-9.825524c-37.229714-30.744381-64.804571-40.69181-100.205715-35.35238-24.283429 3.632762-38.278095 12.141714-63.073523 38.107428l-10.947048 11.654095c-18.041905 19.017143-28.330667 26.258286-43.544381 29.305905-22.25981 4.461714-44.373333-7.046095-80.262095-36.205714-46.250667-37.546667-84.626286-80.676571-117.613715-131.949714-22.869333-35.766857-31.890286-62.902857-24.941714-87.600762 2.82819-9.99619 9.679238-17.042286 24.064-28.184381l14.994286-11.312762 2.413714-1.877334 22.747429-18.553904c20.114286-16.822857 28.281905-28.281905 32.572952-45.836191 8.899048-36.10819 0.487619-66.072381-32.426667-117.638095l-15.62819-24.234667-5.558857-8.533333-6.436572-9.435429z" p-id="7921" fill="#d3d8d9"></path></svg> | 36 | <svg style="position: relative;top: 2px;" t="1711708779620" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="7920" width="20" height="20"><path d="M398.652952 165.692952c-32.280381-46.006857-58.172952-61.318095-92.867047-54.808381-14.969905 2.80381-24.210286 7.850667-41.20381 22.528l-12.946285 11.361524-25.185524 20.894476-6.582857 5.753905c-3.705905 3.413333-6.38781 6.217143-9.825524 10.118095-64 72.46019-81.724952 185.782857-44.470857 292.327619 26.794667 76.55619 74.605714 152.624762 142.774857 228.644572 72.289524 80.62781 133.046857 131.364571 202.922666 168.374857 54.857143 29.013333 96.865524 41.74019 145.676191 43.227429 59.001905 1.828571 110.957714-11.50781 153.648762-39.15581a162.133333 162.133333 0 0 0 19.553524-15.189333l8.289523-7.558095 16.335239-15.213715 5.534476-4.924952 10.922666-9.435429c22.040381-19.651048 29.184-31.939048 30.646858-51.370666 2.194286-29.647238-11.215238-52.736-49.737143-85.699048l-26.063238-21.820952-12.117334-10.581334-11.459047-9.825524c-37.229714-30.744381-64.804571-40.69181-100.205715-35.35238-24.283429 3.632762-38.278095 12.141714-63.073523 38.107428l-10.947048 11.654095c-18.041905 19.017143-28.330667 26.258286-43.544381 29.305905-22.25981 4.461714-44.373333-7.046095-80.262095-36.205714-46.250667-37.546667-84.626286-80.676571-117.613715-131.949714-22.869333-35.766857-31.890286-62.902857-24.941714-87.600762 2.82819-9.99619 9.679238-17.042286 24.064-28.184381l14.994286-11.312762 2.413714-1.877334 22.747429-18.553904c20.114286-16.822857 28.281905-28.281905 32.572952-45.836191 8.899048-36.10819 0.487619-66.072381-32.426667-117.638095l-15.62819-24.234667-5.558857-8.533333-6.436572-9.435429z" p-id="7921" fill="#d3d8d9"></path></svg> |
| 40 | Phone:</label>{{matchData.contactTelno}} | 37 | Phone:</label>086-{{matchData.contactTelno}} |
| 41 | </p> | 38 | </p> |
| 39 | </div> | ||
| 40 | |||
| 41 | <div v-if="matchData.type=='0'"> | ||
| 42 | <p class="ppl"><label>{{ language==0?'比赛时间':'Playing Time' }}:</label>{{matchData.beginTime?.slice(0,10)}} ~ {{matchData.endTime?.slice(0,10) }}</p> | ||
| 43 | <p class="ppl esp"><label>{{ language==0?'地    点':'Location' }}:</label>{{ matchData.address }}</p> | ||
| 44 | <p class="ppl"><label>{{language==0?'赛事级别':'Level'}}:</label>{{matchData.level}}</p> | ||
| 45 | <p class="ppl"><label>{{ language==0?'报名截止':'Registration Deadline' }}:</label>{{ matchData.signEndTime?.slice(0,10) }}</p> | ||
| 46 | <p class="ppl" v-if="matchData.contactPerson"><label>{{ language==0?'联系人员':'Contact Person' }}:</label>{{ matchData.contactPerson }}</p> | ||
| 47 | <p class="ppl"><label>{{ language==0?'联系电话':'Phone' }}:</label>086-{{ matchData.contactTelno }}</p> | ||
| 48 | <p class="ppl" v-if="matchData.contactEmail"><label>{{ language==0?'邮    箱':'E-mail' }}:</label>{{ matchData.contactEmail }}</p> | ||
| 49 | </div> | ||
| 50 | |||
| 51 | |||
| 42 | <div style="height: 30px"></div> | 52 | <div style="height: 30px"></div> |
| 43 | <div class="ppl_pb"> | 53 | <div class="ppl_pb"> |
| 44 | <el-link class="mr20" v-if="matchData.signKnowUrl" type="primary" :href="fillImgUrl(JSON.parse(matchData.signKnowUrl)[0]?.url)" target="_blank"> | 54 | <el-link class="mr20" v-if="matchData.signKnowUrl" type="primary" :href="fillImgUrl(JSON.parse(matchData.signKnowUrl)[0]?.url)" target="_blank"> | ... | ... |
| ... | @@ -63,16 +63,18 @@ | ... | @@ -63,16 +63,18 @@ |
| 63 | </el-col> | 63 | </el-col> |
| 64 | <el-col :lg="9" :md="12" :xl="12"> | 64 | <el-col :lg="9" :md="12" :xl="12"> |
| 65 | <div class="info"> | 65 | <div class="info"> |
| 66 | <h3>{{ n.name }}</h3> | 66 | <h3 class="esp">{{ n.name }}</h3> |
| 67 | <p class="ppl"><label>{{language==0?'赛事级别':'Level'}}:</label>{{n.level}}</p> | 67 | <p class="ppl"><label>{{language==0?'赛事级别':'Level'}}:</label>{{n.level}}</p> |
| 68 | <p class="ppl"><label>{{ language==0?'比赛时间':'Playing Time' }}:</label>{{n.beginTime?.slice(0,10)}} ~ {{ n.endTime?.slice(0,10) }}</p> | 68 | <p class="ppl esp"><label>{{ language==0?'比赛时间':'Playing Time' }}:</label>{{n.beginTime?.slice(0,10)}} ~ {{ n.endTime?.slice(0,10) }}</p> |
| 69 | <!-- <p class="ppl" v-if="n.address"><label>{{ language==0?'地    点':'Location' }}:</label>{{ n.address }}</p>--> | 69 | <!-- <p class="ppl" v-if="n.address"><label>{{ language==0?'地    点':'Location' }}:</label>{{ n.address }}</p>--> |
| 70 | <p class="ppl"><label>{{ language==0?'报名截止':'Registration Deadline' }}:</label>{{ n.signEndTime?.slice(0,10) }}</p> | 70 | <!-- <p class="ppl"><label>{{ language==0?'报名截止':'Registration Deadline' }}:</label>{{ n.signEndTime?.slice(0,10) }}</p>--> |
| 71 | |||
| 72 | <p class="ppl" v-if="n.contactPerson"><label>{{ language==0?'联系人员':'Contact Person' }}:</label>{{ n.contactPerson }}</p> | ||
| 73 | <p class="ppl"><label>{{ language==0?'联系电话':'Phone' }}:</label>{{ n.contactTelno }}</p> | ||
| 74 | <p class="ppl" v-if="n.contactEmail"><label>{{ language==0?'邮    箱':'E-mail' }}:</label>{{ n.contactEmail }}</p> | ||
| 75 | 71 | ||
| 72 | <p class="ppl"><label>{{ language==0?'联系人员':'Contact Person' }}:</label>{{ n.contactPerson }}</p> | ||
| 73 | <p class="ppl"><label>{{ language==0?'联系电话':'Phone' }}:</label>086-{{ n.contactTelno }}</p> | ||
| 74 | <p class="ppl esp"><label>{{ language==0?'邮    箱':'E-mail' }}:</label>{{ n.contactEmail }}</p> | ||
| 75 | <p class="ppl" v-if="n.type=='1'"> | ||
| 76 | <label>{{ language==0?'分站赛':'Station race' }}:</label>{{n.cpts?.length}} | ||
| 77 | </p> | ||
| 76 | </div> | 78 | </div> |
| 77 | </el-col> | 79 | </el-col> |
| 78 | <el-col :lg="8" :md="12" :xl="6"> | 80 | <el-col :lg="8" :md="12" :xl="6"> |
| ... | @@ -271,7 +273,7 @@ function goDetail(id) { | ... | @@ -271,7 +273,7 @@ function goDetail(id) { |
| 271 | left: 0; | 273 | left: 0; |
| 272 | } | 274 | } |
| 273 | .info h3{margin: 0 0 15px} | 275 | .info h3{margin: 0 0 15px} |
| 274 | .info .ppl{margin: 14px 0;} | 276 | .info .ppl{margin: 6px 0;} |
| 275 | .ppl{color: #29343C; | 277 | .ppl{color: #29343C; |
| 276 | label{color: #929AA0;} | 278 | label{color: #929AA0;} |
| 277 | } | 279 | } | ... | ... |
| ... | @@ -26,28 +26,33 @@ | ... | @@ -26,28 +26,33 @@ |
| 26 | <el-form-item :label="language==0?'参赛队名称':'Name of participating team'" required prop="abreviations"> | 26 | <el-form-item :label="language==0?'参赛队名称':'Name of participating team'" required prop="abreviations"> |
| 27 | <el-input type="text" v-model="form.abreviations" :placeholder="language==0?'请输入内容':''"/> | 27 | <el-input type="text" v-model="form.abreviations" :placeholder="language==0?'请输入内容':''"/> |
| 28 | </el-form-item> | 28 | </el-form-item> |
| 29 | <el-form-item :label="language==0?'团体名称':'Team Name'" prop="name"> | 29 | <el-form-item :label="language==0?'团体名称':'Institution Name'" prop="name"> |
| 30 | <el-input v-model="form.name" :placeholder="language==0?'请输入团体名称':''" /> | 30 | <el-input v-model="form.name" :placeholder="language==0?'请输入团体名称':''" /> |
| 31 | </el-form-item> | 31 | </el-form-item> |
| 32 | <el-form-item :label="language==0?'所属国家/地区':'Country'" required> | ||
| 33 | <el-select filterable v-model="form.countryId"> | ||
| 34 | <el-option v-for="item in countryList" :key="item.id" :label="language==0?item.name:item.enName" :value="item.id" /> | ||
| 35 | </el-select> | ||
| 36 | </el-form-item> | ||
| 32 | <el-form-item :label="language==0?'负责人姓名':'Contact Person'" prop="contactPerson"> | 37 | <el-form-item :label="language==0?'负责人姓名':'Contact Person'" prop="contactPerson"> |
| 33 | <el-input v-model="form.contactPerson" :placeholder="language==0?'请输入联系人':''" /> | 38 | <el-input v-model="form.contactPerson" :placeholder="language==0?'请输入联系人':''" /> |
| 34 | </el-form-item> | 39 | </el-form-item> |
| 35 | <el-form-item :label="language==0?'邮箱':'Email'" required prop="contactEmail"> | 40 | <el-form-item :label="language==0?'邮箱':'Email'" required prop="contactEmail"> |
| 36 | <el-input v-model="form.contactEmail" type="email" :placeholder="language==0?'请输入内容':''"/> | 41 | <el-input v-model="form.contactEmail" type="email" :placeholder="language==0?'请输入内容':''"/> |
| 37 | </el-form-item> | 42 | </el-form-item> |
| 38 | <el-form-item :label="language==0?'专业/业余':'Professional/Amateur'" required prop="majorFlag"> | 43 | <!-- <el-form-item :label="language==0?'专业/业余':'Professional/Amateur'" required prop="majorFlag">--> |
| 39 | <el-select v-model="form.majorFlag"> | 44 | <!-- <el-select v-model="form.majorFlag">--> |
| 40 | <el-option :label="language==0?'专业':'Professional'" value="1" /> | 45 | <!-- <el-option :label="language==0?'专业':'Professional'" value="1" />--> |
| 41 | <el-option :label="language==0?'业余':'Amateur'" value="0" /> | 46 | <!-- <el-option :label="language==0?'业余':'Amateur'" value="0" />--> |
| 42 | </el-select> | 47 | <!-- </el-select>--> |
| 43 | </el-form-item> | 48 | <!-- </el-form-item>--> |
| 44 | <el-form-item :label="language==0?'团体类型':'Group type'" prop="type"> | 49 | <el-form-item :label="language==0?'团体类型':'Group type'" prop="type"> |
| 45 | <el-select v-model="form.type" :placeholder="typeOptions[language].selectPlaceholder" style="width: 100%;"> | 50 | <el-select :disabled="language==1" v-model="form.type" :placeholder="typeOptions[language].selectPlaceholder" style="width: 100%;"> |
| 46 | <el-option v-for="(o,index) in typeOptions[language].options" :label="o.text" | 51 | <el-option v-for="(o,index) in typeOptions[language].options" :label="o.text" |
| 47 | :key="index" :value="o.value" /> | 52 | :key="index" :value="o.value" /> |
| 48 | </el-select> | 53 | </el-select> |
| 49 | </el-form-item> | 54 | </el-form-item> |
| 50 | <el-form-item :label="language==0?'详细地址':'Detailed Address'" required prop="address"> | 55 | <el-form-item :label="language==0?'详细地址':'Detailed Address'" prop="address"> |
| 51 | <el-input type="textarea" v-model="form.address" class="mt10" :placeholder="language==0?'请输入详细地址':''"/> | 56 | <el-input type="textarea" v-model="form.address" class="mt10" :placeholder="language==0?'请输入详细地址':''"/> |
| 52 | </el-form-item> | 57 | </el-form-item> |
| 53 | </el-col> | 58 | </el-col> |
| ... | @@ -67,7 +72,6 @@ | ... | @@ -67,7 +72,6 @@ |
| 67 | <ImageUpload v-if="s.type == '3'" v-model="s.value" :limit="1" :is-show-tip="false" /> | 72 | <ImageUpload v-if="s.type == '3'" v-model="s.value" :limit="1" :is-show-tip="false" /> |
| 68 | <!-- 文件 2--> | 73 | <!-- 文件 2--> |
| 69 | <FileUpload v-if="s.type == '2'" :button-text="language==0?'上传文件':'Upload file'" :is-show-tip="false" v-model="s.fixWxFile" :action="uploadUrl" :accept="accept" /> | 74 | <FileUpload v-if="s.type == '2'" :button-text="language==0?'上传文件':'Upload file'" :is-show-tip="false" v-model="s.fixWxFile" :action="uploadUrl" :accept="accept" /> |
| 70 | |||
| 71 | </el-form-item> | 75 | </el-form-item> |
| 72 | </el-col> | 76 | </el-col> |
| 73 | </el-row> | 77 | </el-row> |
| ... | @@ -135,6 +139,7 @@ const data = reactive({ | ... | @@ -135,6 +139,7 @@ const data = reactive({ |
| 135 | cptId: route.query.matchId||0, | 139 | cptId: route.query.matchId||0, |
| 136 | signType: false, | 140 | signType: false, |
| 137 | regionsList: [], | 141 | regionsList: [], |
| 142 | countryList: [], | ||
| 138 | participantsInfoArr: [], | 143 | participantsInfoArr: [], |
| 139 | rankList: [], | 144 | rankList: [], |
| 140 | accept: '.doc, .pdf, .docx, .zip', | 145 | accept: '.doc, .pdf, .docx, .zip', |
| ... | @@ -154,7 +159,7 @@ const data = reactive({ | ... | @@ -154,7 +159,7 @@ const data = reactive({ |
| 154 | contactPerson: { required: true, message: 'required', trigger: 'blur' }, | 159 | contactPerson: { required: true, message: 'required', trigger: 'blur' }, |
| 155 | contactEmail: { required: true, message: 'required', trigger: 'blur' }, | 160 | contactEmail: { required: true, message: 'required', trigger: 'blur' }, |
| 156 | abreviations: { required: true, message: 'required', trigger: 'blur' }, | 161 | abreviations: { required: true, message: 'required', trigger: 'blur' }, |
| 157 | address: { required: true, message: 'required', trigger: 'blur' } | 162 | // address: { required: true, message: 'required', trigger: 'blur' } |
| 158 | }, | 163 | }, |
| 159 | coachOrLeaderFlag: '', | 164 | coachOrLeaderFlag: '', |
| 160 | matchInfo:{} | 165 | matchInfo:{} |
| ... | @@ -168,7 +173,7 @@ const { | ... | @@ -168,7 +173,7 @@ const { |
| 168 | participantsInfoArr, | 173 | participantsInfoArr, |
| 169 | cptId, | 174 | cptId, |
| 170 | rules,rules_en, | 175 | rules,rules_en, |
| 171 | regionsList,matchInfo, | 176 | regionsList,countryList,matchInfo, |
| 172 | coachOrLeaderFlag, accept,typeOptions | 177 | coachOrLeaderFlag, accept,typeOptions |
| 173 | } = toRefs(data) | 178 | } = toRefs(data) |
| 174 | const uploadUrl = ref('/upload/upLoadToFileServer') | 179 | const uploadUrl = ref('/upload/upLoadToFileServer') |
| ... | @@ -180,6 +185,7 @@ onMounted(() => { | ... | @@ -180,6 +185,7 @@ onMounted(() => { |
| 180 | signType.value = route.query.signType | 185 | signType.value = route.query.signType |
| 181 | 186 | ||
| 182 | getRegionsList() | 187 | getRegionsList() |
| 188 | getCountryList() | ||
| 183 | match.getMatchById({ id: cptId.value }).then(res => { | 189 | match.getMatchById({ id: cptId.value }).then(res => { |
| 184 | coachOrLeaderFlag.value = res.data.coachOrLeaderFlag | 190 | coachOrLeaderFlag.value = res.data.coachOrLeaderFlag |
| 185 | matchInfo.value = res.data | 191 | matchInfo.value = res.data |
| ... | @@ -219,10 +225,20 @@ function getRegionsList() { | ... | @@ -219,10 +225,20 @@ function getRegionsList() { |
| 219 | regionsList.value = res.data | 225 | regionsList.value = res.data |
| 220 | }) | 226 | }) |
| 221 | } | 227 | } |
| 222 | 228 | function getCountryList() { | |
| 229 | match.countryList().then(res => { | ||
| 230 | countryList.value = res.data | ||
| 231 | }) | ||
| 232 | } | ||
| 223 | function getGroupInfo() { | 233 | function getGroupInfo() { |
| 224 | match.getGroupInfo().then(res => { | 234 | match.getGroupInfo().then(res => { |
| 225 | form.value = res.data | 235 | form.value = res.data |
| 236 | if(language.value == 1){ | ||
| 237 | form.value.type = '4' | ||
| 238 | } | ||
| 239 | }).catch(err => { | ||
| 240 | router.push({name: 'home'}) | ||
| 241 | return | ||
| 226 | }) | 242 | }) |
| 227 | } | 243 | } |
| 228 | 244 | ... | ... |
src/viewsPc/match/teamSign_bak.vue
0 → 100644
| 1 | <template> | ||
| 2 | <div class="app-container"> | ||
| 3 | |||
| 4 | <div class="box ph-30"> | ||
| 5 | <el-card> | ||
| 6 | <team-sign-step :language="language" :active-step="0"/> | ||
| 7 | </el-card> | ||
| 8 | <div class="h20"></div> | ||
| 9 | <div class="panel" style="box-shadow: var(--el-box-shadow)"> | ||
| 10 | <match-info-row :match-id="cptId" :language="language"/> | ||
| 11 | <div class="h20"></div> | ||
| 12 | <el-form ref="ruleFormRef" label-width="120px" class="signForm" | ||
| 13 | :model="form" :rules="language==0?rules:rules_en" | ||
| 14 | :label-position="language==0?'left':'top'"> | ||
| 15 | <el-row> | ||
| 16 | <el-col :lg="8" :offset="2"> | ||
| 17 | <el-form-item :label="language==0?'团体Logo':'Group Logo'" prop="imgUrl"> | ||
| 18 | <ImageUpload2 v-model="form.imgUrl" :is-show-tip="false" :crop-width="200" :crop-height="200" :limit="1"/> | ||
| 19 | <span class="tip" v-if="language==0">请上传不超过 <i>5M</i> 的文件 格式为 <i>png/jpg/jpeg</i> 的文件</span> | ||
| 20 | <span class="tip" v-else>Please upload a file in the format of | ||
| 21 | <i>png/jpg/jpeg</i> that does not exceed <i>5MB</i> | ||
| 22 | </span> | ||
| 23 | </el-form-item> | ||
| 24 | </el-col> | ||
| 25 | <el-col :lg="10"> | ||
| 26 | <el-form-item :label="language==0?'参赛队名称':'Name of participating team'" required prop="abreviations"> | ||
| 27 | <el-input type="text" v-model="form.abreviations" :placeholder="language==0?'请输入内容':''"/> | ||
| 28 | </el-form-item> | ||
| 29 | <el-form-item :label="language==0?'团体名称':'Team Name'" prop="name"> | ||
| 30 | <el-input v-model="form.name" :placeholder="language==0?'请输入团体名称':''" /> | ||
| 31 | </el-form-item> | ||
| 32 | <el-form-item :label="language==0?'所属国家/地区':'Country'" required> | ||
| 33 | <el-select filterable v-model="form.countryId"> | ||
| 34 | <el-option v-for="item in countryList" :key="item.id" :label="language==0?item.name:item.enName" :value="item.id" /> | ||
| 35 | </el-select> | ||
| 36 | </el-form-item> | ||
| 37 | <el-form-item :label="language==0?'负责人姓名':'Contact Person'" prop="contactPerson"> | ||
| 38 | <el-input v-model="form.contactPerson" :placeholder="language==0?'请输入联系人':''" /> | ||
| 39 | </el-form-item> | ||
| 40 | <el-form-item :label="language==0?'邮箱':'Email'" required prop="contactEmail"> | ||
| 41 | <el-input v-model="form.contactEmail" type="email" :placeholder="language==0?'请输入内容':''"/> | ||
| 42 | </el-form-item> | ||
| 43 | <!-- <el-form-item :label="language==0?'专业/业余':'Professional/Amateur'" required prop="majorFlag">--> | ||
| 44 | <!-- <el-select v-model="form.majorFlag">--> | ||
| 45 | <!-- <el-option :label="language==0?'专业':'Professional'" value="1" />--> | ||
| 46 | <!-- <el-option :label="language==0?'业余':'Amateur'" value="0" />--> | ||
| 47 | <!-- </el-select>--> | ||
| 48 | <!-- </el-form-item>--> | ||
| 49 | <el-form-item :label="language==0?'团体类型':'Group type'" prop="type"> | ||
| 50 | <el-select :disabled="language==1" v-model="form.type" :placeholder="typeOptions[language].selectPlaceholder" style="width: 100%;"> | ||
| 51 | <el-option v-for="(o,index) in typeOptions[language].options" :label="o.text" | ||
| 52 | :key="index" :value="o.value" /> | ||
| 53 | </el-select> | ||
| 54 | </el-form-item> | ||
| 55 | <el-form-item :label="language==0?'详细地址':'Detailed Address'" prop="address"> | ||
| 56 | <el-input type="textarea" v-model="form.address" class="mt10" :placeholder="language==0?'请输入详细地址':''"/> | ||
| 57 | </el-form-item> | ||
| 58 | </el-col> | ||
| 59 | </el-row> | ||
| 60 | <el-row v-if="participantsInfoArr&&participantsInfoArr.length>0"> | ||
| 61 | <el-col :span="16" :offset="4"> | ||
| 62 | <h3>{{ language==0?'补充信息':'Supplemental information'}}</h3> | ||
| 63 | <el-form-item v-for="(s,index) in participantsInfoArr" :key="index"> | ||
| 64 | <template #label> | ||
| 65 | <span v-if="s.status == 0" class="red">*</span>{{ s.name }} | ||
| 66 | </template> | ||
| 67 | <el-input v-if="s.type == '0'" v-model="s.value" /> | ||
| 68 | <el-input v-if="s.type == '1'" v-model="s.value" type="number" /> | ||
| 69 | <el-select v-if="s.type == '4'" v-model="s.value" class="m-2"> | ||
| 70 | <el-option v-for="item in s.option" :key="item.id" :label="item.name" :value="item.name" /> | ||
| 71 | </el-select> | ||
| 72 | <ImageUpload v-if="s.type == '3'" v-model="s.value" :limit="1" :is-show-tip="false" /> | ||
| 73 | <!-- 文件 2--> | ||
| 74 | <FileUpload v-if="s.type == '2'" :button-text="language==0?'上传文件':'Upload file'" :is-show-tip="false" v-model="s.fixWxFile" :action="uploadUrl" :accept="accept" /> | ||
| 75 | |||
| 76 | </el-form-item> | ||
| 77 | </el-col> | ||
| 78 | </el-row> | ||
| 79 | </el-form> | ||
| 80 | |||
| 81 | |||
| 82 | <div class="panel-footer text-center"> | ||
| 83 | <el-button type="primary" class="btn-lineG w200px" round @click="submitForm()"> | ||
| 84 | {{ language==0?'下一步':'NEXT' }} | ||
| 85 | </el-button> | ||
| 86 | </div> | ||
| 87 | </div> | ||
| 88 | </div> | ||
| 89 | |||
| 90 | </div> | ||
| 91 | </template> | ||
| 92 | |||
| 93 | <script setup> | ||
| 94 | import { reactive, ref } from 'vue' | ||
| 95 | import { getCurrentInstance, onMounted } from '@vue/runtime-core' | ||
| 96 | import { useRoute, useRouter } from 'vue-router' | ||
| 97 | import { toRefs } from '@vueuse/shared' | ||
| 98 | import TeamSignStep from './components/teamSignStep' | ||
| 99 | import MatchInfoRow from "@/viewsPc/match/components/matchInfo-row"; | ||
| 100 | |||
| 101 | const language= useStorage('language',0) | ||
| 102 | |||
| 103 | const { proxy } = getCurrentInstance() | ||
| 104 | const router = useRouter() | ||
| 105 | const route = useRoute() | ||
| 106 | import * as match from '@/apiPc/match' | ||
| 107 | import { ElMessage } from 'element-plus' | ||
| 108 | import _ from 'lodash' | ||
| 109 | import {useStorage} from "@vueuse/core/index"; | ||
| 110 | |||
| 111 | const data = reactive({ | ||
| 112 | isRanks: false, | ||
| 113 | matchData:{ | ||
| 114 | enBo:{} | ||
| 115 | }, | ||
| 116 | form: {}, | ||
| 117 | typeOptions: { | ||
| 118 | 0: { | ||
| 119 | selectPlaceholder: '请选择团体类型', | ||
| 120 | options: [ | ||
| 121 | {value:'0',text:'普通院校'}, | ||
| 122 | {value:'1',text:'专业舞蹈学校'}, | ||
| 123 | {value:'2',text:'培训机构/俱乐部'}, | ||
| 124 | {value:'3',text:'地方协会'}, | ||
| 125 | {value:'4',text:'国家协会'}, | ||
| 126 | ] | ||
| 127 | }, | ||
| 128 | 1: { | ||
| 129 | selectPlaceholder: 'Please select group type', | ||
| 130 | options: [ | ||
| 131 | {value:'0',text:'School'}, | ||
| 132 | {value:'1',text:'Professional dance school'}, | ||
| 133 | {value:'2',text:'Company/Club'}, | ||
| 134 | {value:'3',text:'Local Association'}, | ||
| 135 | {value:'4',text:'National Association'}, | ||
| 136 | ] | ||
| 137 | } | ||
| 138 | }, | ||
| 139 | groupId: route.query.groupId||0, | ||
| 140 | cptId: route.query.matchId||0, | ||
| 141 | signType: false, | ||
| 142 | regionsList: [], | ||
| 143 | countryList: [], | ||
| 144 | participantsInfoArr: [], | ||
| 145 | rankList: [], | ||
| 146 | accept: '.doc, .pdf, .docx, .zip', | ||
| 147 | rules: { | ||
| 148 | imgUrl: { required: true, message: '请上传', trigger: 'blur' }, | ||
| 149 | name: { required: true, message: '请填写', trigger: 'blur' }, | ||
| 150 | type: { required: true, message: '请选择', trigger: 'change' }, | ||
| 151 | contactPerson: { required: true, message: '请填写内容', trigger: 'blur' }, | ||
| 152 | contactEmail: { required: true, message: '请填写内容', trigger: 'blur' }, | ||
| 153 | abreviations: { required: true, message: '请填写内容', trigger: 'blur' }, | ||
| 154 | address: { required: true, message: '请填写内容', trigger: 'blur' } | ||
| 155 | }, | ||
| 156 | rules_en: { | ||
| 157 | imgUrl: { required: true, message: 'required', trigger: 'blur' }, | ||
| 158 | name: { required: true, message: 'required', trigger: 'blur' }, | ||
| 159 | type: { required: true, message: 'required', trigger: 'change' }, | ||
| 160 | contactPerson: { required: true, message: 'required', trigger: 'blur' }, | ||
| 161 | contactEmail: { required: true, message: 'required', trigger: 'blur' }, | ||
| 162 | abreviations: { required: true, message: 'required', trigger: 'blur' }, | ||
| 163 | address: { required: true, message: 'required', trigger: 'blur' } | ||
| 164 | }, | ||
| 165 | coachOrLeaderFlag: '', | ||
| 166 | matchInfo:{} | ||
| 167 | }) | ||
| 168 | const { | ||
| 169 | isRanks,matchData, | ||
| 170 | rankList, | ||
| 171 | form, | ||
| 172 | groupId, | ||
| 173 | signType, | ||
| 174 | participantsInfoArr, | ||
| 175 | cptId, | ||
| 176 | rules,rules_en, | ||
| 177 | regionsList,countryList,matchInfo, | ||
| 178 | coachOrLeaderFlag, accept,typeOptions | ||
| 179 | } = toRefs(data) | ||
| 180 | const uploadUrl = ref('/upload/upLoadToFileServer') | ||
| 181 | |||
| 182 | onMounted(() => { | ||
| 183 | console.log(cptId.value,route.query,route.params) | ||
| 184 | // 获取团体信息 | ||
| 185 | getGroupInfo() | ||
| 186 | signType.value = route.query.signType | ||
| 187 | |||
| 188 | getRegionsList() | ||
| 189 | match.getMatchById({ id: cptId.value }).then(res => { | ||
| 190 | coachOrLeaderFlag.value = res.data.coachOrLeaderFlag | ||
| 191 | matchInfo.value = res.data | ||
| 192 | if (res.data.groupInfo) { | ||
| 193 | participantsInfoArr.value = JSON.parse(res.data.groupInfo) | ||
| 194 | } | ||
| 195 | |||
| 196 | // 获取补充信息 | ||
| 197 | match.getMyGroupForCpt(groupId.value, cptId.value).then(res => { | ||
| 198 | if (res.data.groupInfo && res.data.groupInfo.groupInfo) { | ||
| 199 | const groupInfo = JSON.parse(res.data.groupInfo.groupInfo) | ||
| 200 | if (groupInfo.length > 0) { | ||
| 201 | // 补充字段信息 | ||
| 202 | participantsInfoArr.value = groupInfo | ||
| 203 | for (var n of participantsInfoArr.value) { | ||
| 204 | if (n.type == '3' && n.value.url) { | ||
| 205 | // 图片 | ||
| 206 | n.value = n.value.url | ||
| 207 | } | ||
| 208 | if (n.type == '2') { | ||
| 209 | // 文件 | ||
| 210 | var arr = [{ | ||
| 211 | name: n.value.name, | ||
| 212 | url: n.value.url | ||
| 213 | }] | ||
| 214 | n.fixWxFile = arr | ||
| 215 | } | ||
| 216 | } | ||
| 217 | } | ||
| 218 | } | ||
| 219 | }) | ||
| 220 | }) | ||
| 221 | }) | ||
| 222 | |||
| 223 | function getRegionsList() { | ||
| 224 | match.regionsList().then(res => { | ||
| 225 | regionsList.value = res.data | ||
| 226 | }) | ||
| 227 | } | ||
| 228 | function getCountryList() { | ||
| 229 | match.countryList().then(res => { | ||
| 230 | countryList.value = res.data | ||
| 231 | }) | ||
| 232 | } | ||
| 233 | function getGroupInfo() { | ||
| 234 | match.getGroupInfo().then(res => { | ||
| 235 | form.value = res.data | ||
| 236 | if(language.value == 1){ | ||
| 237 | form.value.type = '4' | ||
| 238 | } | ||
| 239 | }).catch(err => { | ||
| 240 | router.push({name: 'home'}) | ||
| 241 | return | ||
| 242 | }) | ||
| 243 | } | ||
| 244 | |||
| 245 | function getTeamList() { | ||
| 246 | return match.getMyTeamList(cptId.value, groupId.value).then(response => { | ||
| 247 | rankList.value = response.data | ||
| 248 | }) | ||
| 249 | } | ||
| 250 | |||
| 251 | function goPrev() { | ||
| 252 | router.go(-1) | ||
| 253 | } | ||
| 254 | |||
| 255 | function submitForm() { | ||
| 256 | proxy.$refs['ruleFormRef'].validate((valid, fields) => { | ||
| 257 | if (valid) { | ||
| 258 | console.log(form.value) | ||
| 259 | for (const n of participantsInfoArr.value) { | ||
| 260 | if (n.status == 0 && (!n.value && (!n.fixWxFile||n.fixWxFile.length==0))) { | ||
| 261 | ElMessage.warning(language.value==0?`请完善${n.name}信息`:`Please complete ${n.name} information`) | ||
| 262 | return | ||
| 263 | } | ||
| 264 | } | ||
| 265 | |||
| 266 | if (participantsInfoArr.value.length>0) { | ||
| 267 | // 保存补充信息 | ||
| 268 | let fileInfo = {} | ||
| 269 | for (var p of participantsInfoArr.value) { | ||
| 270 | if (p.type == '2' && p.fixWxFile) { | ||
| 271 | console.log(p.fixWxFile) | ||
| 272 | const temp = p.fixWxFile[0]?.name.split('.') | ||
| 273 | fileInfo = { | ||
| 274 | url: p.fixWxFile[0].url, | ||
| 275 | name: p.fixWxFile[0].name, | ||
| 276 | extname: temp[temp.length - 1] | ||
| 277 | } | ||
| 278 | p.value = fileInfo | ||
| 279 | } | ||
| 280 | } | ||
| 281 | const obj = { | ||
| 282 | cptId: cptId.value, | ||
| 283 | groupId: groupId.value, | ||
| 284 | groupInfo: JSON.stringify(participantsInfoArr.value) | ||
| 285 | } | ||
| 286 | match.saveMyGroupExtraInfo(obj).then(res => { | ||
| 287 | |||
| 288 | }) | ||
| 289 | } | ||
| 290 | // 保存团体信息 | ||
| 291 | form.value.cptId = cptId.value | ||
| 292 | form.value.groupId = groupId.value | ||
| 293 | match.saveMyGroupForCpt(form.value).then(res => { | ||
| 294 | goNext() | ||
| 295 | }) | ||
| 296 | } else { | ||
| 297 | console.log(form.value, fields) | ||
| 298 | } | ||
| 299 | }) | ||
| 300 | } | ||
| 301 | |||
| 302 | function goNext() { | ||
| 303 | // 选教练 | ||
| 304 | router.push({ | ||
| 305 | name: `chooseCoach`, | ||
| 306 | query: { | ||
| 307 | matchId: cptId.value, | ||
| 308 | groupId: groupId.value, | ||
| 309 | signType: signType.value | ||
| 310 | } | ||
| 311 | }) | ||
| 312 | } | ||
| 313 | </script> | ||
| 314 | |||
| 315 | <style scoped lang="scss"> | ||
| 316 | .app-container { | ||
| 317 | padding: 0; | ||
| 318 | background: #F5F7F9; | ||
| 319 | } | ||
| 320 | |||
| 321 | .panel-footer .el-button--success { | ||
| 322 | padding: 0 40px; | ||
| 323 | } | ||
| 324 | .bili43{ | ||
| 325 | :deep(.fileItem) { | ||
| 326 | width: 200px; | ||
| 327 | height: 150px; | ||
| 328 | } | ||
| 329 | |||
| 330 | .el-upload-list--picture-card .el-upload-list__item { | ||
| 331 | width: 200px; | ||
| 332 | height: 150px; | ||
| 333 | } | ||
| 334 | } | ||
| 335 | .signForm { | ||
| 336 | .el-form-item__label { | ||
| 337 | color: #4C5359; | ||
| 338 | } | ||
| 339 | } | ||
| 340 | |||
| 341 | .tip { | ||
| 342 | font-size: 13px; | ||
| 343 | color: #999; | ||
| 344 | margin: 10px 0; | ||
| 345 | |||
| 346 | i { | ||
| 347 | color: red;font-style: normal; | ||
| 348 | margin: 0 4px 0 0; | ||
| 349 | } | ||
| 350 | } | ||
| 351 | |||
| 352 | .threeFour { | ||
| 353 | width: 100%; | ||
| 354 | } | ||
| 355 | |||
| 356 | :deep(.el-upload--picture-card) { | ||
| 357 | width: 120px; | ||
| 358 | height: 120px; | ||
| 359 | } | ||
| 360 | |||
| 361 | :deep(.el-upload-list--picture-card .el-upload-list__item) { | ||
| 362 | width: 120px; | ||
| 363 | height: 120px; | ||
| 364 | } | ||
| 365 | |||
| 366 | .red { | ||
| 367 | color: #f56c6c; | ||
| 368 | } | ||
| 369 | </style> |
| ... | @@ -2,8 +2,8 @@ | ... | @@ -2,8 +2,8 @@ |
| 2 | <div> | 2 | <div> |
| 3 | <div class="box"> | 3 | <div class="box"> |
| 4 | <div class="indexTitle"> | 4 | <div class="indexTitle"> |
| 5 | <h3 class="leftboderTT">Asian Games News</h3> | 5 | <h3 class="leftboderTT">Games News</h3> |
| 6 | <a class="more" @click="goList(query1.sortId,'Asian Games News')">MORE</a> | 6 | <a class="more" @click="goList(query1.sortId,'Games News')">MORE</a> |
| 7 | </div> | 7 | </div> |
| 8 | <el-card> | 8 | <el-card> |
| 9 | <el-row class="topNews" :gutter="20"> | 9 | <el-row class="topNews" :gutter="20"> | ... | ... |
| ... | @@ -9,7 +9,7 @@ | ... | @@ -9,7 +9,7 @@ |
| 9 | <div class="pt30"> | 9 | <div class="pt30"> |
| 10 | <el-form ref="wdsfDataRef" class="d-form" size="large" :label-width="language==0?120:180" | 10 | <el-form ref="wdsfDataRef" class="d-form" size="large" :label-width="language==0?120:180" |
| 11 | style="max-width: 560px;margin: auto" :rules="wdsfDataRule"> | 11 | style="max-width: 560px;margin: auto" :rules="wdsfDataRule"> |
| 12 | <el-form-item :label="language==0?'WDSF卡号':'WDSF ID'" required> | 12 | <el-form-item :label="language==0?'WDSF会员号':'WDSF MIN'" required> |
| 13 | <el-input type="text" v-model="form.card" @change="resetCode(0)" @blur="verifyCode"> | 13 | <el-input type="text" v-model="form.card" @change="resetCode(0)" @blur="verifyCode"> |
| 14 | <template #append> | 14 | <template #append> |
| 15 | <el-button type="primary" plain style="width: 110px" @click="checkCard"> | 15 | <el-button type="primary" plain style="width: 110px" @click="checkCard"> |
| ... | @@ -27,22 +27,22 @@ | ... | @@ -27,22 +27,22 @@ |
| 27 | <span v-else>(Obtain automatically according to the WDSF number)</span> | 27 | <span v-else>(Obtain automatically according to the WDSF number)</span> |
| 28 | </div> | 28 | </div> |
| 29 | <div class="h20"></div> | 29 | <div class="h20"></div> |
| 30 | <el-form-item :label="language==0?'姓氏':'surname'"> | 30 | <el-form-item :label="language==0?'姓氏':'Surname'"> |
| 31 | <el-input v-model="wdsfData.surname" disabled/> | 31 | <el-input v-model="wdsfData.surname" disabled/> |
| 32 | </el-form-item> | 32 | </el-form-item> |
| 33 | <el-form-item :label="language==0?'名':'name'"> | 33 | <el-form-item :label="language==0?'名':'Name'"> |
| 34 | <el-input v-model="wdsfData.name" disabled/> | 34 | <el-input v-model="wdsfData.name" disabled/> |
| 35 | </el-form-item> | 35 | </el-form-item> |
| 36 | <el-form-item label="Representing"> | 36 | <el-form-item :label="language==0?'代表':'Representing'"> |
| 37 | <el-input v-model="wdsfData.representing" disabled/> | 37 | <el-input v-model="wdsfData.representing" disabled/> |
| 38 | </el-form-item> | 38 | </el-form-item> |
| 39 | <el-form-item label="Age group"> | 39 | <el-form-item :label="language==1?'Age group':'年龄组'"> |
| 40 | <el-input v-model="wdsfData.ageGroup" disabled/> | 40 | <el-input v-model="wdsfData.ageGroup" disabled/> |
| 41 | </el-form-item> | 41 | </el-form-item> |
| 42 | <el-form-item label="Division"> | 42 | <el-form-item :label="language==1?'舞种':'Division'"> |
| 43 | <el-input v-model="wdsfData.division" disabled/> | 43 | <el-input v-model="wdsfData.division" disabled/> |
| 44 | </el-form-item> | 44 | </el-form-item> |
| 45 | <el-form-item label="Status"> | 45 | <el-form-item :label="language==1?'状态':'Status'"> |
| 46 | <el-input v-model="wdsfData.status" disabled/> | 46 | <el-input v-model="wdsfData.status" disabled/> |
| 47 | </el-form-item> | 47 | </el-form-item> |
| 48 | <div class="h30"></div> | 48 | <div class="h30"></div> |
| ... | @@ -50,33 +50,36 @@ | ... | @@ -50,33 +50,36 @@ |
| 50 | {{ language == 0 ? '补充信息' : 'Supplementary Information' }} | 50 | {{ language == 0 ? '补充信息' : 'Supplementary Information' }} |
| 51 | </div> | 51 | </div> |
| 52 | <div class="h20"></div> | 52 | <div class="h20"></div> |
| 53 | <el-form-item prop="picUrl" :label="language==0?'个人照片':'photo'" required> | 53 | <el-form-item prop="picUrl" :label="language==0?'个人照片':'Photo'"> |
| 54 | <ImageUpload2 | 54 | <ImageUpload2 |
| 55 | v-model="wdsfData.picUrl" :crop-height="280" :crop-width="200" class="threeFour" :limit="1" | 55 | v-model="wdsfData.picUrl" :crop-height="280" :crop-width="200" class="threeFour" :limit="1" |
| 56 | :is-show-tip="false" | 56 | :is-show-tip="false" |
| 57 | /> | 57 | /> |
| 58 | </el-form-item> | 58 | </el-form-item> |
| 59 | 59 | ||
| 60 | <el-form-item :label="language==0?'性别':'Sex'" required> | 60 | <el-form-item :label="language==0?'性别':'Gender'" required> |
| 61 | <el-radio-group v-model="wdsfData.sex"> | 61 | <el-radio-group v-model="wdsfData.sex"> |
| 62 | <el-radio value="0">{{ language == 0 ? '女' : 'female' }}</el-radio> | 62 | <el-radio value="0">{{ language == 0 ? '女' : 'female' }}</el-radio> |
| 63 | <el-radio value="1">{{ language == 0 ? '男' : 'male' }}</el-radio> | 63 | <el-radio value="1">{{ language == 0 ? '男' : 'male' }}</el-radio> |
| 64 | </el-radio-group> | 64 | </el-radio-group> |
| 65 | </el-form-item> | 65 | </el-form-item> |
| 66 | 66 | <el-form-item :label="language==0?'证件号':'Passport number'" required> | |
| 67 | <el-form-item :label="language==0?'出生日期':'Birthday'" required> | 67 | <el-input v-model="wdsfData.passportNumber"/> |
| 68 | </el-form-item> | ||
| 69 | <el-form-item :label="language==0?'有效证件':'Passport File'" required> | ||
| 70 | <file-upload v-model="wdsfData.passportUrl" :limit="1" :is-show-tip="false" :button-text="'Upload'"/> | ||
| 71 | <div class="tip"> | ||
| 72 | <span>用途</span> | ||
| 73 | </div> | ||
| 74 | </el-form-item> | ||
| 75 | <el-form-item :label="language==0?'出生日期':'Birthday'"> | ||
| 68 | <el-date-picker | 76 | <el-date-picker |
| 69 | v-model="wdsfData.birthday" | 77 | v-model="wdsfData.birthday" |
| 70 | style="width: 100%;" | 78 | style="width: 100%;" |
| 71 | type="date" format="YYYY-MM-DD" value-format="YYYY-MM-DD" | 79 | type="date" format="YYYY-MM-DD" value-format="YYYY-MM-DD" |
| 72 | /> | 80 | /> |
| 73 | </el-form-item> | 81 | </el-form-item> |
| 74 | <el-form-item label="Passport number" required> | 82 | |
| 75 | <el-input v-model="wdsfData.passportNumber"/> | ||
| 76 | </el-form-item> | ||
| 77 | <el-form-item label="Passport File" required> | ||
| 78 | <file-upload v-model="wdsfData.passportUrl" :limit="1" :is-show-tip="false" :button-text="'Upload'"/> | ||
| 79 | </el-form-item> | ||
| 80 | 83 | ||
| 81 | 84 | ||
| 82 | <div class="h30"></div> | 85 | <div class="h30"></div> |
| ... | @@ -121,9 +124,8 @@ | ... | @@ -121,9 +124,8 @@ |
| 121 | v-if="wdsfData.personFlag=='0'"> | 124 | v-if="wdsfData.personFlag=='0'"> |
| 122 | <el-input type="password" show-password v-model="form.confirmPassword" autocomplete="false" @change="vconfirmPassword" | 125 | <el-input type="password" show-password v-model="form.confirmPassword" autocomplete="false" @change="vconfirmPassword" |
| 123 | :placeholder="language==0?'再次输入密码':'Confirm Password'"/> | 126 | :placeholder="language==0?'再次输入密码':'Confirm Password'"/> |
| 124 | <div class="text-danger" v-if="showError">{{ | 127 | <div class="text-danger" v-if="showError"> |
| 125 | language == 0 ? '密码不一致' : 'Password inconsistency' | 128 | {{language == 0 ? '密码不一致' : 'Password inconsistency'}} |
| 126 | }} | ||
| 127 | </div> | 129 | </div> |
| 128 | </el-form-item> | 130 | </el-form-item> |
| 129 | </el-form> | 131 | </el-form> |
| ... | @@ -287,16 +289,14 @@ function goBack() { | ... | @@ -287,16 +289,14 @@ function goBack() { |
| 287 | } | 289 | } |
| 288 | 290 | ||
| 289 | function next() { | 291 | function next() { |
| 290 | // proxy.$refs['wdsfDataRef'].validate((valid) => { | 292 | // if (!wdsfData.value.birthday) { |
| 291 | // if (valid) | 293 | // ElMessage.warning('Please fill in your birthday') |
| 294 | // return | ||
| 295 | // } | ||
| 292 | if (!wdsfData.value.passportNumber) { | 296 | if (!wdsfData.value.passportNumber) { |
| 293 | ElMessage.warning('Please fill in your passport number') | 297 | ElMessage.warning('Please fill in your passport number') |
| 294 | return | 298 | return |
| 295 | } | 299 | } |
| 296 | if (!wdsfData.value.birthday) { | ||
| 297 | ElMessage.warning('Please fill in your birthday') | ||
| 298 | return | ||
| 299 | } | ||
| 300 | if (!wdsfData.value.passportUrl) { | 300 | if (!wdsfData.value.passportUrl) { |
| 301 | ElMessage.warning('Please upload your passport file') | 301 | ElMessage.warning('Please upload your passport file') |
| 302 | return | 302 | return |
| ... | @@ -332,6 +332,7 @@ function next() { | ... | @@ -332,6 +332,7 @@ function next() { |
| 332 | let obj = { | 332 | let obj = { |
| 333 | sex: wdsfData.value.sex, | 333 | sex: wdsfData.value.sex, |
| 334 | passportNumber: wdsfData.value.passportNumber, | 334 | passportNumber: wdsfData.value.passportNumber, |
| 335 | picUrl: wdsfData.value.picUrl, | ||
| 335 | birth: wdsfData.value.birthday, | 336 | birth: wdsfData.value.birthday, |
| 336 | personId: wdsfData.value.personId, | 337 | personId: wdsfData.value.personId, |
| 337 | username: wdsfData.value.email, | 338 | username: wdsfData.value.email, |
| ... | @@ -348,7 +349,7 @@ function next() { | ... | @@ -348,7 +349,7 @@ function next() { |
| 348 | afterR() | 349 | afterR() |
| 349 | }) | 350 | }) |
| 350 | } | 351 | } |
| 351 | // }) | 352 | |
| 352 | } | 353 | } |
| 353 | 354 | ||
| 354 | function afterR() { | 355 | function afterR() { | ... | ... |
| ... | @@ -39,7 +39,7 @@ | ... | @@ -39,7 +39,7 @@ |
| 39 | /> | 39 | /> |
| 40 | <el-input type="textarea" v-model="form.address" class="mt10"/> | 40 | <el-input type="textarea" v-model="form.address" class="mt10"/> |
| 41 | </el-form-item> | 41 | </el-form-item> |
| 42 | <el-form-item :label="language==0?'机构名称':'Institution name'" required prop="teamName"> | 42 | <el-form-item :label="language==0?'机构名称':'Institution Name'" required prop="teamName"> |
| 43 | <el-input type="text" v-model="form.teamName" :placeholder="language==0?'请输入内容':''"/> | 43 | <el-input type="text" v-model="form.teamName" :placeholder="language==0?'请输入内容':''"/> |
| 44 | </el-form-item> | 44 | </el-form-item> |
| 45 | <el-form-item :label="language==0?'专业/业余':'Professional/Amateur'" required prop="majorFlag"> | 45 | <el-form-item :label="language==0?'专业/业余':'Professional/Amateur'" required prop="majorFlag"> | ... | ... |
| ... | @@ -82,8 +82,8 @@ export default defineConfig(({ mode, command }) => { | ... | @@ -82,8 +82,8 @@ export default defineConfig(({ mode, command }) => { |
| 82 | rewrite: (p) => p.replace(/^\/dev-api\/ztx-webSite/, '') | 82 | rewrite: (p) => p.replace(/^\/dev-api\/ztx-webSite/, '') |
| 83 | }, | 83 | }, |
| 84 | '/dev-api': { | 84 | '/dev-api': { |
| 85 | target: 'http://192.168.1.118:8081/', | 85 | // target: 'http://192.168.1.131:8081/', |
| 86 | // target: 'https://dance.itechtop.cn/stage-api', | 86 | target: 'https://dance.itechtop.cn/stage-api', |
| 87 | changeOrigin: true, | 87 | changeOrigin: true, |
| 88 | rewrite: (p) => p.replace(/^\/dev-api/, '') | 88 | rewrite: (p) => p.replace(/^\/dev-api/, '') |
| 89 | } | 89 | } | ... | ... |
-
Please register or sign in to post a comment