Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
C
cms_sys
Project
Project
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
西魏
cms_sys
Commits
4cebaff0
Commit
4cebaff0
authored
Dec 02, 2020
by
guwd
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1、生成修改html/编号问题,增加app_dir
2、针对app_dir调整解析器 3、模板交互增加
parent
05bb1bd7
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
9 additions
and
9 deletions
+9
-9
GeneraterAction.java
src/main/java/net/mingsoft/cms/action/GeneraterAction.java
+2
-2
MCmsAction.java
src/main/java/net/mingsoft/cms/action/web/MCmsAction.java
+2
-2
ContentBizImpl.java
src/main/java/net/mingsoft/cms/biz/impl/ContentBizImpl.java
+3
-3
CmsParserUtil.java
src/main/java/net/mingsoft/cms/util/CmsParserUtil.java
+2
-2
No files found.
src/main/java/net/mingsoft/cms/action/GeneraterAction.java
View file @
4cebaff0
...
@@ -223,7 +223,7 @@ public class GeneraterAction extends BaseAction {
...
@@ -223,7 +223,7 @@ public class GeneraterAction extends BaseAction {
contentBean
.
setBeginTime
(
dateTime
);
contentBean
.
setBeginTime
(
dateTime
);
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
if
(
BasicUtil
.
getWebsiteApp
()
!=
null
)
{
if
(
BasicUtil
.
getWebsiteApp
()
!=
null
)
{
map
.
put
(
ParserUtil
.
APP_
ID
,
BasicUtil
.
getWebsiteApp
().
getAppId
());
map
.
put
(
ParserUtil
.
APP_
DIR
,
BasicUtil
.
getWebsiteApp
().
getAppDir
());
}
}
PageBean
page
=
new
PageBean
();
PageBean
page
=
new
PageBean
();
map
.
put
(
ParserUtil
.
HTML
,
ParserUtil
.
HTML
);
map
.
put
(
ParserUtil
.
HTML
,
ParserUtil
.
HTML
);
...
@@ -277,7 +277,7 @@ public class GeneraterAction extends BaseAction {
...
@@ -277,7 +277,7 @@ public class GeneraterAction extends BaseAction {
public
String
viewIndex
(
HttpServletRequest
request
,
@PathVariable
String
position
,
HttpServletResponse
response
)
{
public
String
viewIndex
(
HttpServletRequest
request
,
@PathVariable
String
position
,
HttpServletResponse
response
)
{
AppEntity
app
=
BasicUtil
.
getApp
();
AppEntity
app
=
BasicUtil
.
getApp
();
// 组织主页预览地址
// 组织主页预览地址
String
indexPosition
=
app
.
getAppHostUrl
()
+
File
.
separator
+
ParserUtil
.
HTML
+
File
.
separator
+
app
.
getApp
Id
()
String
indexPosition
=
app
.
getAppHostUrl
()
+
File
.
separator
+
ParserUtil
.
HTML
+
File
.
separator
+
app
.
getApp
Dir
()
+
File
.
separator
+
position
+
ParserUtil
.
HTML_SUFFIX
;
+
File
.
separator
+
position
+
ParserUtil
.
HTML_SUFFIX
;
return
"redirect:"
+
indexPosition
;
return
"redirect:"
+
indexPosition
;
}
}
...
...
src/main/java/net/mingsoft/cms/action/web/MCmsAction.java
View file @
4cebaff0
...
@@ -427,7 +427,7 @@ public class MCmsAction extends net.mingsoft.cms.action.BaseAction {
...
@@ -427,7 +427,7 @@ public class MCmsAction extends net.mingsoft.cms.action.BaseAction {
params
.
put
(
ParserUtil
.
URL
,
url
);
params
.
put
(
ParserUtil
.
URL
,
url
);
params
.
put
(
SEARCH
,
searchMap
);
params
.
put
(
SEARCH
,
searchMap
);
if
(
BasicUtil
.
getWebsiteApp
()
!=
null
)
{
if
(
BasicUtil
.
getWebsiteApp
()
!=
null
)
{
params
.
put
(
ParserUtil
.
APP_
ID
,
BasicUtil
.
getWebsiteApp
().
getAppId
());
params
.
put
(
ParserUtil
.
APP_
DIR
,
BasicUtil
.
getWebsiteApp
().
getAppDir
());
}
}
params
.
put
(
ParserUtil
.
PAGE
,
page
);
params
.
put
(
ParserUtil
.
PAGE
,
page
);
params
.
put
(
ParserUtil
.
HTML
,
ParserUtil
.
HTML
);
params
.
put
(
ParserUtil
.
HTML
,
ParserUtil
.
HTML
);
...
@@ -470,7 +470,7 @@ public class MCmsAction extends net.mingsoft.cms.action.BaseAction {
...
@@ -470,7 +470,7 @@ public class MCmsAction extends net.mingsoft.cms.action.BaseAction {
params
.
put
(
ParserUtil
.
URL
,
url
);
params
.
put
(
ParserUtil
.
URL
,
url
);
params
.
put
(
SEARCH
,
searchMap
);
params
.
put
(
SEARCH
,
searchMap
);
if
(
BasicUtil
.
getWebsiteApp
()
!=
null
)
{
if
(
BasicUtil
.
getWebsiteApp
()
!=
null
)
{
params
.
put
(
ParserUtil
.
APP_
ID
,
BasicUtil
.
getWebsiteApp
().
getAppId
());
params
.
put
(
ParserUtil
.
APP_
DIR
,
BasicUtil
.
getWebsiteApp
().
getAppDir
());
}
}
params
.
put
(
ParserUtil
.
PAGE
,
page
);
params
.
put
(
ParserUtil
.
PAGE
,
page
);
params
.
put
(
ParserUtil
.
HTML
,
ParserUtil
.
HTML
);
params
.
put
(
ParserUtil
.
HTML
,
ParserUtil
.
HTML
);
...
...
src/main/java/net/mingsoft/cms/biz/impl/ContentBizImpl.java
View file @
4cebaff0
...
@@ -125,7 +125,7 @@ public class ContentBizImpl extends BaseBizImpl<IContentDao, ContentEntity> imp
...
@@ -125,7 +125,7 @@ public class ContentBizImpl extends BaseBizImpl<IContentDao, ContentEntity> imp
contentBean
.
setBeginTime
(
dateTime
);
contentBean
.
setBeginTime
(
dateTime
);
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
if
(
BasicUtil
.
getWebsiteApp
()
!=
null
){
if
(
BasicUtil
.
getWebsiteApp
()
!=
null
){
map
.
put
(
ParserUtil
.
APP_
ID
,
BasicUtil
.
getWebsiteApp
().
getAppId
());
map
.
put
(
ParserUtil
.
APP_
DIR
,
BasicUtil
.
getWebsiteApp
().
getAppDir
());
}
}
PageBean
page
=
new
PageBean
();
PageBean
page
=
new
PageBean
();
map
.
put
(
ParserUtil
.
HTML
,
ParserUtil
.
HTML
);
map
.
put
(
ParserUtil
.
HTML
,
ParserUtil
.
HTML
);
...
@@ -177,7 +177,7 @@ public class ContentBizImpl extends BaseBizImpl<IContentDao, ContentEntity> imp
...
@@ -177,7 +177,7 @@ public class ContentBizImpl extends BaseBizImpl<IContentDao, ContentEntity> imp
//获取模板中列表标签中的条件
//获取模板中列表标签中的条件
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
if
(
BasicUtil
.
getWebsiteApp
()
!=
null
){
if
(
BasicUtil
.
getWebsiteApp
()
!=
null
){
map
.
put
(
ParserUtil
.
APP_
ID
,
BasicUtil
.
getWebsiteApp
().
getAppId
());
map
.
put
(
ParserUtil
.
APP_
DIR
,
BasicUtil
.
getWebsiteApp
().
getAppDir
());
}
}
PageBean
page
=
new
PageBean
();
PageBean
page
=
new
PageBean
();
map
.
put
(
ParserUtil
.
HTML
,
ParserUtil
.
HTML
);
map
.
put
(
ParserUtil
.
HTML
,
ParserUtil
.
HTML
);
...
@@ -227,7 +227,7 @@ public class ContentBizImpl extends BaseBizImpl<IContentDao, ContentEntity> imp
...
@@ -227,7 +227,7 @@ public class ContentBizImpl extends BaseBizImpl<IContentDao, ContentEntity> imp
map
.
put
(
ParserUtil
.
HTML
,
ParserUtil
.
HTML
);
map
.
put
(
ParserUtil
.
HTML
,
ParserUtil
.
HTML
);
//设置站点编号
//设置站点编号
if
(
BasicUtil
.
getWebsiteApp
()
!=
null
){
if
(
BasicUtil
.
getWebsiteApp
()
!=
null
){
map
.
put
(
ParserUtil
.
APP_
ID
,
BasicUtil
.
getWebsiteApp
().
getAppId
());
map
.
put
(
ParserUtil
.
APP_
DIR
,
BasicUtil
.
getWebsiteApp
().
getAppDir
());
}
}
String
read
=
ParserUtil
.
rendering
(
templatePath
,
map
);
String
read
=
ParserUtil
.
rendering
(
templatePath
,
map
);
FileUtil
.
writeString
(
read
,
ParserUtil
.
buildHtmlPath
(
targetPath
),
net
.
mingsoft
.
base
.
constant
.
Const
.
UTF8
);
FileUtil
.
writeString
(
read
,
ParserUtil
.
buildHtmlPath
(
targetPath
),
net
.
mingsoft
.
base
.
constant
.
Const
.
UTF8
);
...
...
src/main/java/net/mingsoft/cms/util/CmsParserUtil.java
View file @
4cebaff0
...
@@ -83,7 +83,7 @@ public class CmsParserUtil extends ParserUtil {
...
@@ -83,7 +83,7 @@ public class CmsParserUtil extends ParserUtil {
//获取模板中列表标签中的条件
//获取模板中列表标签中的条件
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
if
(
BasicUtil
.
getWebsiteApp
()
!=
null
)
{
if
(
BasicUtil
.
getWebsiteApp
()
!=
null
)
{
map
.
put
(
ParserUtil
.
APP_
ID
,
BasicUtil
.
getWebsiteApp
().
getAppId
());
map
.
put
(
ParserUtil
.
APP_
DIR
,
BasicUtil
.
getWebsiteApp
().
getAppDir
());
}
}
map
.
put
(
ParserUtil
.
HTML
,
ParserUtil
.
HTML
);
map
.
put
(
ParserUtil
.
HTML
,
ParserUtil
.
HTML
);
...
@@ -107,7 +107,7 @@ public class CmsParserUtil extends ParserUtil {
...
@@ -107,7 +107,7 @@ public class CmsParserUtil extends ParserUtil {
parserParams
.
put
(
IS_DO
,
false
);
parserParams
.
put
(
IS_DO
,
false
);
parserParams
.
put
(
HTML
,
HTML
);
parserParams
.
put
(
HTML
,
HTML
);
if
(
BasicUtil
.
getWebsiteApp
()
!=
null
){
if
(
BasicUtil
.
getWebsiteApp
()
!=
null
){
parserParams
.
put
(
APP_
ID
,
BasicUtil
.
getWebsiteApp
().
getAppId
());
parserParams
.
put
(
APP_
DIR
,
BasicUtil
.
getWebsiteApp
().
getAppDir
());
}
}
if
(
contentModel
!=
null
)
{
if
(
contentModel
!=
null
)
{
// 将自定义模型编号设置为key值
// 将自定义模型编号设置为key值
...
...
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