Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
I
ibzdst
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
1
议题
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
ibiz4jteam
ibzdst
提交
0c061a3e
提交
0c061a3e
编写于
9月 14, 2021
作者:
sq3536
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
dict调整
上级
4c37e1aa
变更
6
展开全部
显示空白字符变更
内嵌
并排
正在显示
6 个修改的文件
包含
561 行增加
和
161 行删除
+561
-161
DictDstService.java
.../ibizlab/core/dict/extensions/service/DictDstService.java
+152
-155
DAChartExService.java
.../cn/ibizlab/core/extensions/service/DAChartExService.java
+34
-0
DAReportExService.java
...cn/ibizlab/core/extensions/service/DAReportExService.java
+34
-0
Catalog.java
ibzdst-util/src/main/java/cn/ibizlab/util/dict/Catalog.java
+170
-3
CodeList.java
ibzdst-util/src/main/java/cn/ibizlab/util/dict/CodeList.java
+170
-2
DataObject.java
...util/src/main/java/cn/ibizlab/util/helper/DataObject.java
+1
-1
未找到文件。
ibzdst-core/src/main/java/cn/ibizlab/core/dict/extensions/service/DictDstService.java
浏览文件 @
0c061a3e
此差异已折叠。
点击以展开。
ibzdst-core/src/main/java/cn/ibizlab/core/extensions/service/DAChartExService.java
浏览文件 @
0c061a3e
...
...
@@ -3,6 +3,8 @@ package cn.ibizlab.core.extensions.service;
import
cn.ibizlab.core.analysis.service.impl.DAChartServiceImpl
;
import
lombok.extern.slf4j.Slf4j
;
import
cn.ibizlab.core.analysis.domain.DAChart
;
import
org.springframework.cache.annotation.CacheEvict
;
import
org.springframework.cache.annotation.Caching
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.context.annotation.Primary
;
...
...
@@ -31,5 +33,37 @@ public class DAChartExService extends DAChartServiceImpl {
public
DAChart
build
(
DAChart
et
)
{
return
super
.
build
(
et
);
}
@Caching
(
evict
=
{
@CacheEvict
(
value
=
"dataAnalyse"
,
allEntries
=
true
)
})
@Override
public
boolean
update
(
DAChart
et
)
{
return
super
.
update
(
et
);
}
@Caching
(
evict
=
{
@CacheEvict
(
value
=
"dataAnalyse"
,
allEntries
=
true
)
})
@Override
public
void
updateBatch
(
List
<
DAChart
>
list
)
{
super
.
updateBatch
(
list
);
}
@Caching
(
evict
=
{
@CacheEvict
(
value
=
"dataAnalyse"
,
allEntries
=
true
)
})
@Override
public
boolean
save
(
DAChart
et
)
{
return
super
.
save
(
et
);
}
@Caching
(
evict
=
{
@CacheEvict
(
value
=
"dataAnalyse"
,
allEntries
=
true
)
})
@Override
public
void
saveBatch
(
List
<
DAChart
>
list
)
{
super
.
saveBatch
(
list
);
}
}
ibzdst-core/src/main/java/cn/ibizlab/core/extensions/service/DAReportExService.java
浏览文件 @
0c061a3e
...
...
@@ -3,6 +3,8 @@ package cn.ibizlab.core.extensions.service;
import
cn.ibizlab.core.analysis.service.impl.DAReportServiceImpl
;
import
lombok.extern.slf4j.Slf4j
;
import
cn.ibizlab.core.analysis.domain.DAReport
;
import
org.springframework.cache.annotation.CacheEvict
;
import
org.springframework.cache.annotation.Caching
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.context.annotation.Primary
;
...
...
@@ -31,5 +33,37 @@ public class DAReportExService extends DAReportServiceImpl {
public
DAReport
build
(
DAReport
et
)
{
return
super
.
build
(
et
);
}
@Caching
(
evict
=
{
@CacheEvict
(
value
=
"dataAnalyse"
,
allEntries
=
true
)
})
@Override
public
boolean
update
(
DAReport
et
)
{
return
super
.
update
(
et
);
}
@Caching
(
evict
=
{
@CacheEvict
(
value
=
"dataAnalyse"
,
allEntries
=
true
)
})
@Override
public
void
updateBatch
(
List
<
DAReport
>
list
)
{
super
.
updateBatch
(
list
);
}
@Caching
(
evict
=
{
@CacheEvict
(
value
=
"dataAnalyse"
,
allEntries
=
true
)
})
@Override
public
boolean
save
(
DAReport
et
)
{
return
super
.
save
(
et
);
}
@Caching
(
evict
=
{
@CacheEvict
(
value
=
"dataAnalyse"
,
allEntries
=
true
)
})
@Override
public
void
saveBatch
(
List
<
DAReport
>
list
)
{
super
.
saveBatch
(
list
);
}
}
ibzdst-util/src/main/java/cn/ibizlab/util/dict/Catalog.java
浏览文件 @
0c061a3e
...
...
@@ -2,8 +2,12 @@ package cn.ibizlab.util.dict;
import
cn.ibizlab.util.annotation.DEField
;
import
cn.ibizlab.util.helper.DataObject
;
import
com.alibaba.fastjson.JSON
;
import
com.alibaba.fastjson.JSONObject
;
import
com.alibaba.fastjson.annotation.JSONField
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.fasterxml.jackson.annotation.JsonIgnore
;
import
com.fasterxml.jackson.annotation.JsonProperty
;
import
lombok.AllArgsConstructor
;
import
lombok.Getter
;
...
...
@@ -13,9 +17,7 @@ import lombok.experimental.Accessors;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.util.StringUtils
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.*
;
@Getter
@Setter
...
...
@@ -50,4 +52,169 @@ public class Catalog
return
null
;
}
private
Map
<
String
,
Object
>
advancedSettings
;
public
Catalog
putAdvancedSettings
(
String
settings
)
{
try
{
if
(!
StringUtils
.
isEmpty
(
settings
))
advancedSettings
=
JSON
.
parseObject
(
settings
,
Map
.
class
);
}
catch
(
Exception
ex
){}
return
this
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getUrl
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"url"
)!=
null
?
advancedSettings
.
get
(
"url"
).
toString
():
null
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getRequestMethod
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"requestMethod"
)!=
null
?
advancedSettings
.
get
(
"requestMethod"
).
toString
():
"GET"
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getRequestBody
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"requestBody"
)!=
null
?
advancedSettings
.
get
(
"requestBody"
).
toString
():
"{}"
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getNodeProp
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"nodeProp"
)!=
null
?
advancedSettings
.
get
(
"nodeProp"
).
toString
():
""
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getValueProp
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"valueProp"
)!=
null
?
advancedSettings
.
get
(
"valueProp"
).
toString
():
"value"
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getLabelProp
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"labelProp"
)!=
null
?
advancedSettings
.
get
(
"labelProp"
).
toString
():
"label"
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getParentProp
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"parentProp"
)!=
null
?
advancedSettings
.
get
(
"parentProp"
).
toString
():
"parent"
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getChildrenProp
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"childrenProp"
)!=
null
?
advancedSettings
.
get
(
"childrenProp"
).
toString
():
"children"
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getDisabledProp
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"disabledProp"
)!=
null
?
advancedSettings
.
get
(
"disabledProp"
).
toString
():
"disabled"
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getFilterProp
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"filterProp"
)!=
null
?
advancedSettings
.
get
(
"filterProp"
).
toString
():
"filter"
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getExpiredProp
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"expiredProp"
)!=
null
?
advancedSettings
.
get
(
"expiredProp"
).
toString
():
"expired"
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getIconClassProp
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"iconClassProp"
)!=
null
?
advancedSettings
.
get
(
"iconClassProp"
).
toString
():
"iconClass"
;
}
public
Catalog
setNodes
(
List
<
Map
>
nodes
)
{
return
setNodes
(
nodes
,
null
,
null
);
}
public
Catalog
setNodes
(
List
<
Map
>
nodes
,
String
filter
,
String
subCode
)
{
Map
<
String
,
List
<
Option
>>
map
=
new
LinkedHashMap
<>();
Option
subOption
=
null
;
for
(
Map
item:
unfoldList
(
nodes
,
null
))
{
Map
<
String
,
Object
>
extension
=
new
HashMap
<>();
if
(!
StringUtils
.
isEmpty
(
item
.
get
(
"extension"
)))
extension
=
JSONObject
.
parseObject
(
item
.
get
(
"extension"
).
toString
(),
Map
.
class
);
String
pid
=
DataObject
.
getStringValue
(
item
.
get
(
this
.
getParentProp
()),
DataObject
.
getStringValue
(
item
.
get
(
"pvalue"
),
"_root"
));
if
(
StringUtils
.
isEmpty
(
pid
))
pid
=
"_root"
;
List
<
Option
>
list
=
null
;
if
(!
map
.
containsKey
(
pid
))
{
list
=
new
ArrayList
<>();
map
.
put
(
pid
,
list
);
}
else
list
=
map
.
get
(
pid
);
Option
option
=
new
Option
().
setValue
(
DataObject
.
getStringValue
(
item
.
get
(
this
.
getValueProp
()),
DataObject
.
getStringValue
(
item
.
get
(
"id"
),
null
)))
.
setId
(
DataObject
.
getStringValue
(
item
.
get
(
this
.
getValueProp
()),
DataObject
.
getStringValue
(
item
.
get
(
"id"
),
null
)))
.
setDisabled
(
DataObject
.
getBooleanValue
(
item
.
get
(
this
.
getDisabledProp
()),
false
)||
DataObject
.
getBooleanValue
(
item
.
get
(
this
.
getExpiredProp
()),
false
))
.
setFilter
(
DataObject
.
getStringValue
(
item
.
get
(
this
.
getFilterProp
()),
null
)).
setIconClass
(
DataObject
.
getStringValue
(
item
.
get
(
this
.
getIconClassProp
()),
null
))
.
setLabel
(
DataObject
.
getStringValue
(
item
.
get
(
this
.
getLabelProp
()),
DataObject
.
getStringValue
(
item
.
get
(
"text"
),
""
)))
.
setParent
(
DataObject
.
getStringValue
(
item
.
get
(
this
.
getParentProp
()),
DataObject
.
getStringValue
(
item
.
get
(
"pvalue"
),
""
))).
setExtension
(
extension
);
if
(
option
.
getValue
().
equals
(
subCode
))
subOption
=
option
;
if
(
StringUtils
.
isEmpty
(
filter
)||
option
.
getFilterSet
().
contains
(
filter
))
list
.
add
(
option
);
}
List
<
Option
>
codeItemTreeList
=
loop
(
map
,
(
StringUtils
.
isEmpty
(
subCode
))?
"_root"
:
subCode
);
if
(
subOption
!=
null
)
{
subOption
.
setChildren
(
codeItemTreeList
).
setParent
(
""
);
this
.
getOptions
().
add
(
subOption
.
setParent
(
null
));
}
else
this
.
setOptions
(
codeItemTreeList
);
return
this
;
}
public
List
<
Map
>
unfoldList
(
List
<
Map
>
nodes
,
String
parent
)
{
List
<
Map
>
unfoldList
=
new
ArrayList
<>();
for
(
Map
item:
nodes
)
{
if
((!
StringUtils
.
isEmpty
(
parent
))&&
StringUtils
.
isEmpty
(
DataObject
.
getStringValue
(
item
.
get
(
this
.
getParentProp
()),
DataObject
.
getStringValue
(
item
.
get
(
"pvalue"
),
null
))))
item
.
put
(
this
.
getParentProp
(),
parent
);
String
value
=
DataObject
.
getStringValue
(
item
.
get
(
this
.
getValueProp
()),
DataObject
.
getStringValue
(
item
.
get
(
"id"
),
null
));
unfoldList
.
add
(
item
);
Object
child
=
item
.
get
(
this
.
getChildrenProp
());
if
(!
ObjectUtils
.
isEmpty
(
child
))
{
if
(
child
instanceof
List
&&
((
List
)
child
).
get
(
0
)
instanceof
Map
)
unfoldList
.
addAll
(
unfoldList
((
List
)
child
,
value
));
item
.
remove
(
this
.
getChildrenProp
());
}
}
return
unfoldList
;
}
public
List
<
Option
>
loop
(
Map
<
String
,
List
<
Option
>>
listCodeItem
,
Object
parentValue
)
{
List
<
Option
>
trees
=
new
ArrayList
<
Option
>();
if
(
listCodeItem
.
containsKey
(
parentValue
))
{
for
(
Option
codeItem
:
listCodeItem
.
get
(
parentValue
))
{
List
<
Option
>
childCodeItem
=
loop
(
listCodeItem
,
codeItem
.
getValue
());
if
(
childCodeItem
.
size
()
>
0
)
codeItem
.
setChildren
(
childCodeItem
);
trees
.
add
(
codeItem
);
}
}
return
trees
;
}
}
ibzdst-util/src/main/java/cn/ibizlab/util/dict/CodeList.java
浏览文件 @
0c061a3e
package
cn
.
ibizlab
.
util
.
dict
;
import
cn.ibizlab.util.helper.DataObject
;
import
com.alibaba.fastjson.JSON
;
import
com.alibaba.fastjson.JSONObject
;
import
com.alibaba.fastjson.annotation.JSONField
;
import
com.fasterxml.jackson.annotation.JsonIgnore
;
import
com.fasterxml.jackson.annotation.JsonProperty
;
import
lombok.AllArgsConstructor
;
import
lombok.Getter
;
import
lombok.NoArgsConstructor
;
import
lombok.Setter
;
import
lombok.experimental.Accessors
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.util.StringUtils
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.*
;
@Getter
@Setter
...
...
@@ -53,4 +58,167 @@ public class CodeList
resultCodeItem
.
setChildren
(
children
);
return
resultCodeItem
;
}
private
Map
<
String
,
Object
>
advancedSettings
;
public
CodeList
putAdvancedSettings
(
String
settings
)
{
try
{
if
(!
StringUtils
.
isEmpty
(
settings
))
advancedSettings
=
JSON
.
parseObject
(
settings
,
Map
.
class
);
}
catch
(
Exception
ex
){}
return
this
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getUrl
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"url"
)!=
null
?
advancedSettings
.
get
(
"url"
).
toString
():
null
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getRequestMethod
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"requestMethod"
)!=
null
?
advancedSettings
.
get
(
"requestMethod"
).
toString
():
"GET"
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getRequestBody
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"requestBody"
)!=
null
?
advancedSettings
.
get
(
"requestBody"
).
toString
():
"{}"
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getNodeProp
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"nodeProp"
)!=
null
?
advancedSettings
.
get
(
"nodeProp"
).
toString
():
""
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getValueProp
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"valueProp"
)!=
null
?
advancedSettings
.
get
(
"valueProp"
).
toString
():
"value"
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getLabelProp
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"labelProp"
)!=
null
?
advancedSettings
.
get
(
"labelProp"
).
toString
():
"label"
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getParentProp
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"parentProp"
)!=
null
?
advancedSettings
.
get
(
"parentProp"
).
toString
():
"parent"
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getChildrenProp
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"childrenProp"
)!=
null
?
advancedSettings
.
get
(
"childrenProp"
).
toString
():
"children"
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getDisabledProp
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"disabledProp"
)!=
null
?
advancedSettings
.
get
(
"disabledProp"
).
toString
():
"disabled"
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getFilterProp
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"filterProp"
)!=
null
?
advancedSettings
.
get
(
"filterProp"
).
toString
():
"filter"
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getExpiredProp
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"expiredProp"
)!=
null
?
advancedSettings
.
get
(
"expiredProp"
).
toString
():
"expired"
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
String
getIconClassProp
()
{
return
advancedSettings
!=
null
&&
advancedSettings
.
get
(
"iconClassProp"
)!=
null
?
advancedSettings
.
get
(
"iconClassProp"
).
toString
():
"iconClass"
;
}
public
CodeList
setNodes
(
List
<
Map
>
nodes
,
String
filter
,
String
subCode
)
{
Map
<
String
,
List
<
CodeItem
>>
map
=
new
LinkedHashMap
<>();
List
<
CodeItem
>
alllist
=
new
ArrayList
<>();
CodeItem
subOption
=
null
;
for
(
Map
item:
unfoldList
(
nodes
,
null
))
{
Map
<
String
,
Object
>
extension
=
new
HashMap
<>();
if
(!
StringUtils
.
isEmpty
(
item
.
get
(
"extension"
)))
extension
=
JSONObject
.
parseObject
(
item
.
get
(
"extension"
).
toString
(),
Map
.
class
);
String
pid
=
DataObject
.
getStringValue
(
item
.
get
(
this
.
getParentProp
()),
DataObject
.
getStringValue
(
item
.
get
(
"pvalue"
),
"_root"
));
if
(
StringUtils
.
isEmpty
(
pid
))
pid
=
"_root"
;
List
<
CodeItem
>
list
=
null
;
if
(!
map
.
containsKey
(
pid
))
{
list
=
new
ArrayList
<>();
map
.
put
(
pid
,
list
);
}
else
list
=
map
.
get
(
pid
);
CodeItem
option
=
new
CodeItem
().
setValue
(
DataObject
.
getStringValue
(
item
.
get
(
this
.
getValueProp
()),
DataObject
.
getStringValue
(
item
.
get
(
"id"
),
null
)))
.
setId
(
DataObject
.
getStringValue
(
item
.
get
(
this
.
getValueProp
()),
DataObject
.
getStringValue
(
item
.
get
(
"id"
),
null
)))
.
setDisabled
(
DataObject
.
getBooleanValue
(
item
.
get
(
this
.
getDisabledProp
()),
false
)||
DataObject
.
getBooleanValue
(
item
.
get
(
this
.
getExpiredProp
()),
false
))
.
setFilter
(
DataObject
.
getStringValue
(
item
.
get
(
this
.
getFilterProp
()),
null
)).
setIconClass
(
DataObject
.
getStringValue
(
item
.
get
(
this
.
getIconClassProp
()),
null
))
.
setLabel
(
DataObject
.
getStringValue
(
item
.
get
(
this
.
getLabelProp
()),
DataObject
.
getStringValue
(
item
.
get
(
"text"
),
""
)))
.
setParent
(
DataObject
.
getStringValue
(
item
.
get
(
this
.
getParentProp
()),
DataObject
.
getStringValue
(
item
.
get
(
"pvalue"
),
""
))).
setExtension
(
extension
);
if
(
option
.
getValue
().
equals
(
subCode
))
subOption
=
option
;
if
(
StringUtils
.
isEmpty
(
filter
)||
option
.
getFilterSet
().
contains
(
filter
))
{
alllist
.
add
(
option
);
list
.
add
(
option
);
}
}
if
(
subOption
!=
null
)
{
List
<
CodeItem
>
codeItemTreeList
=
loop
(
map
,
(
StringUtils
.
isEmpty
(
subCode
))?
"_root"
:
subCode
);
codeItemTreeList
.
add
(
0
,
subOption
.
setParent
(
null
));
this
.
setOptions
(
codeItemTreeList
);
}
else
this
.
setOptions
(
alllist
);
return
this
;
}
public
List
<
Map
>
unfoldList
(
List
<
Map
>
nodes
,
String
parent
)
{
List
<
Map
>
unfoldList
=
new
ArrayList
<>();
for
(
Map
item:
nodes
)
{
if
((!
StringUtils
.
isEmpty
(
parent
))&&
StringUtils
.
isEmpty
(
DataObject
.
getStringValue
(
item
.
get
(
this
.
getParentProp
()),
DataObject
.
getStringValue
(
item
.
get
(
"pvalue"
),
null
))))
item
.
put
(
this
.
getParentProp
(),
parent
);
String
value
=
DataObject
.
getStringValue
(
item
.
get
(
this
.
getValueProp
()),
DataObject
.
getStringValue
(
item
.
get
(
"id"
),
null
));
unfoldList
.
add
(
item
);
Object
child
=
item
.
get
(
this
.
getChildrenProp
());
if
(!
ObjectUtils
.
isEmpty
(
child
))
{
if
(
child
instanceof
List
&&
((
List
)
child
).
get
(
0
)
instanceof
Map
)
unfoldList
.
addAll
(
unfoldList
((
List
)
child
,
value
));
item
.
remove
(
this
.
getChildrenProp
());
}
}
return
unfoldList
;
}
public
List
<
CodeItem
>
loop
(
Map
<
String
,
List
<
CodeItem
>>
listCodeItem
,
Object
parentValue
)
{
List
<
CodeItem
>
trees
=
new
ArrayList
<
CodeItem
>();
if
(
listCodeItem
.
containsKey
(
parentValue
))
{
for
(
CodeItem
codeItem
:
listCodeItem
.
get
(
parentValue
))
{
trees
.
add
(
codeItem
);
List
<
CodeItem
>
childCodeItem
=
loop
(
listCodeItem
,
codeItem
.
getValue
());
if
(
childCodeItem
.
size
()
>
0
)
trees
.
addAll
(
childCodeItem
);
}
}
return
trees
;
}
}
ibzdst-util/src/main/java/cn/ibizlab/util/helper/DataObject.java
浏览文件 @
0c061a3e
...
...
@@ -159,7 +159,7 @@ public class DataObject {
if
(
objValue
instanceof
Boolean
)
{
return
(
Boolean
)
objValue
;
}
return
objValue
.
toString
().
equalsIgnoreCase
(
"true"
)||
objValue
.
toString
().
equals
(
"1"
)||
objValue
.
toString
().
equals
(
"y"
);
return
objValue
.
toString
().
equalsIgnoreCase
(
"true"
)||
objValue
.
toString
().
equals
(
"1"
)||
objValue
.
toString
().
equals
IgnoreCase
(
"y"
);
}
final
static
public
char
[]
getCharacterValue
(
Object
objValue
,
char
[]
cDefault
)
{
...
...
编辑
预览
Markdown
格式
0%
请重试
or
添加新附件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录