提交 273f01fd 编写于 作者: zhouweidong's avatar zhouweidong

修复getById主键数据类型

上级 3202fe08
......@@ -38,7 +38,7 @@ import ${pub.getPKGCodeName()}.core.${de.getPSSystemModule().getCodeName()?lower
<#comment>SQL存储-Mybatis</#comment>
<#if de.getStorageMode()==1>
<#assign keyfield=item.getKeyPSDEField()>
import com.baomidou.mybatisplus.extension.service.IService;
/**
......@@ -63,13 +63,13 @@ public interface I${item.codeName}Service extends IService<${item.codeName}>{
boolean execute(String sql, Map param);
<#if hasDEPrefield>
List<${de.codeName}> get${deCodeNameCamel}ByIds(List<String> ids) ;
List<${de.codeName}> get${deCodeNameCamel}ByIds(List<${srfr7javatype(keyfield.stdDataType)}> ids) ;
List<${de.codeName}> get${deCodeNameCamel}ByEntities(List<${de.codeName}> entities) ;
</#if>
}
<#comment>NoSQL存储-MongoDB</#comment>
<#elseif de.getStorageMode()==2>
<#assign keyfield=item.getKeyPSDEField()>
/**
* 实体[${item.codeName}] 服务对象接口
*/
......@@ -78,7 +78,7 @@ public interface I${item.codeName}Service{
<@addIDESerivceBody />
<#if hasDEPrefield>
List<${de.codeName}> get${deCodeNameCamel}ByIds(List<String> ids) ;
List<${de.codeName}> get${deCodeNameCamel}ByIds(List<${srfr7javatype(keyfield.stdDataType)}> ids) ;
List<${de.codeName}> get${deCodeNameCamel}ByEntities(List<${de.codeName}> entities) ;
</#if>
}
......
......@@ -881,7 +881,7 @@ public class ${item.getCodeName()}ServiceImpl extends ServiceImpl<${de.getCodeNa
<#if hasDEPrefield>
@Override
public List<${de.codeName}> get${deCodeNameCamel}ByIds(List<String> ids) {
public List<${de.codeName}> get${deCodeNameCamel}ByIds(List<${srfr7javatype(keyfield.stdDataType)}> ids) {
return this.listByIds(ids);
}
......@@ -1422,7 +1422,7 @@ public class ${item.getCodeName()}ServiceImpl implements I${de.getCodeName()}Ser
<#if hasDEPrefield>
@Override
public List<${de.codeName}> get${deCodeNameCamel}ByIds(List<String> ids) {
public List<${de.codeName}> get${deCodeNameCamel}ByIds(List<${srfr7javatype(keyfield.stdDataType)}> ids) {
QueryBuilder permissionCond=new QueryBuilder();
permissionCond.and("${keyfield.codeName?lower_case}").in(ids);
Query query = new BasicQuery(permissionCond.get().toString());
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册