diff --git a/.idea/misc.xml b/.idea/misc.xml index 81e27d4..661e6c6 100644 --- a/.idea/misc.xml +++ b/.idea/misc.xml @@ -1,4 +1,3 @@ - diff --git a/.idea/vcs.xml b/.idea/vcs.xml index 47c9172..94a25f7 100644 --- a/.idea/vcs.xml +++ b/.idea/vcs.xml @@ -2,6 +2,5 @@ - \ No newline at end of file diff --git a/guigu-ssyx-parent/common/common-util/pom.xml b/guigu-ssyx-parent/common/common-util/pom.xml index 66c2049..621c6ea 100644 --- a/guigu-ssyx-parent/common/common-util/pom.xml +++ b/guigu-ssyx-parent/common/common-util/pom.xml @@ -26,6 +26,22 @@ joda-time + + + com.baomidou + mybatis-plus-boot-starter + + + + + com.baomidou + mybatis-plus-generator + 3.4.0 + + + mysql + mysql-connector-java + com.atguigu model diff --git a/guigu-ssyx-parent/common/service-util/src/test/java/com/atguigu/ssyx/CodeGet.java b/guigu-ssyx-parent/common/common-util/src/test/java/ssyx/CodeGet.java similarity index 98% rename from guigu-ssyx-parent/common/service-util/src/test/java/com/atguigu/ssyx/CodeGet.java rename to guigu-ssyx-parent/common/common-util/src/test/java/ssyx/CodeGet.java index 85d7c86..d9b47e4 100644 --- a/guigu-ssyx-parent/common/service-util/src/test/java/com/atguigu/ssyx/CodeGet.java +++ b/guigu-ssyx-parent/common/common-util/src/test/java/ssyx/CodeGet.java @@ -1,4 +1,4 @@ -package com.atguigu.ssyx; +package ssyx; import com.baomidou.mybatisplus.annotation.DbType; import com.baomidou.mybatisplus.generator.AutoGenerator; diff --git a/guigu-ssyx-parent/common/service-util/pom.xml b/guigu-ssyx-parent/common/service-util/pom.xml index a9938dc..702c6a0 100644 --- a/guigu-ssyx-parent/common/service-util/pom.xml +++ b/guigu-ssyx-parent/common/service-util/pom.xml @@ -37,12 +37,9 @@ redisson 3.11.2 - - com.baomidou mybatis-plus-boot-starter - provided com.atguigu @@ -50,16 +47,6 @@ 1.0-SNAPSHOT compile - - - com.baomidou - mybatis-plus-generator - 3.4.1 - - - mysql - mysql-connector-java - org.apache.velocity velocity-engine-core diff --git a/guigu-ssyx-parent/common/service-util/src/main/java/com/atguigu/ssyx/common/config/MybatisPlusConfig.java b/guigu-ssyx-parent/common/service-util/src/main/java/com/atguigu/ssyx/common/config/MybatisPlusConfig.java index 9d35e79..829717e 100644 --- a/guigu-ssyx-parent/common/service-util/src/main/java/com/atguigu/ssyx/common/config/MybatisPlusConfig.java +++ b/guigu-ssyx-parent/common/service-util/src/main/java/com/atguigu/ssyx/common/config/MybatisPlusConfig.java @@ -18,7 +18,7 @@ import org.springframework.transaction.annotation.EnableTransactionManagement; */ @EnableTransactionManagement @Configuration -@MapperScan("com.atguigu.ssyx.*.mapper") +@MapperScan(value = {"com.atguigu.ssyx.*.mapper"}) public class MybatisPlusConfig { /** diff --git a/guigu-ssyx-parent/pom.xml b/guigu-ssyx-parent/pom.xml index bba7f75..dbf0974 100644 --- a/guigu-ssyx-parent/pom.xml +++ b/guigu-ssyx-parent/pom.xml @@ -25,7 +25,7 @@ 1.8 Hoxton.SR8 2.2.2.RELEASE - 3.4.1 + 3.4.0 8.0.30 0.7.0 2.0.0 diff --git a/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/ServiceSysApplication.java b/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/ServiceSysApplication.java similarity index 65% rename from guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/ServiceSysApplication.java rename to guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/ServiceSysApplication.java index d2a3502..d9bc6f8 100644 --- a/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/ServiceSysApplication.java +++ b/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/ServiceSysApplication.java @@ -1,9 +1,7 @@ -package com.atguigu.ssyx.sys; +package com.atguigu.ssyx; -import org.mybatis.spring.annotation.MapperScan; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; -import springfox.documentation.swagger2.annotations.EnableSwagger2WebMvc; /** * ClassName: ServiceSysApplication @@ -13,8 +11,6 @@ import springfox.documentation.swagger2.annotations.EnableSwagger2WebMvc; * @Create 2023/9/14 15:36 */ @SpringBootApplication -@EnableSwagger2WebMvc -@MapperScan(value = "com.atguigu.ssyx.*.mapper") public class ServiceSysApplication { public static void main(String[] args) { SpringApplication.run(ServiceSysApplication.class, args); diff --git a/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/controller/RegionController.java b/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/controller/RegionController.java index 0b1bda1..6ac2c2f 100644 --- a/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/controller/RegionController.java +++ b/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/controller/RegionController.java @@ -7,10 +7,7 @@ import com.atguigu.ssyx.sys.service.RegionService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.web.bind.annotation.GetMapping; -import org.springframework.web.bind.annotation.PathVariable; -import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.RestController; +import org.springframework.web.bind.annotation.*; import java.util.List; @@ -25,7 +22,7 @@ import java.util.List; @Api(value = "地区接口", tags = "地区接口") @RestController @RequestMapping("/admin/sys/region") -//@CrossOrigin +@CrossOrigin public class RegionController { @Autowired diff --git a/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/controller/RegionWareController.java b/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/controller/RegionWareController.java index 9fda9b9..7093540 100644 --- a/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/controller/RegionWareController.java +++ b/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/controller/RegionWareController.java @@ -10,10 +10,9 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiParam; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.*; -import javax.annotation.Resource; - /** *

* 城市仓库关联表 前端控制器 @@ -22,23 +21,21 @@ import javax.annotation.Resource; * @author atguigu * @since 2023-09-14 */ -@Api(value = "开通区域接口", tags = "开通区域接口") @RestController @RequestMapping(value = "/admin/sys/regionWare") +@Api(value = "开通区域接口", tags = "开通区域接口") @CrossOrigin public class RegionWareController { - @Resource + @Autowired private RegionWareService regionWareService; + + //TODO 分页查询错误 @ApiOperation(value = "获取开通区域列表") @GetMapping("{page}/{limit}") - public Result index( - @ApiParam(name = "page", value = "当前页码", required = true) - @PathVariable Long page, - @ApiParam(name = "limit", value = "每页记录数", required = true) - @PathVariable Long limit, - @ApiParam(name = "regionWareVo", value = "查询对象", required = false) - RegionWareQueryVo regionWareQueryVo) { + public Result index(@ApiParam(name = "page", value = "当前页码", required = true) @PathVariable Long page, + @ApiParam(name = "limit", value = "每页记录数", required = true) @PathVariable Long limit, + @ApiParam(name = "regionWareVo", value = "查询对象", required = false) RegionWareQueryVo regionWareQueryVo) { try { Page pageParam = new Page<>(page, limit); IPage pageModel = regionWareService.selectPage(pageParam, regionWareQueryVo); diff --git a/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/mapper/RegionMapper.java b/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/mapper/RegionMapper.java index 3284229..1cd2b9c 100644 --- a/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/mapper/RegionMapper.java +++ b/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/mapper/RegionMapper.java @@ -2,7 +2,7 @@ package com.atguigu.ssyx.sys.mapper; import com.atguigu.ssyx.model.sys.Region; import com.baomidou.mybatisplus.core.mapper.BaseMapper; -import org.mapstruct.Mapper; +import org.springframework.stereotype.Repository; /** *

@@ -12,7 +12,7 @@ import org.mapstruct.Mapper; * @author atguigu * @since 2023-09-14 */ -@Mapper +@Repository public interface RegionMapper extends BaseMapper { } diff --git a/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/mapper/RegionWareMapper.java b/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/mapper/RegionWareMapper.java index ca42e97..8d55ef3 100644 --- a/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/mapper/RegionWareMapper.java +++ b/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/mapper/RegionWareMapper.java @@ -2,7 +2,7 @@ package com.atguigu.ssyx.sys.mapper; import com.atguigu.ssyx.model.sys.RegionWare; import com.baomidou.mybatisplus.core.mapper.BaseMapper; -import org.mapstruct.Mapper; +import org.springframework.stereotype.Repository; /** *

@@ -12,7 +12,7 @@ import org.mapstruct.Mapper; * @author atguigu * @since 2023-09-14 */ -@Mapper +@Repository public interface RegionWareMapper extends BaseMapper { } diff --git a/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/mapper/WareMapper.java b/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/mapper/WareMapper.java index d507d3b..c4dd5ba 100644 --- a/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/mapper/WareMapper.java +++ b/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/mapper/WareMapper.java @@ -3,7 +3,7 @@ package com.atguigu.ssyx.sys.mapper; import com.atguigu.ssyx.model.sys.Ware; import com.baomidou.mybatisplus.core.mapper.BaseMapper; -import org.mapstruct.Mapper; +import org.springframework.stereotype.Repository; /** *

@@ -13,7 +13,7 @@ import org.mapstruct.Mapper; * @author atguigu * @since 2023-09-14 */ -@Mapper +@Repository public interface WareMapper extends BaseMapper { } diff --git a/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/service/impl/RegionWareServiceImpl.java b/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/service/impl/RegionWareServiceImpl.java index c960a52..782e858 100644 --- a/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/service/impl/RegionWareServiceImpl.java +++ b/guigu-ssyx-parent/service/service-sys/src/main/java/com/atguigu/ssyx/sys/service/impl/RegionWareServiceImpl.java @@ -10,11 +10,10 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import org.springframework.util.StringUtils; -import javax.annotation.Resource; - /** *

* 城市仓库关联表 服务实现类 @@ -27,7 +26,7 @@ import javax.annotation.Resource; public class RegionWareServiceImpl extends ServiceImpl implements RegionWareService { - @Resource + @Autowired RegionWareMapper regionWareMapper; //开通区域列表 @@ -41,7 +40,8 @@ public class RegionWareServiceImpl extends ServiceImpl regionWarePage = baseMapper.selectPage(pageParam, wrapper); + return regionWarePage; } //添加开通区域 diff --git a/guigu-ssyx-parent/service/service-sys/src/main/resources/application-dev.yml b/guigu-ssyx-parent/service/service-sys/src/main/resources/application-dev.yml index 2eeff64..15a66c2 100644 --- a/guigu-ssyx-parent/service/service-sys/src/main/resources/application-dev.yml +++ b/guigu-ssyx-parent/service/service-sys/src/main/resources/application-dev.yml @@ -16,3 +16,4 @@ spring: jackson: date-format: yyyy-MM-dd HH:mm:ss time-zone: GMT+8 + diff --git a/ssyx-admin/.env.development b/ssyx-admin/.env.development index ec6a076..f9082c0 100644 --- a/ssyx-admin/.env.development +++ b/ssyx-admin/.env.development @@ -3,4 +3,4 @@ ENV = 'development' # base api # VUE_APP_BASE_API = '/dev-api' -VUE_APP_BASE_API = 'http://localhost:8201' +VUE_APP_BASE_API = 'http://localhost:9001' diff --git a/ssyx-admin/.env.production b/ssyx-admin/.env.production index 367d835..91b93c6 100644 --- a/ssyx-admin/.env.production +++ b/ssyx-admin/.env.production @@ -3,5 +3,5 @@ ENV = 'production' # base api #VUE_APP_BASE_API = '/prod-api' -VUE_APP_BASE_API = 'http://localhost:8201' +VUE_APP_BASE_API = 'http://localhost:9001' diff --git a/ssyx-admin/src/components/Breadcrumb/index.vue b/ssyx-admin/src/components/Breadcrumb/index.vue index 2a79302..9ff38dd 100644 --- a/ssyx-admin/src/components/Breadcrumb/index.vue +++ b/ssyx-admin/src/components/Breadcrumb/index.vue @@ -2,7 +2,7 @@ - {{ + {{ item.meta.title }} {{ item.meta.title }}