4ee16a30 by 杨炀

no message

1 parent 4829bac4
...@@ -17,8 +17,10 @@ ...@@ -17,8 +17,10 @@
17 <h3 class="panel-title" v-else>My Information</h3> 17 <h3 class="panel-title" v-else>My Information</h3>
18 </div> 18 </div>
19 <div class="panel-body"> 19 <div class="panel-body">
20 <div class="text-danger fontsize14 mb10" v-if="language==0">*报名双人项目请勾选您的舞伴</div> 20 <div v-if="form.danceMate">
21 <div class="text-danger fontsize14 mb10" v-else>*Please select your dance mate if you are signing up for a double event</div> 21 <div class="text-danger fontsize14 mb10" v-if="language==0">*报名双人项目请勾选您的舞伴</div>
22 <div class="text-danger fontsize14 mb10" v-else>*Please select your dance mate if you are signing up for a double event</div>
23 </div>
22 <div class="chooseForm" style="display: flex;flex-wrap: wrap;"> 24 <div class="chooseForm" style="display: flex;flex-wrap: wrap;">
23 <div @click="editPerson" class="mb20" style="width: 50%;text-align: center;"> 25 <div @click="editPerson" class="mb20" style="width: 50%;text-align: center;">
24 <el-avatar fit="cover" v-if="form.picUrl" :size="60" :src="fillImgUrl(form.picUrl)"/> 26 <el-avatar fit="cover" v-if="form.picUrl" :size="60" :src="fillImgUrl(form.picUrl)"/>
...@@ -56,15 +58,15 @@ ...@@ -56,15 +58,15 @@
56 </el-checkbox> 58 </el-checkbox>
57 </el-checkbox-group> 59 </el-checkbox-group>
58 </div> 60 </div>
59 <div style="min-width:50%;" v-else @click="addMate"> 61 <!-- <div style="min-width:50%;" v-else @click="addMate" hidden>-->
60 <div class="addBttn" style="margin: 0 auto">+</div> 62 <!-- <div class="addBttn" style="margin: 0 auto">+</div>-->
61 <div class="text-center mt10 text-primary text-sm"> 63 <!-- <div class="text-center mt10 text-primary text-sm">-->
62 Please add your partner 64 <!-- Please add your partner-->
63 <el-icon> 65 <!-- <el-icon>-->
64 <Edit/> 66 <!-- <Edit/>-->
65 </el-icon> 67 <!-- </el-icon>-->
66 </div> 68 <!-- </div>-->
67 </div> 69 <!-- </div>-->
68 </div> 70 </div>
69 </div> 71 </div>
70 </div> 72 </div>
......
...@@ -254,25 +254,32 @@ function submitForm() { ...@@ -254,25 +254,32 @@ function submitForm() {
254 if (Array.isArray(form.value.passportUrl)) { 254 if (Array.isArray(form.value.passportUrl)) {
255 form.value.passportUrl = form.value.passportUrl[0].url 255 form.value.passportUrl = form.value.passportUrl[0].url
256 } 256 }
257 if(groupId=='0'){ 257 if(groupId=='0'||!groupId){
258 match.savePersonForMyPerson(form.value).then(res => { 258 addPersonal()
259 ElMessage.success('保存成功')
260 show.value = false
261 emit('submitForm', res.data)
262 })
263 } else { 259 } else {
264 form.value.groupId = groupId 260 if(groupId){
265 match.savePersonForMyGroup(form.value).then(res => { 261 addGroupMember()
266 ElMessage.success(language.value == 0 ?'保存成功':'Save successful') 262 }
267 show.value = false
268 emit('submitForm')
269 })
270 } 263 }
271
272 } 264 }
273 } 265 }
274 } 266 }
267 function addPersonal() {
268 match.savePersonForMyPerson(form.value).then(res => {
269 ElMessage.success('保存成功')
270 show.value = false
271 emit('submitForm', res.data)
272 })
273 }
274 function addGroupMember() {
275 form.value.groupId = groupId
276 match.savePersonForMyGroup(form.value).then(res => {
277 ElMessage.success(language.value == 0 ?'保存成功':'Save successful')
278 show.value = false
279 emit('submitForm')
280 })
275 281
282 }
276 function cancel() { 283 function cancel() {
277 show.value = false 284 show.value = false
278 showVcode.value = false 285 showVcode.value = false
......
...@@ -10,8 +10,7 @@ ...@@ -10,8 +10,7 @@
10 10
11 <el-calendar v-model="calendarValue"> 11 <el-calendar v-model="calendarValue">
12 <template #date-cell="data"> 12 <template #date-cell="data">
13 <div v-if="data.data.day.slice(8,10)==22" class="primaryDate date">22</div> 13 <div class="date" :class="data.data.day==calendarValue?'primaryDate':''" @click="selectDate(data.data.day)">
14 <div v-else class="date">
15 {{ data.data.day.slice(8,10) }} 14 {{ data.data.day.slice(8,10) }}
16 </div> 15 </div>
17 16
...@@ -85,7 +84,7 @@ const ztxPlanList = ref([]) ...@@ -85,7 +84,7 @@ const ztxPlanList = ref([])
85 const planList = ref([]) 84 const planList = ref([])
86 const schList = ref([]) 85 const schList = ref([])
87 const loading = ref(false) 86 const loading = ref(false)
88 const calendarValue = ref('2024-07-22') 87 const calendarValue = ref(new Date())
89 88
90 89
91 // onMounted(() => { 90 // onMounted(() => {
...@@ -101,6 +100,10 @@ const calendarValue = ref('2024-07-22') ...@@ -101,6 +100,10 @@ const calendarValue = ref('2024-07-22')
101 // } 100 // }
102 // }) 101 // })
103 102
103 function selectDate(date) {
104 console.log(date,calendarValue.value)
105 }
106
104 function getPlanList() { 107 function getPlanList() {
105 loading.value = true 108 loading.value = true
106 109
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!