admin
2024-07-25 47e3087067abd35e6337c011f96d2338c0bb1aae
src/main/resources/generater/service/method/impl/mybatis/add.ftl
@@ -1,7 +1,7 @@
<#assign daoObjName="${dao.name?uncap_first}" >
<#assign entityObjName="${entity.name?uncap_first}" >
     if(bean.getCreateTime()==null){
        bean.setCreateTime(new Date());
     if(${entityObjName}.getCreateTime()==null){
        ${entityObjName}.setCreateTime(new Date());
     }
     //保存
     ${daoObjName}.insertSelective(bean);
     ${daoObjName}.insertSelective(${entityObjName});