Commit 6439af720ae10d31be16ea8f53667b6524aa8b16
1 parent
61447fd6
Exists in
master
id format to long
Showing
6 changed files
with
10 additions
and
10 deletions
Show diff stats
build.gradle
@@ -55,7 +55,7 @@ uploadArchives { | @@ -55,7 +55,7 @@ uploadArchives { | ||
55 | authentication(userName: NEXUS_USERNAME, password: NEXUS_PASSWORD) | 55 | authentication(userName: NEXUS_USERNAME, password: NEXUS_PASSWORD) |
56 | } | 56 | } |
57 | pom.project { | 57 | pom.project { |
58 | - version '1.2.22' | 58 | + version '1.2.24' |
59 | artifactId ARTIFACT_Id | 59 | artifactId ARTIFACT_Id |
60 | groupId GROUP_ID | 60 | groupId GROUP_ID |
61 | packaging TYPE | 61 | packaging TYPE |
build/classes/java/main/com/taover/codegenerate/bazhuayun/GenerateCode.class
No preview for this file type
src/main/resources/template/bazhuayun/RepositoryTemplate.ftl
@@ -16,20 +16,20 @@ import com.taover.util.UtilHttpRequestMap; | @@ -16,20 +16,20 @@ import com.taover.util.UtilHttpRequestMap; | ||
16 | import com.taover.util.UtilObject; | 16 | import com.taover.util.UtilObject; |
17 | 17 | ||
18 | @Repository | 18 | @Repository |
19 | -public class ${repositoryClassSimpleName} extends CustomJdbcTemplate<${entityClassSimpleName}, Integer>{ | 19 | +public class ${repositoryClassSimpleName} extends CustomJdbcTemplate<${entityClassSimpleName}, Long>{ |
20 | 20 | ||
21 | public ${repositoryClassSimpleName}() throws Exception { | 21 | public ${repositoryClassSimpleName}() throws Exception { |
22 | super(); | 22 | super(); |
23 | } | 23 | } |
24 | 24 | ||
25 | - public String getSsidById(Integer id) throws Exception{ | 25 | + public String getSsidById(Long id) throws Exception{ |
26 | MessagePack pack = new MessagePack(); | 26 | MessagePack pack = new MessagePack(); |
27 | - return Base64.getEncoder().encodeToString(pack.write(new Integer[]{id, id, id})); | 27 | + return Base64.getEncoder().encodeToString(pack.write(new Long[]{id, id, id})); |
28 | } | 28 | } |
29 | 29 | ||
30 | public Integer getIdBySsid(String ssid) throws Exception{ | 30 | public Integer getIdBySsid(String ssid) throws Exception{ |
31 | MessagePack pack = new MessagePack(); | 31 | MessagePack pack = new MessagePack(); |
32 | - return pack.read(Base64.getDecoder().decode(ssid), Integer[].class)[0]; | 32 | + return pack.read(Base64.getDecoder().decode(ssid), Long[].class)[0]; |
33 | } | 33 | } |
34 | 34 | ||
35 | public Map<String, Object> getVoPage(List<Object[]> condition, Integer page, Integer size) throws Exception{ | 35 | public Map<String, Object> getVoPage(List<Object[]> condition, Integer page, Integer size) throws Exception{ |
src/main/resources/template/bazhuayun/ServiceImplTemplate.ftl
@@ -30,7 +30,7 @@ public class ${serviceImplClassSimpleName} implements ${serviceClassSimpleName} | @@ -30,7 +30,7 @@ public class ${serviceImplClassSimpleName} implements ${serviceClassSimpleName} | ||
30 | } | 30 | } |
31 | 31 | ||
32 | @Override | 32 | @Override |
33 | - public ResultInfo getOneV1(Integer id) { | 33 | + public ResultInfo getOneV1(Long id) { |
34 | try { | 34 | try { |
35 | return UtilResultInfo.getSuccess("查询成功", this.${repositoryClassFieldName}.findEntityByID(id)); | 35 | return UtilResultInfo.getSuccess("查询成功", this.${repositoryClassFieldName}.findEntityByID(id)); |
36 | } catch (Exception e) { | 36 | } catch (Exception e) { |
src/main/resources/template/bazhuayun/ServiceTemplate.ftl
src/main/resources/template/bazhuayun/V1ControllerTemplate.ftl
@@ -82,7 +82,7 @@ public class ${controllerClassName} { | @@ -82,7 +82,7 @@ public class ${controllerClassName} { | ||
82 | * @apiUse ResultInfo | 82 | * @apiUse ResultInfo |
83 | */ | 83 | */ |
84 | @GetMapping("/{id}") | 84 | @GetMapping("/{id}") |
85 | - public ResultInfo get(@PathVariable Integer id){ | 85 | + public ResultInfo get(@PathVariable Long id){ |
86 | return this.${serviceClassFieldName}.getOneV1(id); | 86 | return this.${serviceClassFieldName}.getOneV1(id); |
87 | } | 87 | } |
88 | 88 | ||
@@ -114,7 +114,7 @@ public class ${controllerClassName} { | @@ -114,7 +114,7 @@ public class ${controllerClassName} { | ||
114 | * @apiUse ResultInfo | 114 | * @apiUse ResultInfo |
115 | */ | 115 | */ |
116 | @DeleteMapping("/{id}") | 116 | @DeleteMapping("/{id}") |
117 | - public ResultInfo delete(@PathVariable Integer id){ | 117 | + public ResultInfo delete(@PathVariable Long id){ |
118 | return UtilResultInfo.getFailure("没有找到对应处理逻辑"); | 118 | return UtilResultInfo.getFailure("没有找到对应处理逻辑"); |
119 | } | 119 | } |
120 | 120 | ||
@@ -130,7 +130,7 @@ public class ${controllerClassName} { | @@ -130,7 +130,7 @@ public class ${controllerClassName} { | ||
130 | * @apiUse ResultInfo | 130 | * @apiUse ResultInfo |
131 | */ | 131 | */ |
132 | @PutMapping("/{id}") | 132 | @PutMapping("/{id}") |
133 | - public ResultInfo put(@PathVariable Integer id, HttpServletRequest request){ | 133 | + public ResultInfo put(@PathVariable Long id, HttpServletRequest request){ |
134 | return UtilResultInfo.getFailure("没有找到对应处理逻辑"); | 134 | return UtilResultInfo.getFailure("没有找到对应处理逻辑"); |
135 | } | 135 | } |
136 | 136 |