Commit 46f929ee8c03bdb68c9aaa5c1ec124ed280f3fc8
Committed by
Gitee
!792 修复代码生成模板文件中import的错误
Merge pull request !792 from 云开/fix-vm
Showing
5 changed files
with
9 additions
and
9 deletions
yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/java/controller/controller.vm
| 1 | 1 | package ${basePackage}.module.${table.moduleName}.controller.${sceneEnum.basePackage}.${table.businessName}; |
| 2 | 2 | |
| 3 | 3 | import org.springframework.web.bind.annotation.*; |
| 4 | -import javax.annotation.Resource; | |
| 4 | +import jakarta.annotation.Resource; | |
| 5 | 5 | import org.springframework.validation.annotation.Validated; |
| 6 | 6 | #if ($sceneEnum.scene == 1)import org.springframework.security.access.prepost.PreAuthorize;#end |
| 7 | 7 | |
| ... | ... | @@ -9,9 +9,9 @@ import io.swagger.v3.oas.annotations.tags.Tag; |
| 9 | 9 | import io.swagger.v3.oas.annotations.Parameter; |
| 10 | 10 | import io.swagger.v3.oas.annotations.Operation; |
| 11 | 11 | |
| 12 | -import javax.validation.constraints.*; | |
| 13 | -import javax.validation.*; | |
| 14 | -import javax.servlet.http.*; | |
| 12 | +import jakarta.validation.constraints.*; | |
| 13 | +import jakarta.validation.*; | |
| 14 | +import jakarta.servlet.http.*; | |
| 15 | 15 | import java.util.*; |
| 16 | 16 | import java.io.IOException; |
| 17 | 17 | ... | ... |
yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/java/controller/vo/saveReqVO.vm
| ... | ... | @@ -3,7 +3,7 @@ package ${basePackage}.module.${table.moduleName}.controller.${sceneEnum.basePac |
| 3 | 3 | import io.swagger.v3.oas.annotations.media.Schema; |
| 4 | 4 | import lombok.*; |
| 5 | 5 | import java.util.*; |
| 6 | -import javax.validation.constraints.*; | |
| 6 | +import jakarta.validation.constraints.*; | |
| 7 | 7 | ## 处理 BigDecimal 字段的引入 |
| 8 | 8 | import java.util.*; |
| 9 | 9 | #foreach ($column in $columns) | ... | ... |
yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/java/service/service.vm
| 1 | 1 | package ${basePackage}.module.${table.moduleName}.service.${table.businessName}; |
| 2 | 2 | |
| 3 | 3 | import java.util.*; |
| 4 | -import javax.validation.*; | |
| 4 | +import jakarta.validation.*; | |
| 5 | 5 | import ${basePackage}.module.${table.moduleName}.controller.${sceneEnum.basePackage}.${table.businessName}.vo.*; |
| 6 | 6 | import ${basePackage}.module.${table.moduleName}.dal.dataobject.${table.businessName}.${table.className}DO; |
| 7 | 7 | ## 特殊:主子表专属逻辑 | ... | ... |
yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/java/service/serviceImpl.vm
| 1 | 1 | package ${basePackage}.module.${table.moduleName}.service.${table.businessName}; |
| 2 | 2 | |
| 3 | 3 | import org.springframework.stereotype.Service; |
| 4 | -import javax.annotation.Resource; | |
| 4 | +import jakarta.annotation.Resource; | |
| 5 | 5 | import org.springframework.validation.annotation.Validated; |
| 6 | 6 | import org.springframework.transaction.annotation.Transactional; |
| 7 | 7 | ... | ... |
yudao-module-infra/yudao-module-infra-biz/src/main/resources/codegen/java/test/serviceTest.vm
| ... | ... | @@ -4,7 +4,7 @@ import org.junit.jupiter.api.Disabled; |
| 4 | 4 | import org.junit.jupiter.api.Test; |
| 5 | 5 | import org.springframework.boot.test.mock.mockito.MockBean; |
| 6 | 6 | |
| 7 | -import javax.annotation.Resource; | |
| 7 | +import jakarta.annotation.Resource; | |
| 8 | 8 | |
| 9 | 9 | import ${baseFrameworkPackage}.test.core.ut.BaseDbUnitTest; |
| 10 | 10 | |
| ... | ... | @@ -13,7 +13,7 @@ import ${basePackage}.module.${table.moduleName}.dal.dataobject.${table.business |
| 13 | 13 | import ${basePackage}.module.${table.moduleName}.dal.mysql.${table.businessName}.${table.className}Mapper; |
| 14 | 14 | import ${PageResultClassName}; |
| 15 | 15 | |
| 16 | -import javax.annotation.Resource; | |
| 16 | +import jakarta.annotation.Resource; | |
| 17 | 17 | import org.springframework.context.annotation.Import; |
| 18 | 18 | import java.util.*; |
| 19 | 19 | import java.time.LocalDateTime; | ... | ... |