diff --git a/db-file/opsli-boot.sql b/db-file/opsli-boot.sql index 0dd5bbe..7f1cf43 100644 --- a/db-file/opsli-boot.sql +++ b/db-file/opsli-boot.sql @@ -11,7 +11,7 @@ Target Server Version : 50733 File Encoding : 65001 - Date: 01/06/2021 20:37:34 + Date: 03/06/2021 20:54:51 */ SET NAMES utf8mb4; @@ -45,7 +45,7 @@ CREATE TABLE `gen_logs` ( -- Records of gen_logs -- ---------------------------- INSERT INTO `gen_logs` VALUES (1340631269252005889, 1340630022558056449, '', 'org.opsli.modulars', 'gentest', 'carinfo', '汽车信息', '汽车信息', 'Parker', 1398253704724828162, 0, 1313694379541635074, '2020-12-20 20:12:57', 1313694379541635074, '2021-06-01 20:33:43'); -INSERT INTO `gen_logs` VALUES (1359429290382323714, 1359428685312028674, '', 'org.opsli.modulars.gentest', 'other', 'crypto', '非对称加密管理', '非对称加密', 'Parker', 1398253704724828162, 0, 1313694379541635074, '2021-02-10 17:09:34', 1313694379541635074, '2021-06-01 20:34:18'); +INSERT INTO `gen_logs` VALUES (1359429290382323714, 1359428685312028674, '', 'org.opsli.modulars.gentest', 'other', 'crypto', '非对称加密管理', '非对称加密', 'Parker', 1398253704724828162, 0, 1313694379541635074, '2021-02-10 17:09:34', 1, '2021-06-02 18:33:30'); -- ---------------------------- -- Table structure for gen_table @@ -74,7 +74,7 @@ CREATE TABLE `gen_table` ( -- ---------------------------- INSERT INTO `gen_table` VALUES (1340630022558056449, 'test_car', 'test_car', '0', '测试汽车', 'mysql', '1', NULL, 1, 1313694379541635074, '2020-12-20 20:08:00', 1313694379541635074, '2020-12-20 20:10:48'); INSERT INTO `gen_table` VALUES (1356152016136482817, 'test_car_copy1', 'test_car_copy1', '0', '测试', 'mysql', '1', NULL, 0, 1313694379541635074, '2021-02-01 16:06:51', 1313694379541635074, '2021-02-01 16:06:51'); -INSERT INTO `gen_table` VALUES (1359428685312028674, 'other_crypto_asymmetric', 'other_crypto_asymmetric', '0', '非对称加密表', 'mysql', '0', NULL, 12, 1313694379541635074, '2021-02-10 17:07:10', 1313694379541635074, '2021-05-26 20:39:14'); +INSERT INTO `gen_table` VALUES (1359428685312028674, 'other_crypto_asymmetric', 'other_crypto_asymmetric', '0', '非对称加密表', 'mysql', '1', NULL, 12, 1313694379541635074, '2021-02-10 17:07:10', 1313694379541635074, '2021-05-26 20:39:14'); INSERT INTO `gen_table` VALUES (1397541427197468673, 'test_user', 'test_user', '0', '某系统用户', 'mysql', '0', NULL, 1, 1313694379541635074, '2021-05-26 21:13:36', 1313694379541635074, '2021-05-26 21:29:06'); -- ---------------------------- @@ -182,7 +182,7 @@ CREATE TABLE `gen_template` ( -- ---------------------------- -- Records of gen_template -- ---------------------------- -INSERT INTO `gen_template` VALUES (1398253704724828162, 'Form表单', '0', '', 28, 1313694379541635074, '2021-05-28 20:23:56', 1313694379541635074, '2021-06-01 20:34:07'); +INSERT INTO `gen_template` VALUES (1398253704724828162, 'Form表单', '0', '默认Form表单', 31, 1313694379541635074, '2021-05-28 20:23:56', 1313694379541635074, '2021-06-03 12:51:13'); -- ---------------------------- -- Table structure for gen_template_detail @@ -208,18 +208,18 @@ CREATE TABLE `gen_template_detail` ( -- ---------------------------- -- Records of gen_template_detail -- ---------------------------- -INSERT INTO `gen_template_detail` VALUES (1399705818550484994, 1398253704724828162, '0', '${packageName}/${moduleName}/${subModuleName}/entity', 'Entity.java', '#if(data.subModuleName != null && data.subModuleName != \"\")\npackage #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).entity;\n#else\npackage #(data.packageName+\".\"+data.moduleName).entity;\n#end\n\n#for(pkg : data.model.entityPkgList)\nimport #(pkg);\n#end\nimport com.baomidou.mybatisplus.annotation.FieldStrategy;\nimport com.baomidou.mybatisplus.annotation.TableField;\nimport com.baomidou.mybatisplus.annotation.TableLogic;\nimport lombok.Data;\nimport lombok.EqualsAndHashCode;\nimport org.opsli.core.base.entity.BaseEntity;\n\n/**\n * #(data.codeTitle) Entity\n *\n * @author #(data.authorName)\n * @date #(currTime)\n */\n@Data\n@EqualsAndHashCode(callSuper = false)\npublic class #(data.model.tableHumpName) extends BaseEntity {\n\n\n #for(column : data.model.columnList)\n ### 不等于 删除字段 和 不等于 租户字段放入上边\n #if(column.fieldHumpName != \"deleted\" && column.fieldHumpName != \"tenantId\")\n /** #(column.fieldComments) */\n #if(!column.izNotNull)\n @TableField(updateStrategy = FieldStrategy.IGNORED)\n #end\n private #(column.javaType) #(column.fieldHumpName);\n\n #end\n #end\n\n // ========================================\n\n ### 专门处理 删除字段 和 租户字段\n #for(column : data.model.columnList)\n #if(column.fieldHumpName == \"deleted\")\n /** 逻辑删除字段 */\n @TableLogic\n private Integer deleted;\n #else if(column.fieldHumpName == \"tenantId\")\n /** 多租户字段 */\n private String tenantId;\n #end\n\n #end\n\n}', '1', 0, 1313694379541635074, '2021-06-01 20:34:07', 1313694379541635074, '2021-06-01 20:34:07'); -INSERT INTO `gen_template_detail` VALUES (1399705818613399554, 1398253704724828162, '0', '${packageName}/${moduleName}/${subModuleName}/mapper', 'Mapper.java', '#if(data.subModuleName != null && data.subModuleName != \"\")\npackage #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).mapper;\n#else\npackage #(data.packageName+\".\"+data.moduleName).mapper;\n#end\n\nimport com.baomidou.mybatisplus.core.mapper.BaseMapper;\nimport org.apache.ibatis.annotations.Mapper;\nimport org.apache.ibatis.annotations.Param;\n#if(data.subModuleName != null && data.subModuleName != \"\")\nimport #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).entity.#(data.model.tableHumpName);\n#else\nimport #(data.packageName+\".\"+data.moduleName).entity.#(data.model.tableHumpName);\n#end\n\n/**\n * #(data.codeTitle) Mapper\n *\n * @author #(data.authorName)\n * @date #(currTime)\n */\n@Mapper\npublic interface #(data.model.tableHumpName)Mapper extends BaseMapper<#(data.model.tableHumpName)> {\n\n}', '0', 0, 1313694379541635074, '2021-06-01 20:34:07', 1313694379541635074, '2021-06-01 20:34:07'); -INSERT INTO `gen_template_detail` VALUES (1399705818613399555, 1398253704724828162, '0', '${packageName}/${moduleName}/${subModuleName}/mapper/xml', 'Mapper.xml', '\n\n#if(data.subModuleName != null && data.subModuleName != \"\")\n\n#else\n\n#end\n\n\n', '0', 0, 1313694379541635074, '2021-06-01 20:34:07', 1313694379541635074, '2021-06-01 20:34:07'); -INSERT INTO `gen_template_detail` VALUES (1399705818680508418, 1398253704724828162, '0', 'org/opsli/api/wrapper/${moduleName}/${subModuleName}', 'Model.java', '#if(data.subModuleName != null && data.subModuleName != \"\")\npackage #(apiPath).wrapper.#(data.moduleName+\".\"+data.subModuleName);\n#else\npackage #(apiPath).wrapper.#(data.moduleName);\n#end\n\n#for(pkg : data.model.entityPkgList)\nimport #(pkg);\n#end\nimport com.alibaba.excel.annotation.ExcelProperty;\nimport io.swagger.annotations.ApiModelProperty;\nimport lombok.Data;\nimport lombok.EqualsAndHashCode;\nimport #(apiPath).base.warpper.ApiWrapper;\nimport org.opsli.common.annotation.validator.Validator;\nimport org.opsli.common.annotation.validator.ValidatorLenMax;\nimport org.opsli.common.annotation.validator.ValidatorLenMin;\nimport org.opsli.common.enums.ValidatorType;\nimport org.opsli.plugins.excel.annotation.ExcelInfo;\nimport com.fasterxml.jackson.annotation.JsonFormat;\nimport org.springframework.format.annotation.DateTimeFormat;\n\n/**\n* #(data.codeTitle) Model\n*\n* @author #(data.authorName)\n* @date #(currTime)\n*/\n@Data\n@EqualsAndHashCode(callSuper = false)\npublic class #(data.model.tableHumpName)Model extends ApiWrapper {\n\n #for(column : data.model.columnList)\n ### 不等于 删除字段 和 不等于 租户字段放入上边\n #if(column.fieldHumpName != \"deleted\" && column.fieldHumpName != \"tenantId\")\n /** #(column.fieldComments) */\n @ApiModelProperty(value = \"#(column.fieldComments)\")\n @ExcelProperty(value = \"#(column.fieldComments)\", order = #(column.sort))\n #if(column.dictTypeCode != null && column.dictTypeCode != \"\")\n @ExcelInfo( dictType = \"#(column.dictTypeCode)\" )\n #else\n @ExcelInfo\n #end\n #if(column.validateTypeAndCommaList != null && column.validateTypeAndCommaList.size() > 0)\n @Validator({\n #for(typeAndComma : column.validateTypeAndCommaList)\n ValidatorType.#(typeAndComma)\n #end\n })\n #end\n #if(column.fieldLength != null && column.fieldLength > 0)\n #if(column.fieldPrecision != null && column.fieldPrecision > 0)\n @ValidatorLenMax(#(column.fieldLength+column.fieldPrecision))\n #else\n @ValidatorLenMax(#(column.fieldLength))\n #end\n #end\n ### 日期处理\n #if(column.javaType == \"Date\")\n #if(column.showType == \"4\")\n @JsonFormat(timezone = \"GMT+8\", pattern = \"yyyy-MM-dd\")\n @DateTimeFormat(pattern = \"yyyy-MM-dd\")\n #else\n @JsonFormat(timezone = \"GMT+8\", pattern = \"yyyy-MM-dd HH:mm:ss\")\n @DateTimeFormat(pattern = \"yyyy-MM-dd HH:mm:ss\")\n #end\n #end\n private #(column.javaType) #(column.fieldHumpName);\n\n #end\n #end\n\n\n}', '0', 0, 1313694379541635074, '2021-06-01 20:34:07', 1313694379541635074, '2021-06-01 20:34:07'); -INSERT INTO `gen_template_detail` VALUES (1399705818743422977, 1398253704724828162, '0', 'org/opsli/api/web/${moduleName}/${subModuleName}', 'RestApi.java', '#if(data.subModuleName != null && data.subModuleName != \"\")\npackage #(apiPath).web.#(data.moduleName+\".\"+data.subModuleName);\n#else\npackage #(apiPath).web.#(data.moduleName);\n#end\n\nimport #(apiPath).base.result.ResultVo;\nimport org.springframework.web.bind.annotation.GetMapping;\nimport org.springframework.web.bind.annotation.PostMapping;\nimport org.springframework.web.bind.annotation.RequestBody;\nimport org.springframework.web.bind.annotation.RequestParam;\nimport org.springframework.web.multipart.MultipartHttpServletRequest;\nimport javax.servlet.http.HttpServletRequest;\nimport javax.servlet.http.HttpServletResponse;\n\n#if(data.subModuleName != null && data.subModuleName != \"\")\nimport #(apiPath).wrapper.#(data.moduleName+\".\"+data.subModuleName).#(data.model.tableHumpName)Model;\n#else\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\n#end\n\n\n/**\n * #(data.codeTitle) Api\n *\n * 对外 API 直接 暴露 @GetMapping 或者 @PostMapping\n * 对内也推荐 单机版 不需要设置 Mapping 但是调用方法得从Controller写起\n *\n * 这样写法虽然比较绕,但是当单体项目想要改造微服务架构时 时非常容易的\n *\n * @author #(data.authorName)\n * @date #(currTime)\n */\npublic interface #(data.model.tableHumpName)RestApi {\n\n /** 标题 */\n String TITLE = \"#(data.codeTitle)\";\n /** 子标题 */\n String SUB_TITLE = \"#(data.codeTitleBrief)\";\n\n /**\n * #(data.codeTitle) 查一条\n * @param model 模型\n * @return ResultVo\n */\n @GetMapping(\"/get\")\n ResultVo<#(data.model.tableHumpName)Model> get(#(data.model.tableHumpName)Model model);\n\n /**\n * #(data.codeTitle) 查询分页\n * @param pageNo 当前页\n * @param pageSize 每页条数\n * @param request request\n * @return ResultVo\n */\n @GetMapping(\"/findPage\")\n ResultVo findPage(\n @RequestParam(name = \"pageNo\", defaultValue = \"1\") Integer pageNo,\n @RequestParam(name = \"pageSize\", defaultValue = \"10\") Integer pageSize,\n HttpServletRequest request\n );\n\n /**\n * #(data.codeTitle) 新增\n * @param model 模型\n * @return ResultVo\n */\n @PostMapping(\"/insert\")\n ResultVo insert(@RequestBody #(data.model.tableHumpName)Model model);\n\n /**\n * #(data.codeTitle) 修改\n * @param model 模型\n * @return ResultVo\n */\n @PostMapping(\"/update\")\n ResultVo update(@RequestBody #(data.model.tableHumpName)Model model);\n\n /**\n * #(data.codeTitle) 删除\n * @param id ID\n * @return ResultVo\n */\n @PostMapping(\"/del\")\n ResultVo del(String id);\n\n /**\n * #(data.codeTitle) 批量删除\n * @param ids ID 数组\n * @return ResultVo\n */\n @PostMapping(\"/delAll\")\n ResultVo delAll(String ids);\n\n /**\n * #(data.codeTitle) Excel 导出\n *\n * 导出时,Token认证和方法权限认证 全部都由自定义完成\n * 因为在 导出不成功时,需要推送错误信息,\n * 前端直接走下载流,当失败时无法获得失败信息,即使前后端换一种方式后端推送二进制文件前端再次解析也是最少2倍的耗时\n * ,且如果数据量过大,前端进行渲染时直接会把浏览器卡死\n * 而直接开启socket接口推送显然是太过浪费资源了,所以目前采用Java最原始的手段\n * response 推送 javascript代码 alert 提示报错信息\n *\n * @param request request\n * @param response response\n */\n @GetMapping(\"/exportExcel\")\n void exportExcel(HttpServletRequest request, HttpServletResponse response);\n\n /**\n * #(data.codeTitle) Excel 导入\n * @param request 文件流 request\n * @return ResultVo\n */\n @PostMapping(\"/importExcel\")\n ResultVo importExcel(MultipartHttpServletRequest request);\n\n /**\n * #(data.codeTitle) Excel 下载导入模版\n * @param response response\n */\n @GetMapping(\"/importExcel/template\")\n void importTemplate(HttpServletResponse response);\n\n}', '0', 0, 1313694379541635074, '2021-06-01 20:34:07', 1313694379541635074, '2021-06-01 20:34:07'); -INSERT INTO `gen_template_detail` VALUES (1399705818806337537, 1398253704724828162, '0', '${packageName}/${moduleName}/${subModuleName}/web', 'RestController.java', '#if(data.subModuleName != null && data.subModuleName != \"\")\npackage #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).web;\n#else\npackage #(data.packageName+\".\"+data.moduleName).web;\n#end\n\nimport cn.hutool.core.util.ReflectUtil;\nimport cn.hutool.core.convert.Convert;\nimport io.swagger.annotations.Api;\nimport io.swagger.annotations.ApiOperation;\nimport lombok.extern.slf4j.Slf4j;\nimport org.opsli.common.annotation.RequiresPermissionsCus;\nimport org.apache.shiro.authz.annotation.RequiresPermissions;\nimport #(apiPath).base.result.ResultVo;\nimport org.opsli.common.annotation.ApiRestController;\nimport org.opsli.common.annotation.EnableLog;\nimport org.opsli.core.base.controller.BaseRestController;\nimport org.opsli.core.persistence.Page;\nimport org.opsli.core.persistence.querybuilder.QueryBuilder;\nimport org.opsli.core.persistence.querybuilder.WebQueryBuilder;\nimport org.springframework.web.multipart.MultipartHttpServletRequest;\nimport javax.servlet.http.HttpServletRequest;\nimport javax.servlet.http.HttpServletResponse;\nimport java.lang.reflect.Method;\n\n#if(data.subModuleName != null && data.subModuleName != \"\")\nimport #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).entity.#(data.model.tableHumpName);\nimport #(apiPath).wrapper.#(data.moduleName+\".\"+data.subModuleName).#(data.model.tableHumpName)Model;\nimport #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).service.I#(data.model.tableHumpName)Service;\nimport #(apiPath).web.#(data.moduleName+\".\"+data.subModuleName).#(data.model.tableHumpName)RestApi;\n#else\nimport #(data.packageName+\".\"+data.moduleName).entity.#(data.model.tableHumpName);\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\nimport #(data.packageName+\".\"+data.moduleName).service.I#(data.model.tableHumpName)Service;\nimport #(apiPath).web.#(data.moduleName).#(data.model.tableHumpName)RestApi;\n#end\n\n/**\n * #(data.codeTitle) Controller\n *\n * @author #(data.authorName)\n * @date #(currTime)\n */\n@Api(tags = #(data.model.tableHumpName)RestApi.TITLE)\n@Slf4j\n#if(data.subModuleName != null && data.subModuleName != \"\")\n@ApiRestController(\"/#(data.moduleName)/#(data.subModuleName)\")\n#else\n@ApiRestController(\"/#(data.moduleName)\")\n#end\npublic class #(data.model.tableHumpName)RestController extends BaseRestController<#(data.model.tableHumpName), #(data.model.tableHumpName)Model, I#(data.model.tableHumpName)Service>\n implements #(data.model.tableHumpName)RestApi {\n\n\n /**\n * #(data.codeTitleBrief) 查一条\n * @param model 模型\n * @return ResultVo\n */\n @ApiOperation(value = \"获得单条#(data.codeTitleBrief)\", notes = \"获得单条#(data.codeTitleBrief) - ID\")\n #if(data.subModuleName != null && data.subModuleName != \"\")\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_select\")\n #else\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_select\")\n #end\n @Override\n public ResultVo<#(data.model.tableHumpName)Model> get(#(data.model.tableHumpName)Model model) {\n // 如果系统内部调用 则直接查数据库\n if(model != null && model.getIzApi() != null && model.getIzApi()){\n model = IService.get(model);\n }\n return ResultVo.success(model);\n }\n\n /**\n * #(data.codeTitleBrief) 查询分页\n * @param pageNo 当前页\n * @param pageSize 每页条数\n * @param request request\n * @return ResultVo\n */\n @ApiOperation(value = \"获得分页数据\", notes = \"获得分页数据 - 查询构造器\")\n #if(data.subModuleName != null && data.subModuleName != \"\")\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_select\")\n #else\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_select\")\n #end\n @Override\n public ResultVo findPage(Integer pageNo, Integer pageSize, HttpServletRequest request) {\n\n QueryBuilder<#(data.model.tableHumpName)> queryBuilder = new WebQueryBuilder<>(entityClazz, request.getParameterMap());\n Page<#(data.model.tableHumpName), #(data.model.tableHumpName)Model> page = new Page<>(pageNo, pageSize);\n page.setQueryWrapper(queryBuilder.build());\n page = IService.findPage(page);\n\n return ResultVo.success(page.getPageData());\n }\n\n /**\n * #(data.codeTitleBrief) 新增\n * @param model 模型\n * @return ResultVo\n */\n @ApiOperation(value = \"新增#(data.codeTitleBrief)数据\", notes = \"新增#(data.codeTitleBrief)数据\")\n #if(data.subModuleName != null && data.subModuleName != \"\")\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_insert\")\n #else\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_insert\")\n #end\n @EnableLog\n @Override\n public ResultVo insert(#(data.model.tableHumpName)Model model) {\n // 调用新增方法\n IService.insert(model);\n return ResultVo.success(\"新增#(data.codeTitleBrief)成功\");\n }\n\n /**\n * #(data.codeTitleBrief) 修改\n * @param model 模型\n * @return ResultVo\n */\n @ApiOperation(value = \"修改#(data.codeTitleBrief)数据\", notes = \"修改#(data.codeTitleBrief)数据\")\n #if(data.subModuleName != null && data.subModuleName != \"\")\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_update\")\n #else\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_update\")\n #end\n @EnableLog\n @Override\n public ResultVo update(#(data.model.tableHumpName)Model model) {\n // 调用修改方法\n IService.update(model);\n return ResultVo.success(\"修改#(data.codeTitleBrief)成功\");\n }\n\n\n /**\n * #(data.codeTitleBrief) 删除\n * @param id ID\n * @return ResultVo\n */\n @ApiOperation(value = \"删除#(data.codeTitleBrief)数据\", notes = \"删除#(data.codeTitleBrief)数据\")\n #if(data.subModuleName != null && data.subModuleName != \"\")\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_update\")\n #else\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_update\")\n #end\n @EnableLog\n @Override\n public ResultVo del(String id){\n IService.delete(id);\n return ResultVo.success(\"删除#(data.codeTitleBrief)成功\");\n }\n\n /**\n * #(data.codeTitleBrief) 批量删除\n * @param ids ID 数组\n * @return ResultVo\n */\n @ApiOperation(value = \"批量删除#(data.codeTitleBrief)数据\", notes = \"批量删除#(data.codeTitleBrief)数据\")\n #if(data.subModuleName != null && data.subModuleName != \"\")\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_update\")\n #else\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_update\")\n #end\n @EnableLog\n @Override\n public ResultVo delAll(String ids){\n String[] idArray = Convert.toStrArray(ids);\n IService.deleteAll(idArray);\n return ResultVo.success(\"批量删除#(data.codeTitleBrief)成功\");\n }\n\n\n /**\n * #(data.codeTitleBrief) Excel 导出\n * 注:这里 RequiresPermissionsCus 引入的是 自定义鉴权注解\n *\n * 导出时,Token认证和方法权限认证 全部都由自定义完成\n * 因为在 导出不成功时,需要推送错误信息,\n * 前端直接走下载流,当失败时无法获得失败信息,即使前后端换一种方式后端推送二进制文件前端再次解析也是最少2倍的耗时\n * ,且如果数据量过大,前端进行渲染时直接会把浏览器卡死\n * 而直接开启socket接口推送显然是太过浪费资源了,所以目前采用Java最原始的手段\n * response 推送 javascript代码 alert 提示报错信息\n *\n * @param request request\n * @param response response\n */\n @ApiOperation(value = \"导出Excel\", notes = \"导出Excel\")\n #if(data.subModuleName != null && data.subModuleName != \"\")\n @RequiresPermissionsCus(\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_export\")\n #else\n @RequiresPermissionsCus(\"#(data.moduleName.toLowerCase())_export\")\n #end\n @EnableLog\n @Override\n public void exportExcel(HttpServletRequest request, HttpServletResponse response) {\n // 当前方法\n Method method = ReflectUtil.getMethodByName(this.getClass(), \"exportExcel\");\n QueryBuilder<#(data.model.tableHumpName)> queryBuilder = new WebQueryBuilder<>(entityClazz, request.getParameterMap());\n super.excelExport(#(data.model.tableHumpName)RestApi.SUB_TITLE, queryBuilder.build(), response, method);\n }\n\n /**\n * #(data.codeTitleBrief) Excel 导入\n * 注:这里 RequiresPermissions 引入的是 Shiro原生鉴权注解\n * @param request 文件流 request\n * @return ResultVo\n */\n @ApiOperation(value = \"导入Excel\", notes = \"导入Excel\")\n #if(data.subModuleName != null && data.subModuleName != \"\")\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_import\")\n #else\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_import\")\n #end\n @EnableLog\n @Override\n public ResultVo importExcel(MultipartHttpServletRequest request) {\n return super.importExcel(request);\n }\n\n /**\n * #(data.codeTitleBrief) Excel 下载导入模版\n * 注:这里 RequiresPermissionsCus 引入的是 自定义鉴权注解\n * @param response response\n */\n @ApiOperation(value = \"导出Excel模版\", notes = \"导出Excel模版\")\n #if(data.subModuleName != null && data.subModuleName != \"\")\n @RequiresPermissionsCus(\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_import\")\n #else\n @RequiresPermissionsCus(\"#(data.moduleName.toLowerCase())_import\")\n #end\n @Override\n public void importTemplate(HttpServletResponse response) {\n // 当前方法\n Method method = ReflectUtil.getMethodByName(this.getClass(), \"importTemplate\");\n super.importTemplate(#(data.model.tableHumpName)RestApi.SUB_TITLE, response, method);\n }\n\n}', '0', 0, 1313694379541635074, '2021-06-01 20:34:07', 1313694379541635074, '2021-06-01 20:34:07'); -INSERT INTO `gen_template_detail` VALUES (1399705818873446402, 1398253704724828162, '0', '${packageName}/${moduleName}/${subModuleName}/service', 'Service.java', '#if(data.subModuleName != null && data.subModuleName != \"\")\npackage #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).service;\n#else\npackage #(data.packageName+\".\"+data.moduleName).service;\n#end\n\nimport org.opsli.core.base.service.interfaces.CrudServiceInterface;\n\n\n#if(data.subModuleName != null && data.subModuleName != \"\")\nimport #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).entity.#(data.model.tableHumpName);\nimport #(apiPath).wrapper.#(data.moduleName+\".\"+data.subModuleName).#(data.model.tableHumpName)Model;\n#else\nimport #(data.packageName+\".\"+data.moduleName).entity.#(data.model.tableHumpName);\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\n#end\n\n/**\n * #(data.codeTitle) Service\n *\n * @author #(data.authorName)\n * @date #(currTime)\n */\npublic interface I#(data.model.tableHumpName)Service extends CrudServiceInterface<#(data.model.tableHumpName), #(data.model.tableHumpName)Model> {\n\n}', '0', 0, 1313694379541635074, '2021-06-01 20:34:07', 1313694379541635074, '2021-06-01 20:34:07'); -INSERT INTO `gen_template_detail` VALUES (1399705818940555265, 1398253704724828162, '0', '${packageName}/${moduleName}/${subModuleName}/service/impl', 'ServiceImpl.java', '#if(data.subModuleName != null && data.subModuleName != \"\")\npackage #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).service.impl;\n#else\npackage #(data.packageName+\".\"+data.moduleName).service.impl;\n#end\n\n\nimport org.springframework.beans.factory.annotation.Autowired;\nimport org.springframework.stereotype.Service;\nimport org.springframework.transaction.annotation.Transactional;\nimport org.opsli.core.base.service.impl.CrudServiceImpl;\n\n#if(data.subModuleName != null && data.subModuleName != \"\")\nimport #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).entity.#(data.model.tableHumpName);\nimport #(apiPath).wrapper.#(data.moduleName+\".\"+data.subModuleName).#(data.model.tableHumpName)Model;\nimport #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).service.I#(data.model.tableHumpName)Service;\nimport #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).mapper.#(data.model.tableHumpName)Mapper;\n#else\nimport #(data.packageName+\".\"+data.moduleName).entity.#(data.model.tableHumpName);\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\nimport #(data.packageName+\".\"+data.moduleName).service.I#(data.model.tableHumpName)Service;\nimport #(data.packageName+\".\"+data.moduleName).mapper.#(data.model.tableHumpName)Mapper;\n#end\n\n\n/**\n * #(data.codeTitle) Service Impl\n *\n * @author #(data.authorName)\n * @date #(currTime)\n */\n@Service\npublic class #(data.model.tableHumpName)ServiceImpl extends CrudServiceImpl<#(data.model.tableHumpName)Mapper, #(data.model.tableHumpName), #(data.model.tableHumpName)Model>\n implements I#(data.model.tableHumpName)Service {\n\n @Autowired(required = false)\n private #(data.model.tableHumpName)Mapper mapper;\n\n}', '0', 0, 1313694379541635074, '2021-06-01 20:34:07', 1313694379541635074, '2021-06-01 20:34:07'); -INSERT INTO `gen_template_detail` VALUES (1399705819007664129, 1398253704724828162, '1', 'src/api/${moduleName}/${subModuleName}', 'Api.js', 'import request from \"@/utils/request\";\nimport {downloadFileByData} from \"@/utils/download\";\n\nexport function getList(data) {\n return request({\n #if(data.subModuleName != null && data.subModuleName != \"\")\n url: \"/api/v1/#(data.moduleName)/#(data.subModuleName)/findPage\",\n #else\n url: \"/api/v1/#(data.moduleName)/findPage\",\n #end\n method: \"get\",\n params: data,\n });\n}\n\n\nexport function doInsert(data) {\n return request({\n #if(data.subModuleName != null && data.subModuleName != \"\")\n url: \"/api/v1/#(data.moduleName)/#(data.subModuleName)/insert\",\n #else\n url: \"/api/v1/#(data.moduleName)/insert\",\n #end\n method: \"post\",\n data,\n });\n}\n\nexport function doUpdate(data) {\n return request({\n #if(data.subModuleName != null && data.subModuleName != \"\")\n url: \"/api/v1/#(data.moduleName)/#(data.subModuleName)/update\",\n #else\n url: \"/api/v1/#(data.moduleName)/update\",\n #end\n method: \"post\",\n data,\n });\n}\n\nexport function doDelete(data) {\n return request({\n #if(data.subModuleName != null && data.subModuleName != \"\")\n url: \"/api/v1/#(data.moduleName)/#(data.subModuleName)/del\",\n #else\n url: \"/api/v1/#(data.moduleName)/del\",\n #end\n method: \"post\",\n params: data,\n });\n}\n\nexport function doDeleteAll(data) {\n return request({\n #if(data.subModuleName != null && data.subModuleName != \"\")\n url: \"/api/v1/#(data.moduleName)/#(data.subModuleName)/delAll\",\n #else\n url: \"/api/v1/#(data.moduleName)/delAll\",\n #end\n method: \"post\",\n params: data,\n });\n}\n\n\n/**\n* 导出Excel 目前只支持一层参数传递\n* @param data\n* @returns file\n*/\nexport function doExportExcel(data) {\n #if(data.subModuleName != null && data.subModuleName != \"\")\n let requestURL = \"/api/v1/#(data.moduleName)/#(data.subModuleName)/exportExcel\";\n #else\n let requestURL = \"/api/v1/#(data.moduleName)/exportExcel\";\n #end\n // 下载文件\n downloadFileByData(requestURL, data);\n}\n\n\n/**\n* 下载模版\n* @returns file\n*/\nexport function doDownloadTemplate() {\n let data = {};\n #if(data.subModuleName != null && data.subModuleName != \"\")\n let requestURL = \"/api/v1/#(data.moduleName)/#(data.subModuleName)/importExcel/template\";\n #else\n let requestURL = \"/api/v1/#(data.moduleName)/importExcel/template\";\n #end\n // 下载文件\n downloadFileByData(requestURL, data);\n}\n\n/**\n* 导入Excel\n* @returns file\n*/\nexport function doImportExcel(data) {\n return request({\n #if(data.subModuleName != null && data.subModuleName != \"\")\n url: \"/api/v1/#(data.moduleName)/#(data.subModuleName)/importExcel\",\n #else\n url: \"/api/v1/#(data.moduleName)/importExcel\",\n #end\n method: \"post\",\n // 最长超时时间 3 分钟\n timeout: 180000,\n headers: {\n \"Content-Type\": \"multipart/form-data\"\n },\n data,\n });\n}\n\n\n', '0', 0, 1313694379541635074, '2021-06-01 20:34:07', 1313694379541635074, '2021-06-01 20:34:07'); -INSERT INTO `gen_template_detail` VALUES (1399705819133493250, 1398253704724828162, '1', 'src/views/modules/${moduleName}/${subModuleName}/components', 'Edit.vue', '\n\n\n', '0', 0, 1313694379541635074, '2021-06-01 20:34:07', 1313694379541635074, '2021-06-01 20:34:07'); -INSERT INTO `gen_template_detail` VALUES (1399705819196407810, 1398253704724828162, '1', 'src/views/modules/${moduleName}/${subModuleName}/components', 'Import.vue', '\n\n\n', '0', 0, 1313694379541635074, '2021-06-01 20:34:07', 1313694379541635074, '2021-06-01 20:34:07'); -INSERT INTO `gen_template_detail` VALUES (1399705819322236929, 1398253704724828162, '1', 'src/views/modules/${moduleName}/${subModuleName}', 'index.vue', '\n\n\n', '0', 0, 1313694379541635074, '2021-06-01 20:34:07', 1313694379541635074, '2021-06-01 20:34:07'); +INSERT INTO `gen_template_detail` VALUES (1400314102462513153, 1398253704724828162, '0', '${packageName}/${moduleName}/${subModuleName}/entity', '${model.tableHumpName}Entity.java', '#if(data.subModuleName != null && data.subModuleName != \"\")\npackage #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).entity;\n#else\npackage #(data.packageName+\".\"+data.moduleName).entity;\n#end\n\n#for(pkg : data.model.entityPkgList)\nimport #(pkg);\n#end\nimport com.baomidou.mybatisplus.annotation.FieldStrategy;\nimport com.baomidou.mybatisplus.annotation.TableField;\nimport com.baomidou.mybatisplus.annotation.TableLogic;\nimport lombok.Data;\nimport lombok.EqualsAndHashCode;\nimport org.opsli.core.base.entity.BaseEntity;\n\n/**\n * #(data.codeTitle) Entity\n *\n * @author #(data.authorName)\n * @date #(currTime)\n */\n@Data\n@EqualsAndHashCode(callSuper = false)\npublic class #(data.model.tableHumpName) extends BaseEntity {\n\n\n #for(column : data.model.columnList)\n ### 不等于 删除字段 和 不等于 租户字段放入上边\n #if(column.fieldHumpName != \"deleted\" && column.fieldHumpName != \"tenantId\")\n /** #(column.fieldComments) */\n #if(!column.izNotNull)\n @TableField(updateStrategy = FieldStrategy.IGNORED)\n #end\n private #(column.javaType) #(column.fieldHumpName);\n\n #end\n #end\n\n // ========================================\n\n ### 专门处理 删除字段 和 租户字段\n #for(column : data.model.columnList)\n #if(column.fieldHumpName == \"deleted\")\n /** 逻辑删除字段 */\n @TableLogic\n private Integer deleted;\n #else if(column.fieldHumpName == \"tenantId\")\n /** 多租户字段 */\n private String tenantId;\n #end\n\n #end\n\n}', '1', 0, 1313694379541635074, '2021-06-03 12:51:13', 1313694379541635074, '2021-06-03 12:51:13'); +INSERT INTO `gen_template_detail` VALUES (1400314102672228354, 1398253704724828162, '0', '${packageName}/${moduleName}/${subModuleName}/mapper', '${model.tableHumpName}Mapper.java', '#if(data.subModuleName != null && data.subModuleName != \"\")\npackage #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).mapper;\n#else\npackage #(data.packageName+\".\"+data.moduleName).mapper;\n#end\n\nimport com.baomidou.mybatisplus.core.mapper.BaseMapper;\nimport org.apache.ibatis.annotations.Mapper;\nimport org.apache.ibatis.annotations.Param;\n#if(data.subModuleName != null && data.subModuleName != \"\")\nimport #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).entity.#(data.model.tableHumpName);\n#else\nimport #(data.packageName+\".\"+data.moduleName).entity.#(data.model.tableHumpName);\n#end\n\n/**\n * #(data.codeTitle) Mapper\n *\n * @author #(data.authorName)\n * @date #(currTime)\n */\n@Mapper\npublic interface #(data.model.tableHumpName)Mapper extends BaseMapper<#(data.model.tableHumpName)> {\n\n}', '0', 0, 1313694379541635074, '2021-06-03 12:51:13', 1313694379541635074, '2021-06-03 12:51:13'); +INSERT INTO `gen_template_detail` VALUES (1400314102735142914, 1398253704724828162, '0', '${packageName}/${moduleName}/${subModuleName}/mapper/xml', '${model.tableHumpName}Mapper.xml', '\n\n#if(data.subModuleName != null && data.subModuleName != \"\")\n\n#else\n\n#end\n\n\n', '0', 0, 1313694379541635074, '2021-06-03 12:51:13', 1313694379541635074, '2021-06-03 12:51:13'); +INSERT INTO `gen_template_detail` VALUES (1400314102860972033, 1398253704724828162, '0', 'org/opsli/api/wrapper/${moduleName}/${subModuleName}', '${model.tableHumpName}Model.java', '#if(data.subModuleName != null && data.subModuleName != \"\")\npackage #(apiPath).wrapper.#(data.moduleName+\".\"+data.subModuleName);\n#else\npackage #(apiPath).wrapper.#(data.moduleName);\n#end\n\n#for(pkg : data.model.entityPkgList)\nimport #(pkg);\n#end\nimport com.alibaba.excel.annotation.ExcelProperty;\nimport io.swagger.annotations.ApiModelProperty;\nimport lombok.Data;\nimport lombok.EqualsAndHashCode;\nimport #(apiPath).base.warpper.ApiWrapper;\nimport org.opsli.common.annotation.validator.Validator;\nimport org.opsli.common.annotation.validator.ValidatorLenMax;\nimport org.opsli.common.annotation.validator.ValidatorLenMin;\nimport org.opsli.common.enums.ValidatorType;\nimport org.opsli.plugins.excel.annotation.ExcelInfo;\nimport com.fasterxml.jackson.annotation.JsonFormat;\nimport org.springframework.format.annotation.DateTimeFormat;\n\n/**\n* #(data.codeTitle) Model\n*\n* @author #(data.authorName)\n* @date #(currTime)\n*/\n@Data\n@EqualsAndHashCode(callSuper = false)\npublic class #(data.model.tableHumpName)Model extends ApiWrapper {\n\n #for(column : data.model.columnList)\n ### 不等于 删除字段 和 不等于 租户字段放入上边\n #if(column.fieldHumpName != \"deleted\" && column.fieldHumpName != \"tenantId\")\n /** #(column.fieldComments) */\n @ApiModelProperty(value = \"#(column.fieldComments)\")\n @ExcelProperty(value = \"#(column.fieldComments)\", order = #(column.sort))\n #if(column.dictTypeCode != null && column.dictTypeCode != \"\")\n @ExcelInfo( dictType = \"#(column.dictTypeCode)\" )\n #else\n @ExcelInfo\n #end\n #if(column.validateTypeAndCommaList != null && column.validateTypeAndCommaList.size() > 0)\n @Validator({\n #for(typeAndComma : column.validateTypeAndCommaList)\n ValidatorType.#(typeAndComma)\n #end\n })\n #end\n #if(column.fieldLength != null && column.fieldLength > 0)\n #if(column.fieldPrecision != null && column.fieldPrecision > 0)\n @ValidatorLenMax(#(column.fieldLength+column.fieldPrecision))\n #else\n @ValidatorLenMax(#(column.fieldLength))\n #end\n #end\n ### 日期处理\n #if(column.javaType == \"Date\")\n #if(column.showType == \"4\")\n @JsonFormat(timezone = \"GMT+8\", pattern = \"yyyy-MM-dd\")\n @DateTimeFormat(pattern = \"yyyy-MM-dd\")\n #else\n @JsonFormat(timezone = \"GMT+8\", pattern = \"yyyy-MM-dd HH:mm:ss\")\n @DateTimeFormat(pattern = \"yyyy-MM-dd HH:mm:ss\")\n #end\n #end\n private #(column.javaType) #(column.fieldHumpName);\n\n #end\n #end\n\n\n}', '0', 0, 1313694379541635074, '2021-06-03 12:51:13', 1313694379541635074, '2021-06-03 12:51:13'); +INSERT INTO `gen_template_detail` VALUES (1400314102995189761, 1398253704724828162, '0', 'org/opsli/api/web/${moduleName}/${subModuleName}', '${model.tableHumpName}RestApi.java', '#if(data.subModuleName != null && data.subModuleName != \"\")\npackage #(apiPath).web.#(data.moduleName+\".\"+data.subModuleName);\n#else\npackage #(apiPath).web.#(data.moduleName);\n#end\n\nimport #(apiPath).base.result.ResultVo;\nimport org.springframework.web.bind.annotation.GetMapping;\nimport org.springframework.web.bind.annotation.PostMapping;\nimport org.springframework.web.bind.annotation.RequestBody;\nimport org.springframework.web.bind.annotation.RequestParam;\nimport org.springframework.web.multipart.MultipartHttpServletRequest;\nimport javax.servlet.http.HttpServletRequest;\nimport javax.servlet.http.HttpServletResponse;\n\n#if(data.subModuleName != null && data.subModuleName != \"\")\nimport #(apiPath).wrapper.#(data.moduleName+\".\"+data.subModuleName).#(data.model.tableHumpName)Model;\n#else\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\n#end\n\n\n/**\n * #(data.codeTitle) Api\n *\n * 对外 API 直接 暴露 @GetMapping 或者 @PostMapping\n * 对内也推荐 单机版 不需要设置 Mapping 但是调用方法得从Controller写起\n *\n * 这样写法虽然比较绕,但是当单体项目想要改造微服务架构时 时非常容易的\n *\n * @author #(data.authorName)\n * @date #(currTime)\n */\npublic interface #(data.model.tableHumpName)RestApi {\n\n /** 标题 */\n String TITLE = \"#(data.codeTitle)\";\n /** 子标题 */\n String SUB_TITLE = \"#(data.codeTitleBrief)\";\n\n /**\n * #(data.codeTitle) 查一条\n * @param model 模型\n * @return ResultVo\n */\n @GetMapping(\"/get\")\n ResultVo<#(data.model.tableHumpName)Model> get(#(data.model.tableHumpName)Model model);\n\n /**\n * #(data.codeTitle) 查询分页\n * @param pageNo 当前页\n * @param pageSize 每页条数\n * @param request request\n * @return ResultVo\n */\n @GetMapping(\"/findPage\")\n ResultVo findPage(\n @RequestParam(name = \"pageNo\", defaultValue = \"1\") Integer pageNo,\n @RequestParam(name = \"pageSize\", defaultValue = \"10\") Integer pageSize,\n HttpServletRequest request\n );\n\n /**\n * #(data.codeTitle) 新增\n * @param model 模型\n * @return ResultVo\n */\n @PostMapping(\"/insert\")\n ResultVo insert(@RequestBody #(data.model.tableHumpName)Model model);\n\n /**\n * #(data.codeTitle) 修改\n * @param model 模型\n * @return ResultVo\n */\n @PostMapping(\"/update\")\n ResultVo update(@RequestBody #(data.model.tableHumpName)Model model);\n\n /**\n * #(data.codeTitle) 删除\n * @param id ID\n * @return ResultVo\n */\n @PostMapping(\"/del\")\n ResultVo del(String id);\n\n /**\n * #(data.codeTitle) 批量删除\n * @param ids ID 数组\n * @return ResultVo\n */\n @PostMapping(\"/delAll\")\n ResultVo delAll(String ids);\n\n /**\n * #(data.codeTitle) Excel 导出\n *\n * 导出时,Token认证和方法权限认证 全部都由自定义完成\n * 因为在 导出不成功时,需要推送错误信息,\n * 前端直接走下载流,当失败时无法获得失败信息,即使前后端换一种方式后端推送二进制文件前端再次解析也是最少2倍的耗时\n * ,且如果数据量过大,前端进行渲染时直接会把浏览器卡死\n * 而直接开启socket接口推送显然是太过浪费资源了,所以目前采用Java最原始的手段\n * response 推送 javascript代码 alert 提示报错信息\n *\n * @param request request\n * @param response response\n */\n @GetMapping(\"/exportExcel\")\n void exportExcel(HttpServletRequest request, HttpServletResponse response);\n\n /**\n * #(data.codeTitle) Excel 导入\n * @param request 文件流 request\n * @return ResultVo\n */\n @PostMapping(\"/importExcel\")\n ResultVo importExcel(MultipartHttpServletRequest request);\n\n /**\n * #(data.codeTitle) Excel 下载导入模版\n * @param response response\n */\n @GetMapping(\"/importExcel/template\")\n void importTemplate(HttpServletResponse response);\n\n}', '0', 0, 1313694379541635074, '2021-06-03 12:51:13', 1313694379541635074, '2021-06-03 12:51:13'); +INSERT INTO `gen_template_detail` VALUES (1400314103062298626, 1398253704724828162, '0', '${packageName}/${moduleName}/${subModuleName}/web', '${model.tableHumpName}RestController.java', '#if(data.subModuleName != null && data.subModuleName != \"\")\npackage #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).web;\n#else\npackage #(data.packageName+\".\"+data.moduleName).web;\n#end\n\nimport cn.hutool.core.util.ReflectUtil;\nimport cn.hutool.core.convert.Convert;\nimport io.swagger.annotations.Api;\nimport io.swagger.annotations.ApiOperation;\nimport lombok.extern.slf4j.Slf4j;\nimport org.opsli.common.annotation.RequiresPermissionsCus;\nimport org.apache.shiro.authz.annotation.RequiresPermissions;\nimport #(apiPath).base.result.ResultVo;\nimport org.opsli.common.annotation.ApiRestController;\nimport org.opsli.common.annotation.EnableLog;\nimport org.opsli.core.base.controller.BaseRestController;\nimport org.opsli.core.persistence.Page;\nimport org.opsli.core.persistence.querybuilder.QueryBuilder;\nimport org.opsli.core.persistence.querybuilder.WebQueryBuilder;\nimport org.springframework.web.multipart.MultipartHttpServletRequest;\nimport javax.servlet.http.HttpServletRequest;\nimport javax.servlet.http.HttpServletResponse;\nimport java.lang.reflect.Method;\n\n#if(data.subModuleName != null && data.subModuleName != \"\")\nimport #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).entity.#(data.model.tableHumpName);\nimport #(apiPath).wrapper.#(data.moduleName+\".\"+data.subModuleName).#(data.model.tableHumpName)Model;\nimport #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).service.I#(data.model.tableHumpName)Service;\nimport #(apiPath).web.#(data.moduleName+\".\"+data.subModuleName).#(data.model.tableHumpName)RestApi;\n#else\nimport #(data.packageName+\".\"+data.moduleName).entity.#(data.model.tableHumpName);\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\nimport #(data.packageName+\".\"+data.moduleName).service.I#(data.model.tableHumpName)Service;\nimport #(apiPath).web.#(data.moduleName).#(data.model.tableHumpName)RestApi;\n#end\n\n/**\n * #(data.codeTitle) Controller\n *\n * @author #(data.authorName)\n * @date #(currTime)\n */\n@Api(tags = #(data.model.tableHumpName)RestApi.TITLE)\n@Slf4j\n#if(data.subModuleName != null && data.subModuleName != \"\")\n@ApiRestController(\"/#(data.moduleName)/#(data.subModuleName)\")\n#else\n@ApiRestController(\"/#(data.moduleName)\")\n#end\npublic class #(data.model.tableHumpName)RestController extends BaseRestController<#(data.model.tableHumpName), #(data.model.tableHumpName)Model, I#(data.model.tableHumpName)Service>\n implements #(data.model.tableHumpName)RestApi {\n\n\n /**\n * #(data.codeTitleBrief) 查一条\n * @param model 模型\n * @return ResultVo\n */\n @ApiOperation(value = \"获得单条#(data.codeTitleBrief)\", notes = \"获得单条#(data.codeTitleBrief) - ID\")\n #if(data.subModuleName != null && data.subModuleName != \"\")\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_select\")\n #else\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_select\")\n #end\n @Override\n public ResultVo<#(data.model.tableHumpName)Model> get(#(data.model.tableHumpName)Model model) {\n // 如果系统内部调用 则直接查数据库\n if(model != null && model.getIzApi() != null && model.getIzApi()){\n model = IService.get(model);\n }\n return ResultVo.success(model);\n }\n\n /**\n * #(data.codeTitleBrief) 查询分页\n * @param pageNo 当前页\n * @param pageSize 每页条数\n * @param request request\n * @return ResultVo\n */\n @ApiOperation(value = \"获得分页数据\", notes = \"获得分页数据 - 查询构造器\")\n #if(data.subModuleName != null && data.subModuleName != \"\")\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_select\")\n #else\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_select\")\n #end\n @Override\n public ResultVo findPage(Integer pageNo, Integer pageSize, HttpServletRequest request) {\n\n QueryBuilder<#(data.model.tableHumpName)> queryBuilder = new WebQueryBuilder<>(entityClazz, request.getParameterMap());\n Page<#(data.model.tableHumpName), #(data.model.tableHumpName)Model> page = new Page<>(pageNo, pageSize);\n page.setQueryWrapper(queryBuilder.build());\n page = IService.findPage(page);\n\n return ResultVo.success(page.getPageData());\n }\n\n /**\n * #(data.codeTitleBrief) 新增\n * @param model 模型\n * @return ResultVo\n */\n @ApiOperation(value = \"新增#(data.codeTitleBrief)数据\", notes = \"新增#(data.codeTitleBrief)数据\")\n #if(data.subModuleName != null && data.subModuleName != \"\")\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_insert\")\n #else\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_insert\")\n #end\n @EnableLog\n @Override\n public ResultVo insert(#(data.model.tableHumpName)Model model) {\n // 调用新增方法\n IService.insert(model);\n return ResultVo.success(\"新增#(data.codeTitleBrief)成功\");\n }\n\n /**\n * #(data.codeTitleBrief) 修改\n * @param model 模型\n * @return ResultVo\n */\n @ApiOperation(value = \"修改#(data.codeTitleBrief)数据\", notes = \"修改#(data.codeTitleBrief)数据\")\n #if(data.subModuleName != null && data.subModuleName != \"\")\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_update\")\n #else\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_update\")\n #end\n @EnableLog\n @Override\n public ResultVo update(#(data.model.tableHumpName)Model model) {\n // 调用修改方法\n IService.update(model);\n return ResultVo.success(\"修改#(data.codeTitleBrief)成功\");\n }\n\n\n /**\n * #(data.codeTitleBrief) 删除\n * @param id ID\n * @return ResultVo\n */\n @ApiOperation(value = \"删除#(data.codeTitleBrief)数据\", notes = \"删除#(data.codeTitleBrief)数据\")\n #if(data.subModuleName != null && data.subModuleName != \"\")\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_update\")\n #else\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_update\")\n #end\n @EnableLog\n @Override\n public ResultVo del(String id){\n IService.delete(id);\n return ResultVo.success(\"删除#(data.codeTitleBrief)成功\");\n }\n\n /**\n * #(data.codeTitleBrief) 批量删除\n * @param ids ID 数组\n * @return ResultVo\n */\n @ApiOperation(value = \"批量删除#(data.codeTitleBrief)数据\", notes = \"批量删除#(data.codeTitleBrief)数据\")\n #if(data.subModuleName != null && data.subModuleName != \"\")\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_update\")\n #else\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_update\")\n #end\n @EnableLog\n @Override\n public ResultVo delAll(String ids){\n String[] idArray = Convert.toStrArray(ids);\n IService.deleteAll(idArray);\n return ResultVo.success(\"批量删除#(data.codeTitleBrief)成功\");\n }\n\n\n /**\n * #(data.codeTitleBrief) Excel 导出\n * 注:这里 RequiresPermissionsCus 引入的是 自定义鉴权注解\n *\n * 导出时,Token认证和方法权限认证 全部都由自定义完成\n * 因为在 导出不成功时,需要推送错误信息,\n * 前端直接走下载流,当失败时无法获得失败信息,即使前后端换一种方式后端推送二进制文件前端再次解析也是最少2倍的耗时\n * ,且如果数据量过大,前端进行渲染时直接会把浏览器卡死\n * 而直接开启socket接口推送显然是太过浪费资源了,所以目前采用Java最原始的手段\n * response 推送 javascript代码 alert 提示报错信息\n *\n * @param request request\n * @param response response\n */\n @ApiOperation(value = \"导出Excel\", notes = \"导出Excel\")\n #if(data.subModuleName != null && data.subModuleName != \"\")\n @RequiresPermissionsCus(\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_export\")\n #else\n @RequiresPermissionsCus(\"#(data.moduleName.toLowerCase())_export\")\n #end\n @EnableLog\n @Override\n public void exportExcel(HttpServletRequest request, HttpServletResponse response) {\n // 当前方法\n Method method = ReflectUtil.getMethodByName(this.getClass(), \"exportExcel\");\n QueryBuilder<#(data.model.tableHumpName)> queryBuilder = new WebQueryBuilder<>(entityClazz, request.getParameterMap());\n super.excelExport(#(data.model.tableHumpName)RestApi.SUB_TITLE, queryBuilder.build(), response, method);\n }\n\n /**\n * #(data.codeTitleBrief) Excel 导入\n * 注:这里 RequiresPermissions 引入的是 Shiro原生鉴权注解\n * @param request 文件流 request\n * @return ResultVo\n */\n @ApiOperation(value = \"导入Excel\", notes = \"导入Excel\")\n #if(data.subModuleName != null && data.subModuleName != \"\")\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_import\")\n #else\n @RequiresPermissions(\"#(data.moduleName.toLowerCase())_import\")\n #end\n @EnableLog\n @Override\n public ResultVo importExcel(MultipartHttpServletRequest request) {\n return super.importExcel(request);\n }\n\n /**\n * #(data.codeTitleBrief) Excel 下载导入模版\n * 注:这里 RequiresPermissionsCus 引入的是 自定义鉴权注解\n * @param response response\n */\n @ApiOperation(value = \"导出Excel模版\", notes = \"导出Excel模版\")\n #if(data.subModuleName != null && data.subModuleName != \"\")\n @RequiresPermissionsCus(\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_import\")\n #else\n @RequiresPermissionsCus(\"#(data.moduleName.toLowerCase())_import\")\n #end\n @Override\n public void importTemplate(HttpServletResponse response) {\n // 当前方法\n Method method = ReflectUtil.getMethodByName(this.getClass(), \"importTemplate\");\n super.importTemplate(#(data.model.tableHumpName)RestApi.SUB_TITLE, response, method);\n }\n\n}', '0', 0, 1313694379541635074, '2021-06-03 12:51:13', 1313694379541635074, '2021-06-03 12:51:13'); +INSERT INTO `gen_template_detail` VALUES (1400314103196516353, 1398253704724828162, '0', '${packageName}/${moduleName}/${subModuleName}/service/impl', '${model.tableHumpName}ServiceImpl.java', '#if(data.subModuleName != null && data.subModuleName != \"\")\npackage #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).service.impl;\n#else\npackage #(data.packageName+\".\"+data.moduleName).service.impl;\n#end\n\n\nimport org.springframework.beans.factory.annotation.Autowired;\nimport org.springframework.stereotype.Service;\nimport org.springframework.transaction.annotation.Transactional;\nimport org.opsli.core.base.service.impl.CrudServiceImpl;\n\n#if(data.subModuleName != null && data.subModuleName != \"\")\nimport #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).entity.#(data.model.tableHumpName);\nimport #(apiPath).wrapper.#(data.moduleName+\".\"+data.subModuleName).#(data.model.tableHumpName)Model;\nimport #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).service.I#(data.model.tableHumpName)Service;\nimport #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).mapper.#(data.model.tableHumpName)Mapper;\n#else\nimport #(data.packageName+\".\"+data.moduleName).entity.#(data.model.tableHumpName);\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\nimport #(data.packageName+\".\"+data.moduleName).service.I#(data.model.tableHumpName)Service;\nimport #(data.packageName+\".\"+data.moduleName).mapper.#(data.model.tableHumpName)Mapper;\n#end\n\n\n/**\n * #(data.codeTitle) Service Impl\n *\n * @author #(data.authorName)\n * @date #(currTime)\n */\n@Service\npublic class #(data.model.tableHumpName)ServiceImpl extends CrudServiceImpl<#(data.model.tableHumpName)Mapper, #(data.model.tableHumpName), #(data.model.tableHumpName)Model>\n implements I#(data.model.tableHumpName)Service {\n\n @Autowired(required = false)\n private #(data.model.tableHumpName)Mapper mapper;\n\n}', '0', 0, 1313694379541635074, '2021-06-03 12:51:13', 1313694379541635074, '2021-06-03 12:51:13'); +INSERT INTO `gen_template_detail` VALUES (1400314103313956865, 1398253704724828162, '0', '${packageName}/${moduleName}/${subModuleName}/service', 'I${model.tableHumpName}Service.java', '#if(data.subModuleName != null && data.subModuleName != \"\")\npackage #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).service;\n#else\npackage #(data.packageName+\".\"+data.moduleName).service;\n#end\n\nimport org.opsli.core.base.service.interfaces.CrudServiceInterface;\n\n\n#if(data.subModuleName != null && data.subModuleName != \"\")\nimport #(data.packageName+\".\"+data.moduleName+\".\"+data.subModuleName).entity.#(data.model.tableHumpName);\nimport #(apiPath).wrapper.#(data.moduleName+\".\"+data.subModuleName).#(data.model.tableHumpName)Model;\n#else\nimport #(data.packageName+\".\"+data.moduleName).entity.#(data.model.tableHumpName);\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\n#end\n\n/**\n * #(data.codeTitle) Service\n *\n * @author #(data.authorName)\n * @date #(currTime)\n */\npublic interface I#(data.model.tableHumpName)Service extends CrudServiceInterface<#(data.model.tableHumpName), #(data.model.tableHumpName)Model> {\n\n}', '0', 0, 1313694379541635074, '2021-06-03 12:51:13', 1313694379541635074, '2021-06-03 12:51:13'); +INSERT INTO `gen_template_detail` VALUES (1400314103515283457, 1398253704724828162, '1', 'src/api/${moduleName}/${subModuleName}', '${model.tableHumpName}ManagementApi.js', 'import request from \"@/utils/request\";\nimport { downloadFileByData } from \"@/utils/download\";\n\nexport function getList(data) {\n return request({\n #if(data.subModuleName != null && data.subModuleName != \"\")\n url: \"/api/v1/#(data.moduleName)/#(data.subModuleName)/findPage\",\n #else\n url: \"/api/v1/#(data.moduleName)/findPage\",\n #end\n method: \"get\",\n params: data,\n });\n}\n\nexport function doInsert(data) {\n return request({\n #if(data.subModuleName != null && data.subModuleName != \"\")\n url: \"/api/v1/#(data.moduleName)/#(data.subModuleName)/insert\",\n #else\n url: \"/api/v1/#(data.moduleName)/insert\",\n #end\n method: \"post\",\n data,\n });\n}\n\nexport function doUpdate(data) {\n return request({\n #if(data.subModuleName != null && data.subModuleName != \"\")\n url: \"/api/v1/#(data.moduleName)/#(data.subModuleName)/update\",\n #else\n url: \"/api/v1/#(data.moduleName)/update\",\n #end\n method: \"post\",\n data,\n });\n}\n\nexport function doDelete(data) {\n return request({\n #if(data.subModuleName != null && data.subModuleName != \"\")\n url: \"/api/v1/#(data.moduleName)/#(data.subModuleName)/del\",\n #else\n url: \"/api/v1/#(data.moduleName)/del\",\n #end\n method: \"post\",\n params: data,\n });\n}\n\nexport function doDeleteAll(data) {\n return request({\n #if(data.subModuleName != null && data.subModuleName != \"\")\n url: \"/api/v1/#(data.moduleName)/#(data.subModuleName)/delAll\",\n #else\n url: \"/api/v1/#(data.moduleName)/delAll\",\n #end\n method: \"post\",\n params: data,\n });\n}\n\n/**\n * 导出Excel 目前只支持一层参数传递\n * @param data\n * @returns file\n */\nexport function doExportExcel(data) {\n #if(data.subModuleName != null && data.subModuleName != \"\")\n let requestURL = \"/api/v1/#(data.moduleName)/#(data.subModuleName)/exportExcel\";\n #else\n let requestURL = \"/api/v1/#(data.moduleName)/exportExcel\";\n #end\n // 下载文件\n downloadFileByData(requestURL, data);\n}\n\n/**\n * 下载模版\n * @returns file\n */\nexport function doDownloadTemplate() {\n let data = {};\n #if(data.subModuleName != null && data.subModuleName != \"\")\n let requestURL = \"/api/v1/#(data.moduleName)/#(data.subModuleName)/importExcel/template\";\n #else\n let requestURL = \"/api/v1/#(data.moduleName)/importExcel/template\";\n #end\n // 下载文件\n downloadFileByData(requestURL, data);\n}\n\n/**\n * 导入Excel\n * @returns file\n */\nexport function doImportExcel(data) {\n return request({\n #if(data.subModuleName != null && data.subModuleName != \"\")\n url: \"/api/v1/#(data.moduleName)/#(data.subModuleName)/importExcel\",\n #else\n url: \"/api/v1/#(data.moduleName)/importExcel\",\n #end\n method: \"post\",\n // 最长超时时间 3 分钟\n timeout: 180000,\n headers: {\n \"Content-Type\": \"multipart/form-data\"\n },\n data,\n });\n}', '0', 0, 1313694379541635074, '2021-06-03 12:51:14', 1313694379541635074, '2021-06-03 12:51:14'); +INSERT INTO `gen_template_detail` VALUES (1400314103641112578, 1398253704724828162, '1', 'src/views/modules/${moduleName}/${subModuleName}/components', '${model.tableHumpName}ManagementEdit.vue', '\n\n\n', '0', 0, 1313694379541635074, '2021-06-03 12:51:14', 1313694379541635074, '2021-06-03 12:51:14'); +INSERT INTO `gen_template_detail` VALUES (1400314103825661953, 1398253704724828162, '1', 'src/views/modules/${moduleName}/${subModuleName}/components', '${model.tableHumpName}ManagementImport.vue', '\n\n\n', '0', 0, 1313694379541635074, '2021-06-03 12:51:14', 1313694379541635074, '2021-06-03 12:51:14'); +INSERT INTO `gen_template_detail` VALUES (1400314103955685378, 1398253704724828162, '1', 'src/views/modules/${moduleName}/${subModuleName}', 'index.vue', '\n\n\n', '0', 0, 1313694379541635074, '2021-06-03 12:51:14', 1313694379541635074, '2021-06-03 12:51:14'); -- ---------------------------- -- Table structure for sys_area @@ -3630,6 +3630,7 @@ INSERT INTO `sys_dict_detail` VALUES (1396789224945967105, '1328591039258980353' INSERT INTO `sys_dict_detail` VALUES (1396789343724462082, '1328591039258980353', 'validate_type', '浮点数', 'IS_DECIMAL', '1', 3, NULL, '0', 1, 1, '2021-05-24 19:25:05', 1, '2021-05-24 19:25:50', '2021-05-24 19:25:49'); INSERT INTO `sys_dict_detail` VALUES (1396789437249052674, '1328591039258980353', 'validate_type', '质数_素数', 'IS_PRIMES', '1', 4, NULL, '0', 1, 1, '2021-05-24 19:25:28', 1, '2021-05-24 19:25:54', '2021-05-24 19:25:54'); INSERT INTO `sys_dict_detail` VALUES (1396790553273655298, '1328591039258980353', 'validate_type', '安全密码', 'IS_SECURITY_PASSWORD', '1', 22, NULL, '0', 0, 1, '2021-05-24 19:29:54', 1, '2021-05-24 19:29:54', '2021-05-24 19:29:53'); +INSERT INTO `sys_dict_detail` VALUES (1400399500568121346, '1388562098925977601', 'storage_type', '又拍云', 'upYun', '1', 2, NULL, '0', 0, 1, '2021-06-03 18:30:34', 1, '2021-06-03 18:30:34', '2021-06-03 18:30:33'); -- ---------------------------- -- Table structure for sys_logs @@ -6179,6 +6180,40 @@ INSERT INTO `sys_logs` VALUES (1399705666469216258, '1', '开发工具-开发向 INSERT INTO `sys_logs` VALUES (1399705716482097154, '1', '开发工具-开发向导-代码生成器-生成', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/logs/create', 'GET', 30, '[{\"moduleName\":\"gentest\",\"izApi\":false,\"templateId\":\"1398253704724828162\",\"tableType\":\"\",\"createBy\":\"1313694379541635074\",\"izManual\":false,\"createTime\":1608466377000,\"authorName\":\"Parker\",\"encryptData\":\"null\",\"codeTitleBrief\":\"汽车信息\",\"codeTitle\":\"汽车信息\",\"tableId\":\"1340630022558056449\",\"packageName\":\"org.opsli.modulars\",\"id\":\"1340631269252005889\",\"subModuleName\":\"carinfo\"},{\"request\":{\"request\":{\"request\":{},\"orgRequest\":{}},\"servletContext\":{},\"session\":{\"servletContext\":{},\"session\":{}},\"httpSessions\":false},\"response\":{\"response\":{},\"status\":200},\"context\":{}}]', NULL, 0, 1313694379541635074, '2021-06-01 20:33:43', 1313694379541635074, '2021-06-01 20:33:43', '2021-06-01 20:33:42'); INSERT INTO `sys_logs` VALUES (1399705819578089474, '1', '开发工具-开发向导-代码模板-修改', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/template/updateAndDetail', 'POST', 238, '[{\"izApi\":false,\"remark\":\"\",\"updateTime\":1622550740000,\"version\":27,\"tableType\":\"0\",\"tempName\":\"Form表单\",\"createBy\":\"1313694379541635074\",\"izManual\":false,\"createTime\":1622204636000,\"updateBy\":\"1313694379541635074\",\"detailList\":[{\"fileName\":\"Entity.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/entity\",\"izManual\":false,\"ignoreFileName\":\"1\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).entity;\\n#end\\n\\n#for(pkg : data.model.entityPkgList)\\nimport #(pkg);\\n#end\\nimport com.baomidou.mybatisplus.annotation.FieldStrategy;\\nimport com.baomidou.mybatisplus.annotation.TableField;\\nimport com.baomidou.mybatisplus.annotation.TableLogic;\\nimport lombok.Data;\\nimport lombok.EqualsAndHashCode;\\nimport org.opsli.core.base.entity.BaseEntity;\\n\\n/**\\n * #(data.codeTitle) Entity\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\n@Data\\n@EqualsAndHashCode(callSuper = false)\\npublic class #(data.model.tableHumpName) extends BaseEntity {\\n\\n\\n #for(column : data.model.columnList)\\n ### 不等于 删除字段 和 不等于 租户字段放入上边\\n #if(column.fieldHumpName != \\\"deleted\\\" && column.fieldHumpName != \\\"tenantId\\\")\\n /** #(column.fieldComments) */\\n #if(!column.izNotNull)\\n @TableField(updateStrategy = FieldStrategy.IGNORED)\\n #end\\n private #(column.javaType) #(column.fieldHumpName);\\n\\n #end\\n #end\\n\\n // ========================================\\n\\n ### 专门处理 删除字段 和 租户字段\\n #for(column : data.model.columnList)\\n #if(column.fieldHumpName == \\\"deleted\\\")\\n /** 逻辑删除字段 */\\n @TableLogic\\n private Integer deleted;\\n #else if(column.fieldHumpName == \\\"tenantId\\\")\\n /** 多租户字段 */\\n private String tenantId;\\n #end\\n\\n #end\\n\\n}\"},{\"fileName\":\"Mapper.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/mapper\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).mapper;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).mapper;\\n#end\\n\\nimport com.baomidou.mybatisplus.core.mapper.BaseMapper;\\nimport org.apache.ibatis.annotations.Mapper;\\nimport org.apache.ibatis.annotations.Param;\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity.#(data.model.tableHumpName);\\n#else\\nimport #(data.packageName+\\\".\\\"+data.moduleName).entity.#(data.model.tableHumpName);\\n#end\\n\\n/**\\n * #(data.codeTitle) Mapper\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\n@Mapper\\npublic interface #(data.model.tableHumpName)Mapper extends BaseMapper<#(data.model.tableHumpName)> {\\n\\n}\"},{\"fileName\":\"Mapper.xml\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/mapper/xml\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n\\n#else\\n\\n#end\\n\\n\\n\"},{\"fileName\":\"Model.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"org/opsli/api/wrapper/${moduleName}/${subModuleName}\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName);\\n#else\\npackage #(apiPath).wrapper.#(data.moduleName);\\n#end\\n\\n#for(pkg : data.model.entityPkgList)\\nimport #(pkg);\\n#end\\nimport com.alibaba.excel.annotation.ExcelProperty;\\nimport io.swagger.annotations.ApiModelProperty;\\nimport lombok.Data;\\nimport lombok.EqualsAndHashCode;\\nimport #(apiPath).base.warpper.ApiWrapper;\\nimport org.opsli.common.annotation.validator.Validator;\\nimport org.opsli.common.annotation.validator.ValidatorLenMax;\\nimport org.opsli.common.annotation.validator.ValidatorLenMin;\\nimport org.opsli.common.enums.ValidatorType;\\nimport org.opsli.plugins.excel.annotation.ExcelInfo;\\nimport com.fasterxml.jackson.annotation.JsonFormat;\\nimport org.springframework.format.annotation.DateTimeFormat;\\n\\n/**\\n* #(data.codeTitle) Model\\n*\\n* @author #(data.authorName)\\n* @date #(currTime)\\n*/\\n@Data\\n@EqualsAndHashCode(callSuper = false)\\npublic class #(data.model.tableHumpName)Model extends ApiWrapper {\\n\\n #for(column : data.model.columnList)\\n ### 不等于 删除字段 和 不等于 租户字段放入上边\\n #if(column.fieldHumpName != \\\"deleted\\\" && column.fieldHumpName != \\\"tenantId\\\")\\n /** #(column.fieldComments) */\\n @ApiModelProperty(value = \\\"#(column.fieldComments)\\\")\\n @ExcelProperty(value = \\\"#(column.fieldComments)\\\", order = #(column.sort))\\n #if(column.dictTypeCode != null && column.dictTypeCode != \\\"\\\")\\n @ExcelInfo( dictType = \\\"#(column.dictTypeCode)\\\" )\\n #else\\n @ExcelInfo\\n #end\\n #if(column.validateTypeAndCommaList != null && column.validateTypeAndCommaList.size() > 0)\\n @Validator({\\n #for(typeAndComma : column.validateTypeAndCommaList)\\n ValidatorType.#(typeAndComma)\\n #end\\n })\\n #end\\n #if(column.fieldLength != null && column.fieldLength > 0)\\n #if(column.fieldPrecision != null && column.fieldPrecision > 0)\\n @ValidatorLenMax(#(column.fieldLength+column.fieldPrecision))\\n #else\\n @ValidatorLenMax(#(column.fieldLength))\\n #end\\n #end\\n ### 日期处理\\n #if(column.javaType == \\\"Date\\\")\\n #if(column.showType == \\\"4\\\")\\n @JsonFormat(timezone = \\\"GMT+8\\\", pattern = \\\"yyyy-MM-dd\\\")\\n @DateTimeFormat(pattern = \\\"yyyy-MM-dd\\\")\\n #else\\n @JsonFormat(timezone = \\\"GMT+8\\\", pattern = \\\"yyyy-MM-dd HH:mm:ss\\\")\\n @DateTimeFormat(pattern = \\\"yyyy-MM-dd HH:mm:ss\\\")\\n #end\\n #end\\n private #(column.javaType) #(column.fieldHumpName);\\n\\n #end\\n #end\\n\\n\\n}\"},{\"fileName\":\"RestApi.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"org/opsli/api/web/${moduleName}/${subModuleName}\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(apiPath).web.#(data.moduleName+\\\".\\\"+data.subModuleName);\\n#else\\npackage #(apiPath).web.#(data.moduleName);\\n#end\\n\\nimport #(apiPath).base.result.ResultVo;\\nimport org.springframework.web.bind.annotation.GetMapping;\\nimport org.springframework.web.bind.annotation.PostMapping;\\nimport org.springframework.web.bind.annotation.RequestBody;\\nimport org.springframework.web.bind.annotation.RequestParam;\\nimport org.springframework.web.multipart.MultipartHttpServletRequest;\\nimport javax.servlet.http.HttpServletRequest;\\nimport javax.servlet.http.HttpServletResponse;\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)Model;\\n#else\\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\\n#end\\n\\n\\n/**\\n * #(data.codeTitle) Api\\n *\\n * 对外 API 直接 暴露 @GetMapping 或者 @PostMapping\\n * 对内也推荐 单机版 不需要设置 Mapping 但是调用方法得从Controller写起\\n *\\n * 这样写法虽然比较绕,但是当单体项目想要改造微服务架构时 时非常容易的\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\npublic interface #(data.model.tableHumpName)RestApi {\\n\\n /** 标题 */\\n String TITLE = \\\"#(data.codeTitle)\\\";\\n /** 子标题 */\\n String SUB_TITLE = \\\"#(data.codeTitleBrief)\\\";\\n\\n /**\\n * #(data.codeTitle) 查一条\\n * @param model 模型\\n * @return ResultVo\\n */\\n @GetMapping(\\\"/get\\\")\\n ResultVo<#(data.model.tableHumpName)Model> get(#(data.model.tableHumpName)Model model);\\n\\n /**\\n * #(data.codeTitle) 查询分页\\n * @param pageNo 当前页\\n * @param pageSize 每页条数\\n * @param request request\\n * @return ResultVo\\n */\\n @GetMapping(\\\"/findPage\\\")\\n ResultVo findPage(\\n @RequestParam(name = \\\"pageNo\\\", defaultValue = \\\"1\\\") Integer pageNo,\\n @RequestParam(name = \\\"pageSize\\\", defaultValue = \\\"10\\\") Integer pageSize,\\n HttpServletRequest request\\n );\\n\\n /**\\n * #(data.codeTitle) 新增\\n * @param model 模型\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/insert\\\")\\n ResultVo insert(@RequestBody #(data.model.tableHumpName)Model model);\\n\\n /**\\n * #(data.codeTitle) 修改\\n * @param model 模型\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/update\\\")\\n ResultVo update(@RequestBody #(data.model.tableHumpName)Model model);\\n\\n /**\\n * #(data.codeTitle) 删除\\n * @param id ID\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/del\\\")\\n ResultVo del(String id);\\n\\n /**\\n * #(data.codeTitle) 批量删除\\n * @param ids ID 数组\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/delAll\\\")\\n ResultVo delAll(String ids);\\n\\n /**\\n * #(data.codeTitle) Excel 导出\\n *\\n * 导出时,Token认证和方法权限认证 全部都由自定义完成\\n * 因为在 导出不成功时,需要推送错误信息,\\n * 前端直接走下载流,当失败时无法获得失败信息,即使前后端换一种方式后端推送二进制文件前端再次解析也是最少2倍的耗时\\n * ,且如果数据量过大,前端进行渲染时直接会把浏览器卡死\\n * 而直接开启socket接口推送显然是太过浪费资源了,所以目前采用Java最原始的手段\\n * response 推送 javascript代码 alert 提示报错信息\\n *\\n * @param request request\\n * @param response response\\n */\\n @GetMapping(\\\"/exportExcel\\\")\\n void exportExcel(HttpServletRequest request, HttpServletResponse response);\\n\\n /**\\n * #(data.codeTitle) Excel 导入\\n * @param request 文件流 request\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/importExcel\\\")\\n ResultVo importExcel(MultipartHttpServletRequest request);\\n\\n /**\\n * #(data.codeTitle) Excel 下载导入模版\\n * @param response response\\n */\\n @GetMapping(\\\"/importExcel/template\\\")\\n void importTemplate(HttpServletResponse response);\\n\\n}\"},{\"fileName\":\"RestController.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/web\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).web;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).web;\\n#end\\n\\nimport cn.hutool.core.util.ReflectUtil;\\nimport cn.hutool.core.convert.Convert;\\nimport io.swagger.annotations.Api;\\nimport io.swagger.annotations.ApiOperation;\\nimport lombok.extern.slf4j.Slf4j;\\nimport org.opsli.common.annotation.RequiresPermissionsCus;\\nimport org.apache.shiro.authz.annotation.RequiresPermissions;\\nimport #(apiPath).base.result.ResultVo;\\nimport org.opsli.common.annotation.ApiRestController;\\nimport org.opsli.common.annotation.EnableLog;\\nimport org.opsli.core.base.controller.BaseRestController;\\nimport org.opsli.core.persistence.Page;\\nimport org.opsli.core.persistence.querybuilder.QueryBuilder;\\nimport org.opsli.core.persistence.querybuilder.WebQueryBuilder;\\nimport org.springframework.web.multipart.MultipartHttpServletRequest;\\nimport javax.servlet.http.HttpServletRequest;\\nimport javax.servlet.http.HttpServletResponse;\\nimport java.lang.reflect.Method;\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)Model;\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).service.I#(data.model.tableHumpName)Service;\\nimport #(apiPath).web.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)RestApi;\\n#else\\nimport #(data.packageName+\\\".\\\"+data.moduleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\\nimport #(data.packageName+\\\".\\\"+data.moduleName).service.I#(data.model.tableHumpName)Service;\\nimport #(apiPath).web.#(data.moduleName).#(data.model.tableHumpName)RestApi;\\n#end\\n\\n/**\\n * #(data.codeTitle) Controller\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\n@Api(tags = #(data.model.tableHumpName)RestApi.TITLE)\\n@Slf4j\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n@ApiRestController(\\\"/#(data.moduleName)/#(data.subModuleName)\\\")\\n#else\\n@ApiRestController(\\\"/#(data.moduleName)\\\")\\n#end\\npublic class #(data.model.tableHumpName)RestController extends BaseRestController<#(data.model.tableHumpName), #(data.model.tableHumpName)Model, I#(data.model.tableHumpName)Service>\\n implements #(data.model.tableHumpName)RestApi {\\n\\n\\n /**\\n * #(data.codeTitleBrief) 查一条\\n * @param model 模型\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"获得单条#(data.codeTitleBrief)\\\", notes = \\\"获得单条#(data.codeTitleBrief) - ID\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_select\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_select\\\")\\n #end\\n @Override\\n public ResultVo<#(data.model.tableHumpName)Model> get(#(data.model.tableHumpName)Model model) {\\n // 如果系统内部调用 则直接查数据库\\n if(model != null && model.getIzApi() != null && model.getIzApi()){\\n model = IService.get(model);\\n }\\n return ResultVo.success(model);\\n }\\n\\n /**\\n * #(data.codeTitleBrief) 查询分页\\n * @param pageNo 当前页\\n * @param pageSize 每页条数\\n * @param request request\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"获得分页数据\\\", notes = \\\"获得分页数据 - 查询构造器\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_select\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_select\\\")\\n #end\\n @Override\\n public ResultVo findPage(Integer pageNo, Integer pageSize, HttpServletRequest request) {\\n\\n QueryBuilder<#(data.model.tableHumpName)> queryBuilder = new WebQueryBuilder<>(entityClazz, request.getParameterMap());\\n Page<#(data.model.tableHumpName), #(data.model.tableHumpName)Model> page = new Page<>(pageNo, pageSize);\\n page.setQueryWrapper(queryBuilder.build());\\n page = IService.findPage(page);\\n\\n return ResultVo.success(page.getPageData());\\n }\\n\\n /**\\n * #(data.codeTitleBrief) 新增\\n * @param model 模型\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"新增#(data.codeTitleBrief)数据\\\", notes = \\\"新增#(data.codeTitleBrief)数据\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_insert\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_insert\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo insert(#(data.model.tableHumpName)Model model) {\\n // 调用新增方法\\n IService.insert(model);\\n return ResultVo.success(\\\"新增#(data.codeTitleBrief)成功\\\");\\n }\\n\\n /**\\n * #(data.codeTitleBrief) 修改\\n * @param model 模型\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"修改#(data.codeTitleBrief)数据\\\", notes = \\\"修改#(data.codeTitleBrief)数据\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_update\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_update\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo update(#(data.model.tableHumpName)Model model) {\\n // 调用修改方法\\n IService.update(model);\\n return ResultVo.success(\\\"修改#(data.codeTitleBrief)成功\\\");\\n }\\n\\n\\n /**\\n * #(data.codeTitleBrief) 删除\\n * @param id ID\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"删除#(data.codeTitleBrief)数据\\\", notes = \\\"删除#(data.codeTitleBrief)数据\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_update\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_update\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo del(String id){\\n IService.delete(id);\\n return ResultVo.success(\\\"删除#(data.codeTitleBrief)成功\\\");\\n }\\n\\n /**\\n * #(data.codeTitleBrief) 批量删除\\n * @param ids ID 数组\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"批量删除#(data.codeTitleBrief)数据\\\", notes = \\\"批量删除#(data.codeTitleBrief)数据\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_update\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_update\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo delAll(String ids){\\n String[] idArray = Convert.toStrArray(ids);\\n IService.deleteAll(idArray);\\n return ResultVo.success(\\\"批量删除#(data.codeTitleBrief)成功\\\");\\n }\\n\\n\\n /**\\n * #(data.codeTitleBrief) Excel 导出\\n * 注:这里 RequiresPermissionsCus 引入的是 自定义鉴权注解\\n *\\n * 导出时,Token认证和方法权限认证 全部都由自定义完成\\n * 因为在 导出不成功时,需要推送错误信息,\\n * 前端直接走下载流,当失败时无法获得失败信息,即使前后端换一种方式后端推送二进制文件前端再次解析也是最少2倍的耗时\\n * ,且如果数据量过大,前端进行渲染时直接会把浏览器卡死\\n * 而直接开启socket接口推送显然是太过浪费资源了,所以目前采用Java最原始的手段\\n * response 推送 javascript代码 alert 提示报错信息\\n *\\n * @param request request\\n * @param response response\\n */\\n @ApiOperation(value = \\\"导出Excel\\\", notes = \\\"导出Excel\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissionsCus(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_export\\\")\\n #else\\n @RequiresPermissionsCus(\\\"#(data.moduleName.toLowerCase())_export\\\")\\n #end\\n @EnableLog\\n @Override\\n public void exportExcel(HttpServletRequest request, HttpServletResponse response) {\\n // 当前方法\\n Method method = ReflectUtil.getMethodByName(this.getClass(), \\\"exportExcel\\\");\\n QueryBuilder<#(data.model.tableHumpName)> queryBuilder = new WebQueryBuilder<>(entityClazz, request.getParameterMap());\\n super.excelExport(#(data.model.tableHumpName)RestApi.SUB_TITLE, queryBuilder.build(), response, method);\\n }\\n\\n /**\\n * #(data.codeTitleBrief) Excel 导入\\n * 注:这里 RequiresPermissions 引入的是 Shiro原生鉴权注解\\n * @param request 文件流 request\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"导入Excel\\\", notes = \\\"导入Excel\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_import\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_import\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo importExcel(MultipartHttpServletRequest request) {\\n return super.importExcel(request);\\n }\\n\\n /**\\n * #(data.codeTitleBrief) Excel 下载导入模版\\n * 注:这里 RequiresPermissionsCus 引入的是 自定义鉴权注解\\n * @param response response\\n */\\n @ApiOperation(value = \\\"导出Excel模版\\\", notes = \\\"导出Excel模版\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissionsCus(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_import\\\")\\n #else\\n @RequiresPermissionsCus(\\\"#(data.moduleName.toLowerCase())_import\\\")\\n #end\\n @Override\\n public void importTemplate(HttpServletResponse response) {\\n // 当前方法\\n Method method = ReflectUtil.getMethodByName(this.getClass(), \\\"importTemplate\\\");\\n super.importTemplate(#(data.model.tableHumpName)RestApi.SUB_TITLE, response, method);\\n }\\n\\n}\"},{\"fileName\":\"Service.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/service\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).service;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).service;\\n#end\\n\\nimport org.opsli.core.base.service.interfaces.CrudServiceInterface;\\n\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)Model;\\n#else\\nimport #(data.packageName+\\\".\\\"+data.moduleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\\n#end\\n\\n/**\\n * #(data.codeTitle) Service\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\npublic interface I#(data.model.tableHumpName)Service extends CrudServiceInterface<#(data.model.tableHumpName), #(data.model.tableHumpName)Model> {\\n\\n}\"},{\"fileName\":\"ServiceImpl.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/service/impl\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).service.impl;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).service.impl;\\n#end\\n\\n\\nimport org.springframework.beans.factory.annotation.Autowired;\\nimport org.springframework.stereotype.Service;\\nimport org.springframework.transaction.annotation.Transactional;\\nimport org.opsli.core.base.service.impl.CrudServiceImpl;\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)Model;\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).service.I#(data.model.tableHumpName)Service;\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).mapper.#(data.model.tableHumpName)Mapper;\\n#else\\nimport #(data.packageName+\\\".\\\"+data.moduleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\\nimport #(data.packageName+\\\".\\\"+data.moduleName).service.I#(data.model.tableHumpName)Service;\\nimport #(data.packageName+\\\".\\\"+data.moduleName).mapper.#(data.model.tableHumpName)Mapper;\\n#end\\n\\n\\n/**\\n * #(data.codeTitle) Service Impl\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\n@Service\\npublic class #(data.model.tableHumpName)ServiceImpl extends CrudServiceImpl<#(data.model.tableHumpName)Mapper, #(data.model.tableHumpName), #(data.model.tableHumpName)Model>\\n implements I#(data.model.tableHumpName)Service {\\n\\n @Autowired(required = false)\\n private #(data.model.tableHumpName)Mapper mapper;\\n\\n}\"},{\"fileName\":\"Api.js\",\"izApi\":false,\"type\":\"1\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"src/api/${moduleName}/${subModuleName}\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"import request from \\\"@/utils/request\\\";\\nimport {downloadFileByData} from \\\"@/utils/download\\\";\\n\\nexport function getList(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/findPage\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/findPage\\\",\\n #end\\n method: \\\"get\\\",\\n params: data,\\n });\\n}\\n\\n\\nexport function doInsert(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/insert\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/insert\\\",\\n #end\\n method: \\\"post\\\",\\n data,\\n });\\n}\\n\\nexport function doUpdate(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/update\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/update\\\",\\n #end\\n method: \\\"post\\\",\\n data,\\n });\\n}\\n\\nexport function doDelete(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/del\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/del\\\",\\n #end\\n method: \\\"post\\\",\\n params: data,\\n });\\n}\\n\\nexport function doDeleteAll(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/delAll\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/delAll\\\",\\n #end\\n method: \\\"post\\\",\\n params: data,\\n });\\n}\\n\\n\\n/**\\n* 导出Excel 目前只支持一层参数传递\\n* @param data\\n* @returns file\\n*/\\nexport function doExportExcel(data) {\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n let requestURL = \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/exportExcel\\\";\\n #else\\n let requestURL = \\\"/api/v1/#(data.moduleName)/exportExcel\\\";\\n #end\\n // 下载文件\\n downloadFileByData(requestURL, data);\\n}\\n\\n\\n/**\\n* 下载模版\\n* @returns file\\n*/\\nexport function doDownloadTemplate() {\\n let data = {};\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n let requestURL = \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/importExcel/template\\\";\\n #else\\n let requestURL = \\\"/api/v1/#(data.moduleName)/importExcel/template\\\";\\n #end\\n // 下载文件\\n downloadFileByData(requestURL, data);\\n}\\n\\n/**\\n* 导入Excel\\n* @returns file\\n*/\\nexport function doImportExcel(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/importExcel\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/importExcel\\\",\\n #end\\n method: \\\"post\\\",\\n // 最长超时时间 3 分钟\\n timeout: 180000,\\n headers: {\\n \\\"Content-Type\\\": \\\"multipart/form-data\\\"\\n },\\n data,\\n });\\n}\\n\\n\\n\"},{\"fileName\":\"Edit.vue\",\"izApi\":false,\"type\":\"1\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"src/views/modules/${moduleName}/${subModuleName}/components\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"\\n\\n\\n\"},{\"fileName\":\"Import.vue\",\"izApi\":false,\"type\":\"1\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"src/views/modules/${moduleName}/${subModuleName}/components\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"\\n\\n\\n\"},{\"fileName\":\"index.vue\",\"izApi\":false,\"type\":\"1\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"src/views/modules/${moduleName}/${subModuleName}\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"\\n\\n\\n\"}],\"id\":\"1398253704724828162\"}]', NULL, 0, 1313694379541635074, '2021-06-01 20:34:07', 1313694379541635074, '2021-06-01 20:34:07', '2021-06-01 20:34:07'); INSERT INTO `sys_logs` VALUES (1399705862481625090, '1', '开发工具-开发向导-代码生成器-生成', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/logs/create', 'GET', 35, '[{\"moduleName\":\"other\",\"izApi\":false,\"templateId\":\"1398253704724828162\",\"tableType\":\"\",\"createBy\":\"1313694379541635074\",\"izManual\":false,\"createTime\":1612948174000,\"authorName\":\"Parker\",\"encryptData\":\"null\",\"codeTitleBrief\":\"非对称加密\",\"codeTitle\":\"非对称加密管理\",\"tableId\":\"1359428685312028674\",\"packageName\":\"org.opsli.modulars.gentest\",\"id\":\"1359429290382323714\",\"subModuleName\":\"crypto\"},{\"request\":{\"request\":{\"request\":{},\"orgRequest\":{}},\"servletContext\":{},\"session\":{\"servletContext\":{},\"session\":{}},\"httpSessions\":false},\"response\":{\"response\":{},\"status\":200},\"context\":{}}]', NULL, 0, 1313694379541635074, '2021-06-01 20:34:18', 1313694379541635074, '2021-06-01 20:34:18', '2021-06-01 20:34:17'); +INSERT INTO `sys_logs` VALUES (1399935899172597761, '1', '开发工具-开发向导-代码模板-复制', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/template/copy', 'POST', 357, '[{\"izApi\":false,\"tempName\":\"123123\",\"izManual\":false}]', NULL, 0, 1313694379541635074, '2021-06-02 11:48:23', 1313694379541635074, '2021-06-02 11:48:23', '2021-06-02 11:48:22'); +INSERT INTO `sys_logs` VALUES (1399935988863594498, '1', '开发工具-开发向导-代码模板-修改', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/template/del', 'POST', 16524, '[\"1399935897671036929\"]', NULL, 0, 1313694379541635074, '2021-06-02 11:48:44', 1313694379541635074, '2021-06-02 11:48:44', '2021-06-02 11:48:43'); +INSERT INTO `sys_logs` VALUES (1399936080983093250, '2', '开发工具-开发向导-代码模板-修改', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/template/del', 'POST', 3929, '[\"1398253704724828162\"]', '代码模板同一表类型下,至少保障有一个模板', 0, 1313694379541635074, '2021-06-02 11:49:06', 1313694379541635074, '2021-06-02 11:49:06', '2021-06-02 11:49:05'); +INSERT INTO `sys_logs` VALUES (1399936109529526274, '2', '开发工具-开发向导-代码模板-修改', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/template/del', 'POST', 5, '[\"1398253704724828162\"]', '代码模板同一表类型下,至少保障有一个模板', 0, 1313694379541635074, '2021-06-02 11:49:13', 1313694379541635074, '2021-06-02 11:49:13', '2021-06-02 11:49:12'); +INSERT INTO `sys_logs` VALUES (1399936131172134914, '2', '开发工具-开发向导-代码模板-修改', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/template/del', 'POST', 5, '[\"1398253704724828162\"]', '代码模板同一表类型下,至少保障有一个模板', 0, 1313694379541635074, '2021-06-02 11:49:18', 1313694379541635074, '2021-06-02 11:49:18', '2021-06-02 11:49:17'); +INSERT INTO `sys_logs` VALUES (1399938670034616322, '2', '开发工具-开发向导-代码模板-新增', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/template/insertAndDetail', 'POST', 14, '[{\"izApi\":false,\"remark\":\"\",\"version\":0,\"tableType\":\"0\",\"tempName\":\"12321\",\"izManual\":false,\"detailList\":[]}]', '代码生成器未启用', 0, 1313694379541635074, '2021-06-02 11:59:23', 1313694379541635074, '2021-06-02 11:59:23', '2021-06-02 11:59:23'); +INSERT INTO `sys_logs` VALUES (1399938674690293761, '2', '开发工具-开发向导-代码模板-新增', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/template/insertAndDetail', 'POST', 1, '[{\"izApi\":false,\"remark\":\"\",\"version\":0,\"tableType\":\"0\",\"tempName\":\"12321\",\"izManual\":false,\"detailList\":[]}]', '代码生成器未启用', 0, 1313694379541635074, '2021-06-02 11:59:24', 1313694379541635074, '2021-06-02 11:59:24', '2021-06-02 11:59:24'); +INSERT INTO `sys_logs` VALUES (1399938677869576193, '2', '开发工具-开发向导-代码模板-新增', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/template/insertAndDetail', 'POST', 2, '[{\"izApi\":false,\"remark\":\"\",\"version\":0,\"tableType\":\"0\",\"tempName\":\"12321\",\"izManual\":false,\"detailList\":[]}]', '代码生成器未启用', 0, 1313694379541635074, '2021-06-02 11:59:25', 1313694379541635074, '2021-06-02 11:59:25', '2021-06-02 11:59:25'); +INSERT INTO `sys_logs` VALUES (1399938680147083266, '2', '开发工具-开发向导-代码模板-新增', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/template/insertAndDetail', 'POST', 1, '[{\"izApi\":false,\"remark\":\"\",\"version\":0,\"tableType\":\"0\",\"tempName\":\"12321\",\"izManual\":false,\"detailList\":[]}]', '代码生成器未启用', 0, 1313694379541635074, '2021-06-02 11:59:26', 1313694379541635074, '2021-06-02 11:59:26', '2021-06-02 11:59:25'); +INSERT INTO `sys_logs` VALUES (1400006429019947010, '1', '开发工具-开发向导-代码生成器-生成', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/logs/create', 'GET', 343, '[{\"moduleName\":\"other\",\"izApi\":false,\"templateId\":\"1398253704724828162\",\"tableType\":\"\",\"createBy\":\"1313694379541635074\",\"izManual\":false,\"createTime\":1612948174000,\"authorName\":\"Parker\",\"encryptData\":\"null\",\"codeTitleBrief\":\"非对称加密\",\"codeTitle\":\"非对称加密管理\",\"tableId\":\"1359428685312028674\",\"packageName\":\"org.opsli.modulars.gentest\",\"id\":\"1359429290382323714\",\"subModuleName\":\"crypto\"},{\"request\":{\"request\":{\"request\":{},\"orgRequest\":{}},\"servletContext\":{},\"session\":{\"servletContext\":{},\"session\":{}},\"httpSessions\":false},\"response\":{\"response\":{},\"status\":200},\"context\":{}}]', NULL, 0, 1313694379541635074, '2021-06-02 16:28:38', 1313694379541635074, '2021-06-02 16:28:38', '2021-06-02 16:28:38'); +INSERT INTO `sys_logs` VALUES (1400006735095087106, '1', '开发工具-开发向导-代码生成器-生成', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/logs/create', 'GET', 126, '[{\"moduleName\":\"other\",\"izApi\":false,\"templateId\":\"1398253704724828162\",\"tableType\":\"\",\"createBy\":\"1313694379541635074\",\"izManual\":false,\"createTime\":1612948174000,\"authorName\":\"Parker\",\"encryptData\":\"null\",\"codeTitleBrief\":\"非对称加密\",\"codeTitle\":\"非对称加密管理\",\"tableId\":\"1359428685312028674\",\"packageName\":\"org.opsli.modulars.gentest\",\"id\":\"1359429290382323714\",\"subModuleName\":\"crypto\"},{\"request\":{\"request\":{\"request\":{},\"orgRequest\":{}},\"servletContext\":{},\"session\":{\"servletContext\":{},\"session\":{}},\"httpSessions\":false},\"response\":{\"response\":{},\"status\":200},\"context\":{}}]', NULL, 0, 1313694379541635074, '2021-06-02 16:29:51', 1313694379541635074, '2021-06-02 16:29:51', '2021-06-02 16:29:51'); +INSERT INTO `sys_logs` VALUES (1400007886079213570, '1', '开发工具-开发向导-代码生成器-生成', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/logs/create', 'GET', 190, '[{\"moduleName\":\"other\",\"izApi\":false,\"templateId\":\"1398253704724828162\",\"tableType\":\"\",\"createBy\":\"1313694379541635074\",\"izManual\":false,\"createTime\":1612948174000,\"authorName\":\"Parker\",\"encryptData\":\"null\",\"codeTitleBrief\":\"非对称加密\",\"codeTitle\":\"非对称加密管理\",\"tableId\":\"1359428685312028674\",\"packageName\":\"org.opsli.modulars.gentest\",\"id\":\"1359429290382323714\",\"subModuleName\":\"crypto\"},{\"request\":{\"request\":{\"request\":{},\"orgRequest\":{}},\"servletContext\":{},\"session\":{\"servletContext\":{},\"session\":{}},\"httpSessions\":false},\"response\":{\"response\":{},\"status\":200},\"context\":{}}]', NULL, 0, 1313694379541635074, '2021-06-02 16:34:26', 1313694379541635074, '2021-06-02 16:34:26', '2021-06-02 16:34:25'); +INSERT INTO `sys_logs` VALUES (1400008496203644929, '1', '开发工具-开发向导-代码生成器-生成', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/logs/create', 'GET', 52563, '[{\"moduleName\":\"other\",\"izApi\":false,\"templateId\":\"1398253704724828162\",\"tableType\":\"\",\"createBy\":\"1313694379541635074\",\"izManual\":false,\"createTime\":1612948174000,\"authorName\":\"Parker\",\"encryptData\":\"null\",\"codeTitleBrief\":\"非对称加密\",\"codeTitle\":\"非对称加密管理\",\"tableId\":\"1359428685312028674\",\"packageName\":\"org.opsli.modulars.gentest\",\"id\":\"1359429290382323714\",\"subModuleName\":\"crypto\"},{\"request\":{\"request\":{\"request\":{},\"orgRequest\":{}},\"servletContext\":{},\"session\":{\"servletContext\":{},\"session\":{}},\"httpSessions\":false},\"response\":{\"response\":{},\"status\":200},\"context\":{}}]', NULL, 0, 1313694379541635074, '2021-06-02 16:36:51', 1313694379541635074, '2021-06-02 16:36:51', '2021-06-02 16:36:51'); +INSERT INTO `sys_logs` VALUES (1400009073310515202, '1', '开发工具-开发向导-代码模板-修改', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/template/updateAndDetail', 'POST', 640, '[{\"izApi\":false,\"remark\":\"\",\"updateTime\":1622550847000,\"version\":28,\"tableType\":\"0\",\"tempName\":\"Form表单\",\"createBy\":\"1313694379541635074\",\"izManual\":false,\"createTime\":1622204636000,\"updateBy\":\"1313694379541635074\",\"detailList\":[{\"fileName\":\"${model.tableHumpName}Entity.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/entity\",\"izManual\":false,\"ignoreFileName\":\"1\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).entity;\\n#end\\n\\n#for(pkg : data.model.entityPkgList)\\nimport #(pkg);\\n#end\\nimport com.baomidou.mybatisplus.annotation.FieldStrategy;\\nimport com.baomidou.mybatisplus.annotation.TableField;\\nimport com.baomidou.mybatisplus.annotation.TableLogic;\\nimport lombok.Data;\\nimport lombok.EqualsAndHashCode;\\nimport org.opsli.core.base.entity.BaseEntity;\\n\\n/**\\n * #(data.codeTitle) Entity\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\n@Data\\n@EqualsAndHashCode(callSuper = false)\\npublic class #(data.model.tableHumpName) extends BaseEntity {\\n\\n\\n #for(column : data.model.columnList)\\n ### 不等于 删除字段 和 不等于 租户字段放入上边\\n #if(column.fieldHumpName != \\\"deleted\\\" && column.fieldHumpName != \\\"tenantId\\\")\\n /** #(column.fieldComments) */\\n #if(!column.izNotNull)\\n @TableField(updateStrategy = FieldStrategy.IGNORED)\\n #end\\n private #(column.javaType) #(column.fieldHumpName);\\n\\n #end\\n #end\\n\\n // ========================================\\n\\n ### 专门处理 删除字段 和 租户字段\\n #for(column : data.model.columnList)\\n #if(column.fieldHumpName == \\\"deleted\\\")\\n /** 逻辑删除字段 */\\n @TableLogic\\n private Integer deleted;\\n #else if(column.fieldHumpName == \\\"tenantId\\\")\\n /** 多租户字段 */\\n private String tenantId;\\n #end\\n\\n #end\\n\\n}\"},{\"fileName\":\"${model.tableHumpName}Mapper.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/mapper\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).mapper;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).mapper;\\n#end\\n\\nimport com.baomidou.mybatisplus.core.mapper.BaseMapper;\\nimport org.apache.ibatis.annotations.Mapper;\\nimport org.apache.ibatis.annotations.Param;\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity.#(data.model.tableHumpName);\\n#else\\nimport #(data.packageName+\\\".\\\"+data.moduleName).entity.#(data.model.tableHumpName);\\n#end\\n\\n/**\\n * #(data.codeTitle) Mapper\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\n@Mapper\\npublic interface #(data.model.tableHumpName)Mapper extends BaseMapper<#(data.model.tableHumpName)> {\\n\\n}\"},{\"fileName\":\"${model.tableHumpName}Mapper.xml\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/mapper/xml\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n\\n#else\\n\\n#end\\n\\n\\n\"},{\"fileName\":\"${model.tableHumpName}Model.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"org/opsli/api/wrapper/${moduleName}/${subModuleName}\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName);\\n#else\\npackage #(apiPath).wrapper.#(data.moduleName);\\n#end\\n\\n#for(pkg : data.model.entityPkgList)\\nimport #(pkg);\\n#end\\nimport com.alibaba.excel.annotation.ExcelProperty;\\nimport io.swagger.annotations.ApiModelProperty;\\nimport lombok.Data;\\nimport lombok.EqualsAndHashCode;\\nimport #(apiPath).base.warpper.ApiWrapper;\\nimport org.opsli.common.annotation.validator.Validator;\\nimport org.opsli.common.annotation.validator.ValidatorLenMax;\\nimport org.opsli.common.annotation.validator.ValidatorLenMin;\\nimport org.opsli.common.enums.ValidatorType;\\nimport org.opsli.plugins.excel.annotation.ExcelInfo;\\nimport com.fasterxml.jackson.annotation.JsonFormat;\\nimport org.springframework.format.annotation.DateTimeFormat;\\n\\n/**\\n* #(data.codeTitle) Model\\n*\\n* @author #(data.authorName)\\n* @date #(currTime)\\n*/\\n@Data\\n@EqualsAndHashCode(callSuper = false)\\npublic class #(data.model.tableHumpName)Model extends ApiWrapper {\\n\\n #for(column : data.model.columnList)\\n ### 不等于 删除字段 和 不等于 租户字段放入上边\\n #if(column.fieldHumpName != \\\"deleted\\\" && column.fieldHumpName != \\\"tenantId\\\")\\n /** #(column.fieldComments) */\\n @ApiModelProperty(value = \\\"#(column.fieldComments)\\\")\\n @ExcelProperty(value = \\\"#(column.fieldComments)\\\", order = #(column.sort))\\n #if(column.dictTypeCode != null && column.dictTypeCode != \\\"\\\")\\n @ExcelInfo( dictType = \\\"#(column.dictTypeCode)\\\" )\\n #else\\n @ExcelInfo\\n #end\\n #if(column.validateTypeAndCommaList != null && column.validateTypeAndCommaList.size() > 0)\\n @Validator({\\n #for(typeAndComma : column.validateTypeAndCommaList)\\n ValidatorType.#(typeAndComma)\\n #end\\n })\\n #end\\n #if(column.fieldLength != null && column.fieldLength > 0)\\n #if(column.fieldPrecision != null && column.fieldPrecision > 0)\\n @ValidatorLenMax(#(column.fieldLength+column.fieldPrecision))\\n #else\\n @ValidatorLenMax(#(column.fieldLength))\\n #end\\n #end\\n ### 日期处理\\n #if(column.javaType == \\\"Date\\\")\\n #if(column.showType == \\\"4\\\")\\n @JsonFormat(timezone = \\\"GMT+8\\\", pattern = \\\"yyyy-MM-dd\\\")\\n @DateTimeFormat(pattern = \\\"yyyy-MM-dd\\\")\\n #else\\n @JsonFormat(timezone = \\\"GMT+8\\\", pattern = \\\"yyyy-MM-dd HH:mm:ss\\\")\\n @DateTimeFormat(pattern = \\\"yyyy-MM-dd HH:mm:ss\\\")\\n #end\\n #end\\n private #(column.javaType) #(column.fieldHumpName);\\n\\n #end\\n #end\\n\\n\\n}\"},{\"fileName\":\"${model.tableHumpName}RestApi.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"org/opsli/api/web/${moduleName}/${subModuleName}\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(apiPath).web.#(data.moduleName+\\\".\\\"+data.subModuleName);\\n#else\\npackage #(apiPath).web.#(data.moduleName);\\n#end\\n\\nimport #(apiPath).base.result.ResultVo;\\nimport org.springframework.web.bind.annotation.GetMapping;\\nimport org.springframework.web.bind.annotation.PostMapping;\\nimport org.springframework.web.bind.annotation.RequestBody;\\nimport org.springframework.web.bind.annotation.RequestParam;\\nimport org.springframework.web.multipart.MultipartHttpServletRequest;\\nimport javax.servlet.http.HttpServletRequest;\\nimport javax.servlet.http.HttpServletResponse;\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)Model;\\n#else\\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\\n#end\\n\\n\\n/**\\n * #(data.codeTitle) Api\\n *\\n * 对外 API 直接 暴露 @GetMapping 或者 @PostMapping\\n * 对内也推荐 单机版 不需要设置 Mapping 但是调用方法得从Controller写起\\n *\\n * 这样写法虽然比较绕,但是当单体项目想要改造微服务架构时 时非常容易的\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\npublic interface #(data.model.tableHumpName)RestApi {\\n\\n /** 标题 */\\n String TITLE = \\\"#(data.codeTitle)\\\";\\n /** 子标题 */\\n String SUB_TITLE = \\\"#(data.codeTitleBrief)\\\";\\n\\n /**\\n * #(data.codeTitle) 查一条\\n * @param model 模型\\n * @return ResultVo\\n */\\n @GetMapping(\\\"/get\\\")\\n ResultVo<#(data.model.tableHumpName)Model> get(#(data.model.tableHumpName)Model model);\\n\\n /**\\n * #(data.codeTitle) 查询分页\\n * @param pageNo 当前页\\n * @param pageSize 每页条数\\n * @param request request\\n * @return ResultVo\\n */\\n @GetMapping(\\\"/findPage\\\")\\n ResultVo findPage(\\n @RequestParam(name = \\\"pageNo\\\", defaultValue = \\\"1\\\") Integer pageNo,\\n @RequestParam(name = \\\"pageSize\\\", defaultValue = \\\"10\\\") Integer pageSize,\\n HttpServletRequest request\\n );\\n\\n /**\\n * #(data.codeTitle) 新增\\n * @param model 模型\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/insert\\\")\\n ResultVo insert(@RequestBody #(data.model.tableHumpName)Model model);\\n\\n /**\\n * #(data.codeTitle) 修改\\n * @param model 模型\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/update\\\")\\n ResultVo update(@RequestBody #(data.model.tableHumpName)Model model);\\n\\n /**\\n * #(data.codeTitle) 删除\\n * @param id ID\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/del\\\")\\n ResultVo del(String id);\\n\\n /**\\n * #(data.codeTitle) 批量删除\\n * @param ids ID 数组\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/delAll\\\")\\n ResultVo delAll(String ids);\\n\\n /**\\n * #(data.codeTitle) Excel 导出\\n *\\n * 导出时,Token认证和方法权限认证 全部都由自定义完成\\n * 因为在 导出不成功时,需要推送错误信息,\\n * 前端直接走下载流,当失败时无法获得失败信息,即使前后端换一种方式后端推送二进制文件前端再次解析也是最少2倍的耗时\\n * ,且如果数据量过大,前端进行渲染时直接会把浏览器卡死\\n * 而直接开启socket接口推送显然是太过浪费资源了,所以目前采用Java最原始的手段\\n * response 推送 javascript代码 alert 提示报错信息\\n *\\n * @param request request\\n * @param response response\\n */\\n @GetMapping(\\\"/exportExcel\\\")\\n void exportExcel(HttpServletRequest request, HttpServletResponse response);\\n\\n /**\\n * #(data.codeTitle) Excel 导入\\n * @param request 文件流 request\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/importExcel\\\")\\n ResultVo importExcel(MultipartHttpServletRequest request);\\n\\n /**\\n * #(data.codeTitle) Excel 下载导入模版\\n * @param response response\\n */\\n @GetMapping(\\\"/importExcel/template\\\")\\n void importTemplate(HttpServletResponse response);\\n\\n}\"},{\"fileName\":\"${model.tableHumpName}RestController.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/web\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).web;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).web;\\n#end\\n\\nimport cn.hutool.core.util.ReflectUtil;\\nimport cn.hutool.core.convert.Convert;\\nimport io.swagger.annotations.Api;\\nimport io.swagger.annotations.ApiOperation;\\nimport lombok.extern.slf4j.Slf4j;\\nimport org.opsli.common.annotation.RequiresPermissionsCus;\\nimport org.apache.shiro.authz.annotation.RequiresPermissions;\\nimport #(apiPath).base.result.ResultVo;\\nimport org.opsli.common.annotation.ApiRestController;\\nimport org.opsli.common.annotation.EnableLog;\\nimport org.opsli.core.base.controller.BaseRestController;\\nimport org.opsli.core.persistence.Page;\\nimport org.opsli.core.persistence.querybuilder.QueryBuilder;\\nimport org.opsli.core.persistence.querybuilder.WebQueryBuilder;\\nimport org.springframework.web.multipart.MultipartHttpServletRequest;\\nimport javax.servlet.http.HttpServletRequest;\\nimport javax.servlet.http.HttpServletResponse;\\nimport java.lang.reflect.Method;\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)Model;\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).service.I#(data.model.tableHumpName)Service;\\nimport #(apiPath).web.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)RestApi;\\n#else\\nimport #(data.packageName+\\\".\\\"+data.moduleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\\nimport #(data.packageName+\\\".\\\"+data.moduleName).service.I#(data.model.tableHumpName)Service;\\nimport #(apiPath).web.#(data.moduleName).#(data.model.tableHumpName)RestApi;\\n#end\\n\\n/**\\n * #(data.codeTitle) Controller\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\n@Api(tags = #(data.model.tableHumpName)RestApi.TITLE)\\n@Slf4j\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n@ApiRestController(\\\"/#(data.moduleName)/#(data.subModuleName)\\\")\\n#else\\n@ApiRestController(\\\"/#(data.moduleName)\\\")\\n#end\\npublic class #(data.model.tableHumpName)RestController extends BaseRestController<#(data.model.tableHumpName), #(data.model.tableHumpName)Model, I#(data.model.tableHumpName)Service>\\n implements #(data.model.tableHumpName)RestApi {\\n\\n\\n /**\\n * #(data.codeTitleBrief) 查一条\\n * @param model 模型\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"获得单条#(data.codeTitleBrief)\\\", notes = \\\"获得单条#(data.codeTitleBrief) - ID\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_select\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_select\\\")\\n #end\\n @Override\\n public ResultVo<#(data.model.tableHumpName)Model> get(#(data.model.tableHumpName)Model model) {\\n // 如果系统内部调用 则直接查数据库\\n if(model != null && model.getIzApi() != null && model.getIzApi()){\\n model = IService.get(model);\\n }\\n return ResultVo.success(model);\\n }\\n\\n /**\\n * #(data.codeTitleBrief) 查询分页\\n * @param pageNo 当前页\\n * @param pageSize 每页条数\\n * @param request request\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"获得分页数据\\\", notes = \\\"获得分页数据 - 查询构造器\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_select\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_select\\\")\\n #end\\n @Override\\n public ResultVo findPage(Integer pageNo, Integer pageSize, HttpServletRequest request) {\\n\\n QueryBuilder<#(data.model.tableHumpName)> queryBuilder = new WebQueryBuilder<>(entityClazz, request.getParameterMap());\\n Page<#(data.model.tableHumpName), #(data.model.tableHumpName)Model> page = new Page<>(pageNo, pageSize);\\n page.setQueryWrapper(queryBuilder.build());\\n page = IService.findPage(page);\\n\\n return ResultVo.success(page.getPageData());\\n }\\n\\n /**\\n * #(data.codeTitleBrief) 新增\\n * @param model 模型\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"新增#(data.codeTitleBrief)数据\\\", notes = \\\"新增#(data.codeTitleBrief)数据\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_insert\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_insert\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo insert(#(data.model.tableHumpName)Model model) {\\n // 调用新增方法\\n IService.insert(model);\\n return ResultVo.success(\\\"新增#(data.codeTitleBrief)成功\\\");\\n }\\n\\n /**\\n * #(data.codeTitleBrief) 修改\\n * @param model 模型\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"修改#(data.codeTitleBrief)数据\\\", notes = \\\"修改#(data.codeTitleBrief)数据\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_update\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_update\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo update(#(data.model.tableHumpName)Model model) {\\n // 调用修改方法\\n IService.update(model);\\n return ResultVo.success(\\\"修改#(data.codeTitleBrief)成功\\\");\\n }\\n\\n\\n /**\\n * #(data.codeTitleBrief) 删除\\n * @param id ID\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"删除#(data.codeTitleBrief)数据\\\", notes = \\\"删除#(data.codeTitleBrief)数据\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_update\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_update\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo del(String id){\\n IService.delete(id);\\n return ResultVo.success(\\\"删除#(data.codeTitleBrief)成功\\\");\\n }\\n\\n /**\\n * #(data.codeTitleBrief) 批量删除\\n * @param ids ID 数组\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"批量删除#(data.codeTitleBrief)数据\\\", notes = \\\"批量删除#(data.codeTitleBrief)数据\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_update\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_update\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo delAll(String ids){\\n String[] idArray = Convert.toStrArray(ids);\\n IService.deleteAll(idArray);\\n return ResultVo.success(\\\"批量删除#(data.codeTitleBrief)成功\\\");\\n }\\n\\n\\n /**\\n * #(data.codeTitleBrief) Excel 导出\\n * 注:这里 RequiresPermissionsCus 引入的是 自定义鉴权注解\\n *\\n * 导出时,Token认证和方法权限认证 全部都由自定义完成\\n * 因为在 导出不成功时,需要推送错误信息,\\n * 前端直接走下载流,当失败时无法获得失败信息,即使前后端换一种方式后端推送二进制文件前端再次解析也是最少2倍的耗时\\n * ,且如果数据量过大,前端进行渲染时直接会把浏览器卡死\\n * 而直接开启socket接口推送显然是太过浪费资源了,所以目前采用Java最原始的手段\\n * response 推送 javascript代码 alert 提示报错信息\\n *\\n * @param request request\\n * @param response response\\n */\\n @ApiOperation(value = \\\"导出Excel\\\", notes = \\\"导出Excel\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissionsCus(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_export\\\")\\n #else\\n @RequiresPermissionsCus(\\\"#(data.moduleName.toLowerCase())_export\\\")\\n #end\\n @EnableLog\\n @Override\\n public void exportExcel(HttpServletRequest request, HttpServletResponse response) {\\n // 当前方法\\n Method method = ReflectUtil.getMethodByName(this.getClass(), \\\"exportExcel\\\");\\n QueryBuilder<#(data.model.tableHumpName)> queryBuilder = new WebQueryBuilder<>(entityClazz, request.getParameterMap());\\n super.excelExport(#(data.model.tableHumpName)RestApi.SUB_TITLE, queryBuilder.build(), response, method);\\n }\\n\\n /**\\n * #(data.codeTitleBrief) Excel 导入\\n * 注:这里 RequiresPermissions 引入的是 Shiro原生鉴权注解\\n * @param request 文件流 request\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"导入Excel\\\", notes = \\\"导入Excel\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_import\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_import\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo importExcel(MultipartHttpServletRequest request) {\\n return super.importExcel(request);\\n }\\n\\n /**\\n * #(data.codeTitleBrief) Excel 下载导入模版\\n * 注:这里 RequiresPermissionsCus 引入的是 自定义鉴权注解\\n * @param response response\\n */\\n @ApiOperation(value = \\\"导出Excel模版\\\", notes = \\\"导出Excel模版\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissionsCus(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_import\\\")\\n #else\\n @RequiresPermissionsCus(\\\"#(data.moduleName.toLowerCase())_import\\\")\\n #end\\n @Override\\n public void importTemplate(HttpServletResponse response) {\\n // 当前方法\\n Method method = ReflectUtil.getMethodByName(this.getClass(), \\\"importTemplate\\\");\\n super.importTemplate(#(data.model.tableHumpName)RestApi.SUB_TITLE, response, method);\\n }\\n\\n}\"},{\"fileName\":\"${model.tableHumpName}Service.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/service\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).service;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).service;\\n#end\\n\\nimport org.opsli.core.base.service.interfaces.CrudServiceInterface;\\n\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)Model;\\n#else\\nimport #(data.packageName+\\\".\\\"+data.moduleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\\n#end\\n\\n/**\\n * #(data.codeTitle) Service\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\npublic interface I#(data.model.tableHumpName)Service extends CrudServiceInterface<#(data.model.tableHumpName), #(data.model.tableHumpName)Model> {\\n\\n}\"},{\"fileName\":\"${model.tableHumpName}ServiceImpl.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/service/impl\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).service.impl;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).service.impl;\\n#end\\n\\n\\nimport org.springframework.beans.factory.annotation.Autowired;\\nimport org.springframework.stereotype.Service;\\nimport org.springframework.transaction.annotation.Transactional;\\nimport org.opsli.core.base.service.impl.CrudServiceImpl;\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)Model;\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).service.I#(data.model.tableHumpName)Service;\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).mapper.#(data.model.tableHumpName)Mapper;\\n#else\\nimport #(data.packageName+\\\".\\\"+data.moduleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\\nimport #(data.packageName+\\\".\\\"+data.moduleName).service.I#(data.model.tableHumpName)Service;\\nimport #(data.packageName+\\\".\\\"+data.moduleName).mapper.#(data.model.tableHumpName)Mapper;\\n#end\\n\\n\\n/**\\n * #(data.codeTitle) Service Impl\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\n@Service\\npublic class #(data.model.tableHumpName)ServiceImpl extends CrudServiceImpl<#(data.model.tableHumpName)Mapper, #(data.model.tableHumpName), #(data.model.tableHumpName)Model>\\n implements I#(data.model.tableHumpName)Service {\\n\\n @Autowired(required = false)\\n private #(data.model.tableHumpName)Mapper mapper;\\n\\n}\"},{\"fileName\":\"${model.tableHumpName}ManagementApi.js\",\"izApi\":false,\"type\":\"1\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"src/api/${moduleName}/${subModuleName}\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"import request from \\\"@/utils/request\\\";\\nimport {downloadFileByData} from \\\"@/utils/download\\\";\\n\\nexport function getList(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/findPage\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/findPage\\\",\\n #end\\n method: \\\"get\\\",\\n params: data,\\n });\\n}\\n\\n\\nexport function doInsert(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/insert\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/insert\\\",\\n #end\\n method: \\\"post\\\",\\n data,\\n });\\n}\\n\\nexport function doUpdate(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/update\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/update\\\",\\n #end\\n method: \\\"post\\\",\\n data,\\n });\\n}\\n\\nexport function doDelete(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/del\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/del\\\",\\n #end\\n method: \\\"post\\\",\\n params: data,\\n });\\n}\\n\\nexport function doDeleteAll(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/delAll\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/delAll\\\",\\n #end\\n method: \\\"post\\\",\\n params: data,\\n });\\n}\\n\\n\\n/**\\n* 导出Excel 目前只支持一层参数传递\\n* @param data\\n* @returns file\\n*/\\nexport function doExportExcel(data) {\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n let requestURL = \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/exportExcel\\\";\\n #else\\n let requestURL = \\\"/api/v1/#(data.moduleName)/exportExcel\\\";\\n #end\\n // 下载文件\\n downloadFileByData(requestURL, data);\\n}\\n\\n\\n/**\\n* 下载模版\\n* @returns file\\n*/\\nexport function doDownloadTemplate() {\\n let data = {};\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n let requestURL = \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/importExcel/template\\\";\\n #else\\n let requestURL = \\\"/api/v1/#(data.moduleName)/importExcel/template\\\";\\n #end\\n // 下载文件\\n downloadFileByData(requestURL, data);\\n}\\n\\n/**\\n* 导入Excel\\n* @returns file\\n*/\\nexport function doImportExcel(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/importExcel\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/importExcel\\\",\\n #end\\n method: \\\"post\\\",\\n // 最长超时时间 3 分钟\\n timeout: 180000,\\n headers: {\\n \\\"Content-Type\\\": \\\"multipart/form-data\\\"\\n },\\n data,\\n });\\n}\\n\\n\\n\"},{\"fileName\":\"${model.tableHumpName}ManagementEdit.vue\",\"izApi\":false,\"type\":\"1\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"src/views/modules/${moduleName}/${subModuleName}/components\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"\\n\\n\\n\"},{\"fileName\":\"${model.tableHumpName}ManagementImport.vue\",\"izApi\":false,\"type\":\"1\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"src/views/modules/${moduleName}/${subModuleName}/components\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"\\n\\n\\n\"},{\"fileName\":\"index.vue\",\"izApi\":false,\"type\":\"1\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"src/views/modules/${moduleName}/${subModuleName}\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"\\n\\n\\n\"}],\"id\":\"1398253704724828162\"}]', NULL, 0, 1313694379541635074, '2021-06-02 16:39:09', 1313694379541635074, '2021-06-02 16:39:09', '2021-06-02 16:39:08'); +INSERT INTO `sys_logs` VALUES (1400009105178836993, '1', '开发工具-开发向导-代码生成器-生成', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/logs/create', 'GET', 55, '[{\"moduleName\":\"other\",\"izApi\":false,\"templateId\":\"1398253704724828162\",\"tableType\":\"\",\"createBy\":\"1313694379541635074\",\"izManual\":false,\"createTime\":1612948174000,\"authorName\":\"Parker\",\"encryptData\":\"null\",\"codeTitleBrief\":\"非对称加密\",\"codeTitle\":\"非对称加密管理\",\"tableId\":\"1359428685312028674\",\"packageName\":\"org.opsli.modulars.gentest\",\"id\":\"1359429290382323714\",\"subModuleName\":\"crypto\"},{\"request\":{\"request\":{\"request\":{},\"orgRequest\":{}},\"servletContext\":{},\"session\":{\"servletContext\":{},\"session\":{}},\"httpSessions\":false},\"response\":{\"response\":{},\"status\":200},\"context\":{}}]', NULL, 0, 1313694379541635074, '2021-06-02 16:39:16', 1313694379541635074, '2021-06-02 16:39:16', '2021-06-02 16:39:16'); +INSERT INTO `sys_logs` VALUES (1400024223732142082, '1', '开发工具-开发向导-代码生成器-生成', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/logs/create', 'GET', 266, '[{\"moduleName\":\"other\",\"izApi\":false,\"templateId\":\"1398253704724828162\",\"tableType\":\"\",\"createBy\":\"1313694379541635074\",\"izManual\":false,\"createTime\":1612948174000,\"authorName\":\"Parker\",\"encryptData\":\"null\",\"codeTitleBrief\":\"非对称加密\",\"codeTitle\":\"非对称加密管理\",\"tableId\":\"1359428685312028674\",\"packageName\":\"org.opsli.modulars.gentest\",\"id\":\"1359429290382323714\",\"subModuleName\":\"crypto\"},{\"request\":{\"request\":{\"request\":{},\"orgRequest\":{}},\"servletContext\":{},\"session\":{\"servletContext\":{},\"session\":{}},\"httpSessions\":false},\"response\":{\"response\":{},\"status\":200},\"context\":{}}]', NULL, 0, 1313694379541635074, '2021-06-02 17:39:21', 1313694379541635074, '2021-06-02 17:39:21', '2021-06-02 17:39:20'); +INSERT INTO `sys_logs` VALUES (1400025109703303170, '1', '开发工具-开发向导-代码生成器-生成', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/logs/create', 'GET', 775, '[{\"moduleName\":\"other\",\"izApi\":false,\"templateId\":\"1398253704724828162\",\"tableType\":\"\",\"createBy\":\"1313694379541635074\",\"izManual\":false,\"createTime\":1612948174000,\"authorName\":\"Parker\",\"encryptData\":\"null\",\"codeTitleBrief\":\"非对称加密\",\"codeTitle\":\"非对称加密管理\",\"tableId\":\"1359428685312028674\",\"packageName\":\"org.opsli.modulars.gentest\",\"id\":\"1359429290382323714\",\"subModuleName\":\"crypto\"},{\"request\":{\"request\":{\"request\":{},\"orgRequest\":{}},\"servletContext\":{},\"session\":{\"servletContext\":{},\"session\":{}},\"httpSessions\":false},\"response\":{\"response\":{},\"status\":200},\"context\":{}}]', NULL, 0, 1313694379541635074, '2021-06-02 17:42:52', 1313694379541635074, '2021-06-02 17:42:52', '2021-06-02 17:42:52'); +INSERT INTO `sys_logs` VALUES (1400025354856177665, '1', '开发工具-开发向导-代码生成器-生成', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/logs/create', 'GET', 92, '[{\"moduleName\":\"other\",\"izApi\":false,\"templateId\":\"1398253704724828162\",\"tableType\":\"\",\"createBy\":\"1313694379541635074\",\"izManual\":false,\"createTime\":1612948174000,\"authorName\":\"Parker\",\"encryptData\":\"null\",\"codeTitleBrief\":\"非对称加密\",\"codeTitle\":\"非对称加密管理\",\"tableId\":\"1359428685312028674\",\"packageName\":\"org.opsli.modulars.gentest\",\"id\":\"1359429290382323714\",\"subModuleName\":\"crypto\"},{\"request\":{\"request\":{\"request\":{},\"orgRequest\":{}},\"servletContext\":{},\"session\":{\"servletContext\":{},\"session\":{}},\"httpSessions\":false},\"response\":{\"response\":{},\"status\":200},\"context\":{}}]', NULL, 0, 1313694379541635074, '2021-06-02 17:43:50', 1313694379541635074, '2021-06-02 17:43:50', '2021-06-02 17:43:50'); +INSERT INTO `sys_logs` VALUES (1400025714199080962, '1', '开发工具-开发向导-代码生成器-生成', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/logs/create', 'GET', 228, '[{\"moduleName\":\"other\",\"izApi\":false,\"templateId\":\"1398253704724828162\",\"tableType\":\"\",\"createBy\":\"1313694379541635074\",\"izManual\":false,\"createTime\":1612948174000,\"authorName\":\"Parker\",\"encryptData\":\"null\",\"codeTitleBrief\":\"非对称加密\",\"codeTitle\":\"非对称加密管理\",\"tableId\":\"1359428685312028674\",\"packageName\":\"org.opsli.modulars.gentest\",\"id\":\"1359429290382323714\",\"subModuleName\":\"crypto\"},{\"request\":{\"request\":{\"request\":{},\"orgRequest\":{}},\"servletContext\":{},\"session\":{\"servletContext\":{},\"session\":{}},\"httpSessions\":false},\"response\":{\"response\":{},\"status\":200},\"context\":{}}]', NULL, 0, 1313694379541635074, '2021-06-02 17:45:16', 1313694379541635074, '2021-06-02 17:45:16', '2021-06-02 17:45:16'); +INSERT INTO `sys_logs` VALUES (1400027052928614402, '1', '开发工具-开发向导-代码生成器-生成', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/logs/create', 'GET', 34260, '[{\"moduleName\":\"other\",\"izApi\":false,\"templateId\":\"1398253704724828162\",\"tableType\":\"\",\"createBy\":\"1313694379541635074\",\"izManual\":false,\"createTime\":1612948174000,\"authorName\":\"Parker\",\"encryptData\":\"null\",\"codeTitleBrief\":\"非对称加密\",\"codeTitle\":\"非对称加密管理\",\"tableId\":\"1359428685312028674\",\"packageName\":\"org.opsli.modulars.gentest\",\"id\":\"1359429290382323714\",\"subModuleName\":\"crypto\"},{\"request\":{\"request\":{\"request\":{},\"orgRequest\":{}},\"servletContext\":{},\"session\":{\"servletContext\":{},\"session\":{}},\"httpSessions\":false},\"response\":{\"response\":{},\"status\":200},\"context\":{}}]', NULL, 0, 1313694379541635074, '2021-06-02 17:50:35', 1313694379541635074, '2021-06-02 17:50:35', '2021-06-02 17:50:35'); +INSERT INTO `sys_logs` VALUES (1400028334192017409, '1', '开发工具-开发向导-代码生成器-生成', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/logs/create', 'GET', 173, '[{\"moduleName\":\"other\",\"izApi\":false,\"templateId\":\"1398253704724828162\",\"tableType\":\"\",\"createBy\":\"1313694379541635074\",\"izManual\":false,\"createTime\":1612948174000,\"authorName\":\"Parker\",\"encryptData\":\"null\",\"codeTitleBrief\":\"非对称加密\",\"codeTitle\":\"非对称加密管理\",\"tableId\":\"1359428685312028674\",\"packageName\":\"org.opsli.modulars.gentest\",\"id\":\"1359429290382323714\",\"subModuleName\":\"crypto\"},{\"request\":{\"request\":{\"request\":{},\"orgRequest\":{}},\"servletContext\":{},\"session\":{\"servletContext\":{},\"session\":{}},\"httpSessions\":false},\"response\":{\"response\":{},\"status\":200},\"context\":{}}]', NULL, 0, 1313694379541635074, '2021-06-02 17:55:41', 1313694379541635074, '2021-06-02 17:55:41', '2021-06-02 17:55:40'); +INSERT INTO `sys_logs` VALUES (1400028800351158274, '1', '开发工具-开发向导-代码生成器-生成', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/logs/create', 'GET', 68, '[{\"moduleName\":\"other\",\"izApi\":false,\"templateId\":\"1398253704724828162\",\"tableType\":\"\",\"createBy\":\"1313694379541635074\",\"izManual\":false,\"createTime\":1612948174000,\"authorName\":\"Parker\",\"encryptData\":\"null\",\"codeTitleBrief\":\"非对称加密\",\"codeTitle\":\"非对称加密管理\",\"tableId\":\"1359428685312028674\",\"packageName\":\"org.opsli.modulars.gentest\",\"id\":\"1359429290382323714\",\"subModuleName\":\"crypto\"},{\"request\":{\"request\":{\"request\":{},\"orgRequest\":{}},\"servletContext\":{},\"session\":{\"servletContext\":{},\"session\":{}},\"httpSessions\":false},\"response\":{\"response\":{},\"status\":200},\"context\":{}}]', NULL, 0, 1313694379541635074, '2021-06-02 17:57:32', 1313694379541635074, '2021-06-02 17:57:32', '2021-06-02 17:57:31'); +INSERT INTO `sys_logs` VALUES (1400029687303847937, '1', '开发工具-开发向导-代码模板-修改', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/template/updateAndDetail', 'POST', 353, '[{\"izApi\":false,\"remark\":\"\",\"updateTime\":1622623148000,\"version\":29,\"tableType\":\"0\",\"tempName\":\"Form表单\",\"createBy\":\"1313694379541635074\",\"izManual\":false,\"createTime\":1622204636000,\"updateBy\":\"1313694379541635074\",\"detailList\":[{\"fileName\":\"${model.tableHumpName}Entity.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/entity\",\"izManual\":false,\"ignoreFileName\":\"1\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).entity;\\n#end\\n\\n#for(pkg : data.model.entityPkgList)\\nimport #(pkg);\\n#end\\nimport com.baomidou.mybatisplus.annotation.FieldStrategy;\\nimport com.baomidou.mybatisplus.annotation.TableField;\\nimport com.baomidou.mybatisplus.annotation.TableLogic;\\nimport lombok.Data;\\nimport lombok.EqualsAndHashCode;\\nimport org.opsli.core.base.entity.BaseEntity;\\n\\n/**\\n * #(data.codeTitle) Entity\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\n@Data\\n@EqualsAndHashCode(callSuper = false)\\npublic class #(data.model.tableHumpName) extends BaseEntity {\\n\\n\\n #for(column : data.model.columnList)\\n ### 不等于 删除字段 和 不等于 租户字段放入上边\\n #if(column.fieldHumpName != \\\"deleted\\\" && column.fieldHumpName != \\\"tenantId\\\")\\n /** #(column.fieldComments) */\\n #if(!column.izNotNull)\\n @TableField(updateStrategy = FieldStrategy.IGNORED)\\n #end\\n private #(column.javaType) #(column.fieldHumpName);\\n\\n #end\\n #end\\n\\n // ========================================\\n\\n ### 专门处理 删除字段 和 租户字段\\n #for(column : data.model.columnList)\\n #if(column.fieldHumpName == \\\"deleted\\\")\\n /** 逻辑删除字段 */\\n @TableLogic\\n private Integer deleted;\\n #else if(column.fieldHumpName == \\\"tenantId\\\")\\n /** 多租户字段 */\\n private String tenantId;\\n #end\\n\\n #end\\n\\n}\"},{\"fileName\":\"${model.tableHumpName}Mapper.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/mapper\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).mapper;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).mapper;\\n#end\\n\\nimport com.baomidou.mybatisplus.core.mapper.BaseMapper;\\nimport org.apache.ibatis.annotations.Mapper;\\nimport org.apache.ibatis.annotations.Param;\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity.#(data.model.tableHumpName);\\n#else\\nimport #(data.packageName+\\\".\\\"+data.moduleName).entity.#(data.model.tableHumpName);\\n#end\\n\\n/**\\n * #(data.codeTitle) Mapper\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\n@Mapper\\npublic interface #(data.model.tableHumpName)Mapper extends BaseMapper<#(data.model.tableHumpName)> {\\n\\n}\"},{\"fileName\":\"${model.tableHumpName}Mapper.xml\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/mapper/xml\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n\\n#else\\n\\n#end\\n\\n\\n\"},{\"fileName\":\"${model.tableHumpName}Model.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"org/opsli/api/wrapper/${moduleName}/${subModuleName}\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName);\\n#else\\npackage #(apiPath).wrapper.#(data.moduleName);\\n#end\\n\\n#for(pkg : data.model.entityPkgList)\\nimport #(pkg);\\n#end\\nimport com.alibaba.excel.annotation.ExcelProperty;\\nimport io.swagger.annotations.ApiModelProperty;\\nimport lombok.Data;\\nimport lombok.EqualsAndHashCode;\\nimport #(apiPath).base.warpper.ApiWrapper;\\nimport org.opsli.common.annotation.validator.Validator;\\nimport org.opsli.common.annotation.validator.ValidatorLenMax;\\nimport org.opsli.common.annotation.validator.ValidatorLenMin;\\nimport org.opsli.common.enums.ValidatorType;\\nimport org.opsli.plugins.excel.annotation.ExcelInfo;\\nimport com.fasterxml.jackson.annotation.JsonFormat;\\nimport org.springframework.format.annotation.DateTimeFormat;\\n\\n/**\\n* #(data.codeTitle) Model\\n*\\n* @author #(data.authorName)\\n* @date #(currTime)\\n*/\\n@Data\\n@EqualsAndHashCode(callSuper = false)\\npublic class #(data.model.tableHumpName)Model extends ApiWrapper {\\n\\n #for(column : data.model.columnList)\\n ### 不等于 删除字段 和 不等于 租户字段放入上边\\n #if(column.fieldHumpName != \\\"deleted\\\" && column.fieldHumpName != \\\"tenantId\\\")\\n /** #(column.fieldComments) */\\n @ApiModelProperty(value = \\\"#(column.fieldComments)\\\")\\n @ExcelProperty(value = \\\"#(column.fieldComments)\\\", order = #(column.sort))\\n #if(column.dictTypeCode != null && column.dictTypeCode != \\\"\\\")\\n @ExcelInfo( dictType = \\\"#(column.dictTypeCode)\\\" )\\n #else\\n @ExcelInfo\\n #end\\n #if(column.validateTypeAndCommaList != null && column.validateTypeAndCommaList.size() > 0)\\n @Validator({\\n #for(typeAndComma : column.validateTypeAndCommaList)\\n ValidatorType.#(typeAndComma)\\n #end\\n })\\n #end\\n #if(column.fieldLength != null && column.fieldLength > 0)\\n #if(column.fieldPrecision != null && column.fieldPrecision > 0)\\n @ValidatorLenMax(#(column.fieldLength+column.fieldPrecision))\\n #else\\n @ValidatorLenMax(#(column.fieldLength))\\n #end\\n #end\\n ### 日期处理\\n #if(column.javaType == \\\"Date\\\")\\n #if(column.showType == \\\"4\\\")\\n @JsonFormat(timezone = \\\"GMT+8\\\", pattern = \\\"yyyy-MM-dd\\\")\\n @DateTimeFormat(pattern = \\\"yyyy-MM-dd\\\")\\n #else\\n @JsonFormat(timezone = \\\"GMT+8\\\", pattern = \\\"yyyy-MM-dd HH:mm:ss\\\")\\n @DateTimeFormat(pattern = \\\"yyyy-MM-dd HH:mm:ss\\\")\\n #end\\n #end\\n private #(column.javaType) #(column.fieldHumpName);\\n\\n #end\\n #end\\n\\n\\n}\"},{\"fileName\":\"${model.tableHumpName}RestApi.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"org/opsli/api/web/${moduleName}/${subModuleName}\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(apiPath).web.#(data.moduleName+\\\".\\\"+data.subModuleName);\\n#else\\npackage #(apiPath).web.#(data.moduleName);\\n#end\\n\\nimport #(apiPath).base.result.ResultVo;\\nimport org.springframework.web.bind.annotation.GetMapping;\\nimport org.springframework.web.bind.annotation.PostMapping;\\nimport org.springframework.web.bind.annotation.RequestBody;\\nimport org.springframework.web.bind.annotation.RequestParam;\\nimport org.springframework.web.multipart.MultipartHttpServletRequest;\\nimport javax.servlet.http.HttpServletRequest;\\nimport javax.servlet.http.HttpServletResponse;\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)Model;\\n#else\\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\\n#end\\n\\n\\n/**\\n * #(data.codeTitle) Api\\n *\\n * 对外 API 直接 暴露 @GetMapping 或者 @PostMapping\\n * 对内也推荐 单机版 不需要设置 Mapping 但是调用方法得从Controller写起\\n *\\n * 这样写法虽然比较绕,但是当单体项目想要改造微服务架构时 时非常容易的\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\npublic interface #(data.model.tableHumpName)RestApi {\\n\\n /** 标题 */\\n String TITLE = \\\"#(data.codeTitle)\\\";\\n /** 子标题 */\\n String SUB_TITLE = \\\"#(data.codeTitleBrief)\\\";\\n\\n /**\\n * #(data.codeTitle) 查一条\\n * @param model 模型\\n * @return ResultVo\\n */\\n @GetMapping(\\\"/get\\\")\\n ResultVo<#(data.model.tableHumpName)Model> get(#(data.model.tableHumpName)Model model);\\n\\n /**\\n * #(data.codeTitle) 查询分页\\n * @param pageNo 当前页\\n * @param pageSize 每页条数\\n * @param request request\\n * @return ResultVo\\n */\\n @GetMapping(\\\"/findPage\\\")\\n ResultVo findPage(\\n @RequestParam(name = \\\"pageNo\\\", defaultValue = \\\"1\\\") Integer pageNo,\\n @RequestParam(name = \\\"pageSize\\\", defaultValue = \\\"10\\\") Integer pageSize,\\n HttpServletRequest request\\n );\\n\\n /**\\n * #(data.codeTitle) 新增\\n * @param model 模型\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/insert\\\")\\n ResultVo insert(@RequestBody #(data.model.tableHumpName)Model model);\\n\\n /**\\n * #(data.codeTitle) 修改\\n * @param model 模型\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/update\\\")\\n ResultVo update(@RequestBody #(data.model.tableHumpName)Model model);\\n\\n /**\\n * #(data.codeTitle) 删除\\n * @param id ID\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/del\\\")\\n ResultVo del(String id);\\n\\n /**\\n * #(data.codeTitle) 批量删除\\n * @param ids ID 数组\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/delAll\\\")\\n ResultVo delAll(String ids);\\n\\n /**\\n * #(data.codeTitle) Excel 导出\\n *\\n * 导出时,Token认证和方法权限认证 全部都由自定义完成\\n * 因为在 导出不成功时,需要推送错误信息,\\n * 前端直接走下载流,当失败时无法获得失败信息,即使前后端换一种方式后端推送二进制文件前端再次解析也是最少2倍的耗时\\n * ,且如果数据量过大,前端进行渲染时直接会把浏览器卡死\\n * 而直接开启socket接口推送显然是太过浪费资源了,所以目前采用Java最原始的手段\\n * response 推送 javascript代码 alert 提示报错信息\\n *\\n * @param request request\\n * @param response response\\n */\\n @GetMapping(\\\"/exportExcel\\\")\\n void exportExcel(HttpServletRequest request, HttpServletResponse response);\\n\\n /**\\n * #(data.codeTitle) Excel 导入\\n * @param request 文件流 request\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/importExcel\\\")\\n ResultVo importExcel(MultipartHttpServletRequest request);\\n\\n /**\\n * #(data.codeTitle) Excel 下载导入模版\\n * @param response response\\n */\\n @GetMapping(\\\"/importExcel/template\\\")\\n void importTemplate(HttpServletResponse response);\\n\\n}\"},{\"fileName\":\"${model.tableHumpName}RestController.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/web\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).web;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).web;\\n#end\\n\\nimport cn.hutool.core.util.ReflectUtil;\\nimport cn.hutool.core.convert.Convert;\\nimport io.swagger.annotations.Api;\\nimport io.swagger.annotations.ApiOperation;\\nimport lombok.extern.slf4j.Slf4j;\\nimport org.opsli.common.annotation.RequiresPermissionsCus;\\nimport org.apache.shiro.authz.annotation.RequiresPermissions;\\nimport #(apiPath).base.result.ResultVo;\\nimport org.opsli.common.annotation.ApiRestController;\\nimport org.opsli.common.annotation.EnableLog;\\nimport org.opsli.core.base.controller.BaseRestController;\\nimport org.opsli.core.persistence.Page;\\nimport org.opsli.core.persistence.querybuilder.QueryBuilder;\\nimport org.opsli.core.persistence.querybuilder.WebQueryBuilder;\\nimport org.springframework.web.multipart.MultipartHttpServletRequest;\\nimport javax.servlet.http.HttpServletRequest;\\nimport javax.servlet.http.HttpServletResponse;\\nimport java.lang.reflect.Method;\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)Model;\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).service.I#(data.model.tableHumpName)Service;\\nimport #(apiPath).web.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)RestApi;\\n#else\\nimport #(data.packageName+\\\".\\\"+data.moduleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\\nimport #(data.packageName+\\\".\\\"+data.moduleName).service.I#(data.model.tableHumpName)Service;\\nimport #(apiPath).web.#(data.moduleName).#(data.model.tableHumpName)RestApi;\\n#end\\n\\n/**\\n * #(data.codeTitle) Controller\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\n@Api(tags = #(data.model.tableHumpName)RestApi.TITLE)\\n@Slf4j\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n@ApiRestController(\\\"/#(data.moduleName)/#(data.subModuleName)\\\")\\n#else\\n@ApiRestController(\\\"/#(data.moduleName)\\\")\\n#end\\npublic class #(data.model.tableHumpName)RestController extends BaseRestController<#(data.model.tableHumpName), #(data.model.tableHumpName)Model, I#(data.model.tableHumpName)Service>\\n implements #(data.model.tableHumpName)RestApi {\\n\\n\\n /**\\n * #(data.codeTitleBrief) 查一条\\n * @param model 模型\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"获得单条#(data.codeTitleBrief)\\\", notes = \\\"获得单条#(data.codeTitleBrief) - ID\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_select\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_select\\\")\\n #end\\n @Override\\n public ResultVo<#(data.model.tableHumpName)Model> get(#(data.model.tableHumpName)Model model) {\\n // 如果系统内部调用 则直接查数据库\\n if(model != null && model.getIzApi() != null && model.getIzApi()){\\n model = IService.get(model);\\n }\\n return ResultVo.success(model);\\n }\\n\\n /**\\n * #(data.codeTitleBrief) 查询分页\\n * @param pageNo 当前页\\n * @param pageSize 每页条数\\n * @param request request\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"获得分页数据\\\", notes = \\\"获得分页数据 - 查询构造器\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_select\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_select\\\")\\n #end\\n @Override\\n public ResultVo findPage(Integer pageNo, Integer pageSize, HttpServletRequest request) {\\n\\n QueryBuilder<#(data.model.tableHumpName)> queryBuilder = new WebQueryBuilder<>(entityClazz, request.getParameterMap());\\n Page<#(data.model.tableHumpName), #(data.model.tableHumpName)Model> page = new Page<>(pageNo, pageSize);\\n page.setQueryWrapper(queryBuilder.build());\\n page = IService.findPage(page);\\n\\n return ResultVo.success(page.getPageData());\\n }\\n\\n /**\\n * #(data.codeTitleBrief) 新增\\n * @param model 模型\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"新增#(data.codeTitleBrief)数据\\\", notes = \\\"新增#(data.codeTitleBrief)数据\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_insert\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_insert\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo insert(#(data.model.tableHumpName)Model model) {\\n // 调用新增方法\\n IService.insert(model);\\n return ResultVo.success(\\\"新增#(data.codeTitleBrief)成功\\\");\\n }\\n\\n /**\\n * #(data.codeTitleBrief) 修改\\n * @param model 模型\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"修改#(data.codeTitleBrief)数据\\\", notes = \\\"修改#(data.codeTitleBrief)数据\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_update\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_update\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo update(#(data.model.tableHumpName)Model model) {\\n // 调用修改方法\\n IService.update(model);\\n return ResultVo.success(\\\"修改#(data.codeTitleBrief)成功\\\");\\n }\\n\\n\\n /**\\n * #(data.codeTitleBrief) 删除\\n * @param id ID\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"删除#(data.codeTitleBrief)数据\\\", notes = \\\"删除#(data.codeTitleBrief)数据\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_update\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_update\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo del(String id){\\n IService.delete(id);\\n return ResultVo.success(\\\"删除#(data.codeTitleBrief)成功\\\");\\n }\\n\\n /**\\n * #(data.codeTitleBrief) 批量删除\\n * @param ids ID 数组\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"批量删除#(data.codeTitleBrief)数据\\\", notes = \\\"批量删除#(data.codeTitleBrief)数据\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_update\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_update\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo delAll(String ids){\\n String[] idArray = Convert.toStrArray(ids);\\n IService.deleteAll(idArray);\\n return ResultVo.success(\\\"批量删除#(data.codeTitleBrief)成功\\\");\\n }\\n\\n\\n /**\\n * #(data.codeTitleBrief) Excel 导出\\n * 注:这里 RequiresPermissionsCus 引入的是 自定义鉴权注解\\n *\\n * 导出时,Token认证和方法权限认证 全部都由自定义完成\\n * 因为在 导出不成功时,需要推送错误信息,\\n * 前端直接走下载流,当失败时无法获得失败信息,即使前后端换一种方式后端推送二进制文件前端再次解析也是最少2倍的耗时\\n * ,且如果数据量过大,前端进行渲染时直接会把浏览器卡死\\n * 而直接开启socket接口推送显然是太过浪费资源了,所以目前采用Java最原始的手段\\n * response 推送 javascript代码 alert 提示报错信息\\n *\\n * @param request request\\n * @param response response\\n */\\n @ApiOperation(value = \\\"导出Excel\\\", notes = \\\"导出Excel\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissionsCus(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_export\\\")\\n #else\\n @RequiresPermissionsCus(\\\"#(data.moduleName.toLowerCase())_export\\\")\\n #end\\n @EnableLog\\n @Override\\n public void exportExcel(HttpServletRequest request, HttpServletResponse response) {\\n // 当前方法\\n Method method = ReflectUtil.getMethodByName(this.getClass(), \\\"exportExcel\\\");\\n QueryBuilder<#(data.model.tableHumpName)> queryBuilder = new WebQueryBuilder<>(entityClazz, request.getParameterMap());\\n super.excelExport(#(data.model.tableHumpName)RestApi.SUB_TITLE, queryBuilder.build(), response, method);\\n }\\n\\n /**\\n * #(data.codeTitleBrief) Excel 导入\\n * 注:这里 RequiresPermissions 引入的是 Shiro原生鉴权注解\\n * @param request 文件流 request\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"导入Excel\\\", notes = \\\"导入Excel\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_import\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_import\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo importExcel(MultipartHttpServletRequest request) {\\n return super.importExcel(request);\\n }\\n\\n /**\\n * #(data.codeTitleBrief) Excel 下载导入模版\\n * 注:这里 RequiresPermissionsCus 引入的是 自定义鉴权注解\\n * @param response response\\n */\\n @ApiOperation(value = \\\"导出Excel模版\\\", notes = \\\"导出Excel模版\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissionsCus(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_import\\\")\\n #else\\n @RequiresPermissionsCus(\\\"#(data.moduleName.toLowerCase())_import\\\")\\n #end\\n @Override\\n public void importTemplate(HttpServletResponse response) {\\n // 当前方法\\n Method method = ReflectUtil.getMethodByName(this.getClass(), \\\"importTemplate\\\");\\n super.importTemplate(#(data.model.tableHumpName)RestApi.SUB_TITLE, response, method);\\n }\\n\\n}\"},{\"fileName\":\"${model.tableHumpName}ServiceImpl.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/service/impl\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).service.impl;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).service.impl;\\n#end\\n\\n\\nimport org.springframework.beans.factory.annotation.Autowired;\\nimport org.springframework.stereotype.Service;\\nimport org.springframework.transaction.annotation.Transactional;\\nimport org.opsli.core.base.service.impl.CrudServiceImpl;\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)Model;\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).service.I#(data.model.tableHumpName)Service;\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).mapper.#(data.model.tableHumpName)Mapper;\\n#else\\nimport #(data.packageName+\\\".\\\"+data.moduleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\\nimport #(data.packageName+\\\".\\\"+data.moduleName).service.I#(data.model.tableHumpName)Service;\\nimport #(data.packageName+\\\".\\\"+data.moduleName).mapper.#(data.model.tableHumpName)Mapper;\\n#end\\n\\n\\n/**\\n * #(data.codeTitle) Service Impl\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\n@Service\\npublic class #(data.model.tableHumpName)ServiceImpl extends CrudServiceImpl<#(data.model.tableHumpName)Mapper, #(data.model.tableHumpName), #(data.model.tableHumpName)Model>\\n implements I#(data.model.tableHumpName)Service {\\n\\n @Autowired(required = false)\\n private #(data.model.tableHumpName)Mapper mapper;\\n\\n}\"},{\"fileName\":\"I${model.tableHumpName}Service.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/service\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).service;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).service;\\n#end\\n\\nimport org.opsli.core.base.service.interfaces.CrudServiceInterface;\\n\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)Model;\\n#else\\nimport #(data.packageName+\\\".\\\"+data.moduleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\\n#end\\n\\n/**\\n * #(data.codeTitle) Service\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\npublic interface I#(data.model.tableHumpName)Service extends CrudServiceInterface<#(data.model.tableHumpName), #(data.model.tableHumpName)Model> {\\n\\n}\"},{\"fileName\":\"${model.tableHumpName}ManagementApi.js\",\"izApi\":false,\"type\":\"1\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"src/api/${moduleName}/${subModuleName}\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"import request from \\\"@/utils/request\\\";\\nimport { downloadFileByData } from \\\"@/utils/download\\\";\\n\\nexport function getList(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/findPage\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/findPage\\\",\\n #end\\n method: \\\"get\\\",\\n params: data,\\n });\\n}\\n\\nexport function doInsert(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/insert\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/insert\\\",\\n #end\\n method: \\\"post\\\",\\n data,\\n });\\n}\\n\\nexport function doUpdate(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/update\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/update\\\",\\n #end\\n method: \\\"post\\\",\\n data,\\n });\\n}\\n\\nexport function doDelete(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/del\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/del\\\",\\n #end\\n method: \\\"post\\\",\\n params: data,\\n });\\n}\\n\\nexport function doDeleteAll(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/delAll\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/delAll\\\",\\n #end\\n method: \\\"post\\\",\\n params: data,\\n });\\n}\\n\\n/**\\n * 导出Excel 目前只支持一层参数传递\\n * @param data\\n * @returns file\\n */\\nexport function doExportExcel(data) {\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n let requestURL = \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/exportExcel\\\";\\n #else\\n let requestURL = \\\"/api/v1/#(data.moduleName)/exportExcel\\\";\\n #end\\n // 下载文件\\n downloadFileByData(requestURL, data);\\n}\\n\\n/**\\n * 下载模版\\n * @returns file\\n */\\nexport function doDownloadTemplate() {\\n let data = {};\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n let requestURL = \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/importExcel/template\\\";\\n #else\\n let requestURL = \\\"/api/v1/#(data.moduleName)/importExcel/template\\\";\\n #end\\n // 下载文件\\n downloadFileByData(requestURL, data);\\n}\\n\\n/**\\n * 导入Excel\\n * @returns file\\n */\\nexport function doImportExcel(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/importExcel\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/importExcel\\\",\\n #end\\n method: \\\"post\\\",\\n // 最长超时时间 3 分钟\\n timeout: 180000,\\n headers: {\\n \\\"Content-Type\\\": \\\"multipart/form-data\\\"\\n },\\n data,\\n });\\n}\"},{\"fileName\":\"${model.tableHumpName}ManagementEdit.vue\",\"izApi\":false,\"type\":\"1\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"src/views/modules/${moduleName}/${subModuleName}/components\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"\\n\\n\\n\"},{\"fileName\":\"${model.tableHumpName}ManagementImport.vue\",\"izApi\":false,\"type\":\"1\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"src/views/modules/${moduleName}/${subModuleName}/components\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"\\n\\n\\n\"},{\"fileName\":\"index.vue\",\"izApi\":false,\"type\":\"1\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"src/views/modules/${moduleName}/${subModuleName}\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"\\n\\n\\n\"}],\"id\":\"1398253704724828162\"}]', NULL, 0, 1313694379541635074, '2021-06-02 18:01:03', 1313694379541635074, '2021-06-02 18:01:03', '2021-06-02 18:01:03'); +INSERT INTO `sys_logs` VALUES (1400031877565194241, '1', '开发工具-开发向导-代码生成器-生成菜单', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/logs/createMenu', 'POST', 132, '[\"1327085543511293954\",\"1359428685312028674\"]', NULL, 0, 1, '2021-06-02 18:09:46', 1, '2021-06-02 18:09:46', '2021-06-02 18:09:45'); +INSERT INTO `sys_logs` VALUES (1400033648089894913, '1', '开发工具-开发向导-代码生成器-同步', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/table/sync', 'POST', 339, '[\"1359428685312028674\"]', NULL, 0, 1, '2021-06-02 18:16:48', 1, '2021-06-02 18:16:48', '2021-06-02 18:16:47'); +INSERT INTO `sys_logs` VALUES (1400037855320797185, '1', '开发工具-开发向导-代码生成器-生成', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/logs/create', 'GET', 476, '[{\"moduleName\":\"other\",\"izApi\":false,\"templateId\":\"1398253704724828162\",\"tableType\":\"\",\"createBy\":\"1313694379541635074\",\"izManual\":false,\"createTime\":1612948174000,\"authorName\":\"Parker\",\"encryptData\":\"null\",\"codeTitleBrief\":\"非对称加密\",\"codeTitle\":\"非对称加密管理\",\"tableId\":\"1359428685312028674\",\"packageName\":\"org.opsli.modulars.gentest\",\"id\":\"1359429290382323714\",\"subModuleName\":\"crypto\"},{\"request\":{\"request\":{\"request\":{},\"orgRequest\":{}},\"servletContext\":{},\"session\":{\"servletContext\":{},\"session\":{}},\"httpSessions\":false},\"response\":{\"response\":{},\"status\":200},\"context\":{}}]', NULL, 0, 1, '2021-06-02 18:33:31', 1, '2021-06-02 18:33:31', '2021-06-02 18:33:30'); +INSERT INTO `sys_logs` VALUES (1400314104723243009, '1', '开发工具-开发向导-代码模板-修改', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/generator/template/updateAndDetail', 'POST', 657, '[{\"izApi\":false,\"remark\":\"默认Form表单\",\"updateTime\":1622628063000,\"version\":30,\"tableType\":\"0\",\"tempName\":\"Form表单\",\"createBy\":\"1313694379541635074\",\"izManual\":false,\"createTime\":1622204636000,\"updateBy\":\"1313694379541635074\",\"detailList\":[{\"fileName\":\"${model.tableHumpName}Entity.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/entity\",\"izManual\":false,\"ignoreFileName\":\"1\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).entity;\\n#end\\n\\n#for(pkg : data.model.entityPkgList)\\nimport #(pkg);\\n#end\\nimport com.baomidou.mybatisplus.annotation.FieldStrategy;\\nimport com.baomidou.mybatisplus.annotation.TableField;\\nimport com.baomidou.mybatisplus.annotation.TableLogic;\\nimport lombok.Data;\\nimport lombok.EqualsAndHashCode;\\nimport org.opsli.core.base.entity.BaseEntity;\\n\\n/**\\n * #(data.codeTitle) Entity\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\n@Data\\n@EqualsAndHashCode(callSuper = false)\\npublic class #(data.model.tableHumpName) extends BaseEntity {\\n\\n\\n #for(column : data.model.columnList)\\n ### 不等于 删除字段 和 不等于 租户字段放入上边\\n #if(column.fieldHumpName != \\\"deleted\\\" && column.fieldHumpName != \\\"tenantId\\\")\\n /** #(column.fieldComments) */\\n #if(!column.izNotNull)\\n @TableField(updateStrategy = FieldStrategy.IGNORED)\\n #end\\n private #(column.javaType) #(column.fieldHumpName);\\n\\n #end\\n #end\\n\\n // ========================================\\n\\n ### 专门处理 删除字段 和 租户字段\\n #for(column : data.model.columnList)\\n #if(column.fieldHumpName == \\\"deleted\\\")\\n /** 逻辑删除字段 */\\n @TableLogic\\n private Integer deleted;\\n #else if(column.fieldHumpName == \\\"tenantId\\\")\\n /** 多租户字段 */\\n private String tenantId;\\n #end\\n\\n #end\\n\\n}\"},{\"fileName\":\"${model.tableHumpName}Mapper.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/mapper\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).mapper;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).mapper;\\n#end\\n\\nimport com.baomidou.mybatisplus.core.mapper.BaseMapper;\\nimport org.apache.ibatis.annotations.Mapper;\\nimport org.apache.ibatis.annotations.Param;\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity.#(data.model.tableHumpName);\\n#else\\nimport #(data.packageName+\\\".\\\"+data.moduleName).entity.#(data.model.tableHumpName);\\n#end\\n\\n/**\\n * #(data.codeTitle) Mapper\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\n@Mapper\\npublic interface #(data.model.tableHumpName)Mapper extends BaseMapper<#(data.model.tableHumpName)> {\\n\\n}\"},{\"fileName\":\"${model.tableHumpName}Mapper.xml\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/mapper/xml\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n\\n#else\\n\\n#end\\n\\n\\n\"},{\"fileName\":\"${model.tableHumpName}Model.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"org/opsli/api/wrapper/${moduleName}/${subModuleName}\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName);\\n#else\\npackage #(apiPath).wrapper.#(data.moduleName);\\n#end\\n\\n#for(pkg : data.model.entityPkgList)\\nimport #(pkg);\\n#end\\nimport com.alibaba.excel.annotation.ExcelProperty;\\nimport io.swagger.annotations.ApiModelProperty;\\nimport lombok.Data;\\nimport lombok.EqualsAndHashCode;\\nimport #(apiPath).base.warpper.ApiWrapper;\\nimport org.opsli.common.annotation.validator.Validator;\\nimport org.opsli.common.annotation.validator.ValidatorLenMax;\\nimport org.opsli.common.annotation.validator.ValidatorLenMin;\\nimport org.opsli.common.enums.ValidatorType;\\nimport org.opsli.plugins.excel.annotation.ExcelInfo;\\nimport com.fasterxml.jackson.annotation.JsonFormat;\\nimport org.springframework.format.annotation.DateTimeFormat;\\n\\n/**\\n* #(data.codeTitle) Model\\n*\\n* @author #(data.authorName)\\n* @date #(currTime)\\n*/\\n@Data\\n@EqualsAndHashCode(callSuper = false)\\npublic class #(data.model.tableHumpName)Model extends ApiWrapper {\\n\\n #for(column : data.model.columnList)\\n ### 不等于 删除字段 和 不等于 租户字段放入上边\\n #if(column.fieldHumpName != \\\"deleted\\\" && column.fieldHumpName != \\\"tenantId\\\")\\n /** #(column.fieldComments) */\\n @ApiModelProperty(value = \\\"#(column.fieldComments)\\\")\\n @ExcelProperty(value = \\\"#(column.fieldComments)\\\", order = #(column.sort))\\n #if(column.dictTypeCode != null && column.dictTypeCode != \\\"\\\")\\n @ExcelInfo( dictType = \\\"#(column.dictTypeCode)\\\" )\\n #else\\n @ExcelInfo\\n #end\\n #if(column.validateTypeAndCommaList != null && column.validateTypeAndCommaList.size() > 0)\\n @Validator({\\n #for(typeAndComma : column.validateTypeAndCommaList)\\n ValidatorType.#(typeAndComma)\\n #end\\n })\\n #end\\n #if(column.fieldLength != null && column.fieldLength > 0)\\n #if(column.fieldPrecision != null && column.fieldPrecision > 0)\\n @ValidatorLenMax(#(column.fieldLength+column.fieldPrecision))\\n #else\\n @ValidatorLenMax(#(column.fieldLength))\\n #end\\n #end\\n ### 日期处理\\n #if(column.javaType == \\\"Date\\\")\\n #if(column.showType == \\\"4\\\")\\n @JsonFormat(timezone = \\\"GMT+8\\\", pattern = \\\"yyyy-MM-dd\\\")\\n @DateTimeFormat(pattern = \\\"yyyy-MM-dd\\\")\\n #else\\n @JsonFormat(timezone = \\\"GMT+8\\\", pattern = \\\"yyyy-MM-dd HH:mm:ss\\\")\\n @DateTimeFormat(pattern = \\\"yyyy-MM-dd HH:mm:ss\\\")\\n #end\\n #end\\n private #(column.javaType) #(column.fieldHumpName);\\n\\n #end\\n #end\\n\\n\\n}\"},{\"fileName\":\"${model.tableHumpName}RestApi.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"org/opsli/api/web/${moduleName}/${subModuleName}\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(apiPath).web.#(data.moduleName+\\\".\\\"+data.subModuleName);\\n#else\\npackage #(apiPath).web.#(data.moduleName);\\n#end\\n\\nimport #(apiPath).base.result.ResultVo;\\nimport org.springframework.web.bind.annotation.GetMapping;\\nimport org.springframework.web.bind.annotation.PostMapping;\\nimport org.springframework.web.bind.annotation.RequestBody;\\nimport org.springframework.web.bind.annotation.RequestParam;\\nimport org.springframework.web.multipart.MultipartHttpServletRequest;\\nimport javax.servlet.http.HttpServletRequest;\\nimport javax.servlet.http.HttpServletResponse;\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)Model;\\n#else\\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\\n#end\\n\\n\\n/**\\n * #(data.codeTitle) Api\\n *\\n * 对外 API 直接 暴露 @GetMapping 或者 @PostMapping\\n * 对内也推荐 单机版 不需要设置 Mapping 但是调用方法得从Controller写起\\n *\\n * 这样写法虽然比较绕,但是当单体项目想要改造微服务架构时 时非常容易的\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\npublic interface #(data.model.tableHumpName)RestApi {\\n\\n /** 标题 */\\n String TITLE = \\\"#(data.codeTitle)\\\";\\n /** 子标题 */\\n String SUB_TITLE = \\\"#(data.codeTitleBrief)\\\";\\n\\n /**\\n * #(data.codeTitle) 查一条\\n * @param model 模型\\n * @return ResultVo\\n */\\n @GetMapping(\\\"/get\\\")\\n ResultVo<#(data.model.tableHumpName)Model> get(#(data.model.tableHumpName)Model model);\\n\\n /**\\n * #(data.codeTitle) 查询分页\\n * @param pageNo 当前页\\n * @param pageSize 每页条数\\n * @param request request\\n * @return ResultVo\\n */\\n @GetMapping(\\\"/findPage\\\")\\n ResultVo findPage(\\n @RequestParam(name = \\\"pageNo\\\", defaultValue = \\\"1\\\") Integer pageNo,\\n @RequestParam(name = \\\"pageSize\\\", defaultValue = \\\"10\\\") Integer pageSize,\\n HttpServletRequest request\\n );\\n\\n /**\\n * #(data.codeTitle) 新增\\n * @param model 模型\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/insert\\\")\\n ResultVo insert(@RequestBody #(data.model.tableHumpName)Model model);\\n\\n /**\\n * #(data.codeTitle) 修改\\n * @param model 模型\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/update\\\")\\n ResultVo update(@RequestBody #(data.model.tableHumpName)Model model);\\n\\n /**\\n * #(data.codeTitle) 删除\\n * @param id ID\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/del\\\")\\n ResultVo del(String id);\\n\\n /**\\n * #(data.codeTitle) 批量删除\\n * @param ids ID 数组\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/delAll\\\")\\n ResultVo delAll(String ids);\\n\\n /**\\n * #(data.codeTitle) Excel 导出\\n *\\n * 导出时,Token认证和方法权限认证 全部都由自定义完成\\n * 因为在 导出不成功时,需要推送错误信息,\\n * 前端直接走下载流,当失败时无法获得失败信息,即使前后端换一种方式后端推送二进制文件前端再次解析也是最少2倍的耗时\\n * ,且如果数据量过大,前端进行渲染时直接会把浏览器卡死\\n * 而直接开启socket接口推送显然是太过浪费资源了,所以目前采用Java最原始的手段\\n * response 推送 javascript代码 alert 提示报错信息\\n *\\n * @param request request\\n * @param response response\\n */\\n @GetMapping(\\\"/exportExcel\\\")\\n void exportExcel(HttpServletRequest request, HttpServletResponse response);\\n\\n /**\\n * #(data.codeTitle) Excel 导入\\n * @param request 文件流 request\\n * @return ResultVo\\n */\\n @PostMapping(\\\"/importExcel\\\")\\n ResultVo importExcel(MultipartHttpServletRequest request);\\n\\n /**\\n * #(data.codeTitle) Excel 下载导入模版\\n * @param response response\\n */\\n @GetMapping(\\\"/importExcel/template\\\")\\n void importTemplate(HttpServletResponse response);\\n\\n}\"},{\"fileName\":\"${model.tableHumpName}RestController.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/web\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).web;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).web;\\n#end\\n\\nimport cn.hutool.core.util.ReflectUtil;\\nimport cn.hutool.core.convert.Convert;\\nimport io.swagger.annotations.Api;\\nimport io.swagger.annotations.ApiOperation;\\nimport lombok.extern.slf4j.Slf4j;\\nimport org.opsli.common.annotation.RequiresPermissionsCus;\\nimport org.apache.shiro.authz.annotation.RequiresPermissions;\\nimport #(apiPath).base.result.ResultVo;\\nimport org.opsli.common.annotation.ApiRestController;\\nimport org.opsli.common.annotation.EnableLog;\\nimport org.opsli.core.base.controller.BaseRestController;\\nimport org.opsli.core.persistence.Page;\\nimport org.opsli.core.persistence.querybuilder.QueryBuilder;\\nimport org.opsli.core.persistence.querybuilder.WebQueryBuilder;\\nimport org.springframework.web.multipart.MultipartHttpServletRequest;\\nimport javax.servlet.http.HttpServletRequest;\\nimport javax.servlet.http.HttpServletResponse;\\nimport java.lang.reflect.Method;\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)Model;\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).service.I#(data.model.tableHumpName)Service;\\nimport #(apiPath).web.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)RestApi;\\n#else\\nimport #(data.packageName+\\\".\\\"+data.moduleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\\nimport #(data.packageName+\\\".\\\"+data.moduleName).service.I#(data.model.tableHumpName)Service;\\nimport #(apiPath).web.#(data.moduleName).#(data.model.tableHumpName)RestApi;\\n#end\\n\\n/**\\n * #(data.codeTitle) Controller\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\n@Api(tags = #(data.model.tableHumpName)RestApi.TITLE)\\n@Slf4j\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n@ApiRestController(\\\"/#(data.moduleName)/#(data.subModuleName)\\\")\\n#else\\n@ApiRestController(\\\"/#(data.moduleName)\\\")\\n#end\\npublic class #(data.model.tableHumpName)RestController extends BaseRestController<#(data.model.tableHumpName), #(data.model.tableHumpName)Model, I#(data.model.tableHumpName)Service>\\n implements #(data.model.tableHumpName)RestApi {\\n\\n\\n /**\\n * #(data.codeTitleBrief) 查一条\\n * @param model 模型\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"获得单条#(data.codeTitleBrief)\\\", notes = \\\"获得单条#(data.codeTitleBrief) - ID\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_select\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_select\\\")\\n #end\\n @Override\\n public ResultVo<#(data.model.tableHumpName)Model> get(#(data.model.tableHumpName)Model model) {\\n // 如果系统内部调用 则直接查数据库\\n if(model != null && model.getIzApi() != null && model.getIzApi()){\\n model = IService.get(model);\\n }\\n return ResultVo.success(model);\\n }\\n\\n /**\\n * #(data.codeTitleBrief) 查询分页\\n * @param pageNo 当前页\\n * @param pageSize 每页条数\\n * @param request request\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"获得分页数据\\\", notes = \\\"获得分页数据 - 查询构造器\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_select\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_select\\\")\\n #end\\n @Override\\n public ResultVo findPage(Integer pageNo, Integer pageSize, HttpServletRequest request) {\\n\\n QueryBuilder<#(data.model.tableHumpName)> queryBuilder = new WebQueryBuilder<>(entityClazz, request.getParameterMap());\\n Page<#(data.model.tableHumpName), #(data.model.tableHumpName)Model> page = new Page<>(pageNo, pageSize);\\n page.setQueryWrapper(queryBuilder.build());\\n page = IService.findPage(page);\\n\\n return ResultVo.success(page.getPageData());\\n }\\n\\n /**\\n * #(data.codeTitleBrief) 新增\\n * @param model 模型\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"新增#(data.codeTitleBrief)数据\\\", notes = \\\"新增#(data.codeTitleBrief)数据\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_insert\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_insert\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo insert(#(data.model.tableHumpName)Model model) {\\n // 调用新增方法\\n IService.insert(model);\\n return ResultVo.success(\\\"新增#(data.codeTitleBrief)成功\\\");\\n }\\n\\n /**\\n * #(data.codeTitleBrief) 修改\\n * @param model 模型\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"修改#(data.codeTitleBrief)数据\\\", notes = \\\"修改#(data.codeTitleBrief)数据\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_update\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_update\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo update(#(data.model.tableHumpName)Model model) {\\n // 调用修改方法\\n IService.update(model);\\n return ResultVo.success(\\\"修改#(data.codeTitleBrief)成功\\\");\\n }\\n\\n\\n /**\\n * #(data.codeTitleBrief) 删除\\n * @param id ID\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"删除#(data.codeTitleBrief)数据\\\", notes = \\\"删除#(data.codeTitleBrief)数据\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_update\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_update\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo del(String id){\\n IService.delete(id);\\n return ResultVo.success(\\\"删除#(data.codeTitleBrief)成功\\\");\\n }\\n\\n /**\\n * #(data.codeTitleBrief) 批量删除\\n * @param ids ID 数组\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"批量删除#(data.codeTitleBrief)数据\\\", notes = \\\"批量删除#(data.codeTitleBrief)数据\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_update\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_update\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo delAll(String ids){\\n String[] idArray = Convert.toStrArray(ids);\\n IService.deleteAll(idArray);\\n return ResultVo.success(\\\"批量删除#(data.codeTitleBrief)成功\\\");\\n }\\n\\n\\n /**\\n * #(data.codeTitleBrief) Excel 导出\\n * 注:这里 RequiresPermissionsCus 引入的是 自定义鉴权注解\\n *\\n * 导出时,Token认证和方法权限认证 全部都由自定义完成\\n * 因为在 导出不成功时,需要推送错误信息,\\n * 前端直接走下载流,当失败时无法获得失败信息,即使前后端换一种方式后端推送二进制文件前端再次解析也是最少2倍的耗时\\n * ,且如果数据量过大,前端进行渲染时直接会把浏览器卡死\\n * 而直接开启socket接口推送显然是太过浪费资源了,所以目前采用Java最原始的手段\\n * response 推送 javascript代码 alert 提示报错信息\\n *\\n * @param request request\\n * @param response response\\n */\\n @ApiOperation(value = \\\"导出Excel\\\", notes = \\\"导出Excel\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissionsCus(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_export\\\")\\n #else\\n @RequiresPermissionsCus(\\\"#(data.moduleName.toLowerCase())_export\\\")\\n #end\\n @EnableLog\\n @Override\\n public void exportExcel(HttpServletRequest request, HttpServletResponse response) {\\n // 当前方法\\n Method method = ReflectUtil.getMethodByName(this.getClass(), \\\"exportExcel\\\");\\n QueryBuilder<#(data.model.tableHumpName)> queryBuilder = new WebQueryBuilder<>(entityClazz, request.getParameterMap());\\n super.excelExport(#(data.model.tableHumpName)RestApi.SUB_TITLE, queryBuilder.build(), response, method);\\n }\\n\\n /**\\n * #(data.codeTitleBrief) Excel 导入\\n * 注:这里 RequiresPermissions 引入的是 Shiro原生鉴权注解\\n * @param request 文件流 request\\n * @return ResultVo\\n */\\n @ApiOperation(value = \\\"导入Excel\\\", notes = \\\"导入Excel\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_import\\\")\\n #else\\n @RequiresPermissions(\\\"#(data.moduleName.toLowerCase())_import\\\")\\n #end\\n @EnableLog\\n @Override\\n public ResultVo importExcel(MultipartHttpServletRequest request) {\\n return super.importExcel(request);\\n }\\n\\n /**\\n * #(data.codeTitleBrief) Excel 下载导入模版\\n * 注:这里 RequiresPermissionsCus 引入的是 自定义鉴权注解\\n * @param response response\\n */\\n @ApiOperation(value = \\\"导出Excel模版\\\", notes = \\\"导出Excel模版\\\")\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n @RequiresPermissionsCus(\\\"#(data.moduleName.toLowerCase())_#(data.subModuleName.toLowerCase())_import\\\")\\n #else\\n @RequiresPermissionsCus(\\\"#(data.moduleName.toLowerCase())_import\\\")\\n #end\\n @Override\\n public void importTemplate(HttpServletResponse response) {\\n // 当前方法\\n Method method = ReflectUtil.getMethodByName(this.getClass(), \\\"importTemplate\\\");\\n super.importTemplate(#(data.model.tableHumpName)RestApi.SUB_TITLE, response, method);\\n }\\n\\n}\"},{\"fileName\":\"${model.tableHumpName}ServiceImpl.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/service/impl\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).service.impl;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).service.impl;\\n#end\\n\\n\\nimport org.springframework.beans.factory.annotation.Autowired;\\nimport org.springframework.stereotype.Service;\\nimport org.springframework.transaction.annotation.Transactional;\\nimport org.opsli.core.base.service.impl.CrudServiceImpl;\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)Model;\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).service.I#(data.model.tableHumpName)Service;\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).mapper.#(data.model.tableHumpName)Mapper;\\n#else\\nimport #(data.packageName+\\\".\\\"+data.moduleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\\nimport #(data.packageName+\\\".\\\"+data.moduleName).service.I#(data.model.tableHumpName)Service;\\nimport #(data.packageName+\\\".\\\"+data.moduleName).mapper.#(data.model.tableHumpName)Mapper;\\n#end\\n\\n\\n/**\\n * #(data.codeTitle) Service Impl\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\n@Service\\npublic class #(data.model.tableHumpName)ServiceImpl extends CrudServiceImpl<#(data.model.tableHumpName)Mapper, #(data.model.tableHumpName), #(data.model.tableHumpName)Model>\\n implements I#(data.model.tableHumpName)Service {\\n\\n @Autowired(required = false)\\n private #(data.model.tableHumpName)Mapper mapper;\\n\\n}\"},{\"fileName\":\"I${model.tableHumpName}Service.java\",\"izApi\":false,\"type\":\"0\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"${packageName}/${moduleName}/${subModuleName}/service\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\npackage #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).service;\\n#else\\npackage #(data.packageName+\\\".\\\"+data.moduleName).service;\\n#end\\n\\nimport org.opsli.core.base.service.interfaces.CrudServiceInterface;\\n\\n\\n#if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\nimport #(data.packageName+\\\".\\\"+data.moduleName+\\\".\\\"+data.subModuleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName+\\\".\\\"+data.subModuleName).#(data.model.tableHumpName)Model;\\n#else\\nimport #(data.packageName+\\\".\\\"+data.moduleName).entity.#(data.model.tableHumpName);\\nimport #(apiPath).wrapper.#(data.moduleName).#(data.model.tableHumpName)Model;\\n#end\\n\\n/**\\n * #(data.codeTitle) Service\\n *\\n * @author #(data.authorName)\\n * @date #(currTime)\\n */\\npublic interface I#(data.model.tableHumpName)Service extends CrudServiceInterface<#(data.model.tableHumpName), #(data.model.tableHumpName)Model> {\\n\\n}\"},{\"fileName\":\"${model.tableHumpName}ManagementApi.js\",\"izApi\":false,\"type\":\"1\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"src/api/${moduleName}/${subModuleName}\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"import request from \\\"@/utils/request\\\";\\nimport { downloadFileByData } from \\\"@/utils/download\\\";\\n\\nexport function getList(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/findPage\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/findPage\\\",\\n #end\\n method: \\\"get\\\",\\n params: data,\\n });\\n}\\n\\nexport function doInsert(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/insert\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/insert\\\",\\n #end\\n method: \\\"post\\\",\\n data,\\n });\\n}\\n\\nexport function doUpdate(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/update\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/update\\\",\\n #end\\n method: \\\"post\\\",\\n data,\\n });\\n}\\n\\nexport function doDelete(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/del\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/del\\\",\\n #end\\n method: \\\"post\\\",\\n params: data,\\n });\\n}\\n\\nexport function doDeleteAll(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/delAll\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/delAll\\\",\\n #end\\n method: \\\"post\\\",\\n params: data,\\n });\\n}\\n\\n/**\\n * 导出Excel 目前只支持一层参数传递\\n * @param data\\n * @returns file\\n */\\nexport function doExportExcel(data) {\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n let requestURL = \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/exportExcel\\\";\\n #else\\n let requestURL = \\\"/api/v1/#(data.moduleName)/exportExcel\\\";\\n #end\\n // 下载文件\\n downloadFileByData(requestURL, data);\\n}\\n\\n/**\\n * 下载模版\\n * @returns file\\n */\\nexport function doDownloadTemplate() {\\n let data = {};\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n let requestURL = \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/importExcel/template\\\";\\n #else\\n let requestURL = \\\"/api/v1/#(data.moduleName)/importExcel/template\\\";\\n #end\\n // 下载文件\\n downloadFileByData(requestURL, data);\\n}\\n\\n/**\\n * 导入Excel\\n * @returns file\\n */\\nexport function doImportExcel(data) {\\n return request({\\n #if(data.subModuleName != null && data.subModuleName != \\\"\\\")\\n url: \\\"/api/v1/#(data.moduleName)/#(data.subModuleName)/importExcel\\\",\\n #else\\n url: \\\"/api/v1/#(data.moduleName)/importExcel\\\",\\n #end\\n method: \\\"post\\\",\\n // 最长超时时间 3 分钟\\n timeout: 180000,\\n headers: {\\n \\\"Content-Type\\\": \\\"multipart/form-data\\\"\\n },\\n data,\\n });\\n}\"},{\"fileName\":\"${model.tableHumpName}ManagementEdit.vue\",\"izApi\":false,\"type\":\"1\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"src/views/modules/${moduleName}/${subModuleName}/components\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"\\n\\n\\n\"},{\"fileName\":\"${model.tableHumpName}ManagementImport.vue\",\"izApi\":false,\"type\":\"1\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"src/views/modules/${moduleName}/${subModuleName}/components\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"\\n\\n\\n\"},{\"fileName\":\"index.vue\",\"izApi\":false,\"type\":\"1\",\"version\":0,\"parentId\":\"1398253704724828162\",\"path\":\"src/views/modules/${moduleName}/${subModuleName}\",\"izManual\":false,\"ignoreFileName\":\"0\",\"fileContent\":\"\\n\\n\\n\"}],\"id\":\"1398253704724828162\"}]', NULL, 0, 1313694379541635074, '2021-06-03 12:51:14', 1313694379541635074, '2021-06-03 12:51:14', '2021-06-03 12:51:13'); +INSERT INTO `sys_logs` VALUES (1400351840435908610, '1', '系统配置-系统设置-更新', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/system/options/updateOptions', 'POST', 148, '[{\"email_smtp\":\"smtp.qq.com\",\"email_addresser\":\"测试\",\"email_password\":\"fegwtupshtkwbeeb\",\"email_port\":\"465\",\"email_account\":\"meet.parker@foxmail.com\",\"email_ssl_enable\":\"1\"}]', NULL, 0, 1313694379541635074, '2021-06-03 15:21:11', 1313694379541635074, '2021-06-03 15:21:11', '2021-06-03 15:21:10'); +INSERT INTO `sys_logs` VALUES (1400399501289541634, '1', '系统配置-字典管理-增加', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/system/dict/detail/insert', 'POST', 119, '[{\"dictValue\":\"upYun\",\"izApi\":false,\"version\":0,\"typeCode\":\"storage_type\",\"sortNo\":2,\"izLock\":\"1\",\"izManual\":false,\"typeId\":\"1388562098925977601\",\"dictName\":\"又拍云\"}]', NULL, 0, 1, '2021-06-03 18:30:34', 1, '2021-06-03 18:30:34', '2021-06-03 18:30:33'); +INSERT INTO `sys_logs` VALUES (1400402255458291713, '1', '系统配置-系统设置-更新', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/system/options/updateOptions', 'POST', 56, '[{\"storage_upyun_path_prefix\":\"\",\"storage_upyun_password\":\"cG3dwy7mK26c4sC2PfoNK1ptvra4leh8\",\"storage_upyun_domain\":\"http://upload.bedebug.com\",\"storage_upyun_username\":\"opsli\",\"storage_upyun_bucket_name\":\"opsli-storage\"}]', NULL, 0, 1, '2021-06-03 18:41:31', 1, '2021-06-03 18:41:31', '2021-06-03 18:41:30'); +INSERT INTO `sys_logs` VALUES (1400402651169902594, '1', '系统配置-系统设置-更新', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/system/options/updateOptions', 'POST', 61, '[{\"storage_type\":\"upYun\",\"def_pass\":\"Aa123456\",\"def_role\":\"007\"}]', NULL, 0, 1, '2021-06-03 18:43:05', 1, '2021-06-03 18:43:05', '2021-06-03 18:43:04'); +INSERT INTO `sys_logs` VALUES (1400415870676606977, '1', '系统配置-系统设置-更新', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/system/options/updateOptions', 'POST', 162, '[{\"storage_upyun_path_prefix\":\"\",\"storage_upyun_password\":\"DjWrspmr4UbfBdnkrgm4ssCOVK7rUTXF\",\"storage_upyun_domain\":\"http://upload.bedebug.com\",\"storage_upyun_username\":\"opsli\",\"storage_upyun_bucket_name\":\"opsli-storage\"}]', NULL, 0, 1, '2021-06-03 19:35:37', 1, '2021-06-03 19:35:37', '2021-06-03 19:35:36'); +INSERT INTO `sys_logs` VALUES (1400418802977447937, '1', '系统配置-系统设置-更新', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/system/options/updateOptions', 'POST', 72, '[{\"storage_upyun_path_prefix\":\"/files\",\"storage_upyun_password\":\"DjWrspmr4UbfBdnkrgm4ssCOVK7rUTXF\",\"storage_upyun_domain\":\"http://upload.bedebug.com\",\"storage_upyun_username\":\"opsli\",\"storage_upyun_bucket_name\":\"opsli-storage\"}]', NULL, 0, 1, '2021-06-03 19:47:16', 1, '2021-06-03 19:47:16', '2021-06-03 19:47:15'); +INSERT INTO `sys_logs` VALUES (1400418951258677250, '1', '系统配置-系统设置-更新', '', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.212 Safari/537.36', '/opsli-boot/api/v1/system/options/updateOptions', 'POST', 58, '[{\"storage_upyun_path_prefix\":\"\",\"storage_upyun_password\":\"DjWrspmr4UbfBdnkrgm4ssCOVK7rUTXF\",\"storage_upyun_domain\":\"http://upload.bedebug.com\",\"storage_upyun_username\":\"opsli\",\"storage_upyun_bucket_name\":\"opsli-storage\"}]', NULL, 0, 1, '2021-06-03 19:47:51', 1, '2021-06-03 19:47:51', '2021-06-03 19:47:51'); -- ---------------------------- -- Table structure for sys_menu @@ -6353,6 +6388,13 @@ INSERT INTO `sys_menu` VALUES (1397807399439392770, 1397807399338729473, '删除 INSERT INTO `sys_menu` VALUES (1397807399456169985, 1397807399338729473, '导入', 'generator_template_import', NULL, '2', NULL, NULL, NULL, 5, '0', '0', '0', 0, 1, '2021-05-27 14:50:29', 1, '2021-05-27 14:50:29', '2021-05-27 14:50:28'); INSERT INTO `sys_menu` VALUES (1397807399481335810, 1397807399338729473, '导出', 'generator_template_export', NULL, '2', NULL, NULL, NULL, 6, '0', '0', '0', 0, 1, '2021-05-27 14:50:29', 1, '2021-05-27 14:50:29', '2021-05-27 14:50:28'); INSERT INTO `sys_menu` VALUES (1399667141430452225, 1397807399338729473, '复制', 'generator_template_copy', NULL, '2', NULL, NULL, NULL, 7, '0', '0', '0', 0, 1, '2021-06-01 18:00:26', 1, '2021-06-01 18:00:26', '2021-06-01 18:00:25'); +INSERT INTO `sys_menu` VALUES (1400031876927660034, 1327085543511293954, '非对称加密管理', NULL, NULL, '1', 'crypto', 'views/modules/other/crypto/index', NULL, 1, '0', '0', '0', 0, 1, '2021-06-02 18:09:45', 1, '2021-06-02 18:09:45', '2021-06-02 18:09:45'); +INSERT INTO `sys_menu` VALUES (1400031877045100546, 1400031876927660034, '查看', 'other_crypto_select', NULL, '2', NULL, NULL, NULL, 1, '0', '0', '0', 0, 1, '2021-06-02 18:09:45', 1, '2021-06-02 18:09:45', '2021-06-02 18:09:45'); +INSERT INTO `sys_menu` VALUES (1400031877108015105, 1400031876927660034, '新增', 'other_crypto_insert', NULL, '2', NULL, NULL, NULL, 2, '0', '0', '0', 0, 1, '2021-06-02 18:09:45', 1, '2021-06-02 18:09:45', '2021-06-02 18:09:45'); +INSERT INTO `sys_menu` VALUES (1400031877108015106, 1400031876927660034, '修改', 'other_crypto_update', NULL, '2', NULL, NULL, NULL, 3, '0', '0', '0', 0, 1, '2021-06-02 18:09:46', 1, '2021-06-02 18:09:46', '2021-06-02 18:09:45'); +INSERT INTO `sys_menu` VALUES (1400031877175123969, 1400031876927660034, '删除', 'other_crypto_delete', NULL, '2', NULL, NULL, NULL, 4, '0', '0', '0', 0, 1, '2021-06-02 18:09:46', 1, '2021-06-02 18:09:46', '2021-06-02 18:09:45'); +INSERT INTO `sys_menu` VALUES (1400031877175123970, 1400031876927660034, '导入', 'other_crypto_import', NULL, '2', NULL, NULL, NULL, 5, '0', '0', '0', 0, 1, '2021-06-02 18:09:46', 1, '2021-06-02 18:09:46', '2021-06-02 18:09:45'); +INSERT INTO `sys_menu` VALUES (1400031877250621442, 1400031876927660034, '导出', 'other_crypto_export', NULL, '2', NULL, NULL, NULL, 6, '0', '0', '0', 0, 1, '2021-06-02 18:09:46', 1, '2021-06-02 18:09:46', '2021-06-02 18:09:45'); -- ---------------------------- -- Table structure for sys_options @@ -6381,21 +6423,26 @@ CREATE TABLE `sys_options` ( INSERT INTO `sys_options` VALUES (1, 'crypto_asymmetric', '非对称加解密算法', 'RSA', '1', NULL, 0, 1, '2021-02-10 23:19:35', 1313694379541635074, '2021-04-04 11:19:26', '2021-04-29 11:11:40'); INSERT INTO `sys_options` VALUES (2, 'crypto_asymmetric_public_key', '非对称加解密-公钥', 'MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCQS75ZTYUL6IJJBgylgFDtksWZx4OsVK5CBJGXi3n9LON1Jg7KsxkgindCD28gQRIEh6ZP1IuhlMs9N/QteRbM3b1oDKW7Cbr7lFk+EYUmpO5nwD1+IHowiNc0AK+XfICOVF5287wE4LFLqBDnWhV0WNQFjYYpAc7852ZfEwThSQIDAQAB', '1', NULL, 0, 1, '2021-02-10 23:19:35', 1313694379541635074, '2021-04-04 11:19:26', '2021-04-29 11:11:41'); INSERT INTO `sys_options` VALUES (3, 'crypto_asymmetric_private_key', '非对称加解密-私钥', 'MIICdwIBADANBgkqhkiG9w0BAQEFAASCAmEwggJdAgEAAoGBAJBLvllNhQvogkkGDKWAUO2SxZnHg6xUrkIEkZeLef0s43UmDsqzGSCKd0IPbyBBEgSHpk/Ui6GUyz039C15FszdvWgMpbsJuvuUWT4RhSak7mfAPX4gejCI1zQAr5d8gI5UXnbzvATgsUuoEOdaFXRY1AWNhikBzvznZl8TBOFJAgMBAAECgYAJvtCmFi7RK6ysIxhBj6JnmTN24ltJpuJ2zpL8Sc0J+B+LyIk6z9CROqjS5L+PM+kN0BEmCedwTBNTf1VV3BXzbPcX/prE004LXcbv5mjgaHf/PybzJQumYM5MuD9dJYBLc1PUNu2b9eGekEU+vzn0HCnmAkfwU7FCdU7Nh8/ZnQJBAMkY/nzYxue0rdfD4ZybM8chBksp9EA8mwmCW/PosJGJ6YVJ913PbfovYuSG4rwm0Ew6i/1zcXvAFjt5dW+L5EsCQQC3sMq5EF4Bfils0dTdn8Pwtv2t3H6wwaAc9QAExHYtZ5pipFH9NXiWn6KUJYq28mRxxKtfoara/8Ahb5yHY0w7AkEArGnmfyno123cgppqC7gxW3AgEj+FL7IGhs+igOumvxFMCsBQ+rhGpXMNSbuwF/r7KfAkaAgbaytUpGdNXXbGIwJAas7uoXsl3iJYvgCokJFkYmRUzzJlrCt6CTxgXWVK/g2+1FqNnfjofFSoORI3PTdmNkzQBRRA/4Q0WHzIfGS9nwJBAMLXrVKH6uhn67dwXKRCy2Xt54dLEtL43jL+xzWeHJibSkSyImLiAn1n2imSpB6ubJnBuvH19Y0nOXKBP0+VDGA=', '1', NULL, 0, 1, '2021-02-10 23:19:35', 1313694379541635074, '2021-04-04 11:19:26', '2021-04-29 11:11:41'); -INSERT INTO `sys_options` VALUES (4, 'def_pass', '系统默认密码', 'Aa123456', '1', NULL, 0, 1, '2021-02-10 23:19:35', 1, '2021-04-09 21:09:36', '2021-04-29 11:11:42'); -INSERT INTO `sys_options` VALUES (5, 'def_role', '系统默认角色编号', '007', '1', NULL, 0, 1, '2021-02-10 23:19:35', 1, '2021-04-09 21:09:36', '2021-04-29 11:11:44'); -INSERT INTO `sys_options` VALUES (1387687830355902465, 'email_account', '邮箱账号', 'meet.parker@foxmail.com', '1', NULL, 38, 1, '2021-04-29 16:38:55', 1, '2021-04-29 21:39:20', '2021-04-29 21:39:19'); -INSERT INTO `sys_options` VALUES (1387687830523674626, 'email_password', '邮箱密码', 'xxxxxxxxxxx', '1', NULL, 38, 1, '2021-04-29 16:38:55', 1, '2021-04-29 21:39:20', '2021-04-29 21:39:20'); -INSERT INTO `sys_options` VALUES (1387687830586589186, 'email_addresser', '发件人', '测试', '1', NULL, 38, 1, '2021-04-29 16:38:55', 1, '2021-04-29 21:39:20', '2021-04-29 21:39:20'); -INSERT INTO `sys_options` VALUES (1387692123406348289, 'email_smtp', 'SMTP地址', 'smtp.qq.com', '1', NULL, 29, 1, '2021-04-29 16:55:59', 1, '2021-04-29 21:39:20', '2021-04-29 21:39:19'); -INSERT INTO `sys_options` VALUES (1387695264482865154, 'email_port', 'SMTP端口', '465', '1', NULL, 21, 1, '2021-04-29 17:08:28', 1, '2021-04-29 21:39:20', '2021-04-29 21:39:19'); -INSERT INTO `sys_options` VALUES (1387700400634605569, 'email_ssl_enable', '开启SSL认证', '1', '1', NULL, 17, 1313694379541635074, '2021-04-29 17:28:52', 1, '2021-04-29 21:39:20', '2021-04-29 21:39:19'); +INSERT INTO `sys_options` VALUES (4, 'def_pass', '系统默认密码', 'Aa123456', '1', NULL, 1, 1, '2021-02-10 23:19:35', 1, '2021-06-03 18:43:05', '2021-06-03 18:43:04'); +INSERT INTO `sys_options` VALUES (5, 'def_role', '系统默认角色编号', '007', '1', NULL, 1, 1, '2021-02-10 23:19:35', 1, '2021-06-03 18:43:05', '2021-06-03 18:43:04'); +INSERT INTO `sys_options` VALUES (1387687830355902465, 'email_account', '邮箱账号', 'meet.parker@foxmail.com', '1', NULL, 39, 1, '2021-04-29 16:38:55', 1313694379541635074, '2021-06-03 15:21:11', '2021-06-03 15:21:10'); +INSERT INTO `sys_options` VALUES (1387687830523674626, 'email_password', '邮箱密码', 'xxxxxxxxxxxxxxxxxxxx', '1', NULL, 39, 1, '2021-04-29 16:38:55', 1313694379541635074, '2021-06-03 15:21:11', '2021-06-03 15:21:10'); +INSERT INTO `sys_options` VALUES (1387687830586589186, 'email_addresser', '发件人', '测试', '1', NULL, 39, 1, '2021-04-29 16:38:55', 1313694379541635074, '2021-06-03 15:21:11', '2021-06-03 15:21:10'); +INSERT INTO `sys_options` VALUES (1387692123406348289, 'email_smtp', 'SMTP地址', 'smtp.qq.com', '1', NULL, 30, 1, '2021-04-29 16:55:59', 1313694379541635074, '2021-06-03 15:21:10', '2021-06-03 15:21:10'); +INSERT INTO `sys_options` VALUES (1387695264482865154, 'email_port', 'SMTP端口', '465', '1', NULL, 22, 1, '2021-04-29 17:08:28', 1313694379541635074, '2021-06-03 15:21:11', '2021-06-03 15:21:10'); +INSERT INTO `sys_options` VALUES (1387700400634605569, 'email_ssl_enable', '开启SSL认证', '1', '1', NULL, 18, 1313694379541635074, '2021-04-29 17:28:52', 1313694379541635074, '2021-06-03 15:21:11', '2021-06-03 15:21:10'); INSERT INTO `sys_options` VALUES (1388129689385472001, 'storage_local_domain', 'storage_local_domain', 'http://127.0.0.1:8080/opsli-boot', '1', NULL, 0, 1313694379541635074, '2021-04-30 21:54:43', 1313694379541635074, '2021-04-30 21:54:43', '2021-04-30 21:54:42'); INSERT INTO `sys_options` VALUES (1388129689523884033, 'storage_local_path_prefix', 'storage_local_path_prefix', '', '1', NULL, 0, 1313694379541635074, '2021-04-30 21:54:43', 1313694379541635074, '2021-04-30 21:54:43', '2021-04-30 21:54:42'); -INSERT INTO `sys_options` VALUES (1388327975470596098, 'storage_type', 'storage_type', 'local', '1', NULL, 0, 1313694379541635074, '2021-05-01 11:02:38', 1313694379541635074, '2021-05-01 11:02:38', '2021-05-11 10:57:44'); +INSERT INTO `sys_options` VALUES (1388327975470596098, 'storage_type', 'storage_type', 'upYun', '1', NULL, 1, 1313694379541635074, '2021-05-01 11:02:38', 1, '2021-06-03 18:43:05', '2021-06-03 18:43:04'); INSERT INTO `sys_options` VALUES (1388333266843320322, '11', '111', '111', '0', NULL, 0, 1313694379541635074, '2021-05-01 11:23:39', 1313694379541635074, '2021-05-01 11:23:39', '2021-05-01 11:23:39'); INSERT INTO `sys_options` VALUES (1388333321180528642, '222', '222', '222', '0', NULL, 0, 1313694379541635074, '2021-05-01 11:23:52', 1313694379541635074, '2021-05-01 11:23:52', '2021-05-01 11:23:52'); INSERT INTO `sys_options` VALUES (1388333452273500161, '333', '333', '333', '0', NULL, 0, 1313694379541635074, '2021-05-01 11:24:24', 1313694379541635074, '2021-05-01 11:24:24', '2021-05-01 11:24:23'); INSERT INTO `sys_options` VALUES (1388333500516384770, '444', '444', '444', '0', NULL, 0, 1313694379541635074, '2021-05-01 11:24:35', 1313694379541635074, '2021-05-01 11:24:35', '2021-05-01 11:24:35'); +INSERT INTO `sys_options` VALUES (1400402255261159426, 'storage_upyun_domain', 'storage_upyun_domain', 'http://upload.bedebug.com', '1', NULL, 3, 1, '2021-06-03 18:41:31', 1, '2021-06-03 19:47:51', '2021-06-03 19:47:51'); +INSERT INTO `sys_options` VALUES (1400402255261159427, 'storage_upyun_path_prefix', 'storage_upyun_path_prefix', '', '1', NULL, 3, 1, '2021-06-03 18:41:31', 1, '2021-06-03 19:47:51', '2021-06-03 19:47:51'); +INSERT INTO `sys_options` VALUES (1400402255328268290, 'storage_upyun_bucket_name', 'storage_upyun_bucket_name', 'opsli-storage', '1', NULL, 3, 1, '2021-06-03 18:41:31', 1, '2021-06-03 19:47:51', '2021-06-03 19:47:51'); +INSERT INTO `sys_options` VALUES (1400402255328268291, 'storage_upyun_username', 'storage_upyun_username', 'opsli', '1', NULL, 3, 1, '2021-06-03 18:41:31', 1, '2021-06-03 19:47:51', '2021-06-03 19:47:51'); +INSERT INTO `sys_options` VALUES (1400402255328268292, 'storage_upyun_password', 'storage_upyun_password', 'xxxxxxxxxxx', '1', NULL, 3, 1, '2021-06-03 18:41:31', 1, '2021-06-03 19:47:51', '2021-06-03 19:47:51'); -- ---------------------------- -- Table structure for sys_org @@ -6695,7 +6742,7 @@ CREATE TABLE `sys_user` ( -- ---------------------------- -- Records of sys_user -- ---------------------------- -INSERT INTO `sys_user` VALUES (1, 'system', '10b80e7442518fee52191617e602527a', '2', 'gu4ix7czy8g2x4xf5td7', '1', '超级管理员', '15321010110', '112', 'http://127.0.0.1:8080/opsli-boot/static/files/20210430/162056101700285193J6IAU.jpg', '', 'meet.parker@foxmail.com', '没有自学能力的人没有未来', '', 1315203865179602945, '0', 95, 1, '2020-09-25 15:03:22', 1, '2021-05-04 01:59:11', '2021-05-24 18:51:35'); +INSERT INTO `sys_user` VALUES (1, 'system', '10b80e7442518fee52191617e602527a', '2', 'gu4ix7czy8g2x4xf5td7', '1', '超级管理员', '15321010110', '112', 'http://upload.bedebug.com/20210603/162433012495676994QGGVX.jpg', '', 'meet.parker@foxmail.com', '没有自学能力的人没有未来', '', 1315203865179602945, '0', 95, 1, '2020-09-25 15:03:22', 1, '2021-05-04 01:59:11', '2021-06-03 19:48:02'); INSERT INTO `sys_user` VALUES (1313694379541635074, 'demo', 'cc6875215ef04072164bc81b9e2ce496', '2', '489e0bs6p7du02t8ij8t', '1', '演示用户', '15321010110', 'test_001', 'http://127.0.0.1:8080/opsli-boot/static/files/20210503/162030164596296168YISD4.jpg', '', 'meet.parker@foxmail.com', '没有自学能力的人没有未来', NULL, 1, '0', 2, 1, '2020-10-06 23:15:22', 1, '2020-10-11 16:53:58', '2021-05-24 18:50:29'); INSERT INTO `sys_user` VALUES (1315218541317750785, 'zhangsan', '386a1212b388a49d6cca827173824914', '1', 'g6880o4q5k98w6a6hplu', '1', '张三', NULL, '123123', NULL, '127.0.0.1', NULL, NULL, NULL, NULL, '0', 0, 1, '2020-10-11 17:11:50', 1, '2020-10-11 17:11:50', '2021-05-13 16:17:27'); INSERT INTO `sys_user` VALUES (1315224529580072961, 'test', '248b77e86f3137b0381e78a0050c8eab', '1', 'x93jqlq94e7bmludjzxm', '0', '123', NULL, '123123123', NULL, NULL, NULL, NULL, NULL, NULL, '1', 0, 1, '2020-10-11 17:35:38', 1, '2020-10-11 17:35:38', '2021-05-13 16:17:27');