Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
X
xiaomai-cloud-class-web
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
xiaomai-cloud-class
xiaomai-cloud-class-web
Commits
6714a322
Commit
6714a322
authored
Apr 08, 2021
by
zangsuyun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
style:更换图标
parent
43c3187e
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
34 additions
and
16 deletions
+34
-16
src/modules/knowledge-base/components/Classification.jsx
+26
-7
src/modules/knowledge-base/components/KnowledgeBaseFilter.jsx
+2
-3
src/modules/knowledge-base/index.jsx
+4
-4
src/routes/config/mainRoutes.tsx
+2
-2
No files found.
src/modules/knowledge-base/components/Classification.jsx
View file @
6714a322
...
...
@@ -3,7 +3,7 @@
* @Author: zangsuyun
* @Date: 2021-03-19 18:05:23
* @LastEditors: zangsuyun
* @LastEditTime: 2021-04-0
6 11:17:10
* @LastEditTime: 2021-04-0
8 11:29:12
* @Copyright: © 2020 杭州杰竞科技有限公司 版权所有
*/
...
...
@@ -143,13 +143,31 @@ class Classification extends Component {
);
item
.
icon
=
item
.
categoryName
===
"未分类"
?
(
<
span
className=
"icon iconfont"
style=
{
{
color
:
"#FBD140"
}
}
>

</
span
>
<
img
style=
{
{
width
:
"24px"
,
height
:
"24px"
,
opacity
:
!
value
||
(
value
&&
item
.
categoryName
.
indexOf
(
value
)
>
-
1
)
?
1
:
0.5
,
}
}
src=
"https://image.xiaomaiketang.com/xm/defaultCategory.png"
alt=
""
/>
)
:
(
<
span
className=
"icon iconfont"
style=
{
{
color
:
"#FBD140"
}
}
>

</
span
>
<
img
style=
{
{
width
:
"24px"
,
height
:
"24px"
,
opacity
:
!
value
||
(
value
&&
item
.
categoryName
.
indexOf
(
value
)
>
-
1
)
?
1
:
0.5
,
}
}
src=
"https://image.xiaomaiketang.com/xm/hasCategory.png"
alt=
""
/>
);
if
(
item
.
sonCategoryList
)
{
item
.
children
=
this
.
renderTreeNodes
(
item
.
sonCategoryList
,
value
);
...
...
@@ -178,6 +196,7 @@ class Classification extends Component {
// TODO 调用查询分类接口
this
.
queryCategoryTree
(
value
);
}
}
enterButton=
{
<
span
className=
"icon iconfont"
>

</
span
>
}
/>
<
div
className=
"sider-btn"
>
<
Button
...
...
src/modules/knowledge-base/components/KnowledgeBaseFilter.jsx
View file @
6714a322
...
...
@@ -3,7 +3,7 @@
* @Author: zangsuyun
* @Date: 2021-03-12 11:16:38
* @LastEditors: zangsuyun
* @LastEditTime: 2021-04-0
2 15:32:13
* @LastEditTime: 2021-04-0
8 11:51:42
* @Copyright: © 2020 杭州杰竞科技有限公司 版权所有
*/
...
...
@@ -39,7 +39,7 @@ class KnowledgeBaseFilter extends React.Component {
},
},
()
=>
{
flag
&&
this
.
props
.
onChange
(
this
.
state
.
query
);
this
.
props
.
onChange
(
this
.
state
.
query
,
flag
);
}
);
};
...
...
@@ -60,7 +60,6 @@ class KnowledgeBaseFilter extends React.Component {
const
{
query
:
{
name
,
type
},
}
=
this
.
state
;
return
(
<
div
className=
"knowledge-base-filter"
>
<
Row
type=
"flex"
justify=
"space-between"
align=
"top"
>
...
...
src/modules/knowledge-base/index.jsx
View file @
6714a322
...
...
@@ -3,7 +3,7 @@
* @Author: zangsuyun
* @Date: 2021-03-12 10:43:10
* @LastEditors: zangsuyun
* @LastEditTime: 2021-04-0
7 13:50:11
* @LastEditTime: 2021-04-0
8 11:52:42
* @Copyright: © 2020 杭州杰竞科技有限公司 版权所有
*/
import
React
from
"react"
;
...
...
@@ -52,7 +52,7 @@ export default class KnowledgeBase extends React.Component {
});
};
// 获取知识库列表
handleFetchScheduleList
=
(
_query
=
{})
=>
{
handleFetchScheduleList
=
(
_query
=
{}
,
flag
=
true
)
=>
{
const
query
=
{
...
this
.
state
.
query
,
...
_query
,
...
...
@@ -61,7 +61,7 @@ export default class KnowledgeBase extends React.Component {
// 更新请求参数
this
.
setState
({
query
});
KnowledgeAPI
.
queryPageKnowledgeForManager
(
query
).
then
((
res
)
=>
{
flag
&&
KnowledgeAPI
.
queryPageKnowledgeForManager
(
query
).
then
((
res
)
=>
{
// KnowledgeAPI.videoSchedulePage(query).then((res) => {
const
{
result
=
{}
}
=
res
||
{};
const
{
records
=
[],
total
=
0
}
=
result
;
...
...
@@ -95,7 +95,7 @@ export default class KnowledgeBase extends React.Component {
</
div
>
<
div
className=
"liner"
style=
{
{
backgroundColor
:
"
#ddd"
,
width
:
1
,
margin
:
"1px 20
px"
}
}
style=
{
{
backgroundColor
:
"
rgb(238, 238, 238)"
,
width
:
0.5
,
margin
:
"1px 24px 1px 2
px"
}
}
></
div
>
<
div
className=
"right"
style=
{
{
width
:
"calc(100% - 285px)"
}
}
>
<
KnowledgeBaseFilter
onChange=
{
this
.
handleFetchScheduleList
}
/>
...
...
src/routes/config/mainRoutes.tsx
View file @
6714a322
...
...
@@ -2,7 +2,7 @@
* @Author: 吴文洁
* @Date: 2020-04-29 10:26:32
* @LastEditors: zangsuyun
* @LastEditTime: 2021-0
3-29 09:57:08
* @LastEditTime: 2021-0
4-07 16:12:14
* @Description: 内容线路由配置
*/
import
Home
from
"@/modules/home/Home"
;
...
...
@@ -25,7 +25,7 @@ import PlanPage from "@/modules/plan-manage/PlanPage";
import
AddPlanPage
from
"@/modules/plan-manage/AddPlan"
;
import
LearningDataPage
from
"@/modules/plan-manage/LearningData"
;
import
StoreInfoPage
from
"@/modules/store-manage/StoreInfo"
;
import
KnowledgeBase
from
"@/modules/knowledge-base"
;
import
KnowledgeBase
from
"@/modules/knowledge-base
/index
"
;
import
QuestionBankIndex
from
"@/modules/teach-tool/QuestionBankIndex"
;
import
QuestionCategoryManage
from
"@/modules/teach-tool/QuestionCategoryManage"
;
import
AddNewQuestion
from
"@/modules/teach-tool/AddNewQuestion"
;
...
...
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