src/main/java/com/zy/common/service/erp/ErpController.java | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
src/main/java/com/zy/common/service/erp/ErpService.java | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 |
src/main/java/com/zy/common/service/erp/ErpController.java
New file @@ -0,0 +1,25 @@ package com.zy.common.service.erp; import com.core.common.R; import com.zy.common.web.BaseController; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; /** * Created by vincent on 2022/12/8 */ @RequestMapping("/erp") @RestController public class ErpController extends BaseController { @Autowired private ErpService erpService; @GetMapping("erp/goods/list") public R goodsList() { return R.ok().add(erpService.selectGoods(0)); } } src/main/java/com/zy/common/service/erp/ErpService.java
@@ -5,8 +5,6 @@ import org.springframework.beans.factory.annotation.Autowired; import org.springframework.jdbc.core.JdbcTemplate; import org.springframework.stereotype.Service; import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.RestController; import java.util.List; @@ -15,7 +13,6 @@ */ @Slf4j @Service @RestController public class ErpService { @Autowired @@ -28,7 +25,6 @@ /** * 获取GOODS表 */ @GetMapping("erp/goods/list") public List<Goods> selectGoods(Integer IsGetData) { String sql = "select * from InStockBillEntry where IsGetData = '" + IsGetData +"'"; return erpSqlServer.select(sql, Goods.class);