Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gs1-office-web-sit
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
吴迪
gs1-office-web-sit
Commits
33f81a3a
Commit
33f81a3a
authored
Dec 13, 2021
by
rongkailun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
【新增】党史教育学习
parent
c3ee0fa6
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
47 additions
and
0 deletions
+47
-0
NewsController.java
...a/io/office/modules/manage/controller/NewsController.java
+8
-0
NewsDao.java
src/main/java/io/office/modules/manage/dao/NewsDao.java
+4
-0
NewsService.java
...in/java/io/office/modules/manage/service/NewsService.java
+3
-0
NewsServiceImpl.java
...o/office/modules/manage/service/impl/NewsServiceImpl.java
+6
-0
NewsDao.xml
src/main/resources/mapper/manage/NewsDao.xml
+26
-0
No files found.
src/main/java/io/office/modules/manage/controller/NewsController.java
View file @
33f81a3a
...
@@ -402,4 +402,12 @@ public class NewsController extends AbstractController {
...
@@ -402,4 +402,12 @@ public class NewsController extends AbstractController {
}
}
/**党史学习教育专栏*/
@Login
@GetMapping
(
"/api/dsxxjyTop8"
)
public
R
dsxxjyTop8
()
{
List
<
NewsEntity
>
list
=
this
.
newsService
.
dsxxjyTop8
();
return
R
.
ok
().
put
(
"data"
,
list
);
}
}
}
src/main/java/io/office/modules/manage/dao/NewsDao.java
View file @
33f81a3a
...
@@ -75,4 +75,8 @@ public interface NewsDao extends BaseMapper<NewsEntity> {
...
@@ -75,4 +75,8 @@ public interface NewsDao extends BaseMapper<NewsEntity> {
List
<
NewsEntity
>
newsTop10
();
List
<
NewsEntity
>
newsTop10
();
List
<
Map
<
String
,
Object
>>
searchKnowledgeInfoNewList
(
@Param
(
"params"
)
Map
<
String
,
Object
>
map
,
Page
page
);
List
<
Map
<
String
,
Object
>>
searchKnowledgeInfoNewList
(
@Param
(
"params"
)
Map
<
String
,
Object
>
map
,
Page
page
);
List
<
NewsEntity
>
dsxxjyTop8
();
}
}
src/main/java/io/office/modules/manage/service/NewsService.java
View file @
33f81a3a
...
@@ -74,5 +74,8 @@ public interface NewsService extends IService<NewsEntity> {
...
@@ -74,5 +74,8 @@ public interface NewsService extends IService<NewsEntity> {
List
<
NewsEntity
>
newsTop10
();
List
<
NewsEntity
>
newsTop10
();
Page
<
List
<
Map
<
String
,
Object
>>>
searchKnowledgePageList
(
NewsParams
params
,
Page
page
);
Page
<
List
<
Map
<
String
,
Object
>>>
searchKnowledgePageList
(
NewsParams
params
,
Page
page
);
List
<
NewsEntity
>
dsxxjyTop8
();
}
}
src/main/java/io/office/modules/manage/service/impl/NewsServiceImpl.java
View file @
33f81a3a
...
@@ -459,6 +459,12 @@ public class NewsServiceImpl extends ServiceImpl<NewsDao, NewsEntity> implements
...
@@ -459,6 +459,12 @@ public class NewsServiceImpl extends ServiceImpl<NewsDao, NewsEntity> implements
return
page
;
return
page
;
}
}
@Override
public
List
<
NewsEntity
>
dsxxjyTop8
()
{
List
<
NewsEntity
>
list
=
this
.
newsDao
.
dsxxjyTop8
();
return
list
;
}
private
List
<
Map
<
String
,
Object
>>
getDataListNew
(
Map
<
String
,
Object
>
map
,
Page
page
)
{
private
List
<
Map
<
String
,
Object
>>
getDataListNew
(
Map
<
String
,
Object
>
map
,
Page
page
)
{
List
<
Map
<
String
,
Object
>>
list
=
this
.
newsDao
.
searchKnowledgeInfoNewList
(
map
,
page
);
List
<
Map
<
String
,
Object
>>
list
=
this
.
newsDao
.
searchKnowledgeInfoNewList
(
map
,
page
);
return
list
;
return
list
;
...
...
src/main/resources/mapper/manage/NewsDao.xml
View file @
33f81a3a
...
@@ -493,4 +493,29 @@
...
@@ -493,4 +493,29 @@
#{item}
#{item}
</foreach>
</foreach>
</select>
</select>
<select
id=
"dsxxjyTop8"
resultMap=
"newsMap"
>
SELECT
TOP 10 a.classid,
a.newsid,
a.id AS yid,
a.newslevels,
a. TIME,
b.title,
b.author,
b.updatedate,
b.levels,
b.id
FROM
TopIcNews AS a
LEFT JOIN news AS b ON a.newsid = b.id
WHERE
b.status = 1
AND b.levels = 1
AND a.classid = 428
AND keyword LIKE '%党史学习教育%'
ORDER BY
levels DESC,
releasedate DESC
</select>
</mapper>
</mapper>
\ No newline at end of file
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