Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
提交反馈
为 GitLab 提交贡献
登录
切换导航
iBiz4j Spring R7
项目
项目
详情
动态
版本
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
iBiz-R7后台标准模板
iBiz4j Spring R7
提交
b8ceaee2
提交
b8ceaee2
编写于
5月 07, 2020
作者:
zhouweidong
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
调整子系统服务
上级
c1a8fee9
变更
1
隐藏空白字符变更
内嵌
并排
正在显示
1 个修改的文件
包含
17 行增加
和
16 行删除
+17
-16
%DE%ServiceImpl.java.ftl
.../core/%MOD_PKGPATH%/service/impl/%DE%ServiceImpl.java.ftl
+17
-16
未找到文件。
SLN/%PUBPRJ%-core/src/main/java/%SYS_PKGPATH%/core/%MOD_PKGPATH%/service/impl/%DE%ServiceImpl.java.ftl
浏览文件 @
b8ceaee2
...
...
@@ -861,8 +861,9 @@ public class ${item.getCodeName()}ServiceImpl implements I${de.getCodeName()}Ser
<#
comment
>
Api
存储
</#
comment
>
<#
elseif
de
.
getStorageMode
()==
4
>
<#
assign
serviceApiCodeName
=
item
.
getPSSubSysServiceAPI
().
codeName
>
import
${
pub
.
getPKGCodeName
()}.
core
.${
de
.
getPSSystemModule
().
getCodeName
()?
lower_case
}.
client
.${
item
.
c
odeName
}
FeignClient
;
import
${
pub
.
getPKGCodeName
()}.
core
.${
de
.
getPSSystemModule
().
getCodeName
()?
lower_case
}.
client
.${
serviceApiC
odeName
}
FeignClient
;
/**
*
实体
[${
item
.
getLogicName
()}]
服务对象接口实现
...
...
@@ -873,7 +874,7 @@ public class ${item.getCodeName()}ServiceImpl implements I${de.getCodeName()}Ser
<#
comment
>
引入
feignClient
</#
comment
>
@
Autowired
${
item
.
codeName
}
FeignClient
${
item
.
c
odeName
?
uncap_first
}
FeignClient
;
${
serviceApiCodeName
}
FeignClient
${
serviceApiC
odeName
?
uncap_first
}
FeignClient
;
<#
assign
keyfield
=
de
.
getKeyPSDEField
()>
...
...
@@ -907,7 +908,7 @@ public class ${item.getCodeName()}ServiceImpl implements I${de.getCodeName()}Ser
public
${
item
.
getCodeName
()}
get
(${
srfjavatype
(
keyfield
.
stdDataType
)}
${
keyfield
.
getCodeName
()?
lower_case
})
{
<#
if
item
.
isEnableAPIStorage
()>
<#
if
deaction
.
getPSSubSysServiceAPIDEMethod
()??
>
${
item
.
getCodeName
()}
et
=${
item
.
c
odeName
?
uncap_first
}
FeignClient
.${
deaction
.
getPSSubSysServiceAPIDEMethod
().
getCodeName
()?
uncap_first
}(${
keyfield
.
getCodeName
()?
lower_case
});
${
item
.
getCodeName
()}
et
=${
serviceApiC
odeName
?
uncap_first
}
FeignClient
.${
deaction
.
getPSSubSysServiceAPIDEMethod
().
getCodeName
()?
uncap_first
}(${
keyfield
.
getCodeName
()?
lower_case
});
if
(
et
==
null
){
et
=
new
${
item
.
getCodeName
()}();
et
.
set
${
srfcaseformat
(
keyfield
.
codeName
,
'l_u2lC'
)?
cap_first
}(${
keyfield
.
getCodeName
()?
lower_case
});
...
...
@@ -955,7 +956,7 @@ public class ${item.getCodeName()}ServiceImpl implements I${de.getCodeName()}Ser
public
boolean
create
(${
item
.
getCodeName
()}
et
)
{
<#
if
item
.
isEnableAPIStorage
()>
<#
if
deaction
.
getPSSubSysServiceAPIDEMethod
()??
>
${
item
.
getCodeName
()}
rt
=
${
item
.
c
odeName
?
uncap_first
}
FeignClient
.
create
(
et
);
${
item
.
getCodeName
()}
rt
=
${
serviceApiC
odeName
?
uncap_first
}
FeignClient
.
create
(
et
);
if
(
rt
==
null
)
return
false
;
<#
comment
>
1
:
N
关系中,在父实体中创建子实体的
List
集合
</#
comment
>
...
...
@@ -996,7 +997,7 @@ public class ${item.getCodeName()}ServiceImpl implements I${de.getCodeName()}Ser
public
void
createBatch
(
List
<${
item
.
codeName
}>
list
){
<#
if
item
.
isEnableAPIStorage
()>
<#
if
deaction
.
getPSSubSysServiceAPIDEMethod
()??
>
${
item
.
c
odeName
?
uncap_first
}
FeignClient
.
createBatch
(
list
)
;
${
serviceApiC
odeName
?
uncap_first
}
FeignClient
.
createBatch
(
list
)
;
</#
if
>
</#
if
>
}
...
...
@@ -1006,7 +1007,7 @@ public class ${item.getCodeName()}ServiceImpl implements I${de.getCodeName()}Ser
public
boolean
update
(${
item
.
getCodeName
()}
et
)
{
<#
if
item
.
isEnableAPIStorage
()>
<#
if
deaction
.
getPSSubSysServiceAPIDEMethod
()??
>
${
item
.
getCodeName
()}
rt
=
${
item
.
c
odeName
?
uncap_first
}
FeignClient
.
update
(
et
.
get
${
srfcaseformat
(
keyfield
.
codeName
,
'l_u2lC'
)?
cap_first
}(),
et
);
${
item
.
getCodeName
()}
rt
=
${
serviceApiC
odeName
?
uncap_first
}
FeignClient
.
update
(
et
.
get
${
srfcaseformat
(
keyfield
.
codeName
,
'l_u2lC'
)?
cap_first
}(),
et
);
if
(
rt
==
null
)
return
false
;
<#
comment
>
1
:
N
关系中,在父实体中创建子实体的
List
集合
</#
comment
>
...
...
@@ -1048,7 +1049,7 @@ public class ${item.getCodeName()}ServiceImpl implements I${de.getCodeName()}Ser
public
void
updateBatch
(
List
<${
item
.
codeName
}>
list
){
<#
if
item
.
isEnableAPIStorage
()>
<#
if
deaction
.
getPSSubSysServiceAPIDEMethod
()??
>
${
item
.
c
odeName
?
uncap_first
}
FeignClient
.
updateBatch
(
list
)
;
${
serviceApiC
odeName
?
uncap_first
}
FeignClient
.
updateBatch
(
list
)
;
</#
if
>
</#
if
>
}
...
...
@@ -1060,7 +1061,7 @@ public class ${item.getCodeName()}ServiceImpl implements I${de.getCodeName()}Ser
<#
if
item
.
isEnableAPIStorage
()>
<#
if
deaction
.
getPSSubSysServiceAPIDEMethod
()??
>
if
(
et
.
get
${
srfcaseformat
(
keyfield
.
codeName
,
'l_u2lC'
)?
cap_first
}()==
null
)
et
.
set
${
srfcaseformat
(
keyfield
.
codeName
,
'l_u2lC'
)?
cap_first
}((${
srfjavatype
(
keyfield
.
stdDataType
)})
et
.
getDefaultKey
(
true
));
if
(
!${
item.c
odeName?uncap_first}FeignClient.save(et))
if
(
!${
serviceApiC
odeName?uncap_first}FeignClient.save(et))
return
false
;
<#
comment
>
1
:
N
关系中,在父实体中创建子实体的
List
集合
</#
comment
>
<#
if
de
.
getMajorPSDERs
??
&&
de
.
getMajorPSDERs
()??>
...
...
@@ -1100,7 +1101,7 @@ public class ${item.getCodeName()}ServiceImpl implements I${de.getCodeName()}Ser
public
void
saveBatch
(
List
<${
item
.
getCodeName
()}>
list
)
{
<#
if
item
.
isEnableAPIStorage
()>
<#
if
deaction
.
getPSSubSysServiceAPIDEMethod
()??
>
${
item
.
c
odeName
?
uncap_first
}
FeignClient
.
saveBatch
(
list
)
;
${
serviceApiC
odeName
?
uncap_first
}
FeignClient
.
saveBatch
(
list
)
;
</#
if
>
</#
if
>
}
...
...
@@ -1119,7 +1120,7 @@ public class ${item.getCodeName()}ServiceImpl implements I${de.getCodeName()}Ser
</#
if
>
<#
if
item
.
isEnableAPIStorage
()>
<#
if
deaction
.
getPSSubSysServiceAPIDEMethod
()??
>
return
${
item
.
c
odeName
?
uncap_first
}
FeignClient
.
remove
(${
keyfield
.
getCodeName
()?
lower_case
})
;
return
${
serviceApiC
odeName
?
uncap_first
}
FeignClient
.
remove
(${
keyfield
.
getCodeName
()?
lower_case
})
;
<#
else
>
return
false
;
</#
if
>
...
...
@@ -1131,7 +1132,7 @@ public class ${item.getCodeName()}ServiceImpl implements I${de.getCodeName()}Ser
public
void
removeBatch
(
Collection
<${
srfjavatype
(
keyfield
.
stdDataType
)}>
idList
){
<#
if
item
.
isEnableAPIStorage
()>
<#
if
deaction
.
getPSSubSysServiceAPIDEMethod
()??
>
${
item
.
c
odeName
?
uncap_first
}
FeignClient
.
removeBatch
(
idList
);
${
serviceApiC
odeName
?
uncap_first
}
FeignClient
.
removeBatch
(
idList
);
</#
if
>
</#
if
>
}
...
...
@@ -1141,7 +1142,7 @@ public class ${item.getCodeName()}ServiceImpl implements I${de.getCodeName()}Ser
public
${
item
.
getCodeName
()}
getDraft
(${
item
.
getCodeName
()}
et
)
{
<#
if
item
.
isEnableAPIStorage
()>
<#
if
deaction
.
getPSSubSysServiceAPIDEMethod
()??
>
return
${
item
.
c
odeName
?
uncap_first
}
FeignClient
.
getDraft
();
return
${
serviceApiC
odeName
?
uncap_first
}
FeignClient
.
getDraft
();
<#
else
>
return
null
;
</#
if
>
...
...
@@ -1155,7 +1156,7 @@ public class ${item.getCodeName()}ServiceImpl implements I${de.getCodeName()}Ser
public
boolean
checkKey
(${
item
.
getCodeName
()}
et
)
{
<#
if
item
.
isEnableAPIStorage
()>
<#
if
deaction
.
getPSSubSysServiceAPIDEMethod
()??
>
return
${
item
.
c
odeName
?
uncap_first
}
FeignClient
.
checkKey
(
et
);
return
${
serviceApiC
odeName
?
uncap_first
}
FeignClient
.
checkKey
(
et
);
<#
else
>
return
false
;
</#
if
>
...
...
@@ -1168,7 +1169,7 @@ public class ${item.getCodeName()}ServiceImpl implements I${de.getCodeName()}Ser
public
${
item
.
getCodeName
()}
${
srfmethodname
(
deaction
.
getCodeName
())}(${
item
.
getCodeName
()}
et
)
{
<#
if
item
.
isEnableAPIStorage
()>
<#
if
deaction
.
getPSSubSysServiceAPIDEMethod
()??
>
return
${
item
.
c
odeName
?
uncap_first
}
FeignClient
.${
deaction
.
getPSSubSysServiceAPIDEMethod
().
getCodeName
()?
uncap_first
}(
et
.
get
${
srfcaseformat
(
keyfield
.
codeName
,
'l_u2lC'
)?
cap_first
}(),
et
);
return
${
serviceApiC
odeName
?
uncap_first
}
FeignClient
.${
deaction
.
getPSSubSysServiceAPIDEMethod
().
getCodeName
()?
uncap_first
}(
et
.
get
${
srfcaseformat
(
keyfield
.
codeName
,
'l_u2lC'
)?
cap_first
}(),
et
);
<#
else
>
return
null
;
</#
if
>
...
...
@@ -1201,7 +1202,7 @@ public class ${item.getCodeName()}ServiceImpl implements I${de.getCodeName()}Ser
${
item
.
getCodeName
()}
SearchContext
context
=
new
${
item
.
getCodeName
()}
SearchContext
();
context
.
setSize
(
Integer
.
MAX_VALUE
);
context
.
setN_
${
MajorField
.
name
?
lower_case
}
_eq
(${
MajorkeyField
.
codeName
?
lower_case
});
return
${
item
.
c
odeName
?
uncap_first
}
FeignClient
.
search
${
deDefaultDataSet
.
getCodeName
()}(
context
).
getContent
();
return
${
serviceApiC
odeName
?
uncap_first
}
FeignClient
.
search
${
deDefaultDataSet
.
getCodeName
()}(
context
).
getContent
();
}
@
Override
...
...
@@ -1273,7 +1274,7 @@ public class ${item.getCodeName()}ServiceImpl implements I${de.getCodeName()}Ser
public
Page
<${
item
.
getCodeName
()}>
search
${
dedataset
.
getCodeName
()}(${
item
.
getCodeName
()}
SearchContext
context
)
{
<#--<#
if
item
.
isEnableNoSQLStorage
()
&&
item
.
getAllPSDEDBTables
()??>-->
<#--<#
list
item
.
getAllPSDEDBTables
()
as
detable
>-->
Page
<${
de
.
getCodeName
()}>
${
de
.
getCodeName
()?
uncap_first
}
s
=${
item
.
c
odeName
?
uncap_first
}
FeignClient
.
search
${
dedataset
.
getCodeName
()}(
context
);
Page
<${
de
.
getCodeName
()}>
${
de
.
getCodeName
()?
uncap_first
}
s
=${
serviceApiC
odeName
?
uncap_first
}
FeignClient
.
search
${
dedataset
.
getCodeName
()}(
context
);
return
${
de
.
getCodeName
()?
uncap_first
}
s
;
<#--</#
list
>-->
<#--<#
else
>-->
...
...
编辑
预览
Markdown
格式
0%
请重试
or
添加新附件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
先完成此消息的编辑!
取消
想要评论请
注册
或
登录