diff --git a/build.gradle b/build.gradle index dd51f45..c2fa11e 100644 --- a/build.gradle +++ b/build.gradle @@ -55,7 +55,7 @@ uploadArchives { authentication(userName: NEXUS_USERNAME, password: NEXUS_PASSWORD) } pom.project { - version '1.2.22' + version '1.2.24' artifactId ARTIFACT_Id groupId GROUP_ID packaging TYPE diff --git a/build/classes/java/main/com/taover/codegenerate/bazhuayun/GenerateCode.class b/build/classes/java/main/com/taover/codegenerate/bazhuayun/GenerateCode.class index 5a146d8..dca65f4 100644 Binary files a/build/classes/java/main/com/taover/codegenerate/bazhuayun/GenerateCode.class and b/build/classes/java/main/com/taover/codegenerate/bazhuayun/GenerateCode.class differ diff --git a/src/main/resources/template/bazhuayun/RepositoryTemplate.ftl b/src/main/resources/template/bazhuayun/RepositoryTemplate.ftl index a62a01f..454a5d0 100644 --- a/src/main/resources/template/bazhuayun/RepositoryTemplate.ftl +++ b/src/main/resources/template/bazhuayun/RepositoryTemplate.ftl @@ -16,20 +16,20 @@ import com.taover.util.UtilHttpRequestMap; import com.taover.util.UtilObject; @Repository -public class ${repositoryClassSimpleName} extends CustomJdbcTemplate<${entityClassSimpleName}, Integer>{ +public class ${repositoryClassSimpleName} extends CustomJdbcTemplate<${entityClassSimpleName}, Long>{ public ${repositoryClassSimpleName}() throws Exception { super(); } - public String getSsidById(Integer id) throws Exception{ + public String getSsidById(Long id) throws Exception{ MessagePack pack = new MessagePack(); - return Base64.getEncoder().encodeToString(pack.write(new Integer[]{id, id, id})); + return Base64.getEncoder().encodeToString(pack.write(new Long[]{id, id, id})); } public Integer getIdBySsid(String ssid) throws Exception{ MessagePack pack = new MessagePack(); - return pack.read(Base64.getDecoder().decode(ssid), Integer[].class)[0]; + return pack.read(Base64.getDecoder().decode(ssid), Long[].class)[0]; } public Map getVoPage(List condition, Integer page, Integer size) throws Exception{ diff --git a/src/main/resources/template/bazhuayun/ServiceImplTemplate.ftl b/src/main/resources/template/bazhuayun/ServiceImplTemplate.ftl index 809211a..55c0675 100644 --- a/src/main/resources/template/bazhuayun/ServiceImplTemplate.ftl +++ b/src/main/resources/template/bazhuayun/ServiceImplTemplate.ftl @@ -30,7 +30,7 @@ public class ${serviceImplClassSimpleName} implements ${serviceClassSimpleName} } @Override - public ResultInfo getOneV1(Integer id) { + public ResultInfo getOneV1(Long id) { try { return UtilResultInfo.getSuccess("查询成功", this.${repositoryClassFieldName}.findEntityByID(id)); } catch (Exception e) { diff --git a/src/main/resources/template/bazhuayun/ServiceTemplate.ftl b/src/main/resources/template/bazhuayun/ServiceTemplate.ftl index ca40106..14c3db9 100644 --- a/src/main/resources/template/bazhuayun/ServiceTemplate.ftl +++ b/src/main/resources/template/bazhuayun/ServiceTemplate.ftl @@ -20,5 +20,5 @@ public interface ${serviceClassSimpleName} { * @param id * @return */ - public ResultInfo getOneV1(Integer id); + public ResultInfo getOneV1(Long id); } diff --git a/src/main/resources/template/bazhuayun/V1ControllerTemplate.ftl b/src/main/resources/template/bazhuayun/V1ControllerTemplate.ftl index c301fb0..4f9a2e8 100644 --- a/src/main/resources/template/bazhuayun/V1ControllerTemplate.ftl +++ b/src/main/resources/template/bazhuayun/V1ControllerTemplate.ftl @@ -82,7 +82,7 @@ public class ${controllerClassName} { * @apiUse ResultInfo */ @GetMapping("/{id}") - public ResultInfo get(@PathVariable Integer id){ + public ResultInfo get(@PathVariable Long id){ return this.${serviceClassFieldName}.getOneV1(id); } @@ -114,7 +114,7 @@ public class ${controllerClassName} { * @apiUse ResultInfo */ @DeleteMapping("/{id}") - public ResultInfo delete(@PathVariable Integer id){ + public ResultInfo delete(@PathVariable Long id){ return UtilResultInfo.getFailure("没有找到对应处理逻辑"); } @@ -130,7 +130,7 @@ public class ${controllerClassName} { * @apiUse ResultInfo */ @PutMapping("/{id}") - public ResultInfo put(@PathVariable Integer id, HttpServletRequest request){ + public ResultInfo put(@PathVariable Long id, HttpServletRequest request){ return UtilResultInfo.getFailure("没有找到对应处理逻辑"); } -- libgit2 0.21.2