Closed cranehe closed 6 years ago
代码生成器生成controller时遇到数字型主键,使用的代码模板没有考虑这种情况
文件位置:wk-code/wk-code-generator/src/main/resources/templet/controller.vm
@At("/detail/?") @Ok("beetl:/${table.ViewBasePath}/detail.html") @RequiresPermissions("${table.Permissions}") public void detail(${table.pkType} id, HttpServletRequest req) { if (!Strings.isBlank(id)) { req.setAttribute("obj", ${table.ServiceInstanceName}.fetch(id)); }else{ req.setAttribute("obj", null); } }
好吧好吧,改了……
代码生成器生成controller时遇到数字型主键,使用的代码模板没有考虑这种情况
文件位置:wk-code/wk-code-generator/src/main/resources/templet/controller.vm