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
15b5c15b
Commit
15b5c15b
authored
Feb 07, 2022
by
mingsoft
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
5.2.6 发布
parent
446ac0ec
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
27 changed files
with
77 additions
and
87 deletions
+77
-87
mcms-5.2.6.sql
doc/mcms-5.2.6.sql
+0
-0
BaseAction.java
src/main/java/net/mingsoft/cms/action/BaseAction.java
+3
-1
CategoryAction.java
src/main/java/net/mingsoft/cms/action/CategoryAction.java
+3
-1
ContentAction.java
src/main/java/net/mingsoft/cms/action/ContentAction.java
+3
-1
GeneraterAction.java
src/main/java/net/mingsoft/cms/action/GeneraterAction.java
+3
-1
CategoryAction.java
...main/java/net/mingsoft/cms/action/web/CategoryAction.java
+3
-1
ContentAction.java
src/main/java/net/mingsoft/cms/action/web/ContentAction.java
+3
-1
MCmsAction.java
src/main/java/net/mingsoft/cms/action/web/MCmsAction.java
+3
-1
ContentAop.java
src/main/java/net/mingsoft/cms/aop/ContentAop.java
+3
-1
CategoryBean.java
src/main/java/net/mingsoft/cms/bean/CategoryBean.java
+3
-1
ContentBean.java
src/main/java/net/mingsoft/cms/bean/ContentBean.java
+3
-1
ICategoryBiz.java
src/main/java/net/mingsoft/cms/biz/ICategoryBiz.java
+3
-1
IContentBiz.java
src/main/java/net/mingsoft/cms/biz/IContentBiz.java
+3
-1
IHistoryLogBiz.java
src/main/java/net/mingsoft/cms/biz/IHistoryLogBiz.java
+3
-1
CategoryBizImpl.java
src/main/java/net/mingsoft/cms/biz/impl/CategoryBizImpl.java
+5
-3
ContentBizImpl.java
src/main/java/net/mingsoft/cms/biz/impl/ContentBizImpl.java
+3
-1
HistoryLogBizImpl.java
...ain/java/net/mingsoft/cms/biz/impl/HistoryLogBizImpl.java
+3
-1
Const.java
src/main/java/net/mingsoft/cms/constant/Const.java
+3
-1
CategoryTypeEnum.java
...in/java/net/mingsoft/cms/constant/e/CategoryTypeEnum.java
+3
-1
ICategoryDao.java
src/main/java/net/mingsoft/cms/dao/ICategoryDao.java
+3
-1
ICmsHistoryLogDao.java
src/main/java/net/mingsoft/cms/dao/ICmsHistoryLogDao.java
+3
-1
IContentDao.java
src/main/java/net/mingsoft/cms/dao/IContentDao.java
+3
-1
CategoryEntity.java
src/main/java/net/mingsoft/cms/entity/CategoryEntity.java
+3
-1
ContentEntity.java
src/main/java/net/mingsoft/cms/entity/ContentEntity.java
+3
-1
HistoryLogEntity.java
src/main/java/net/mingsoft/cms/entity/HistoryLogEntity.java
+3
-1
Upgrade.java
src/main/java/net/mingsoft/cms/upgrade/Upgrade.java
+0
-60
CmsParserUtil.java
src/main/java/net/mingsoft/cms/util/CmsParserUtil.java
+3
-1
No files found.
doc/mcms-5.2.
5
.sql
→
doc/mcms-5.2.
6
.sql
View file @
15b5c15b
This diff is collapsed.
Click to expand it.
src/main/java/net/mingsoft/cms/action/BaseAction.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -18,6 +18,8 @@
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
action
;
import
java.util.MissingResourceException
;
...
...
src/main/java/net/mingsoft/cms/action/CategoryAction.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -18,6 +18,8 @@
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
action
;
import
cn.hutool.core.util.StrUtil
;
...
...
src/main/java/net/mingsoft/cms/action/ContentAction.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -18,6 +18,8 @@
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
action
;
import
io.swagger.annotations.Api
;
...
...
src/main/java/net/mingsoft/cms/action/GeneraterAction.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -20,6 +20,8 @@
*/
package
net
.
mingsoft
.
cms
.
action
;
import
cn.hutool.core.bean.BeanUtil
;
...
...
src/main/java/net/mingsoft/cms/action/web/CategoryAction.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -18,6 +18,8 @@
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
action
.
web
;
import
io.swagger.annotations.Api
;
...
...
src/main/java/net/mingsoft/cms/action/web/ContentAction.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -18,6 +18,8 @@
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
action
.
web
;
import
cn.hutool.core.util.ObjectUtil
;
...
...
src/main/java/net/mingsoft/cms/action/web/MCmsAction.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -20,6 +20,8 @@
*/
package
net
.
mingsoft
.
cms
.
action
.
web
;
import
cn.hutool.core.util.ObjectUtil
;
...
...
src/main/java/net/mingsoft/cms/aop/ContentAop.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -18,6 +18,8 @@
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
aop
;
import
net.mingsoft.basic.aop.BaseAop
;
...
...
src/main/java/net/mingsoft/cms/bean/CategoryBean.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -18,6 +18,8 @@
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
bean
;
import
net.mingsoft.cms.entity.CategoryEntity
;
...
...
src/main/java/net/mingsoft/cms/bean/ContentBean.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -18,6 +18,8 @@
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
bean
;
import
com.alibaba.fastjson.annotation.JSONField
;
...
...
src/main/java/net/mingsoft/cms/biz/ICategoryBiz.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -18,6 +18,8 @@
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
biz
;
import
net.mingsoft.base.biz.IBaseBiz
;
...
...
src/main/java/net/mingsoft/cms/biz/IContentBiz.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -18,6 +18,8 @@
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
biz
;
import
net.mingsoft.base.biz.IBaseBiz
;
...
...
src/main/java/net/mingsoft/cms/biz/IHistoryLogBiz.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -18,6 +18,8 @@
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
biz
;
import
net.mingsoft.base.biz.IBaseBiz
;
...
...
src/main/java/net/mingsoft/cms/biz/impl/CategoryBizImpl.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
* the Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions:
* <p>
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
* <p>
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
* FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
...
...
@@ -20,6 +20,8 @@
*/
package
net
.
mingsoft
.
cms
.
biz
.
impl
;
import
cn.hutool.core.util.ObjectUtil
;
...
...
src/main/java/net/mingsoft/cms/biz/impl/ContentBizImpl.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -20,6 +20,8 @@
*/
package
net
.
mingsoft
.
cms
.
biz
.
impl
;
import
net.mingsoft.base.biz.impl.BaseBizImpl
;
...
...
src/main/java/net/mingsoft/cms/biz/impl/HistoryLogBizImpl.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -20,6 +20,8 @@
*/
package
net
.
mingsoft
.
cms
.
biz
.
impl
;
import
net.mingsoft.cms.biz.IHistoryLogBiz
;
...
...
src/main/java/net/mingsoft/cms/constant/Const.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -18,6 +18,8 @@
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
constant
;
/**
...
...
src/main/java/net/mingsoft/cms/constant/e/CategoryTypeEnum.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -19,6 +19,8 @@
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
constant
.
e
;
import
net.mingsoft.base.constant.e.BaseEnum
;
...
...
src/main/java/net/mingsoft/cms/dao/ICategoryDao.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -18,6 +18,8 @@
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
dao
;
import
net.mingsoft.base.dao.IBaseDao
;
...
...
src/main/java/net/mingsoft/cms/dao/ICmsHistoryLogDao.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -18,6 +18,8 @@
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
dao
;
import
net.mingsoft.base.dao.IBaseDao
;
...
...
src/main/java/net/mingsoft/cms/dao/IContentDao.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -18,6 +18,8 @@
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
dao
;
import
net.mingsoft.base.dao.IBaseDao
;
...
...
src/main/java/net/mingsoft/cms/entity/CategoryEntity.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -18,6 +18,8 @@
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
entity
;
import
com.alibaba.fastjson.annotation.JSONField
;
...
...
src/main/java/net/mingsoft/cms/entity/ContentEntity.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -18,6 +18,8 @@
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
entity
;
import
com.alibaba.fastjson.annotation.JSONField
;
...
...
src/main/java/net/mingsoft/cms/entity/HistoryLogEntity.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -18,6 +18,8 @@
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
entity
;
import
com.alibaba.fastjson.annotation.JSONField
;
...
...
src/main/java/net/mingsoft/cms/upgrade/Upgrade.java
deleted
100644 → 0
View file @
446ac0ec
package
net
.
mingsoft
.
cms
.
upgrade
;
import
net.mingsoft.basic.util.SpringUtil
;
import
net.mingsoft.cms.biz.ICategoryBiz
;
import
net.mingsoft.cms.entity.CategoryEntity
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
/**
* @author by 铭飞开源团队
* @Description
* @date 2020/6/19 15:58
*/
public
class
Upgrade
{
/**
* 更新栏目分类的顶级节点和叶子节点
*/
public
void
upgrade
(){
ICategoryBiz
categoryBiz
=
SpringUtil
.
getBean
(
ICategoryBiz
.
class
);
List
<
CategoryEntity
>
list
=
categoryBiz
.
queryAll
();
list
.
forEach
(
x
->{
//将parentId第一行设为顶级节点
String
topId
=
"0"
;
String
parentId
=
x
.
getParentids
();
if
(
parentId
!=
null
)
{
topId
=
parentId
.
split
(
","
)[
0
];
}
x
.
setTopId
(
topId
);
String
id
=
x
.
getId
();
boolean
leaf
=
true
;
//判断是否叶子,循环查找,如果有节点的父节点中包含该节点的id则判断为否跳出循环
for
(
int
i
=
0
;
i
<
list
.
size
();
i
++)
{
String
pId
=
list
.
get
(
i
).
getParentids
();
if
(
pId
==
null
)
{
continue
;
}
leaf
=
!
pId
.
contains
(
id
);
//如果不是叶子就跳出循环,不需要再判断了
if
(!
leaf
)
{
break
;
}
}
x
.
setLeaf
(
leaf
);
//更新
Map
<
String
,
String
>
fields
=
new
HashMap
<>();
fields
.
put
(
"leaf"
,
x
.
getLeaf
()?
"1"
:
"0"
);
fields
.
put
(
"top_id"
,
x
.
getTopId
());
Map
<
String
,
String
>
where
=
new
HashMap
<>();
where
.
put
(
"id"
,
x
.
getId
());
categoryBiz
.
updateBySQL
(
"cms_category"
,
fields
,
where
);
});
}
}
src/main/java/net/mingsoft/cms/util/CmsParserUtil.java
View file @
15b5c15b
/**
* The MIT License (MIT)
* Copyright (c) 20
20
铭软科技(mingsoft.net)
* Copyright (c) 20
12-2022
铭软科技(mingsoft.net)
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
...
...
@@ -18,6 +18,8 @@
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package
net
.
mingsoft
.
cms
.
util
;
import
cn.hutool.core.collection.CollUtil
;
...
...
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