Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mr-julyedu
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
baiguangyao
mr-julyedu
Commits
6f77278a
Commit
6f77278a
authored
Apr 23, 2019
by
xuzhenghua
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
idea
parent
d97bd399
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
29 additions
and
12 deletions
+29
-12
.idea/workspace.xml
+0
-0
src/components/classify/courselist.js
+24
-8
src/components/classify/courselist.scss
+1
-1
src/components/classify/index.js
+1
-1
src/router.js
+3
-2
No files found.
.idea/workspace.xml
deleted
100644 → 0
View file @
d97bd399
This diff is collapsed.
Click to expand it.
src/components/classify/courselist.js
View file @
6f77278a
...
...
@@ -13,14 +13,21 @@ class Classify extends Component {
handleClick
()
{
console
.
log
(
1
);
}
ontabclick
(
tab
,
index
)
{
console
.
log
(
tab
,
index
)
}
pulldown
(){
alert
(
2
)
pulldown
()
{
this
.
setState
(
status
=>
({
ispull
:
!
status
.
ispull
,
display
:
status
.
ispull
?
'none'
:
'block'
}));
}
state
=
{
ispull
:
false
,
display
:
'none'
,
mockData
:
[
{
title
:
'三月面试求职三月面试求职三月面试求职'
,
...
...
@@ -115,13 +122,22 @@ class Classify extends Component {
{
title
:
'数据结构'
},
{
title
:
'数学'
},
];
const
bottom
=
(
<
i
className
=
{
'iconfont iconiconfront-69 pull-down'
}
><
/i
>
)
const
top
=
(
<
i
className
=
{
'iconfont iconiconfront-71 pull-down'
}
><
/i
>
)
return
(
<
div
className
=
'class-
box
'
>
<
div
className
=
'class-
child
'
>
<
div
>
<
WhiteSpace
/>
<
i
className
=
{
'iconfont iconiconfront-69 pull-down'
}
onClick
=
{
this
.
pulldown
.
bind
(
this
)}
><
/i
>
<
Tabs
<
div
onClick
=
{
this
.
pulldown
.
bind
(
this
)}
>
{
this
.
state
.
ispull
?
top
:
bottom
}
<
/div
>
<
Tabs
tabs
=
{
tabs
}
animated
=
{
false
}
onTabClick
=
{(
tab
,
index
)
=>
this
.
ontabclick
(
tab
,
index
)}
...
...
@@ -154,13 +170,13 @@ class Classify extends Component {
<
/Tabs
>
<
WhiteSpace
/>
<
/div
>
<
div
className
=
'mbc-box'
>
<
div
className
=
'mbc-box'
style
=
{{
display
:
this
.
state
.
display
}}
>
<
div
className
=
"tabcontent"
>
<
div
className
=
"class-course"
>
<
p
className
=
'course-items-title'
>
基础入门
<
/p
>
<
div
className
=
'items-box'
>
{
this
.
state
.
dataList
.
map
((
item
,
index
)
=>
{
this
.
state
.
dataList
.
map
((
item
,
index
)
=>
{
return
(
<
a
href
=
"/#"
key
=
{
index
}
className
=
'item-label'
>
{
item
.
title
}
<
/a
>
)
...
...
@@ -172,7 +188,7 @@ class Classify extends Component {
<
p
className
=
'course-items-title'
>
进阶提高
<
/p
>
<
div
className
=
'items-box'
>
{
this
.
state
.
dataList
.
map
((
item
,
index
)
=>
{
this
.
state
.
dataList
.
map
((
item
,
index
)
=>
{
return
(
<
a
href
=
"/#"
key
=
{
index
}
className
=
'item-label'
>
{
item
.
title
}
<
/a
>
)
...
...
src/components/classify/courselist.scss
View file @
6f77278a
.class-
box
{
.class-
child
{
padding
:
0
12px
;
position
:
relative
;
.v-list-item
{
...
...
src/components/classify/index.js
View file @
6f77278a
...
...
@@ -54,7 +54,7 @@ class Classify extends Component {
{
this
.
state
.
dataList
.
map
((
item
,
index
)
=>
{
return
(
<
a
href
=
"/
#
"
key
=
{
index
}
className
=
'item-banner'
><
img
<
a
href
=
"/
classify/courselist
"
key
=
{
index
}
className
=
'item-banner'
><
img
src
=
{
item
.
src
}
alt
=
""
/><
/a
>
)
...
...
src/router.js
View file @
6f77278a
...
...
@@ -16,10 +16,11 @@ const router = () => (
<
Switch
>
<
Route
exact
path
=
"/"
component
=
{
Index
}
><
/Route
>
<
Route
path
=
"/index"
component
=
{
Index
}
><
/Route
>
<
Route
path
=
'/classify'
component
=
{
Classify
}
><
/Route
>
<
Route
path
=
'/classify'
component
=
{
Classify
}
>
<
Route
path
=
'/classify/courselist'
component
=
{
CourseList
}
><
/Route
>
<
/Route
>
<
Route
path
=
'/study'
component
=
{
Study
}
><
/Route
>
<
Route
path
=
'/my'
component
=
{
My
}
><
/Route
>
<
Route
path
=
'/courselist'
component
=
{
CourseList
}
><
/Route
>
<
Route
path
=
'/search'
component
=
{
Search
}
><
/Route
>
<
/Switch
>
<
Menu
/>
...
...
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