controller模板调整
This commit is contained in:
@@ -74,10 +74,10 @@ public class ${table.controllerName} {
|
|||||||
<% } %>
|
<% } %>
|
||||||
|
|
||||||
<% if(isNotEmpty(controllerMethods.create)){ %>
|
<% if(isNotEmpty(controllerMethods.create)){ %>
|
||||||
|
@PostMapping(value = "/insert")
|
||||||
<% if(!restControllerStyle){ %>
|
<% if(!restControllerStyle){ %>
|
||||||
@ResponseBody
|
@ResponseBody
|
||||||
<% } %>
|
<% } %>
|
||||||
@PostMapping(value = "/insert")
|
|
||||||
public CommonResult.Single<${table.entityName}> insert(${table.entityName} ${entityInstanceName}) {
|
public CommonResult.Single<${table.entityName}> insert(${table.entityName} ${entityInstanceName}) {
|
||||||
CommonResult.Single<${table.entityName}> single = CommonResult.Single.init();
|
CommonResult.Single<${table.entityName}> single = CommonResult.Single.init();
|
||||||
${serviceInstanceName}.save(${entityInstanceName});
|
${serviceInstanceName}.save(${entityInstanceName});
|
||||||
|
|||||||
@@ -73,10 +73,10 @@ public class ${table.controllerName} {
|
|||||||
<% } %>
|
<% } %>
|
||||||
|
|
||||||
<% if(isNotEmpty(controllerMethods.create)){ %>
|
<% if(isNotEmpty(controllerMethods.create)){ %>
|
||||||
|
@PostMapping(value = "/insert")
|
||||||
<% if(!restControllerStyle){ %>
|
<% if(!restControllerStyle){ %>
|
||||||
@ResponseBody
|
@ResponseBody
|
||||||
<% } %>
|
<% } %>
|
||||||
@PostMapping(value = "/insert")
|
|
||||||
public R<${table.entityName}> insert(${table.entityName} ${entityInstanceName}) {
|
public R<${table.entityName}> insert(${table.entityName} ${entityInstanceName}) {
|
||||||
R<${table.entityName}> result = R.ok();
|
R<${table.entityName}> result = R.ok();
|
||||||
${serviceInstanceName}.save(${entityInstanceName});
|
${serviceInstanceName}.save(${entityInstanceName});
|
||||||
|
|||||||
Reference in New Issue
Block a user