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
6c202cdb
Commit
6c202cdb
authored
Nov 09, 2021
by
杨梦雪
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
111
parent
e52b0fb8
Changes
13
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
70 additions
and
110 deletions
+70
-110
public/index.html
public/index.html
+2
-2
src/assets/scss/btn.scss
src/assets/scss/btn.scss
+1
-0
src/common/validator.js
src/common/validator.js
+4
-47
src/components/index/SignUp/invitation.vue
src/components/index/SignUp/invitation.vue
+12
-17
src/components/index/SignUp/pass.vue
src/components/index/SignUp/pass.vue
+1
-1
src/components/index/SignUp/referInfo.vue
src/components/index/SignUp/referInfo.vue
+34
-13
src/components/index/SignUp/success.vue
src/components/index/SignUp/success.vue
+5
-1
src/request/index/network.js
src/request/index/network.js
+4
-7
src/router/index.js
src/router/index.js
+2
-3
src/views/index/camp/Index.vue
src/views/index/camp/Index.vue
+2
-0
src/views/index/camp/SignUp.vue
src/views/index/camp/SignUp.vue
+2
-4
src/views/index/login/Login.vue
src/views/index/login/Login.vue
+1
-1
src/views/index/recruit/Index.vue
src/views/index/recruit/Index.vue
+0
-14
No files found.
public/index.html
View file @
6c202cdb
...
...
@@ -5,11 +5,11 @@
<meta
http-equiv=
"X-UA-Compatible"
content=
"IE=edge"
>
<meta
name=
"viewport"
content=
"width=device-width,initial-scale=1.0"
>
<link
rel=
"icon"
href=
"<%= BASE_URL %>favicon.ico"
>
<title>
<
%=
htmlWebpackPlugin
.
options
.
title
%
>
</title>
<title>
</title>
</head>
<body>
<noscript>
<strong>
We're sorry but
<
%=
htmlWebpackPlugin
.
options
.
title
%
>
doesn't work properly without JavaScript enabled. Please enable it to continue.
</strong>
<strong>
We're sorry but doesn't work properly without JavaScript enabled. Please enable it to continue.
</strong>
</noscript>
<div
id=
"app"
></div>
<!-- built files will be auto injected -->
...
...
src/assets/scss/btn.scss
View file @
6c202cdb
...
...
@@ -6,6 +6,7 @@
height
:
50px
;
background
:
var
(
--
color
);
border-radius
:
4px
;
border-color
:
var
(
--
color
);
opacity
:
0
.8
;
line-height
:
50px
;
text-align
:
center
;
...
...
src/common/validator.js
View file @
6c202cdb
...
...
@@ -24,55 +24,12 @@ export default {
},
validateid_card
:
function
(
rule
,
value
,
callback
)
{
// console.log(value, 'sss')
if
(
!
value
)
{
return
callback
(
new
Error
(
"
身份证号不能为空
"
));
}
console
.
log
(
value
,
'
sss
'
)
if
(
!
/
(
^
\d{15}
$
)
|
(
^
\d{17}(\d
|X|x
)
$
)
/
.
test
(
value
))
{
return
callback
(
new
Error
(
"
你输入的身份证长度或格式错误
"
));
}
//身份证城市
var
aCity
=
{
11
:
"
北京
"
,
12
:
"
天津
"
,
13
:
"
河北
"
,
14
:
"
山西
"
,
15
:
"
内蒙古
"
,
21
:
"
辽宁
"
,
22
:
"
吉林
"
,
23
:
"
黑龙江
"
,
31
:
"
上海
"
,
32
:
"
江苏
"
,
33
:
"
浙江
"
,
34
:
"
安徽
"
,
35
:
"
福建
"
,
36
:
"
江西
"
,
37
:
"
山东
"
,
41
:
"
河南
"
,
42
:
"
湖北
"
,
43
:
"
湖南
"
,
44
:
"
广东
"
,
45
:
"
广西
"
,
46
:
"
海南
"
,
50
:
"
重庆
"
,
51
:
"
四川
"
,
52
:
"
贵州
"
,
53
:
"
云南
"
,
54
:
"
西藏
"
,
61
:
"
陕西
"
,
62
:
"
甘肃
"
,
63
:
"
青海
"
,
64
:
"
宁夏
"
,
65
:
"
新疆
"
,
71
:
"
台湾
"
,
81
:
"
香港
"
,
82
:
"
澳门
"
,
91
:
"
国外
"
};
if
(
!
aCity
[
parseInt
(
value
.
substr
(
0
,
2
))])
{
return
callback
(
new
Error
(
"
你的身份证地区非法
"
));
callback
(
new
Error
(
"
你输入的身份证长度或格式错误
"
));
}
return
callback
();
callback
();
},
// 数字验证
validateNumber
:
function
(
rule
,
value
,
callback
)
{
...
...
src/components/index/SignUp/invitation.vue
View file @
6c202cdb
...
...
@@ -14,7 +14,6 @@
@
input=
"changeValue1"
@
focus=
"getFocus(0, $event)"
v-model=
"invatation1"
maxlength=
"19"
>
</el-input>
<el-input
...
...
@@ -24,7 +23,6 @@
@
input=
"changeValue1"
@
focus=
"getFocus(1, $event)"
v-model=
"invatation2"
maxlength=
"4"
>
</el-input>
<el-input
...
...
@@ -34,7 +32,6 @@
@
input=
"changeValue1"
@
focus=
"getFocus(2, $event)"
v-model=
"invatation3"
maxlength=
"4"
>
</el-input>
<el-input
...
...
@@ -44,7 +41,6 @@
@
input=
"changeValue1"
@
focus=
"getFocus(3, $event)"
v-model=
"invatation4"
maxlength=
"4"
></el-input>
</div>
<!--
<div
class=
"errorCode"
>
该邀请码无效,请输入正确的邀请码。
</div>
-->
...
...
@@ -73,13 +69,15 @@ export default {
invatation3
:
""
,
invatation4
:
""
,
inputFlag
:
true
,
};
},
watch
:
{
invatation1
:
function
()
{
// /\n/g(删除制表符 /t的正则)
this
.
invatation1
=
this
.
invatation1
.
replace
(
/
[\W]
/g
,
""
)
// .replace(/\n/g,"")
// .replace("/\n/g",'')
.
toUpperCase
()
.
substring
(
0
,
4
);
},
...
...
@@ -108,20 +106,21 @@ export default {
// },
//第一个输入框
changeValue1
(
e
)
{
// console.log(e, "输入");
if
(
e
.
length
==
19
&&
e
.
indexOf
(
"
-
"
)
!==
-
1
)
{
const
code
=
e
.
trim
()
console
.
log
(
code
,
"
输入111
"
)
if
(
code
.
indexOf
(
"
-
"
)
!==
-
1
)
{
//如果是复制过来的带'-'邀请码
let
copyCode
=
e
.
split
(
"
-
"
);
// console.log(copyCode, "输入
");
let
copyCode
=
cod
e
.
split
(
"
-
"
);
console
.
log
(
copyCode
,
"
输入222
"
);
this
.
invatation1
=
copyCode
[
0
];
this
.
invatation2
=
copyCode
[
1
];
this
.
invatation3
=
copyCode
[
2
];
this
.
invatation4
=
copyCode
[
3
];
this
.
$refs
.
input3
.
focus
();
}
else
if
(
e
.
length
>
4
)
{
this
.
changeValue
(
e
.
substring
(
0
,
4
));
}
else
if
(
cod
e
.
length
>
4
)
{
this
.
changeValue
(
cod
e
.
substring
(
0
,
4
));
}
else
{
this
.
changeValue
(
e
);
this
.
changeValue
(
cod
e
);
}
},
// 输入框
...
...
@@ -206,14 +205,11 @@ export default {
}
setInviteCode
({
code
:
code
}).
then
((
res
)
=>
{
console
.
log
(
res
,
"
code
"
);
//
console.log(res, "code");
if
(
res
.
data
.
code
!==
200
)
{
return
this
.
$message
.
error
(
res
.
data
.
message
);
}
// this.status=res.data.status
this
.
$emit
(
"
getstatus
"
,
res
.
data
.
status
);
// console.log( res.data.status)
// this.$message.success(res.data.message);
});
},
},
...
...
@@ -262,6 +258,5 @@ export default {
color
:
#d7373f
;
line-height
:
12px
;
}
}
</
style
>
src/components/index/SignUp/pass.vue
View file @
6c202cdb
...
...
@@ -51,7 +51,7 @@ export default {
// console.log(isNexts, "2222");
signUpInit
({}).
then
((
res
)
=>
{
//
console.log(res, "signUpInit");
console
.
log
(
res
,
"
signUpInit
"
);
if
(
res
.
data
.
code
!=
200
)
{
if
(
res
.
data
.
code
==
400001
)
{
this
.
status
=
6
;
...
...
src/components/index/SignUp/referInfo.vue
View file @
6c202cdb
...
...
@@ -35,7 +35,7 @@
<el-col
:span=
"12"
>
<el-form-item
label=
"身份证号"
prop=
"id_card"
>
<el-input
ref=
"id
C
ard"
ref=
"id
_c
ard"
v-model=
"referForm.id_card"
placeholder=
"填写真实姓名身份证号"
size=
"small"
...
...
@@ -157,13 +157,20 @@
</el-col>
<el-col
:span=
"12"
>
<el-form-item
label=
"政治面貌"
prop=
"political_status"
>
<el-
inpu
t
<el-
selec
t
ref=
"political_status"
v-model=
"referForm.political_status"
placeholder=
"填写政治面貌"
size=
"small"
clearable
/>
>
<el-option
v-for=
"item in political_status"
:key=
"item.id"
:label=
"item.name"
:value=
"item.name"
>
</el-option>
</el-select>
</el-form-item>
</el-col>
<el-col
:span=
"12"
>
...
...
@@ -411,7 +418,7 @@ export default {
{
required
:
true
,
validator
:
validateContents
,
trigger
:
"
change
"
},
],
nation
:
[
{
required
:
true
,
message
:
"
民族不能为空!
"
,
trigger
:
"
blur
"
},
{
required
:
true
,
message
:
"
民族不能为空!
"
,
trigger
:
"
change
"
},
],
start_school_date
:
[
{
...
...
@@ -513,7 +520,22 @@ export default {
],
bdYear
:
""
,
//选择的生日年份
bdMonth
:
""
,
//选择的生日月份
bdDay
:
""
,
//选择的生日日期F
bdDay
:
""
,
//选择的生日日期
// 政治面貌
political_status
:
[
{
id
:
1
,
name
:
"
党员
"
,
},
{
id
:
2
,
name
:
"
团员
"
,
},
{
id
:
3
,
name
:
"
群众
"
,
},
],
// 上传的图片
dialogImageUrl
:
""
,
dialogVisible
:
false
,
...
...
@@ -529,7 +551,7 @@ export default {
const
code
=
this
.
$store
.
state
.
indexIdentity
;
this
.
phone
=
window
.
localStorage
.
getItem
(
"
phone
"
+
code
);
//本地取用户手机号
let
signUpFile
=
window
.
localStorage
.
getItem
(
"
sign_up_file_
"
+
window
.
localStorage
.
getItem
(
"
phone
"
+
code
)
"
sign_up_file_
"
+
window
.
localStorage
.
getItem
(
"
phone
"
+
code
)
+
code
);
// console.log(signUpFile)
if
(
signUpFile
&&
JSON
.
parse
(
signUpFile
).
length
>
0
)
{
...
...
@@ -867,7 +889,8 @@ export default {
let
code
=
this
.
$store
.
state
.
indexIdentity
;
window
.
localStorage
.
setItem
(
"
sign_up_file_
"
+
+
window
.
localStorage
.
getItem
(
"
phone
"
+
code
),
+
window
.
localStorage
.
getItem
(
"
phone
"
+
code
)
+
code
,
JSON
.
stringify
(
this
.
fileList
)
);
})
...
...
@@ -912,7 +935,9 @@ export default {
this
.
fileList
.
splice
(
idx
,
1
);
let
code
=
this
.
$store
.
state
.
indexIdentity
;
window
.
localStorage
.
setItem
(
"
sign_up_file_
"
+
window
.
localStorage
.
getItem
(
"
phone
"
+
code
),
"
sign_up_file_
"
+
window
.
localStorage
.
getItem
(
"
phone
"
+
code
)
+
code
,
JSON
.
stringify
(
this
.
fileList
)
);
}
...
...
@@ -972,8 +997,6 @@ export default {
// console.log(res, "setAccount");
if
(
res
.
data
.
code
!=
200
)
{
if
(
res
.
data
.
code
==
400068
)
{
// let code = this.$store.state.indexIdentity;
// this.$router.push("/signUp/check?code=" + code);
this
.
$parent
.
statuss
();
return
this
.
$message
.
error
(
res
.
data
.
message
);
}
...
...
@@ -981,11 +1004,9 @@ export default {
}
// console.log(3333);
this
.
$emit
(
"
getstatus
"
,
res
.
data
.
status
);
// this.$emit("getstatus", res.data.status);
this
.
$message
.
success
(
res
.
data
.
message
);
let
code
=
this
.
$store
.
state
.
indexIdentity
;
this
.
$router
.
push
(
"
/signUp/check?code=
"
+
code
);
// this.$parent.is_nextevent();
this
.
referForm
=
res
.
data
.
data
;
});
});
...
...
src/components/index/SignUp/success.vue
View file @
6c202cdb
...
...
@@ -39,7 +39,11 @@ export default {
return
this
.
$message
.
error
(
res
.
data
.
message
);
}
// this.$message.success(res.data.message);
window
.
location
.
href
=
res
.
data
.
pdf_address
;
if
(
res
.
data
.
is_dowload
==
1
)
{
window
.
location
.
href
=
res
.
data
.
pdf_address
;
}
else
{
return
this
.
$message
.
error
(
"
营地下载证书还未开始
"
);
}
});
},
},
...
...
src/request/index/network.js
View file @
6c202cdb
...
...
@@ -182,11 +182,11 @@ export function request(config) {
instance
.
interceptors
.
response
.
use
(
(
res
)
=>
{
console
.
log
(
res
,
'
11111
'
)
console
.
log
(
res
.
data
.
code
,
'
res.data.code
'
)
//
console.log(res, '11111')
//
console.log(res.data.code, 'res.data.code')
if
(
res
.
data
.
code
==
400034
||
res
.
data
.
code
==
400035
||
res
.
data
.
code
==
400001
||
//
res.data.code == 400001 ||
res
.
data
.
code
==
400002
||
res
.
data
.
code
==
400003
)
{
...
...
@@ -202,9 +202,8 @@ export function request(config) {
return
}
if
(
res
.
data
.
code
==
400023
)
{
console
.
log
(
store
.
state
.
indexIdentity
,
'
store.state.indexIdentity
'
)
//
console.log(store.state.indexIdentity, 'store.state.indexIdentity')
let
code
=
store
.
state
.
indexIdentity
;
window
.
localStorage
.
removeItem
(
"
doubt_code
"
+
code
);
window
.
localStorage
.
removeItem
(
"
doubt_info
"
+
code
);
window
.
localStorage
.
removeItem
(
"
doubt_check
"
+
code
);
...
...
@@ -229,13 +228,11 @@ export function request(config) {
Notification
({
message
:
res
.
data
.
message
,
duration
:
3000
,
});
return
}
if
(
res
.
data
.
code
==
400003
)
{
let
code
=
this
.
$store
.
state
.
indexIdentity
;
window
.
localStorage
.
removeItem
(
"
doubt_code
"
+
code
);
window
.
localStorage
.
removeItem
(
"
doubt_info
"
+
code
);
window
.
localStorage
.
removeItem
(
"
doubt_check
"
+
code
);
...
...
src/router/index.js
View file @
6c202cdb
...
...
@@ -91,11 +91,11 @@ router.onError((error) => {
})
function
checkCam
(
code
,
cb
)
{
console
.
log
(
code
,
'
code
'
)
//
console.log(code, 'code')
// console.log(cb, 'cb')
// const code=store.status.indexIdentity
store
.
state
.
indexIdentity
=
code
;
console
.
log
(
code
,
'
code
'
)
//
console.log(code, 'code')
if
(
!
code
)
{
Message
({
message
:
"
请访问正确的营地链接地址1
"
,
...
...
@@ -158,7 +158,6 @@ router.beforeEach((to, from, next) => {
code
=
to
.
params
.
code
?
to
.
params
.
code
:
to
.
query
.
code
;
checkCam
(
code
,
(
res
)
=>
{
if
(
res
)
{
let
token
=
window
.
localStorage
.
getItem
(
"
index-token
"
+
code
);
// console.log(token, "token")
//检查登陆情况
...
...
src/views/index/camp/Index.vue
View file @
6c202cdb
...
...
@@ -42,6 +42,7 @@ import Cookie from "js-cookie";
import
Header
from
"
@/components/index/SignUp/Header.vue
"
;
import
Footer
from
"
@/components/index/Footer.vue
"
;
export
default
{
name
:
"
campIndex
"
,
components
:
{
...
...
@@ -83,6 +84,7 @@ export default {
// },
},
created
()
{
this
.
getStatus
();
this
.
ToSignUp
(
this
.
index
);
},
...
...
src/views/index/camp/SignUp.vue
View file @
6c202cdb
...
...
@@ -92,11 +92,10 @@ export default {
signUpInit
(
status_val
)
{
console
.
log
(
11111
);
// console.log(status_val, "11111");
// console.log(isNexts, "2222");
signUpInit
({}).
then
((
res
)
=>
{
console
.
log
(
22222
);
//
console.log(res, "signUpInit");
//
console.log(22222);
console
.
log
(
res
,
"
signUpInit
"
);
if
(
res
.
data
.
code
!=
200
)
{
// if (res.data.code == 400001) {
// this.status = 6;
...
...
@@ -149,7 +148,6 @@ export default {
this
.
status
=
3
;
// console.log(this.status, "this.status ");
// console.log(this.isNexts ,'this.isNexts ')
if
(
this
.
isNexts
==
1
)
{
// console.log(11111);
if
(
res
.
data
.
examine_status
==
1
)
{
...
...
src/views/index/login/Login.vue
View file @
6c202cdb
...
...
@@ -53,7 +53,7 @@
</el-form-item>
<div
class=
"box"
>
<div
class=
"fr"
@
click=
"register()"
>
还没有账号?立即注册
</div>
<
div
class=
"fl"
@
click=
"forgetPwd()"
>
忘记密码?
</div
>
<
!--
<div
class=
"fl"
@
click=
"forgetPwd()"
>
忘记密码?
</div>
--
>
</div>
</el-form>
</div>
...
...
src/views/index/recruit/Index.vue
View file @
6c202cdb
...
...
@@ -65,21 +65,7 @@ export default {
let
code
=
this
.
$store
.
state
.
indexIdentity
getCamInfo
(
code
).
then
((
res
)
=>
{
console
.
log
(
res
,
'
33333
'
)
// if (res.data.code == 400034 ||
// res.data.code == 400035 ||
// res.data.code == 400001 ||
// res.data.code == 400002 ||
// res.data.code == 400003) {
// Notification({
// message: res.data.message,
// duration: 1000,
// });
// cb && cb(false);
return
false
;
// }
})
},
methods
:
{
...
...
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