Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
campSite
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
杨梦雪
campSite
Commits
b3b4562d
Commit
b3b4562d
authored
Oct 18, 2021
by
杨梦雪
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
111
parent
97d2bb9c
Changes
11
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
186 additions
and
245 deletions
+186
-245
src/components/breadcrumb.vue
src/components/breadcrumb.vue
+12
-12
src/components/index/SignUp/ConfirmSignUp.vue
src/components/index/SignUp/ConfirmSignUp.vue
+1
-1
src/components/index/SignUp/Header.vue
src/components/index/SignUp/Header.vue
+10
-9
src/components/index/SignUp/paying.vue
src/components/index/SignUp/paying.vue
+29
-7
src/components/index/SignUp/referInfo.vue
src/components/index/SignUp/referInfo.vue
+49
-33
src/request/index/network.js
src/request/index/network.js
+38
-28
src/request/index/pay.js
src/request/index/pay.js
+1
-1
src/request/index/signUp.js
src/request/index/signUp.js
+9
-0
src/views/index/camp/SignUp.vue
src/views/index/camp/SignUp.vue
+21
-10
src/views/index/login/Index.vue
src/views/index/login/Index.vue
+12
-127
src/views/index/login/Login.vue
src/views/index/login/Login.vue
+4
-17
No files found.
src/components/breadcrumb.vue
View file @
b3b4562d
...
@@ -2,11 +2,11 @@
...
@@ -2,11 +2,11 @@
<div
class=
"steps flex"
>
<div
class=
"steps flex"
>
<!-- 1 -->
<!-- 1 -->
<div
class=
"step flex"
>
<div
class=
"step flex"
>
<div
:class=
"'cricle' + ' ' + (status >=
0
? 'speed-bg-color' : '')"
>
<div
:class=
"'cricle' + ' ' + (status >=
1
? 'speed-bg-color' : '')"
>
<span
class=
"num"
>
1
</span>
<span
class=
"num"
>
1
</span>
</div>
</div>
<div
<div
:class=
"'step_title' + ' ' + (status >=
0
? 'speed-text-color' : '')"
:class=
"'step_title' + ' ' + (status >=
1
? 'speed-text-color' : '')"
>
>
确认报名须知
确认报名须知
</div>
</div>
...
@@ -18,12 +18,12 @@
...
@@ -18,12 +18,12 @@
<div
class=
"step flex"
>
<div
class=
"step flex"
>
<div
<div
class=
"cricle cc"
class=
"cricle cc"
:class=
"'cricle' + ' ' + (status >=
1
? 'speed-bg-color' : '')"
:class=
"'cricle' + ' ' + (status >=
2
? 'speed-bg-color' : '')"
>
>
<span
class=
"num"
>
2
</span>
<span
class=
"num"
>
2
</span>
</div>
</div>
<div
<div
:class=
"'step_title' + ' ' + (status >=
1
? 'speed-text-color' : '')"
:class=
"'step_title' + ' ' + (status >=
2
? 'speed-text-color' : '')"
>
>
填写邀请码
填写邀请码
</div>
</div>
...
@@ -33,12 +33,12 @@
...
@@ -33,12 +33,12 @@
<div
class=
"step flex"
>
<div
class=
"step flex"
>
<div
<div
class=
"cricle cc"
class=
"cricle cc"
:class=
"'cricle' + ' ' + (status >=
2
? 'speed-bg-color' : '')"
:class=
"'cricle' + ' ' + (status >=
3
? 'speed-bg-color' : '')"
>
>
<span
class=
"num"
>
3
</span>
<span
class=
"num"
>
3
</span>
</div>
</div>
<div
<div
:class=
"'step_title' + ' ' + (status >=
2
? 'speed-text-color' : '')"
:class=
"'step_title' + ' ' + (status >=
3
? 'speed-text-color' : '')"
>
>
填写报名资料
填写报名资料
</div>
</div>
...
@@ -48,12 +48,12 @@
...
@@ -48,12 +48,12 @@
<div
class=
"step flex"
>
<div
class=
"step flex"
>
<div
<div
class=
"cricle cc"
class=
"cricle cc"
:class=
"'cricle' + ' ' + (status >=
3
? 'speed-bg-color' : '')"
:class=
"'cricle' + ' ' + (status >=
4
? 'speed-bg-color' : '')"
>
>
<span
class=
"num"
>
4
</span>
<span
class=
"num"
>
4
</span>
</div>
</div>
<div
<div
:class=
"'step_title' + ' ' + (status >=
3
? 'speed-text-color' : '')"
:class=
"'step_title' + ' ' + (status >=
4
? 'speed-text-color' : '')"
>
>
报名资料审核
报名资料审核
</div>
</div>
...
@@ -63,12 +63,12 @@
...
@@ -63,12 +63,12 @@
<div
class=
"step flex"
>
<div
class=
"step flex"
>
<div
<div
class=
"cricle cc"
class=
"cricle cc"
:class=
"'cricle' + ' ' + (status >=
4
? 'speed-bg-color' : '')"
:class=
"'cricle' + ' ' + (status >=
5
? 'speed-bg-color' : '')"
>
>
<span
class=
"num"
>
5
</span>
<span
class=
"num"
>
5
</span>
</div>
</div>
<div
<div
:class=
"'step_title' + ' ' + (status >=
4
? 'speed-text-color' : '')"
:class=
"'step_title' + ' ' + (status >=
5
? 'speed-text-color' : '')"
>
>
缴费
缴费
</div>
</div>
...
@@ -80,7 +80,7 @@
...
@@ -80,7 +80,7 @@
/* eslint-disable */
/* eslint-disable */
export
default
{
export
default
{
name
:
"
breadcrumb
"
,
name
:
"
breadcrumb
"
,
props
:
{
statusNum
:
[
String
,
Number
]
},
//进度参数
props
:
{
statusNum
:
[
String
,
Number
]
},
//进度参数
data
()
{
data
()
{
return
{
return
{
status
:
this
.
statusNum
,
status
:
this
.
statusNum
,
...
@@ -109,6 +109,7 @@ export default {
...
@@ -109,6 +109,7 @@ export default {
}
}
.steps
{
.steps
{
.step
{
.step
{
align-items
:
center
;
}
}
.num
{
.num
{
color
:
#ffff
;
color
:
#ffff
;
...
@@ -135,7 +136,6 @@ export default {
...
@@ -135,7 +136,6 @@ export default {
height
:
20px
;
height
:
20px
;
font-weight
:
600
;
font-weight
:
600
;
color
:
#d0ced0
;
color
:
#d0ced0
;
line-height
:
34px
;
}
}
}
}
</
style
>
</
style
>
\ No newline at end of file
src/components/index/SignUp/ConfirmSignUp.vue
View file @
b3b4562d
...
@@ -34,7 +34,7 @@
...
@@ -34,7 +34,7 @@
<
script
>
<
script
>
/* eslint-disable */
/* eslint-disable */
import
{
getWxConfig
}
from
"
r/index/pay
.js
"
;
import
{
getWxConfig
}
from
"
r/index/pay
"
;
import
{
SERVER_WS_URL
}
from
"
config/server
"
;
import
{
SERVER_WS_URL
}
from
"
config/server
"
;
import
QRCode
from
"
qrcodejs2
"
;
import
QRCode
from
"
qrcodejs2
"
;
export
default
{
export
default
{
...
...
src/components/index/SignUp/Header.vue
View file @
b3b4562d
...
@@ -7,11 +7,16 @@
...
@@ -7,11 +7,16 @@
</div>
</div>
<div
class=
"right"
>
<div
class=
"right"
>
<el-dropdown
@
command=
"handleCommand"
>
<el-dropdown
@
command=
"handleCommand"
>
<span
class=
"el-dropdown-link"
>
<div
class=
"el-dropdown-link flex"
>
<img
src=
"@/assets/img/default.svg"
class=
"img_user"
/>
<div>
<span
class=
"phone"
>
{{
phone
}}
</span>
<img
src=
"@/assets/img/default.svg"
class=
"img_user"
/>
<i
class=
"el-icon-arrow-down el-icon--right"
></i>
</div>
</span>
<div
style=
"line-height: 64px"
>
<span
class=
"phone"
>
{{
phone
}}
</span>
<i
class=
"el-icon-arrow-down el-icon--right"
></i>
</div>
</div>
<el-dropdown-menu
slot=
"dropdown"
>
<el-dropdown-menu
slot=
"dropdown"
>
<el-dropdown-item
command=
"1"
>
退出
</el-dropdown-item>
<el-dropdown-item
command=
"1"
>
退出
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown-menu>
...
@@ -72,10 +77,6 @@ export default {
...
@@ -72,10 +77,6 @@ export default {
.cc
{
.cc
{
width
:
100%
;
width
:
100%
;
justify-content
:
space-around
;
justify-content
:
space-around
;
align-items
:
center
;
div
{
flex-direction
:
column
;
}
}
}
}
}
...
...
src/components/index/SignUp/paying.vue
View file @
b3b4562d
...
@@ -3,15 +3,17 @@
...
@@ -3,15 +3,17 @@
<div>
<div>
<span
class=
"pay_titile"
>
报名信息
</span>
<span
class=
"pay_titile"
>
报名信息
</span>
<div
class=
"pay_top"
>
<div
class=
"pay_top"
>
<div>
营地名称:
2021年南开大学历史学科暑假营
</div>
<div>
营地名称:
{{
camp_name
}}
</div>
<div>
真实姓名:
林柒月
</div>
<div>
真实姓名:
{{
personalInfo
.
name
}}
</div>
<div>
身份证号:
340828199612053920
</div>
<div>
身份证号:
{{
personalInfo
.
id_card
}}
</div>
<div>
缴费时间:
2021-8-19 10:00 - 2021-8-31 24:00
</div>
<div>
缴费时间:
{{
personalInfo
.
create_time
}}
</div>
<div>
报名费用:
1500
元
</div>
<div>
报名费用:
{{
has_amount
}}
元
</div>
</div>
</div>
<div
class=
"line"
></div>
<div
class=
"line"
></div>
<div
class=
"pay-money flex"
>
<div
class=
"pay-money flex"
>
<div>
报名费用 :
<span>
¥1500
</span></div>
<div>
报名费用 :
<span>
¥
{{
has_amount
}}
</span>
</div>
<div
class=
"btn"
>
<div
class=
"btn"
>
<el-button
@
click=
"paying()"
>
立即支付
</el-button>
<el-button
@
click=
"paying()"
>
立即支付
</el-button>
</div>
</div>
...
@@ -62,6 +64,7 @@
...
@@ -62,6 +64,7 @@
<
script
>
<
script
>
/* eslint-disable */
/* eslint-disable */
import
ConfirmSignUp
from
"
c/index/SignUp/ConfirmSignUp
"
;
import
ConfirmSignUp
from
"
c/index/SignUp/ConfirmSignUp
"
;
import
{
getAccount
}
from
"
r/index/signUp
"
;
export
default
{
export
default
{
name
:
"
Paying
"
,
name
:
"
Paying
"
,
components
:
{
components
:
{
...
@@ -70,8 +73,16 @@ export default {
...
@@ -70,8 +73,16 @@ export default {
data
()
{
data
()
{
return
{
return
{
confirmSignUpDialogFu
:
false
,
// 控制确认报名弹框的显示与隐藏
confirmSignUpDialogFu
:
false
,
// 控制确认报名弹框的显示与隐藏
personalInfo
:
{},
camp_name
:
""
,
//营地名称
has_amount
:
""
,
//支付金额
};
};
},
},
created
()
{
this
.
camp_name
=
window
.
localStorage
.
getItem
(
"
camp_name
"
);
this
.
has_amount
=
window
.
localStorage
.
getItem
(
"
has_amount
"
);
this
.
getAccount
();
},
methods
:
{
methods
:
{
// 子组件触发,关闭确认报名弹框
// 子组件触发,关闭确认报名弹框
closeCFSUDialog
(
val
,
type
)
{
closeCFSUDialog
(
val
,
type
)
{
...
@@ -80,7 +91,18 @@ export default {
...
@@ -80,7 +91,18 @@ export default {
clearInterval
(
this
.
timer
);
clearInterval
(
this
.
timer
);
}
}
},
},
paying
()
{},
paying
()
{
this
.
confirmSignUpDialogFu
=
true
;
},
getAccount
()
{
getAccount
({}).
then
((
res
)
=>
{
console
.
log
(
res
,
"
getAccount
"
);
if
(
res
.
data
.
code
!=
200
)
{
return
this
.
$message
.
error
(
res
.
data
.
message
);
}
this
.
personalInfo
=
res
.
data
.
info
;
});
},
},
},
};
};
</
script
>
</
script
>
...
...
src/components/index/SignUp/referInfo.vue
View file @
b3b4562d
...
@@ -262,8 +262,7 @@
...
@@ -262,8 +262,7 @@
:disabled=
"isUploading"
:disabled=
"isUploading"
action=
"#"
action=
"#"
accept=
".jpg,.jpeg,.png"
accept=
".jpg,.jpeg,.png"
:limit=
"1"
:limit=
"10"
:headers=
"header"
:file-list=
"fileList"
:file-list=
"fileList"
:before-upload=
"beforeAvatarUpload"
:before-upload=
"beforeAvatarUpload"
:on-progress=
"handleUploadProgress"
:on-progress=
"handleUploadProgress"
...
@@ -272,16 +271,17 @@
...
@@ -272,16 +271,17 @@
>
>
<i
style=
"font-size: 44px"
class=
"el-icon-circle-plus"
>
</i>
<i
style=
"font-size: 44px"
class=
"el-icon-circle-plus"
>
</i>
<!--
<div
class=
"text"
>
上传材料
</div>
-->
<!--
<div
class=
"text"
>
上传材料
</div>
-->
<div
slot=
"file"
slot-scope=
"
{ file }">
<!--
<div
slot=
"file"
slot-scope=
"
{ file }" v-for="(item,idx) in fileList" :key="idx"> -->
<div
v-for=
"(item,idx) in fileList"
:key=
"idx"
>
<img
<img
class=
"el-upload-list__item-thumbnail"
class=
"el-upload-list__item-thumbnail"
:src=
"
file
.url"
:src=
"
item
.url"
alt=
""
alt=
""
/>
/>
<span
class=
"el-upload-list__item-actions"
>
<span
class=
"el-upload-list__item-actions"
>
<span
<span
class=
"el-upload-list__item-preview"
class=
"el-upload-list__item-preview"
@
click=
"handlePictureCardPreview(
file
)"
@
click=
"handlePictureCardPreview(
item
)"
>
>
<i
class=
"el-icon-zoom-in"
></i>
<i
class=
"el-icon-zoom-in"
></i>
</span>
</span>
...
@@ -291,14 +291,14 @@
...
@@ -291,14 +291,14 @@
@
click=
"handleDownload(file)"
@
click=
"handleDownload(file)"
>
>
<i
class=
"el-icon-download"
></i>
<i
class=
"el-icon-download"
></i>
</span>
</span>
-->
<span
<span
v-if=
"!disabled"
v-if=
"!disabled"
class=
"el-upload-list__item-delete"
class=
"el-upload-list__item-delete"
@
click=
"handleRemove(
file
)"
@
click=
"handleRemove(
item
)"
>
>
<i
class=
"el-icon-delete"
></i>
<i
class=
"el-icon-delete"
></i>
</span>
-->
</span>
</span>
</span>
</div>
</div>
</el-upload>
</el-upload>
...
@@ -322,6 +322,7 @@
...
@@ -322,6 +322,7 @@
import
{
import
{
getAccount
,
getAccount
,
getAchievementOss
,
getAchievementOss
,
delPic
,
setAccount
,
setAccount
,
getProAndCity
,
getProAndCity
,
getSchool
,
getSchool
,
...
@@ -369,7 +370,7 @@ export default {
...
@@ -369,7 +370,7 @@ export default {
school
:
""
,
school
:
""
,
school_contacts
:
""
,
school_contacts
:
""
,
school_phone
:
""
,
school_phone
:
""
,
achievement
P
ath
:
""
,
achievement
_p
ath
:
""
,
},
},
schoolName
:
[],
schoolName
:
[],
referInfoRules
:
{
referInfoRules
:
{
...
@@ -495,13 +496,7 @@ export default {
...
@@ -495,13 +496,7 @@ export default {
],
],
bdYear
:
""
,
//选择的生日年份
bdYear
:
""
,
//选择的生日年份
bdMonth
:
""
,
//选择的生日月份
bdMonth
:
""
,
//选择的生日月份
bdDay
:
""
,
//选择的生日日期
bdDay
:
""
,
//选择的生日日期F
// 图片上传接口
imgUrlAction
:
process
.
env
.
VUE_APP_BASE_API
+
"
getAchievementOss
"
,
headers
:
{
Authorization
:
"
Bearer
"
+
getToken
(),
},
// 上传的图片
// 上传的图片
dialogImageUrl
:
""
,
dialogImageUrl
:
""
,
dialogVisible
:
false
,
dialogVisible
:
false
,
...
@@ -513,6 +508,11 @@ export default {
...
@@ -513,6 +508,11 @@ export default {
};
};
},
},
created
()
{
created
()
{
let
signUpFile
=
window
.
localStorage
.
getItem
(
'
sign_up_file_
'
+
window
.
localStorage
.
getItem
(
'
phone
'
));
console
.
log
(
JSON
.
parse
(
signUpFile
))
if
(
signUpFile
&&
JSON
.
parse
(
signUpFile
).
length
>
0
){
this
.
fileList
=
JSON
.
parse
(
signUpFile
);
}
this
.
getAccount
();
this
.
getAccount
();
this
.
getProAndCity
();
this
.
getProAndCity
();
this
.
getSchool
();
this
.
getSchool
();
...
@@ -548,9 +548,9 @@ export default {
...
@@ -548,9 +548,9 @@ export default {
val
.
jiguan_code
!==
"
00
"
val
.
jiguan_code
!==
"
00
"
)
{
)
{
//籍贯
//籍贯
console
.
log
(
val
.
jiguan_code
,
"
val.jiguan_code+++++
"
);
//
console.log(val.jiguan_code, "val.jiguan_code+++++");
this
.
jgProvinceCode
=
Number
(
val
.
jiguan_code
.
slice
(
0
,
2
));
//前2位取省份
this
.
jgProvinceCode
=
Number
(
val
.
jiguan_code
.
slice
(
0
,
2
));
//前2位取省份
console
.
log
(
this
.
jgProvinceCode
,
"
val.jiguan_code+++++
"
);
//
console.log(this.jgProvinceCode, "val.jiguan_code+++++");
this
.
selectJgProvince
(
this
.
jgProvinceCode
,
"
1
"
);
this
.
selectJgProvince
(
this
.
jgProvinceCode
,
"
1
"
);
this
.
jgCityCode
=
Number
(
val
.
jiguan_code
.
slice
(
2
,
6
));
//后4位取城市
this
.
jgCityCode
=
Number
(
val
.
jiguan_code
.
slice
(
2
,
6
));
//后4位取城市
console
.
log
(
this
.
jgCityCode
,
"
val.jiguan_code+++++
"
);
console
.
log
(
this
.
jgCityCode
,
"
val.jiguan_code+++++
"
);
...
@@ -562,14 +562,14 @@ export default {
...
@@ -562,14 +562,14 @@ export default {
getTenYear
()
{
getTenYear
()
{
let
nowDate
=
new
Date
();
let
nowDate
=
new
Date
();
let
currentYear
=
nowDate
.
getFullYear
();
let
currentYear
=
nowDate
.
getFullYear
();
console
.
log
(
nowDate
,
currentYear
);
//
console.log(nowDate, currentYear);
let
yearArr
=
[];
let
yearArr
=
[];
let
rxYearArr
=
[];
let
rxYearArr
=
[];
for
(
let
i
=
0
;
i
<
22
;
i
++
)
{
for
(
let
i
=
0
;
i
<
22
;
i
++
)
{
let
year
=
currentYear
-
i
;
let
year
=
currentYear
-
i
;
yearArr
.
push
(
year
);
yearArr
.
push
(
year
);
}
}
console
.
log
(
yearArr
,
"
yearArr
"
);
//
console.log(yearArr, "yearArr");
for
(
let
i
=
0
;
i
<
10
;
i
++
)
{
for
(
let
i
=
0
;
i
<
10
;
i
++
)
{
let
year
=
currentYear
-
i
;
let
year
=
currentYear
-
i
;
rxYearArr
.
push
(
year
);
rxYearArr
.
push
(
year
);
...
@@ -580,7 +580,7 @@ export default {
...
@@ -580,7 +580,7 @@ export default {
// 页面信息个人获取
// 页面信息个人获取
getAccount
()
{
getAccount
()
{
getAccount
({}).
then
((
res
)
=>
{
getAccount
({}).
then
((
res
)
=>
{
console
.
log
(
res
,
"
getAccount
"
);
//
console.log(res, "getAccount");
if
(
res
.
data
.
code
!=
200
)
{
if
(
res
.
data
.
code
!=
200
)
{
return
this
.
$message
.
error
(
res
.
data
.
message
);
return
this
.
$message
.
error
(
res
.
data
.
message
);
}
}
...
@@ -601,7 +601,7 @@ export default {
...
@@ -601,7 +601,7 @@ export default {
// 获取省份城市
// 获取省份城市
getProAndCity
()
{
getProAndCity
()
{
getProAndCity
({}).
then
((
res
)
=>
{
getProAndCity
({}).
then
((
res
)
=>
{
console
.
log
(
res
,
"
getProAndCity
"
);
//
console.log(res, "getProAndCity");
if
(
res
.
data
.
code
!=
200
)
{
if
(
res
.
data
.
code
!=
200
)
{
return
this
.
$message
.
error
(
res
.
data
.
message
);
return
this
.
$message
.
error
(
res
.
data
.
message
);
}
}
...
@@ -610,7 +610,7 @@ export default {
...
@@ -610,7 +610,7 @@ export default {
});
});
},
},
changeProvince
(
type
,
value
)
{
changeProvince
(
type
,
value
)
{
console
.
log
(
value
,
"
value
"
);
//
console.log(value, "value");
let
selectCity
=
[];
let
selectCity
=
[];
for
(
const
key
in
this
.
CityName
)
{
for
(
const
key
in
this
.
CityName
)
{
if
(
this
.
CityName
[
key
].
parent_id
==
value
)
{
if
(
this
.
CityName
[
key
].
parent_id
==
value
)
{
...
@@ -627,7 +627,7 @@ export default {
...
@@ -627,7 +627,7 @@ export default {
// 获取学校
// 获取学校
getSchool
()
{
getSchool
()
{
getSchool
({}).
then
((
res
)
=>
{
getSchool
({}).
then
((
res
)
=>
{
console
.
log
(
res
,
"
getSchool
"
);
//
console.log(res, "getSchool");
if
(
res
.
data
.
code
!=
200
)
{
if
(
res
.
data
.
code
!=
200
)
{
return
this
.
$message
.
error
(
res
.
data
.
message
);
return
this
.
$message
.
error
(
res
.
data
.
message
);
}
}
...
@@ -662,7 +662,7 @@ export default {
...
@@ -662,7 +662,7 @@ export default {
this
.
isUploading
=
true
;
this
.
isUploading
=
true
;
},
},
uploadSuccess
(
res
,
file
)
{
uploadSuccess
(
res
,
file
)
{
console
.
log
(
res
,
"
111
"
);
//
console.log(res, "111");
this
.
referForm
.
achievementPath
=
res
;
this
.
referForm
.
achievementPath
=
res
;
this
.
fileList
[
0
]
=
{
this
.
fileList
[
0
]
=
{
name
:
file
.
name
,
name
:
file
.
name
,
...
@@ -671,7 +671,7 @@ export default {
...
@@ -671,7 +671,7 @@ export default {
this
.
$refs
[
"
imgUrl
"
].
clearFiles
();
//上传成功之后清除历史记录
this
.
$refs
[
"
imgUrl
"
].
clearFiles
();
//上传成功之后清除历史记录
},
},
uploadPicture
(
params
)
{
uploadPicture
(
params
)
{
console
.
log
(
"
已经准备好上传图片
"
,
params
);
//
console.log("已经准备好上传图片", params);
this
.
file
=
params
.
file
;
this
.
file
=
params
.
file
;
let
raw
=
params
.
file
;
let
raw
=
params
.
file
;
let
image
=
{
let
image
=
{
...
@@ -682,12 +682,17 @@ export default {
...
@@ -682,12 +682,17 @@ export default {
this
.
getOssConfigs
(
image
,
params
.
file
);
this
.
getOssConfigs
(
image
,
params
.
file
);
},
},
async
getOssConfigs
(
image
,
file
)
{
async
getOssConfigs
(
image
,
file
)
{
let
obj
=
{
url
:
''
,
savefile
:
''
}
await
getAchievementOss
({
image
:
image
})
await
getAchievementOss
({
image
:
image
})
.
then
((
res
)
=>
{
.
then
((
res
)
=>
{
console
.
log
(
res
,
"
开始上传图片
"
);
console
.
log
(
res
,
"
开始上传图片
"
);
if
(
res
.
data
.
code
===
200
)
{
if
(
res
.
data
.
code
===
200
)
{
let
oss_url
=
res
.
data
.
config
.
host
;
let
oss_url
=
res
.
data
.
config
.
host
;
let
filename
=
res
.
data
.
config
.
file
;
let
filename
=
res
.
data
.
config
.
file
;
let
formData
=
new
FormData
();
let
formData
=
new
FormData
();
formData
.
append
(
"
OSSAccessKeyId
"
,
res
.
data
.
config
.
accessid
);
formData
.
append
(
"
OSSAccessKeyId
"
,
res
.
data
.
config
.
accessid
);
formData
.
append
(
"
policy
"
,
res
.
data
.
config
.
policy
);
formData
.
append
(
"
policy
"
,
res
.
data
.
config
.
policy
);
...
@@ -697,16 +702,22 @@ export default {
...
@@ -697,16 +702,22 @@ export default {
formData
.
append
(
"
callback
"
,
res
.
data
.
config
.
callback
);
formData
.
append
(
"
callback
"
,
res
.
data
.
config
.
callback
);
formData
.
append
(
"
success_action_status
"
,
200
);
formData
.
append
(
"
success_action_status
"
,
200
);
formData
.
append
(
"
file
"
,
file
);
formData
.
append
(
"
file
"
,
file
);
console
.
log
(
"
已经上传上
"
);
// console.log(formData);
upload
(
oss_url
,
formData
)
upload
(
oss_url
,
formData
)
.
then
((
ress
)
=>
{
.
then
((
ress
)
=>
{
// console.log(ress);
if
(
ress
.
data
.
code
==
200
)
{
if
(
ress
.
data
.
code
==
200
)
{
console
.
log
(
ress
,
"
上传
照
返回数据
"
);
console
.
log
(
ress
,
"
上传返回数据
"
);
this
.
resultPicture
=
this
.
resultPicture
=
filename
+
"
?t=
"
+
Date
.
parse
(
new
Date
());
filename
+
"
?t=
"
+
Date
.
parse
(
new
Date
());
this
.
$forceUpdate
();
this
.
$forceUpdate
();
this
.
$message
.
success
(
"
上传成功
"
);
this
.
$message
.
success
(
"
上传成功
"
);
obj
=
{
url
:
ress
.
data
.
picture_path
,
savefile
:
res
.
data
.
config
.
savefile
}
this
.
fileList
.
push
(
obj
);
window
.
localStorage
.
setItem
(
'
sign_up_file_
'
+
window
.
localStorage
.
getItem
(
'
phone
'
),
JSON
.
stringify
(
this
.
fileList
));
}
else
{
}
else
{
this
.
$message
.
error
(
ress
.
data
.
message
);
this
.
$message
.
error
(
ress
.
data
.
message
);
}
}
...
@@ -727,20 +738,25 @@ export default {
...
@@ -727,20 +738,25 @@ export default {
this
.
resultPicture
=
this
.
addBanner
.
bannerUrl
;
this
.
resultPicture
=
this
.
addBanner
.
bannerUrl
;
this
.
dialogVisible
=
true
;
this
.
dialogVisible
=
true
;
},
},
//删除图片
handleRemove
(
file
)
{
// console.log(file);
// let odject=savefile
// delPic({object:odject}).then((res)=>{
// })
},
confirm
()
{
confirm
()
{
console
.
log
(
1111
);
// console.log(2222)
// this.$refs["referRef"].validate((valid) => {
// this.$refs["referRef"].validate((valid) => {
// console.log(2222)
// console.log(2222)
// if (!valid) return;
// if (!valid) return;
setAccount
(
this
.
referForm
).
then
((
res
)
=>
{
setAccount
(
this
.
referForm
).
then
((
res
)
=>
{
console
.
log
(
res
,
"
setAccount
"
);
//
console.log(res, "setAccount");
if
(
res
.
data
.
code
!=
200
)
{
if
(
res
.
data
.
code
!=
200
)
{
return
this
.
$message
.
error
(
res
.
data
.
message
);
return
this
.
$message
.
error
(
res
.
data
.
message
);
}
}
this
.
$message
.
success
(
"
提交审核成功
"
);
this
.
$message
.
success
(
"
提交审核成功
"
);
// 跳转到报名
// 跳转到报名
this
.
$router
.
push
(
"
/signUp/check
"
);
this
.
$router
.
push
(
"
/signUp/check
"
);
});
});
...
...
src/request/index/network.js
View file @
b3b4562d
...
@@ -20,11 +20,13 @@ const instance = axios.create({
...
@@ -20,11 +20,13 @@ const instance = axios.create({
headers
:
{
headers
:
{
"
Content-Type
"
:
"
application/x-www-form-urlencoded
"
,
"
Content-Type
"
:
"
application/x-www-form-urlencoded
"
,
},
},
withCredentials
:
false
,
});
});
instance
.
interceptors
.
request
.
use
(
instance
.
interceptors
.
request
.
use
(
(
config
)
=>
{
(
config
)
=>
{
console
.
log
(
config
);
console
.
log
(
config
,
'
111
'
);
if
(
config
.
method
===
"
post
"
&&
!
config
.
notQs
)
{
if
(
config
.
method
===
"
post
"
&&
!
config
.
notQs
)
{
config
.
data
=
qs
.
stringify
(
config
.
data
);
config
.
data
=
qs
.
stringify
(
config
.
data
);
}
}
...
@@ -35,7 +37,11 @@ instance.interceptors.request.use(
...
@@ -35,7 +37,11 @@ instance.interceptors.request.use(
config
.
headers
[
"
Content-Type
"
]
=
"
application/x-www-form-urlencoded
"
;
config
.
headers
[
"
Content-Type
"
]
=
"
application/x-www-form-urlencoded
"
;
}
}
// 调用接口请求添加token认证信息
// 调用接口请求添加token认证信息
let
token
=
localStorage
.
getItem
(
"
index-token
"
);
// let token = localStorage.getItem("index-token");
const
token
=
localStorage
.
getItem
(
'
index-token
'
)
//
config
.
headers
.
token
=
token
if
(
token
)
config
.
headers
.
authorization
=
token
;
if
(
token
)
config
.
headers
.
authorization
=
token
;
return
config
;
return
config
;
},
},
...
@@ -43,14 +49,14 @@ instance.interceptors.request.use(
...
@@ -43,14 +49,14 @@ instance.interceptors.request.use(
return
Promise
.
reject
(
error
);
return
Promise
.
reject
(
error
);
}
}
);
);
instance
.
interceptors
.
response
.
use
(
//
instance.interceptors.response.use(
(
response
)
=>
{
//
(response) => {
return
response
.
data
;
//
return response.data;
},
//
},
(
error
)
=>
{
//
(error) => {
return
Promise
.
reject
(
error
);
//
return Promise.reject(error);
}
//
}
);
//
);
export
default
instance
;
export
default
instance
;
...
@@ -224,24 +230,28 @@ export function request(config) {
...
@@ -224,24 +230,28 @@ export function request(config) {
return
instance
(
config
)
return
instance
(
config
)
}
}
/**
/**
* axios:upload 文件上传方法
* axios:upload 文件上传方法
* @param url
* @param url
* @param data
* @param data
* @returns {Promise}
* @returns {Promise}
*/
*/
export
function
upload
(
url
,
data
=
{})
{
export
function
upload
(
url
,
data
=
{})
{
return
new
Promise
((
resolve
,
reject
)
=>
{
// console.log(11111)
axios
.
post
(
url
,
data
).
then
(
return
new
Promise
((
resolve
,
reject
)
=>
{
(
response
)
=>
{
axios
.
post
(
url
,
data
).
then
(
resolve
(
response
);
(
response
)
=>
{
},
console
.
log
(
url
)
(
err
)
=>
{
// console.log(11111)
reject
(
err
);
resolve
(
response
);
}
},
);
(
err
)
=>
{
});
console
.
log
(
11111
)
}
reject
(
err
);
}
);
});
}
// 合并多个请求
// 合并多个请求
export
function
allRequest
(
arrRequest
)
{
export
function
allRequest
(
arrRequest
)
{
return
axios
.
all
(
arrRequest
)
return
axios
.
all
(
arrRequest
)
...
...
src/request/index/pay.js
View file @
b3b4562d
...
@@ -8,7 +8,7 @@ const identity = localStorage.getItem('index-identity')
...
@@ -8,7 +8,7 @@ const identity = localStorage.getItem('index-identity')
export
function
getWxConfig
(
data
)
{
export
function
getWxConfig
(
data
)
{
data
[
'
identity
'
]
=
identity
;
data
[
'
identity
'
]
=
identity
;
return
request
({
return
request
({
method
:
'
pos
t
'
,
method
:
'
ge
t
'
,
url
:
'
/web/pay/getWxPreselectionConfig
'
,
url
:
'
/web/pay/getWxPreselectionConfig
'
,
params
:
data
params
:
data
})
})
...
...
src/request/index/signUp.js
View file @
b3b4562d
...
@@ -53,7 +53,16 @@ export function getAchievementOss(data) {
...
@@ -53,7 +53,16 @@ export function getAchievementOss(data) {
data
data
})
})
}
}
//删除图片
export
function
delPic
(
data
)
{
data
[
'
identity
'
]
=
identity
;
return
request
({
method
:
'
post
'
,
url
:
'
/web/auth/delPic
'
,
params
:
data
})
}
// 页面个人信息保存
// 页面个人信息保存
export
function
setAccount
(
data
)
{
export
function
setAccount
(
data
)
{
data
[
'
identity
'
]
=
identity
;
data
[
'
identity
'
]
=
identity
;
...
...
src/views/index/camp/SignUp.vue
View file @
b3b4562d
...
@@ -40,11 +40,9 @@ export default {
...
@@ -40,11 +40,9 @@ export default {
};
};
},
},
created
()
{
created
()
{
this
.
type
=
this
.
$route
.
params
.
type
;
this
.
type
=
this
.
$route
.
params
.
type
;
// console.log(this.$route);
// console.log(this.$route);
this
.
signUpInit
();
this
.
signUpInit
();
},
},
watch
:
{
watch
:
{
$route
:
{
$route
:
{
...
@@ -61,22 +59,35 @@ export default {
...
@@ -61,22 +59,35 @@ export default {
signUpInit
()
{
signUpInit
()
{
// console.log(111);
// console.log(111);
signUpInit
({}).
then
((
res
)
=>
{
signUpInit
({}).
then
((
res
)
=>
{
console
.
log
(
res
);
console
.
log
(
res
,
"
signUpInit
"
);
if
(
res
.
data
.
code
!=
200
)
{
if
(
res
.
data
.
code
!=
200
)
{
return
this
.
$message
.
error
(
res
.
data
.
message
);
return
this
.
$message
.
error
(
res
.
data
.
message
);
}
}
this
.
status
=
res
.
data
.
status
;
this
.
status
=
res
.
data
.
status
;
if
(
this
.
status
==
0
)
{
if
(
this
.
status
==
1
)
{
this
.
type
=
"
examInfo
"
;
this
.
type
=
"
examInfo
"
;
}
else
if
(
this
.
status
==
1
)
{
}
else
if
(
this
.
status
==
2
)
{
this
.
type
=
"
invitation
"
;
this
.
type
=
"
invitation
"
;
}
else
if
(
this
.
status
==
2
)
{
}
else
if
(
this
.
status
==
3
)
{
this
.
type
=
"
referInfo
"
;
this
.
type
=
"
referInfo
"
;
}
else
if
(
this
.
status
==
3
)
{
}
else
if
(
this
.
status
==
4
)
{
this
.
type
=
"
check
"
;
// this.type = "check";
}
else
if
(
this
.
status
==
4
)
{
if
(
res
.
data
.
examine_status
==
0
)
{
this
.
type
=
"
check
"
;
}
else
if
(
res
.
data
.
examine_status
==
1
)
{
this
.
type
=
"
pay
"
;
}
else
if
(
res
.
data
.
examine_status
==
2
)
{
this
.
type
=
"
referInfo
"
;
// this.status == 3
return
this
.
$message
.
error
(
res
.
data
.
examine_reason
);
}
}
else
if
(
this
.
status
==
5
)
{
this
.
type
=
"
pay
"
;
this
.
type
=
"
pay
"
;
}
}
//审核报名资料状态
//订单支付金额
window
.
localStorage
.
setItem
(
"
has_amount
"
,
res
.
data
.
has_amount
);
});
});
},
},
},
},
...
...
src/views/index/login/Index.vue
View file @
b3b4562d
...
@@ -7,147 +7,32 @@
...
@@ -7,147 +7,32 @@
</
template
>
</
template
>
<
script
>
<
script
>
/* eslint-disable */
/* eslint-disable */
import
{
login
}
from
'
r/index/login.js
'
// import DialogBox from "c/index/register/DialogBox";
export
default
{
export
default
{
name
:
'
loginIndex
'
,
name
:
"
loginIndex
"
,
data
()
{
data
()
{
return
{
return
{};
isShowPwd
:
true
,
// 控制密码显示隐藏
loginForm
:
{
username
:
''
,
password
:
''
},
// 表单验证规则对象
loginFormRules
:
{
// 对用户名进行校验
username
:
[
{
required
:
true
,
message
:
'
请输入用户名
'
,
trigger
:
'
blur
'
},
{
min
:
4
,
max
:
20
,
message
:
'
请输入正确的用户名
'
,
trigger
:
'
blur
'
}
],
// 对密码进行校验
password
:
[
{
required
:
true
,
message
:
'
请输入密码
'
,
trigger
:
'
blur
'
},
{
min
:
6
,
max
:
20
,
message
:
'
请输入正确的密码
'
,
trigger
:
'
blur
'
}
]
},
dialogFormFu
:
{
title
:
''
,
message
:
''
},
dialogVisibleFu
:
false
}
},
},
created
()
{
created
()
{
this
.
$emit
(
'
getStatus
'
,
false
)
this
.
$emit
(
"
getStatus
"
,
false
);
},
},
methods
:
{
};
// 忘记账号/密码
forgetPwd
()
{
window
.
localStorage
.
setItem
(
'
f_forgetpwd
'
,
0
)
this
.
$router
.
replace
({
name
:
'
foundback
'
})
},
// 子组件触发,关闭弹框
closeDialog
(
value
,
type
)
{
this
.
dialogVisibleFu
=
value
if
(
type
)
{
this
.
$router
.
replace
({
name
:
'
StepOne
'
})
}
},
// 去注册
register
()
{
this
.
dialogFormFu
=
{
title
:
'
提示
'
,
message
:
1
}
this
.
dialogVisibleFu
=
true
// this.$router.replace({ name: "StepOne" });
},
// 改变密码显示状态
changePwdStatus
()
{
this
.
isShowPwd
=
!
this
.
isShowPwd
},
// 表单验证
submitForm
()
{
this
.
$refs
.
loginFormRef
.
validate
(
async
(
valid
)
=>
{
// 验证用户名和密码是否符合规定
if
(
!
valid
)
return
// 发送请求的操作
const
{
data
:
res
}
=
await
login
(
this
.
loginForm
)
console
.
log
(
res
,
'
返回用户注册数据
'
)
// 根据返回的状态码做想关的判断
if
(
res
.
code
!==
200
)
{
return
this
.
$message
.
error
(
res
.
message
)
}
// 判断用户注册是否填写信息完整
const
applicationstatus
=
parseInt
(
res
.
applicationstatus
)
const
can_skip
=
parseInt
(
res
.
can_skip
)
window
.
localStorage
.
setItem
(
'
applicationstatus
'
,
res
.
applicationstatus
)
window
.
localStorage
.
setItem
(
'
can_skip
'
,
res
.
can_skip
)
window
.
localStorage
.
setItem
(
'
is_check_id_card
'
,
res
.
is_check_id_card
)
console
.
log
(
!
can_skip
)
if
(
!
can_skip
)
{
if
(
applicationstatus
==
0
)
{
window
.
localStorage
.
setItem
(
'
sfzNum
'
,
res
.
sfzNum
)
this
.
$router
.
replace
({
name
:
'
StepOne
'
,
query
:
{
applicationstatus
:
'
0
'
,
data
:
res
}
})
return
}
else
if
(
applicationstatus
==
3
||
applicationstatus
==
4
||
applicationstatus
==
5
||
applicationstatus
==
6
)
{
window
.
localStorage
.
setItem
(
'
index-token
'
,
res
.
token
)
this
.
$store
.
state
.
token
=
res
.
token
window
.
localStorage
.
setItem
(
'
student_id
'
,
res
.
student_id
)
window
.
localStorage
.
setItem
(
'
sfzNum
'
,
res
.
sfzNum
)
window
.
localStorage
.
setItem
(
'
username
'
,
res
.
username
)
if
(
res
.
is_check_id_card
!=
1
)
{
this
.
$router
.
replace
({
name
:
'
StepTwo
'
})
}
else
{
this
.
$router
.
replace
({
name
:
'
StepThree
'
})
}
return
}
}
this
.
$store
.
state
.
token
=
res
.
token
window
.
localStorage
.
setItem
(
'
index-token
'
,
res
.
token
)
window
.
localStorage
.
setItem
(
'
student_id
'
,
res
.
student_id
)
window
.
localStorage
.
setItem
(
'
sfzNum
'
,
res
.
sfzNum
)
window
.
localStorage
.
setItem
(
'
username
'
,
res
.
username
)
this
.
$router
.
replace
({
name
:
'
examlist
'
})
})
}
}
// components: {
// DialogBox,
// },
}
</
script
>
</
script
>
<
style
scoped
lang=
"scss"
>
<
style
scoped
lang=
"scss"
>
.login-index
{
.login-index
{
// height: 1080px;
// height: 1080px;
background
:
#
F8F8F
8
;
background
:
#
f8f8f
8
;
.ConDivContent_bg
{
.ConDivContent_bg
{
height
:
1080px
;
height
:
1080px
;
background
:
url("../../../assets/img/login/left@2x.png")
no-repeat
center
background
:
url("../../../assets/img/login/left@2x.png")
no-repeat
;
center
;
background-size
:
100%
100%
;
background-size
:
100%
100%
;
// position: relative;
width
:
30%
;
width
:
30%
;
}
}
// @media screen and (m
in-width: 1601
px) {
// @media screen and (m
ax-width: 1600
px) {
// .ConDivContent_bg {
// .ConDivContent_bg {
//
height: 65
0px;
//
max-height: 60
0px;
// max-height: 650px;
// }
// }
// }
// }
}
}
...
...
src/views/index/login/Login.vue
View file @
b3b4562d
...
@@ -104,6 +104,7 @@ export default {
...
@@ -104,6 +104,7 @@ export default {
},
},
created
()
{
created
()
{
this
.
$emit
(
"
getStatus
"
,
false
);
this
.
$emit
(
"
getStatus
"
,
false
);
window
.
localStorage
.
setItem
(
"
index-identity
"
,
'
c59086fdb37848e7a10765812d1da349
'
);
},
},
methods
:
{
methods
:
{
// 忘记账号/密码
// 忘记账号/密码
...
@@ -127,7 +128,7 @@ export default {
...
@@ -127,7 +128,7 @@ export default {
phone
:
this
.
loginForm
.
phone
,
phone
:
this
.
loginForm
.
phone
,
password
:
this
.
loginForm
.
password
,
password
:
this
.
loginForm
.
password
,
}).
then
((
res
)
=>
{
}).
then
((
res
)
=>
{
//
console.log(res, "login");
console
.
log
(
res
,
"
login
"
);
if
(
res
.
data
.
code
!=
200
)
{
if
(
res
.
data
.
code
!=
200
)
{
return
this
.
$message
.
error
(
res
.
data
.
message
);
return
this
.
$message
.
error
(
res
.
data
.
message
);
}
}
...
@@ -135,22 +136,8 @@ export default {
...
@@ -135,22 +136,8 @@ export default {
// token存储
// token存储
window
.
localStorage
.
setItem
(
"
index-token
"
,
res
.
data
.
token
);
window
.
localStorage
.
setItem
(
"
index-token
"
,
res
.
data
.
token
);
window
.
localStorage
.
setItem
(
"
phone
"
,
res
.
data
.
phone
);
window
.
localStorage
.
setItem
(
"
phone
"
,
res
.
data
.
phone
);
// 判断营地报名进度
// 报名信息
// //是否填写个人资料
window
.
localStorage
.
setItem
(
"
camp_name
"
,
res
.
data
.
cam
.
name
);
// window.localStorage.setItem(
// "fill_individual_information",
// res.data.cam.fill_individual_information
// );
// //是否填写邀请码
// window.localStorage.setItem(
// "fill_individual_Invitationcode",
// res.data.cam.fill_individual_Invitationcode
// );
// //是否审核个人资料
// window.localStorage.setItem(
// "audit_individual_information",
// res.data.cam.audit_individual_information
// );
// 跳转到报名
// 跳转到报名
this
.
$router
.
push
({
path
:
"
/signUp/examInfo
"
});
this
.
$router
.
push
({
path
:
"
/signUp/examInfo
"
});
});
});
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment