修改批量生成代码模版,模版中加入App端的list查询接口

This commit is contained in:
kuang.yifei@iwhalecloud.com 2022-07-08 10:01:40 +08:00
parent eb49ce9f71
commit 53e1bb6454
1 changed files with 14 additions and 5 deletions

View File

@ -5,11 +5,7 @@ import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller; import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap; import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.*;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import com.ghy.common.annotation.Log; import com.ghy.common.annotation.Log;
import com.ghy.common.enums.BusinessType; import com.ghy.common.enums.BusinessType;
import ${packageName}.domain.${ClassName}; import ${packageName}.domain.${ClassName};
@ -59,6 +55,19 @@ public class ${ClassName}Controller extends BaseController
List<${ClassName}> list = ${className}Service.select${ClassName}List(${className}); List<${ClassName}> list = ${className}Service.select${ClassName}List(${className});
return getDataTable(list); return getDataTable(list);
} }
/**
* App查询${functionName}列表
*/
@PostMapping("/app/list")
@ResponseBody
public TableDataInfo appList(@RequestBody ${ClassName} ${className})
{
startPage();
List<${ClassName}> list = ${className}Service.select${ClassName}List(${className});
return getDataTable(list);
}
#elseif($table.tree) #elseif($table.tree)
/** /**
* 查询${functionName}树列表 * 查询${functionName}树列表