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
50bf3782
Commit
50bf3782
authored
Oct 27, 2021
by
wuwangwolihui
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
样式调整-lh
parent
cc15c522
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
48 additions
and
15 deletions
+48
-15
src/App.vue
src/App.vue
+25
-0
src/views/index/camp/Index.vue
src/views/index/camp/Index.vue
+22
-14
src/views/index/recruit/Index.vue
src/views/index/recruit/Index.vue
+1
-1
No files found.
src/App.vue
View file @
50bf3782
...
...
@@ -5,14 +5,39 @@
</
template
>
<
script
>
import
{
getCam
}
from
"
r/index/login
"
;
export
default
{
name
:
"
recruit
"
,
data
()
{
return
{};
},
created
()
{
this
.
getCam
();
},
methods
:
{
getCam
()
{
getCam
({}).
then
((
res
)
=>
{
console
.
log
(
res
,
"
getCam
"
);
let
root
=
document
.
querySelector
(
"
:root
"
);
root
.
style
.
setProperty
(
"
--color
"
,
res
.
data
.
system_color
);
root
.
style
.
setProperty
(
"
--bk_pic
"
,
res
.
data
.
background_picture
);
//当前营地的背景图
window
.
localStorage
.
setItem
(
'
bk_pic
'
,
res
.
data
.
background_picture
)
//当前营地logo
window
.
localStorage
.
setItem
(
"
system_logo
"
,
res
.
data
.
system_logo
);
window
.
localStorage
.
setItem
(
"
doubt_code
"
,
res
.
data
.
fill_individual_Invitationcode
);
//是否填写邀请码
window
.
localStorage
.
setItem
(
"
doubt_info
"
,
res
.
data
.
fill_individual_information
);
//是否填写个人资料
window
.
localStorage
.
setItem
(
"
doubt_check
"
,
res
.
data
.
audit_individual_information
);
//是否审核个人资料
});
},
},
};
</
script
>
...
...
src/views/index/camp/Index.vue
View file @
50bf3782
...
...
@@ -6,7 +6,7 @@
</el-header>
<div
class=
"com-container"
>
<div
class=
"index-container"
>
<div
class=
"camp_left"
>
<div
class=
"camp_left"
ref=
"leftBoxFu"
>
<ul
class=
"camp_left_box"
ref=
"leftBox"
:class=
"
{
'is-fixed':isPosition==1,
'is-absolute':isPosition==2,
...
...
@@ -17,7 +17,7 @@
:class=
"
{ active: campindex_type === index }"
@click="ToSignUp(index)"
>
<img
:src=
"item.image"
/>
<img
:src=
"item.image"
/>
{{
item
.
desc
}}
</li>
</ul>
...
...
@@ -71,44 +71,51 @@
},
watch
:
{
type
(
val
)
{
// console.log(val, "index");
window
.
localStorage
.
setItem
(
"
campindex_type
"
,
val
);
},
},
created
()
{
window
.
localStorage
.
setItem
(
"
campindex_type
"
,
0
);
this
.
campindex_type
=
window
.
localStorage
.
getItem
(
"
campindex_type
"
);
console
.
log
(
this
.
type
,
"
type
"
);
},
mounted
()
{
window
.
addEventListener
(
'
scroll
'
,
this
.
handleScrollX
,
true
);
window
.
addEventListener
(
'
resize
'
,
this
.
onResize
,
true
);
},
beforeDestroy
()
{
window
.
removeEventListener
(
'
scroll
'
,
this
.
handleScrollX
,
true
);
window
.
removeEventListener
(
'
resize
'
,
this
.
onResize
,
true
);
},
methods
:
{
ToSignUp
(
index
)
{
this
.
campindex_type
=
index
;
if
(
this
.
campindex_type
==
0
)
{
this
.
$router
.
replace
({
name
:
"
index-signUp
"
});
this
.
$router
.
replace
({
name
:
"
index-signUp
"
});
}
else
if
(
this
.
campindex_type
==
1
)
{
this
.
$router
.
replace
({
name
:
"
index-homework
"
});
this
.
$router
.
replace
({
name
:
"
index-homework
"
});
}
else
if
(
this
.
campindex_type
==
2
)
{
this
.
$router
.
replace
({
name
:
"
index-certificate
"
});
this
.
$router
.
replace
({
name
:
"
index-certificate
"
});
}
},
onResize
()
{
const
refLeft
=
this
.
$refs
[
'
leftBox
'
];
const
leftBoxFu
=
this
.
$refs
[
'
leftBoxFu
'
];
refLeft
.
style
.
width
=
leftBoxFu
.
offsetWidth
+
'
px
'
;
},
// 页面滚动事件
handleScrollX
()
{
let
top
=
document
.
documentElement
.
scrollTop
||
document
.
body
.
scrollTop
;
let
refLeft
=
this
.
$refs
[
'
leftBox
'
];
let
refRight
=
this
.
$refs
[
'
rightBox
'
];
const
top
=
document
.
documentElement
.
scrollTop
||
document
.
body
.
scrollTop
;
const
refLeft
=
this
.
$refs
[
'
leftBox
'
];
const
leftBoxFu
=
this
.
$refs
[
'
leftBoxFu
'
];
const
refRight
=
this
.
$refs
[
'
rightBox
'
];
if
(
top
>
0
)
{
if
(
this
.
isPosition
==
0
)
{
this
.
scorllHeight
=
refRight
.
offsetHeight
-
refLeft
.
offsetHeight
;
refLeft
.
style
.
width
=
leftBoxFu
.
offsetWidth
+
'
px
'
;
}
this
.
isPosition
=
1
;
}
else
{
if
(
this
.
isPosition
=
1
)
{
}
else
{
if
(
this
.
isPosition
=
1
)
{
this
.
isPosition
=
0
;
}
}
...
...
@@ -116,9 +123,10 @@
if
(
this
.
isPosition
==
1
)
{
this
.
isPosition
=
2
;
}
}
else
if
(
top
<
this
.
scorllHeight
)
{
}
else
if
(
top
<
this
.
scorllHeight
)
{
if
(
this
.
isPosition
==
2
)
{
this
.
isPosition
=
1
;
refLeft
.
style
.
width
=
leftBoxFu
.
offsetWidth
+
'
px
'
;
}
}
},
...
...
@@ -178,7 +186,7 @@
&
.is-fixed
{
position
:
fixed
;
top
:
104px
;
width
:
14
.4%
;
/*width: 14.4%;*/
max-width
:
280px
;
min-width
:
216px
;
}
...
...
src/views/index/recruit/Index.vue
View file @
50bf3782
...
...
@@ -59,7 +59,7 @@
"
index-identity
"
,
"
c59086fdb37848e7a10765812d1da349
"
);
this
.
getCam
();
//
this.getCam();
},
methods
:
{
toLogin
()
{
...
...
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