Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
I
ibzdict
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
ibiz4jteam
ibzdict
提交
2649cea0
提交
2649cea0
编写于
4月 15, 2020
作者:
ibizdev
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
ibizdev提交
上级
5752e095
变更
4
显示空白字符变更
内嵌
并排
正在显示
4 个修改的文件
包含
41 行增加
和
62 行删除
+41
-62
IBZDict.java
...re/src/main/java/cn/ibizlab/core/dict/domain/IBZDict.java
+14
-21
IBZDictItem.java
...rc/main/java/cn/ibizlab/core/dict/domain/IBZDictItem.java
+10
-31
DEField.java
...til/src/main/java/cn/ibizlab/util/annotation/DEField.java
+9
-2
EntityBase.java
...util/src/main/java/cn/ibizlab/util/domain/EntityBase.java
+8
-8
未找到文件。
ibzdict-core/src/main/java/cn/ibizlab/core/dict/domain/IBZDict.java
浏览文件 @
2649cea0
...
...
@@ -31,14 +31,12 @@ public class IBZDict extends EntityBase implements Serializable {
private
static
final
long
serialVersionUID
=
1L
;
/**
* 字典标识
*/
@TableId
(
value
=
"ibzdictid"
,
type
=
IdType
.
UUID
)
private
String
dictid
;
/**
* 字典名称
*/
...
...
@@ -46,19 +44,15 @@ public class IBZDict extends EntityBase implements Serializable {
private
String
dictname
;
/**
* 逻辑有效标志
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
LOGICVALID
)
@TableLogic
(
value
=
"1"
,
delval
=
"0"
)
@TableField
(
value
=
"enable"
,
fill
=
FieldFill
.
INSERT
)
@TableField
(
value
=
"enable"
,
fill
=
FieldFill
.
INSERT
_UPDATE
)
private
Integer
enable
;
/**
* 建立时间
*/
...
...
@@ -68,8 +62,6 @@ public class IBZDict extends EntityBase implements Serializable {
private
Timestamp
createdate
;
/**
* 更新时间
*/
...
...
@@ -79,8 +71,6 @@ public class IBZDict extends EntityBase implements Serializable {
private
Timestamp
updatedate
;
/**
* 建立人
*/
...
...
@@ -89,24 +79,32 @@ public class IBZDict extends EntityBase implements Serializable {
private
String
createman
;
/**
* 更新人
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEMAN
)
@TableField
(
value
=
"updateman"
,
fill
=
FieldFill
.
INSERT
)
@TableField
(
value
=
"updateman"
,
fill
=
FieldFill
.
INSERT
_UPDATE
)
private
String
updateman
;
/**
* 字典项目
*/
@JsonIgnore
@JSONField
(
serialize
=
false
)
@TableField
(
exist
=
false
)
private
List
<
cn
.
ibizlab
.
core
.
dict
.
domain
.
IBZDictItem
>
items
;
/**
* 设置 [字典标识]
*/
public
void
setDictid
(
String
dictid
){
this
.
dictid
=
dictid
;
this
.
modify
(
"ibzdictid"
,
dictid
);
this
.
modify
(
"ibzdictid"
,
dictid
);
}
/**
...
...
@@ -114,7 +112,7 @@ public class IBZDict extends EntityBase implements Serializable {
*/
public
void
setDictname
(
String
dictname
){
this
.
dictname
=
dictname
;
this
.
modify
(
"ibzdictname"
,
dictname
);
this
.
modify
(
"ibzdictname"
,
dictname
);
}
/**
...
...
@@ -122,7 +120,6 @@ public class IBZDict extends EntityBase implements Serializable {
*/
public
void
setEnable
(
Integer
enable
){
this
.
enable
=
enable
;
this
.
modify
(
"enable"
,
enable
);
}
/**
...
...
@@ -130,7 +127,6 @@ public class IBZDict extends EntityBase implements Serializable {
*/
public
void
setCreatedate
(
Timestamp
createdate
){
this
.
createdate
=
createdate
;
this
.
modify
(
"createdate"
,
createdate
);
}
/**
...
...
@@ -138,7 +134,6 @@ public class IBZDict extends EntityBase implements Serializable {
*/
public
void
setUpdatedate
(
Timestamp
updatedate
){
this
.
updatedate
=
updatedate
;
this
.
modify
(
"updatedate"
,
updatedate
);
}
/**
...
...
@@ -146,7 +141,6 @@ public class IBZDict extends EntityBase implements Serializable {
*/
public
void
setCreateman
(
String
createman
){
this
.
createman
=
createman
;
this
.
modify
(
"createman"
,
createman
);
}
/**
...
...
@@ -154,7 +148,6 @@ public class IBZDict extends EntityBase implements Serializable {
*/
public
void
setUpdateman
(
String
updateman
){
this
.
updateman
=
updateman
;
this
.
modify
(
"updateman"
,
updateman
);
}
}
...
...
ibzdict-core/src/main/java/cn/ibizlab/core/dict/domain/IBZDictItem.java
浏览文件 @
2649cea0
...
...
@@ -31,63 +31,54 @@ public class IBZDictItem extends EntityBase implements Serializable {
private
static
final
long
serialVersionUID
=
1L
;
/**
* 字典项目标识
*/
@TableId
(
value
=
"ibzdictitemid"
,
type
=
IdType
.
UUID
)
private
String
itemid
;
/**
* 栏目显示值
*/
@TableField
(
value
=
"ibzdictitemname"
)
private
String
itemname
;
/**
* 栏目值
*/
@TableField
(
value
=
"dictitemval"
)
private
String
itemval
;
/**
* 字典标识
*/
@TableField
(
value
=
"dictid"
)
private
String
dictid
;
/**
* 父栏目值
*/
@TableField
(
value
=
"pitemval"
)
private
String
pitemval
;
/**
* 过滤项
*/
@TableField
(
value
=
"itemfilter"
)
private
String
itemfilter
;
/**
* 栏目样式
*/
@TableField
(
value
=
"itemcls"
)
private
String
itemcls
;
/**
* 图标
*/
@TableField
(
value
=
"itemicon"
)
private
String
itemicon
;
/**
* 排序
*/
...
...
@@ -95,8 +86,6 @@ public class IBZDictItem extends EntityBase implements Serializable {
private
Integer
showorder
;
/**
* 建立时间
*/
...
...
@@ -106,8 +95,6 @@ public class IBZDictItem extends EntityBase implements Serializable {
private
Timestamp
createdate
;
/**
* 更新时间
*/
...
...
@@ -117,8 +104,6 @@ public class IBZDictItem extends EntityBase implements Serializable {
private
Timestamp
updatedate
;
/**
* 建立人
*/
...
...
@@ -127,13 +112,11 @@ public class IBZDictItem extends EntityBase implements Serializable {
private
String
createman
;
/**
* 更新人
*/
@DEField
(
preType
=
DEPredefinedFieldType
.
UPDATEMAN
)
@TableField
(
value
=
"updateman"
,
fill
=
FieldFill
.
INSERT
)
@TableField
(
value
=
"updateman"
,
fill
=
FieldFill
.
INSERT
_UPDATE
)
private
String
updateman
;
...
...
@@ -148,7 +131,7 @@ public class IBZDictItem extends EntityBase implements Serializable {
*/
public
void
setItemid
(
String
itemid
){
this
.
itemid
=
itemid
;
this
.
modify
(
"ibzdictitemid"
,
itemid
);
this
.
modify
(
"ibzdictitemid"
,
itemid
);
}
/**
...
...
@@ -156,7 +139,7 @@ public class IBZDictItem extends EntityBase implements Serializable {
*/
public
void
setItemname
(
String
itemname
){
this
.
itemname
=
itemname
;
this
.
modify
(
"ibzdictitemname"
,
itemname
);
this
.
modify
(
"ibzdictitemname"
,
itemname
);
}
/**
...
...
@@ -164,7 +147,7 @@ public class IBZDictItem extends EntityBase implements Serializable {
*/
public
void
setItemval
(
String
itemval
){
this
.
itemval
=
itemval
;
this
.
modify
(
"dictitemval"
,
itemval
);
this
.
modify
(
"dictitemval"
,
itemval
);
}
/**
...
...
@@ -172,7 +155,7 @@ public class IBZDictItem extends EntityBase implements Serializable {
*/
public
void
setDictid
(
String
dictid
){
this
.
dictid
=
dictid
;
this
.
modify
(
"dictid"
,
dictid
);
this
.
modify
(
"dictid"
,
dictid
);
}
/**
...
...
@@ -180,7 +163,7 @@ public class IBZDictItem extends EntityBase implements Serializable {
*/
public
void
setPitemval
(
String
pitemval
){
this
.
pitemval
=
pitemval
;
this
.
modify
(
"pitemval"
,
pitemval
);
this
.
modify
(
"pitemval"
,
pitemval
);
}
/**
...
...
@@ -188,7 +171,7 @@ public class IBZDictItem extends EntityBase implements Serializable {
*/
public
void
setItemfilter
(
String
itemfilter
){
this
.
itemfilter
=
itemfilter
;
this
.
modify
(
"itemfilter"
,
itemfilter
);
this
.
modify
(
"itemfilter"
,
itemfilter
);
}
/**
...
...
@@ -196,7 +179,7 @@ public class IBZDictItem extends EntityBase implements Serializable {
*/
public
void
setItemcls
(
String
itemcls
){
this
.
itemcls
=
itemcls
;
this
.
modify
(
"itemcls"
,
itemcls
);
this
.
modify
(
"itemcls"
,
itemcls
);
}
/**
...
...
@@ -204,7 +187,7 @@ public class IBZDictItem extends EntityBase implements Serializable {
*/
public
void
setItemicon
(
String
itemicon
){
this
.
itemicon
=
itemicon
;
this
.
modify
(
"itemicon"
,
itemicon
);
this
.
modify
(
"itemicon"
,
itemicon
);
}
/**
...
...
@@ -212,7 +195,7 @@ public class IBZDictItem extends EntityBase implements Serializable {
*/
public
void
setShoworder
(
Integer
showorder
){
this
.
showorder
=
showorder
;
this
.
modify
(
"showorder"
,
showorder
);
this
.
modify
(
"showorder"
,
showorder
);
}
/**
...
...
@@ -220,7 +203,6 @@ public class IBZDictItem extends EntityBase implements Serializable {
*/
public
void
setCreatedate
(
Timestamp
createdate
){
this
.
createdate
=
createdate
;
this
.
modify
(
"createdate"
,
createdate
);
}
/**
...
...
@@ -228,7 +210,6 @@ public class IBZDictItem extends EntityBase implements Serializable {
*/
public
void
setUpdatedate
(
Timestamp
updatedate
){
this
.
updatedate
=
updatedate
;
this
.
modify
(
"updatedate"
,
updatedate
);
}
/**
...
...
@@ -236,7 +217,6 @@ public class IBZDictItem extends EntityBase implements Serializable {
*/
public
void
setCreateman
(
String
createman
){
this
.
createman
=
createman
;
this
.
modify
(
"createman"
,
createman
);
}
/**
...
...
@@ -244,7 +224,6 @@ public class IBZDictItem extends EntityBase implements Serializable {
*/
public
void
setUpdateman
(
String
updateman
){
this
.
updateman
=
updateman
;
this
.
modify
(
"updateman"
,
updateman
);
}
}
...
...
ibzdict-util/src/main/java/cn/ibizlab/util/annotation/DEField.java
浏览文件 @
2649cea0
package
cn
.
ibizlab
.
util
.
annotation
;
import
cn.ibizlab.util.enums.DEFieldDefaultValueType
;
import
cn.ibizlab.util.enums.DEPredefinedFieldType
;
import
java.lang.annotation.ElementType
;
import
java.lang.annotation.Retention
;
import
java.lang.annotation.RetentionPolicy
;
...
...
@@ -16,15 +17,21 @@ public @interface DEField
*/
boolean
isKeyField
()
default
false
;
/**
*
填充模式
*
默认值
* @return
*/
String
defaultValue
()
default
""
;
/**
*
预置属性
类型
*
默认值
类型
* @return
*/
DEFieldDefaultValueType
defaultValueType
()
default
DEFieldDefaultValueType
.
NONE
;
/**
* 预置属性类型
* @return
*/
DEPredefinedFieldType
preType
()
default
DEPredefinedFieldType
.
DEFAULT
;
}
ibzdict-util/src/main/java/cn/ibizlab/util/domain/EntityBase.java
浏览文件 @
2649cea0
...
...
@@ -17,22 +17,22 @@ public class EntityBase implements Serializable {
@TableField
(
exist
=
false
)
private
Set
<
String
>
focusNull
;
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
void
addFocusNull
(
String
field
)
{
this
.
getFocusNull
().
add
(
field
);
public
void
modify
(
String
field
,
Object
val
)
{
if
(
val
==
null
)
this
.
getFocusNull
().
add
(
field
.
toLowerCase
());
else
this
.
getFocusNull
().
remove
(
field
.
toLowerCase
());
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
Set
<
String
>
getFocusNull
()
{
if
(
focusNull
==
null
)
focusNull
=
new
HashSet
<>();
return
focusNull
;
}
@JsonIgnore
@JSONField
(
serialize
=
false
)
public
UpdateWrapper
getUpdateWrapper
(
boolean
clean
)
{
UpdateWrapper
wrapper
=
new
UpdateWrapper
();
for
(
String
nullField:
getFocusNull
())
{
...
...
编辑
预览
Markdown
格式
0%
请重试
or
添加新附件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录