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
07948711
Commit
07948711
authored
May 27, 2024
by
suxiaochun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加 网站路由前缀
parent
823bd466
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
24 additions
and
7 deletions
+24
-7
WebsiteHitCountDetailServiceImpl.java
...manage/service/impl/WebsiteHitCountDetailServiceImpl.java
+11
-3
application-dev.yml
src/main/resources/application-dev.yml
+4
-0
application-test.yml
src/main/resources/application-test.yml
+6
-3
application.yml
src/main/resources/application.yml
+3
-1
No files found.
src/main/java/io/office/modules/manage/service/impl/WebsiteHitCountDetailServiceImpl.java
View file @
07948711
...
...
@@ -13,8 +13,10 @@ import io.office.modules.manage.entity.WebsiteHitCountDetailEntity;
import
io.office.modules.manage.form.WebsiteHitCountDetailForm
;
import
io.office.modules.manage.service.WebsiteHitCountDetailService
;
import
io.office.modules.sys.entity.SysUserEntity
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.apache.commons.lang.StringUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.stereotype.Service
;
import
javax.servlet.http.HttpServletRequest
;
...
...
@@ -23,8 +25,6 @@ import java.util.List;
import
java.util.Map
;
@Service
(
"websiteHitCountDetailService"
)
public
class
WebsiteHitCountDetailServiceImpl
extends
ServiceImpl
<
WebsiteHitCountDetailDao
,
WebsiteHitCountDetailEntity
>
implements
WebsiteHitCountDetailService
{
...
...
@@ -35,7 +35,7 @@ public class WebsiteHitCountDetailServiceImpl extends ServiceImpl<WebsiteHitCoun
public
PageUtils
queryPage
(
Map
<
String
,
Object
>
params
)
{
IPage
<
WebsiteHitCountDetailEntity
>
page
=
this
.
page
(
new
Query
<
WebsiteHitCountDetailEntity
>().
getPage
(
params
),
new
QueryWrapper
<
WebsiteHitCountDetailEntity
>().
between
(
params
.
get
(
"createStartTime"
)
!=
null
&&
params
.
get
(
"createEndTime"
)!=
null
&&
StringUtils
.
isNotBlank
(
params
.
get
(
"createStartTime"
).
toString
())&&
StringUtils
.
isNotBlank
(
params
.
get
(
"createEndTime"
).
toString
()),
"create_time"
,
params
.
get
(
"createStartTime"
).
toString
(),
params
.
get
(
"createEndTime"
).
toString
())
new
QueryWrapper
<
WebsiteHitCountDetailEntity
>().
between
(
params
.
get
(
"createStartTime"
)
!=
null
&&
params
.
get
(
"createEndTime"
)
!=
null
&&
StringUtils
.
isNotBlank
(
params
.
get
(
"createStartTime"
).
toString
())
&&
StringUtils
.
isNotBlank
(
params
.
get
(
"createEndTime"
).
toString
()),
"create_time"
,
params
.
get
(
"createStartTime"
).
toString
(),
params
.
get
(
"createEndTime"
).
toString
())
);
return
new
PageUtils
(
page
);
...
...
@@ -50,10 +50,18 @@ public class WebsiteHitCountDetailServiceImpl extends ServiceImpl<WebsiteHitCoun
//baseMapper.updateById(websiteHitCountDetailEntity);
}
@Value
(
"${ipStart}"
)
private
String
ipStart
;
@Override
public
Page
<
WebsiteHitCountDetailForm
>
getListPage
(
WebsiteHitCountDetailForm
websiteHitCountDetailForm
,
Page
page
)
{
//page.setTotal(baseMapper.getListPageCount(websiteHitCountDetailForm));
List
<
WebsiteHitCountDetailForm
>
newsList
=
baseMapper
.
getListPage
(
websiteHitCountDetailForm
,
page
);
if
(
CollectionUtils
.
isNotEmpty
(
newsList
))
{
for
(
WebsiteHitCountDetailForm
form
:
newsList
)
{
form
.
setRoute
(
ipStart
+
form
.
getRoute
());
}
}
page
.
setRecords
(
newsList
);
return
page
;
}
...
...
src/main/resources/application-dev.yml
View file @
07948711
...
...
@@ -118,3 +118,6 @@ directory:
"
/Org/Intro.aspx"
:
/Org/Intro
"
News/PicNews.aspx"
:
News/msg
"
service/notice/article.aspx"
:
News/NoticeArticle
# 网站路由前缀
ipStart
:
http://192.168.0.77
\ No newline at end of file
src/main/resources/application-test.yml
View file @
07948711
...
...
@@ -56,9 +56,9 @@ dynamic:
password
:
wangtian
slave2
:
driver-class-name
:
com.microsoft.sqlserver.jdbc.SQLServerDriver
url
:
jdbc:sqlserver://192.168.0.
77:1433;DatabaseName=gs108
username
:
wangtian
password
:
wangtian
url
:
jdbc:sqlserver://192.168.0.
85:1433;DatabaseName=center_outer
username
:
test2
password
:
test2
server
:
port
:
9091
# password: 123456
...
...
@@ -106,3 +106,5 @@ directory:
service/notice/article.aspx
:
News/NoticeArticle
# 网站路由前缀
ipStart
:
http://192.168.0.77
\ No newline at end of file
src/main/resources/application.yml
View file @
07948711
...
...
@@ -14,7 +14,7 @@ spring:
name
:
GS1OfficeWebSit
# 环境 dev|test|prod
profiles
:
active
:
prod
active
:
test
# jackson时间格式化
jackson
:
time-zone
:
GMT+8
...
...
@@ -82,3 +82,5 @@ id.work.workerId: 0
#机器的数据中心 0-31都可用,如果是分布式部署,需要定义不同的datacenterId
id.work.datacenterId
:
1
# 网站路由前缀
ipStart
:
http://www.gs1cn.org
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