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
29dda675
Commit
29dda675
authored
Nov 30, 2023
by
杨梦雪
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
router +query
parent
5ddadbdd
Changes
13
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
165 additions
and
55 deletions
+165
-55
src/store/index.js
src/store/index.js
+3
-0
src/views/base/active/Active.vue
src/views/base/active/Active.vue
+6
-1
src/views/base/home/Home.vue
src/views/base/home/Home.vue
+12
-2
src/views/base/login/Register.vue
src/views/base/login/Register.vue
+6
-1
src/views/base/login/Reset.vue
src/views/base/login/Reset.vue
+6
-1
src/views/base/myInfo/index.vue
src/views/base/myInfo/index.vue
+6
-1
src/views/index/Info/personalInfo.vue
src/views/index/Info/personalInfo.vue
+0
-5
src/views/index/camp/Index.vue
src/views/index/camp/Index.vue
+29
-6
src/views/index/login/Index.vue
src/views/index/login/Index.vue
+7
-2
src/views/index/login/Login.vue
src/views/index/login/Login.vue
+48
-30
src/views/index/login/Register.vue
src/views/index/login/Register.vue
+14
-2
src/views/index/login/Reset.vue
src/views/index/login/Reset.vue
+14
-2
src/views/index/recruit/Index.vue
src/views/index/recruit/Index.vue
+14
-2
No files found.
src/store/index.js
View file @
29dda675
...
...
@@ -26,6 +26,9 @@ let state = {
token
:
localStorage
.
getItem
(
"
index-token-all
"
)
||
""
,
isLogin
:
localStorage
.
getItem
(
"
isLogin
"
)
||
"
0
"
,
// 只有1为已登录
activeIndex
:
window
.
localStorage
.
getItem
(
'
index-active-path
'
)
||
"
0
"
,
query
:{
disCode
:
localStorage
.
getItem
(
"
index-disCode
"
)
||
""
,
},
};
export
default
new
Vuex
.
Store
({
...
...
src/views/base/active/Active.vue
View file @
29dda675
...
...
@@ -415,7 +415,12 @@
//查看详情
toActive
(
id
)
{
this
.
commonApi
(
36
,
id
)
this
.
$router
.
push
(
'
/active/
'
+
id
);
this
.
$router
.
push
({
path
:
'
/active/
'
+
id
,
query
:
{
...
this
.
$store
.
state
.
query
,
}
});
},
}
}
...
...
src/views/base/home/Home.vue
View file @
29dda675
...
...
@@ -177,12 +177,22 @@
methods
:
{
// 查看更多
viewMore
()
{
this
.
$router
.
push
(
'
/active
'
);
this
.
$router
.
push
({
path
:
"
/active
"
,
query
:
{
...
this
.
$store
.
state
.
query
,
}
});
},
//查看详情
toActive
(
id
){
this
.
commonApi
(
36
,
id
)
this
.
$router
.
push
(
'
/active/
'
+
id
);
this
.
$router
.
push
({
path
:
'
/active/
'
+
id
,
query
:
{
...
this
.
$store
.
state
.
query
,
}
});
},
getHot
()
{
hot
().
then
((
res
)
=>
{
...
...
src/views/base/login/Register.vue
View file @
29dda675
...
...
@@ -222,7 +222,12 @@
methods
:
{
// 去注册
toLogin
()
{
this
.
$router
.
push
(
"
/baseLogin
"
);
this
.
$router
.
push
({
path
:
"
/baseLogin
"
,
query
:
{
...
this
.
$store
.
state
.
query
,
}
});
},
// 改变密码显示状态
changePwdStatus
()
{
...
...
src/views/base/login/Reset.vue
View file @
29dda675
...
...
@@ -302,7 +302,12 @@
// token存储
window
.
localStorage
.
setItem
(
"
login_code_phone
"
,
this
.
resetForm
.
phone
);
// 跳转到登录
this
.
$router
.
replace
(
"
/baseLogin
"
);
this
.
$router
.
replace
({
path
:
"
/baseLogin
"
,
query
:
{
...
this
.
$store
.
state
.
query
,
}
});
});
});
},
...
...
src/views/base/myInfo/index.vue
View file @
29dda675
...
...
@@ -84,7 +84,12 @@
ToSignUp
(
index
)
{
this
.
campindex_type
=
index
;
if
(
this
.
campindex_type
==
0
)
{
this
.
$router
.
push
({
path
:
'
/myInfo/signUpList
'
});
this
.
$router
.
push
({
path
:
"
/myInfo/signUpList
"
,
query
:
{
...
this
.
$store
.
state
.
query
,
}
});
}
},
onResize
()
{
...
...
src/views/index/Info/personalInfo.vue
View file @
29dda675
...
...
@@ -851,13 +851,11 @@ export default {
// console.log(111);
// console.log(this.referForm.birthday);
this
.
$refs
[
"
referRef
"
].
validate
((
valid
,
object
)
=>
{
// console.log(valid, "valid");
if
(
!
valid
)
{
this
.
scrollView
(
object
);
return
false
;
}
setAccountInfo
(
this
.
referForm
).
then
((
res
)
=>
{
// console.log(res, "setAccount");
if
(
res
.
data
.
code
!=
200
)
{
if
(
res
.
data
.
code
==
400068
)
{
this
.
$parent
.
statuss
();
...
...
@@ -865,11 +863,8 @@ export default {
}
return
this
.
$message
.
error
(
res
.
data
.
msg
);
}
// console.log(3333);
this
.
$emit
(
"
getstatus
"
,
res
.
data
.
status
);
this
.
$message
.
success
(
res
.
data
.
msg
);
// let code = this.$store.state.indexIdentity;
// this.$router.push("/signUp/check?code=" + code);
this
.
referForm
=
res
.
data
.
data
;
// this.getAccount(); // 页面信息个人获取(刷新)
});
...
...
src/views/index/camp/Index.vue
View file @
29dda675
...
...
@@ -50,7 +50,7 @@
</
template
>
<div
class=
"camp_right"
ref=
"rightBox"
>
<div
class=
"back-arrow"
@
click=
"backArrow()
"
>
<div
@
click=
"backArrow()"
class=
"back-arrow
"
>
<i
class=
"el-icon-arrow-left"
/>
{{$store.state.info.name}}
</div>
...
...
@@ -159,7 +159,12 @@
backArrow
()
{
let
root
=
document
.
querySelector
(
"
:root
"
);
root
.
style
.
setProperty
(
"
--color
"
,
"
#4FACFE
"
);
this
.
$router
.
push
(
'
/myInfo/signUpList
'
);
this
.
$router
.
push
({
path
:
"
/myInfo/signUpList
"
,
query
:
{
...
this
.
$store
.
state
.
query
,
}
});
},
// torefer(val) {
// console.log(val, "val");
...
...
@@ -173,12 +178,29 @@
let
code
=
this
.
$store
.
state
.
indexIdentity
;
this
.
campindex_type
=
index
;
if
(
this
.
campindex_type
==
0
)
{
this
.
$router
.
push
(
"
/signUp/
"
+
this
.
index_status
+
"
?code=
"
+
code
);
// this.homework_val = "";
this
.
$router
.
push
({
path
:
"
/signUp/
"
+
this
.
index_status
,
query
:
{
...
this
.
$store
.
state
.
query
,
code
:
code
}
});
}
else
if
(
this
.
campindex_type
==
1
)
{
this
.
$router
.
push
(
"
/homework?code=
"
+
code
);
this
.
$router
.
push
({
path
:
"
/homework
"
,
query
:
{
...
this
.
$store
.
state
.
query
,
code
:
code
}
});
}
else
if
(
this
.
campindex_type
==
2
)
{
this
.
$router
.
push
(
"
/certificate?code=
"
+
code
);
this
.
$router
.
push
({
path
:
"
/certificate
"
,
query
:
{
...
this
.
$store
.
state
.
query
,
code
:
code
}
});
}
},
onResize
()
{
...
...
@@ -320,6 +342,7 @@
color
:
#666666
;
font-size
:
14px
;
line-height
:
32px
;
&
:hover
{
color
:
var
(
--
color
);
cursor
:
pointer
;
...
...
src/views/index/login/Index.vue
View file @
29dda675
...
...
@@ -27,13 +27,18 @@ export default {
if
(
bk_pic
)
{
this
.
bigImg
=
bk_pic
;
}
this
.
$emit
(
"
getStatus
"
,
false
);
},
methods
:
{
toHome
()
{
let
code
=
this
.
$store
.
state
.
indexIdentity
;
this
.
$router
.
push
(
"
/
"
+
code
);
this
.
$router
.
push
({
path
:
"
/
"
,
query
:
{
...
this
.
$store
.
state
.
query
,
code
:
code
}
});
}
},
};
...
...
src/views/index/login/Login.vue
View file @
29dda675
...
...
@@ -2,10 +2,10 @@
<div
class=
"container"
>
<div
class=
"title_Login"
>
<div
v-if=
"changeLogin == 1"
>
<div
class=
"title title_top"
@
click=
"toCodeLogin
"
>
<div
@
click=
"toCodeLogin"
class=
"title title_top
"
>
<div
:class=
"changeLogin == 2 ? 'change_login normal' : 'normal'"
>
验证码登录
</div>
</div>
<div
class=
"title"
@
click=
"toLogin
"
>
<div
@
click=
"toLogin"
class=
"title
"
>
<div
:class=
"changeLogin == 1 ? 'change_login' : ''"
>
账号密码登录
</div>
...
...
@@ -13,12 +13,12 @@
</div>
<div
v-else-if=
"changeLogin == 2"
>
<div
class=
"title title_top"
@
click=
"toLogin
"
>
<div
@
click=
"toLogin"
class=
"title title_top
"
>
<div
:class=
"changeLogin == 1 ? 'change_login normal' : 'normal'"
>
账号密码登录
</div>
</div>
<div
class=
"title"
@
click=
"toCodeLogin
"
>
<div
@
click=
"toCodeLogin"
class=
"title
"
>
<div
:class=
"changeLogin == 2 ? 'change_login' : ''"
>
验证码登录
</div>
</div>
</div>
...
...
@@ -27,80 +27,80 @@
<el-form
:model=
"loginForm"
:rules=
"loginFormRules"
ref=
"loginFormRef"
class=
"demo-ruleForm"
ref=
"loginFormRef"
>
<el-form-item
ref=
"phone"
prop
=
"phone"
>
<el-form-item
prop=
"phone"
ref
=
"phone"
>
<img
alt=
""
class=
"img_l"
src=
"../../../assets/img/login/username.png"
alt=
""
/>
<el-input
v-model=
"loginForm.phone"
placeholder=
"请输入手机号"
maxlength=
"11"
placeholder=
"请输入手机号"
v-model=
"loginForm.phone"
></el-input>
</el-form-item>
<el-form-item
v-if=
"changeLogin == 1"
:prop=
"changeLogin == 1 ? 'password' : ''"
ref=
"password"
v-if=
"changeLogin == 1"
>
<img
alt=
""
class=
"img_l"
src=
"../../../assets/img/login/password.png"
alt=
""
/>
<el-input
v-model=
"loginForm.password"
:type=
"isShowPwd ? 'password' : 'text'"
maxlength=
"20"
placeholder=
"请输入密码"
v-model=
"loginForm.password"
></el-input>
<img
@
click=
"changePwdStatus()"
v-if=
"!isShowPwd
"
alt=
"
"
class=
"img_r"
src=
"../../../assets/img/login/eye01.png"
alt=
"
"
v-if=
"!isShowPwd
"
/>
<img
@
click=
"changePwdStatus()"
v-if=
"isShowPwd
"
alt=
"
"
class=
"img_r"
src=
"../../../assets/img/login/eye01.png"
alt=
"
"
v-if=
"isShowPwd
"
/>
</el-form-item>
<el-form-item
v-else-if=
"changeLogin == 2"
:prop=
"changeLogin == 2 ? 'code' : ''"
ref=
"code"
v-else-if=
"changeLogin == 2"
>
<img
class=
"img_l"
src=
"@/assets/img/reset/code.png"
alt=
"
"
/>
<img
alt=
""
class=
"img_l"
src=
"@/assets/img/reset/code.png
"
/>
<el-input
v-model=
"loginForm.code"
placeholder=
"请输入短信验证码"
maxlength=
"20"
placeholder=
"请输入短信验证码"
v-model=
"loginForm.code"
></el-input>
<!-- 短信验证码 -->
<div
class=
"phoneCode"
>
<span
class=
"code"
v-show=
"showCode"
@
click=
"get
Code"
<span
@
click=
"getCode"
class=
"code"
v-show=
"show
Code"
>
获取验证码
</span
>
<span
v-show=
"!showCode"
class=
"count
"
>
{{
count
}}
s
</span>
<span
class=
"count"
v-show=
"!showCode
"
>
{{
count
}}
s
</span>
</div>
</el-form-item>
<el-form-item
style=
"margin: 40px 0 0 0"
></el-form-item>
<el-form-item>
<el-button
@
click=
"submitForm()"
>
登 录
</el-button>
</el-form-item>
<div
v-if=
"changeLogin == 1"
class=
"box
"
>
<div
class=
"box"
v-if=
"changeLogin == 1
"
>
<div>
<div
class=
"fr"
@
click=
"register()
"
>
还没有账号?立即注册
</div>
<div
class=
"fl"
@
click=
"forgetPwd()
"
>
忘记密码?
</div>
<div
@
click=
"register()"
class=
"fr
"
>
还没有账号?立即注册
</div>
<div
@
click=
"forgetPwd()"
class=
"fl
"
>
忘记密码?
</div>
</div>
<!--
<div
class=
"fc"
>
忘记密码请联系管理员邮箱:service@campcenter.cn
</div>
-->
</div>
...
...
@@ -111,7 +111,6 @@
<
script
>
/* eslint-disable */
import
Cookie
from
"
js-cookie
"
;
import
{
login
,
loginCode
}
from
"
r/index/login
"
;
import
{
mobileCheck
}
from
"
@/common/utils.js
"
;
import
{
intervalTime
}
from
"
store/time
"
;
...
...
@@ -259,13 +258,25 @@
// 忘记账号/密码
forgetPwd
()
{
let
code
=
this
.
$store
.
state
.
indexIdentity
;
this
.
$router
.
push
(
"
/reset?code=
"
+
code
);
this
.
$router
.
push
({
path
:
"
/reset
"
,
query
:
{
...
this
.
$store
.
state
.
query
,
code
:
code
}
});
},
// 去注册
register
()
{
let
code
=
this
.
$store
.
state
.
indexIdentity
;
this
.
$router
.
push
(
"
/register?code=
"
+
code
);
this
.
$router
.
push
({
path
:
"
/register
"
,
query
:
{
...
this
.
$store
.
state
.
query
,
code
:
code
}
});
},
// 改变密码显示状态
changePwdStatus
()
{
...
...
@@ -315,7 +326,13 @@
//获取主题色
window
.
localStorage
.
setItem
(
"
system_color
"
+
code
,
res
.
data
.
cam
.
system_color
);
// 跳转到报名
this
.
$router
.
replace
(
"
/signUp/undefined?code=
"
+
code
);
this
.
$router
.
replace
({
path
:
"
/signUp/undefined
"
,
query
:
{
...
this
.
$store
.
state
.
query
,
code
:
code
}
});
});
});
},
...
...
@@ -328,7 +345,7 @@
};
</
script
>
<
style
scoped
lang=
"scss"
>
<
style
lang=
"scss"
scoped
>
.flex
{
display
:
flex
;
}
...
...
@@ -354,6 +371,7 @@
color
:
var
(
--
color
);
line-height
:
20px
;
text-align
:
right
;
&
.title_top
{
display
:
flex
;
justify-content
:
flex-end
;
...
...
src/views/index/login/Register.vue
View file @
29dda675
...
...
@@ -230,7 +230,13 @@
// 去注册
toLogin
()
{
let
code
=
this
.
$store
.
state
.
indexIdentity
;
this
.
$router
.
push
(
"
/login?code=
"
+
code
);
this
.
$router
.
push
({
path
:
"
/login
"
,
query
:
{
...
this
.
$store
.
state
.
query
,
code
:
code
}
});
},
// 改变密码显示状态
changePwdStatus
()
{
...
...
@@ -316,7 +322,13 @@
//获取主题色
window
.
localStorage
.
setItem
(
"
system_color
"
+
code
,
res
.
data
.
cam
.
system_color
);
// 跳转到报名
this
.
$router
.
replace
(
"
/signUp/undefined?code=
"
+
code
);
this
.
$router
.
replace
({
path
:
"
/signUp/undefined
"
,
query
:
{
...
this
.
$store
.
state
.
query
,
code
:
code
}
});
});
});
},
...
...
src/views/index/login/Reset.vue
View file @
29dda675
...
...
@@ -219,7 +219,13 @@
// 去注册
toLogin
()
{
let
code
=
this
.
$store
.
state
.
indexIdentity
;
this
.
$router
.
push
(
"
/login?code=
"
+
code
);
this
.
$router
.
push
({
path
:
"
/login
"
,
query
:
{
...
this
.
$store
.
state
.
query
,
code
:
code
}
});
},
// 改变密码显示状态
changePwdStatus
()
{
...
...
@@ -303,7 +309,13 @@
let
code
=
this
.
$store
.
state
.
indexIdentity
;
window
.
localStorage
.
setItem
(
"
login_code_phone
"
,
this
.
resetForm
.
phone
);
// 跳转到登录
this
.
$router
.
replace
(
"
/login?code=
"
+
code
);
this
.
$router
.
replace
({
path
:
"
/login
"
,
query
:
{
...
this
.
$store
.
state
.
query
,
code
:
code
}
});
});
});
},
...
...
src/views/index/recruit/Index.vue
View file @
29dda675
...
...
@@ -77,9 +77,21 @@
toLogin
()
{
let
code
=
this
.
$store
.
state
.
indexIdentity
;
if
(
!
window
.
localStorage
.
getItem
(
"
index-token-all
"
))
{
this
.
$router
.
push
(
"
/login?code=
"
+
code
);
this
.
$router
.
push
({
path
:
"
/login
"
,
query
:
{
...
this
.
$store
.
state
.
query
,
code
:
code
}
});
}
else
{
this
.
$router
.
push
(
"
/signUp/undefined?code=
"
+
code
);
this
.
$router
.
push
({
path
:
"
/signUp/undefined
"
,
query
:
{
...
this
.
$store
.
state
.
query
,
code
:
code
}
});
}
},
// 锚点跳转方法
...
...
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