log.info优化/pom version update

This commit is contained in:
MOSHOW郑锴 2021-01-17 23:54:05 +08:00
parent 7a4ee452eb
commit 7edeea0247
3 changed files with 6 additions and 8 deletions

View File

@ -7,10 +7,9 @@
<parent>
<groupId>com.softdev.system</groupId>
<artifactId>SpringBootCodeGenerator</artifactId>
<version>2.0</version>
<version>3.0</version>
</parent>
<groupId>com.softdev.system</groupId>
<artifactId>generator-web</artifactId>
<version>2.0</version>
<packaging>jar</packaging>

View File

@ -1,6 +1,5 @@
package com.softdev.system.generator.controller;
import com.alibaba.fastjson.JSON;
import com.softdev.system.generator.entity.ClassInfo;
import com.softdev.system.generator.entity.ParamInfo;
import com.softdev.system.generator.entity.ReturnT;
@ -15,6 +14,7 @@ import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.servlet.ModelAndView;
import java.util.Date;
import java.util.Map;
/**
@ -52,8 +52,7 @@ public class GeneratorController {
@PostMapping("/code/generate")
@ResponseBody
public ReturnT generateCode(@RequestBody ParamInfo paramInfo) throws Exception {
log.info(JSON.toJSONString(paramInfo));
//log.info(JSON.toJSONString(paramInfo.getOptions()));
if (StringUtils.isEmpty(paramInfo.getTableSql())) {
return ReturnT.error("表结构信息为空");
}
@ -85,7 +84,7 @@ public class GeneratorController {
//3.generate the code by freemarker templates with parameters . Freemarker根据参数和模板生成代码
Map<String, String> result = generatorService.getResultByParams(paramInfo.getOptions());
log.info("table:{} - time:{} ", MapUtil.getString(result,"tableName"),new Date());
return ReturnT.ok().put("outputJson",result);
}

View File

@ -5,7 +5,7 @@
<groupId>com.softdev.system</groupId>
<artifactId>SpringBootCodeGenerator</artifactId>
<version>2.0</version>
<version>3.0</version>
<packaging>pom</packaging>
<parent>