修改商项目子服务的名称
This commit is contained in:
@@ -1,63 +0,0 @@
|
||||
package com.yxt.goods.apiadmin;
|
||||
|
||||
import com.yxt.goods.biz.base.basegoodssku.BaseGoodsSkuDto;
|
||||
import com.yxt.goods.biz.base.basegoodsskuextend.BaseGoodsSkuExtendDto;
|
||||
import com.yxt.goods.biz.base.basegoodsskuextend.BaseGoodsSkuExtendQuery;
|
||||
import com.yxt.goods.biz.base.basegoodsskuextend.BaseGoodsSkuExtendService;
|
||||
import com.yxt.goods.biz.base.basegoodsskuextend.BaseGoodsSkuExtendVo;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
import com.yxt.goods.biz.base.basegoodsspu.BaseGoodsSpuDto;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author wangpengfei
|
||||
* @date 2024/3/11 15:05
|
||||
*/
|
||||
@Api(tags = "商品sku扩展")
|
||||
@RestController
|
||||
@RequestMapping("/apiadmin/base/basegoodsskuextend")
|
||||
public class BaseGoodsSkuExtendRest {
|
||||
|
||||
@Autowired
|
||||
BaseGoodsSkuExtendService baseGoodsSkuExtendService;
|
||||
|
||||
@ApiOperation("分页列表")
|
||||
@PostMapping("/listPage")
|
||||
public ResultBean<PagerVo<BaseGoodsSkuExtendVo>> listPage(@RequestBody PagerQuery<BaseGoodsSkuExtendQuery> pq) {
|
||||
return baseGoodsSkuExtendService.listPage(pq);
|
||||
}
|
||||
|
||||
@ApiOperation("保存修改")
|
||||
@PostMapping("/saveOrUpdate")
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody BaseGoodsSkuExtendDto dto) {
|
||||
return baseGoodsSkuExtendService.saveOrUpdate(dto);
|
||||
}
|
||||
@ApiOperation("保存")
|
||||
@PostMapping("/batchSave")
|
||||
public ResultBean<String> batchSave(@RequestBody List<BaseGoodsSkuDto> dtos) {
|
||||
return baseGoodsSkuExtendService.skuEBatchSave(dtos);
|
||||
}
|
||||
@ApiOperation("初始化")
|
||||
@GetMapping("/initialization/{sid}")
|
||||
public ResultBean<BaseGoodsSkuExtendVo> initialization(@PathVariable("sid") String sid) {
|
||||
return baseGoodsSkuExtendService.initialization(sid);
|
||||
}
|
||||
|
||||
@ApiOperation("删除")
|
||||
@DeleteMapping("/delete/{sid}")
|
||||
public ResultBean delete(@PathVariable("sid") String sid) {
|
||||
return baseGoodsSkuExtendService.delete(sid);
|
||||
}
|
||||
@ApiOperation("更改可用状态")
|
||||
@GetMapping("/updateIsEnable/{sid}/{isEnable}")
|
||||
public ResultBean updateIsEnable(@PathVariable("sid") String sid,@PathVariable("isEnable")String isEnable) {
|
||||
return baseGoodsSkuExtendService.updateIsEnable(sid,isEnable);
|
||||
}
|
||||
}
|
||||
@@ -1,89 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.apiadmin;
|
||||
|
||||
import com.yxt.goods.biz.base.basesupplierBank.*;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(供应商管理) <br/>
|
||||
* File: BaseSupplierBankFeignFallback.java <br/>
|
||||
* Class: com.yxt.base.biz.basesupplierbank.BaseSupplierBankRest <br/>
|
||||
* Description: 供应商开户行信息. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-18 13:33:13 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Api(tags = "供应商开户行信息")
|
||||
@RestController
|
||||
@RequestMapping("/apiadmin/base/basesupplierbank")
|
||||
public class BaseSupplierBankRest {
|
||||
|
||||
@Autowired
|
||||
private BaseSupplierBankService baseSupplierBankService;
|
||||
|
||||
@ApiOperation("根据条件分页查询数据的列表")
|
||||
@PostMapping("/listPage")
|
||||
public ResultBean<PagerVo<BaseSupplierBankVo>> listPage(@RequestBody PagerQuery<BaseSupplierBankQuery> pq){
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
PagerVo<BaseSupplierBankVo> pv = baseSupplierBankService.listPageVo(pq);
|
||||
return rb.success().setData(pv);
|
||||
}
|
||||
|
||||
@ApiOperation("新增或修改")
|
||||
@PostMapping("/save")
|
||||
public ResultBean save(@RequestBody BaseSupplierBankDto dto){
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
baseSupplierBankService.saveOrUpdateDto(dto);
|
||||
return rb.success();
|
||||
}
|
||||
|
||||
@ApiOperation("根据sid批量删除")
|
||||
@PostMapping("/delBySids")
|
||||
public ResultBean delBySids(@RequestBody String[] sids){
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
baseSupplierBankService.delBySids(sids);
|
||||
return rb.success();
|
||||
}
|
||||
|
||||
@ApiOperation("根据SID获取一条记录")
|
||||
@GetMapping("/fetchDetailsBySid/{sid}")
|
||||
public ResultBean<BaseSupplierBankDetailsVo> fetchDetailsBySid(@PathVariable("sid") String sid){
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseSupplierBankDetailsVo vo = baseSupplierBankService.fetchDetailsVoBySid(sid);
|
||||
return rb.success().setData(vo);
|
||||
}
|
||||
}
|
||||
@@ -1,89 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.apiadmin;
|
||||
|
||||
import com.yxt.goods.biz.base.basesupplierfile.*;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(仓储基础信息供应商) <br/>
|
||||
* File: BaseSupplierFileFeignFallback.java <br/>
|
||||
* Class: com.yxt.anrui.as.biz.basesupplierfile.BaseSupplierFileRest <br/>
|
||||
* Description: 供应商附件. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-13 16:51:56 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Api(tags = "供应商附件")
|
||||
@RestController
|
||||
@RequestMapping("/apiadmin/base/basesupplierfile")
|
||||
public class BaseSupplierFileRest {
|
||||
|
||||
@Autowired
|
||||
private BaseSupplierFileService baseSupplierFileService;
|
||||
|
||||
@ApiOperation("根据条件分页查询数据的列表")
|
||||
@PostMapping("/listPage")
|
||||
public ResultBean<PagerVo<BaseSupplierFileVo>> listPage(@RequestBody PagerQuery<BaseSupplierFileQuery> pq){
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
PagerVo<BaseSupplierFileVo> pv = baseSupplierFileService.listPageVo(pq);
|
||||
return rb.success().setData(pv);
|
||||
}
|
||||
|
||||
@ApiOperation("新增或修改")
|
||||
@PostMapping("/save")
|
||||
public ResultBean save(@RequestBody BaseSupplierFileDto dto){
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
baseSupplierFileService.saveOrUpdateDto(dto);
|
||||
return rb.success();
|
||||
}
|
||||
|
||||
@ApiOperation("根据sid批量删除")
|
||||
@DeleteMapping("/delBySids")
|
||||
public ResultBean delBySids(@RequestBody String[] sids){
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
baseSupplierFileService.delBySids(sids);
|
||||
return rb.success();
|
||||
}
|
||||
|
||||
@ApiOperation("根据SID获取一条记录")
|
||||
@GetMapping("/fetchDetailsBySid/{sid}")
|
||||
public ResultBean<BaseSupplierFileDetailsVo> fetchDetailsBySid(@PathVariable("sid") String sid){
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseSupplierFileDetailsVo vo = baseSupplierFileService.fetchDetailsVoBySid(sid);
|
||||
return rb.success().setData(vo);
|
||||
}
|
||||
}
|
||||
@@ -1,97 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.apiadmin;
|
||||
|
||||
import com.yxt.goods.biz.base.basesupplierinfo.*;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(仓储基础信息供应商) <br/>
|
||||
* File: BaseSupplierInfoFeignFallback.java <br/>
|
||||
* Class: com.yxt.anrui.as.biz.basesupplierinfo.BaseSupplierInfoRest <br/>
|
||||
* Description: 供应商信息. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-13 16:51:56 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Api(tags = "供应商信息")
|
||||
@RestController
|
||||
@RequestMapping("/apiadmin/base/basesupplierinfo")
|
||||
public class BaseSupplierInfoRest {
|
||||
|
||||
@Autowired
|
||||
private BaseSupplierInfoService baseSupplierInfoService;
|
||||
|
||||
@ApiOperation("根据条件分页查询数据的列表")
|
||||
@PostMapping("/listPage")
|
||||
public ResultBean<PagerVo<BaseSupplierInfoVo>> listPage(@RequestBody PagerQuery<BaseSupplierInfoQuery> pq){
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
PagerVo<BaseSupplierInfoVo> pv = baseSupplierInfoService.listPageVo(pq);
|
||||
return rb.success().setData(pv);
|
||||
}
|
||||
|
||||
@ApiOperation("新增或修改")
|
||||
@PostMapping("/save")
|
||||
public ResultBean save(@RequestBody BaseSupplierInfoDto dto){
|
||||
return baseSupplierInfoService.saveOrUpdateDto(dto);
|
||||
}
|
||||
|
||||
@ApiOperation("根据sid批量删除")
|
||||
@DeleteMapping("/delBySids")
|
||||
public ResultBean delBySids(@RequestBody String[] sids){
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
baseSupplierInfoService.delAll(sids);
|
||||
return rb.success();
|
||||
}
|
||||
|
||||
@ApiOperation("根据SID获取一条记录")
|
||||
@GetMapping("/fetchDetailsBySid/{sid}")
|
||||
public ResultBean<BaseSupplierInfoDetailsVo> fetchDetailsBySid(@PathVariable("sid") String sid){
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseSupplierInfoDetailsVo vo = baseSupplierInfoService.fetchDetailsVoBySid(sid);
|
||||
return rb.success().setData(vo);
|
||||
}
|
||||
|
||||
@ApiOperation("选择供应商")
|
||||
@PostMapping("/choiceSupplierInfo")
|
||||
public ResultBean<List<BaseSupplierInfoChoice>> choiceSupplierInfo(@RequestParam("createOrgSid") String createOrgSid){
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
List<BaseSupplierInfoChoice> baseSupplierInfoChoiceList = baseSupplierInfoService.choiceSupplierInfo(createOrgSid);
|
||||
return rb.success().setData(baseSupplierInfoChoiceList);
|
||||
}
|
||||
}
|
||||
@@ -1,89 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.apiadmin;
|
||||
|
||||
import com.yxt.goods.biz.base.basesuppliertype.*;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(仓储基础信息供应商) <br/>
|
||||
* File: BaseSupplierTypeFeignFallback.java <br/>
|
||||
* Class: com.yxt.anrui.as.biz.basesuppliertype.BaseSupplierTypeRest <br/>
|
||||
* Description: 供应商类型. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-13 16:51:56 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Api(tags = "供应商类型")
|
||||
@RestController
|
||||
@RequestMapping("/apiadmin/base/basesuppliertype")
|
||||
public class BaseSupplierTypeRest {
|
||||
|
||||
@Autowired
|
||||
private BaseSupplierTypeService baseSupplierTypeService;
|
||||
|
||||
@ApiOperation("根据条件分页查询数据的列表")
|
||||
@PostMapping("/listPage")
|
||||
public ResultBean<PagerVo<BaseSupplierTypeVo>> listPage(@RequestBody PagerQuery<BaseSupplierTypeQuery> pq){
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
PagerVo<BaseSupplierTypeVo> pv = baseSupplierTypeService.listPageVo(pq);
|
||||
return rb.success().setData(pv);
|
||||
}
|
||||
|
||||
@ApiOperation("新增或修改")
|
||||
@PostMapping("/save")
|
||||
public ResultBean save(@RequestBody BaseSupplierTypeDto dto){
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
baseSupplierTypeService.saveOrUpdateDto(dto);
|
||||
return rb.success();
|
||||
}
|
||||
|
||||
@ApiOperation("根据sid批量删除")
|
||||
@DeleteMapping("/delBySids")
|
||||
public ResultBean delBySids(@RequestBody String[] sids){
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
baseSupplierTypeService.delBySids(sids);
|
||||
return rb.success();
|
||||
}
|
||||
|
||||
@ApiOperation("根据SID获取一条记录")
|
||||
@GetMapping("/fetchDetailsBySid/{sid}")
|
||||
public ResultBean<BaseSupplierTypeDetailsVo> fetchDetailsBySid(@PathVariable("sid") String sid){
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseSupplierTypeDetailsVo vo = baseSupplierTypeService.fetchDetailsVoBySid(sid);
|
||||
return rb.success().setData(vo);
|
||||
}
|
||||
}
|
||||
@@ -5,6 +5,6 @@ import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
@RestController("com.yxt.base.apiadmin.AdminHomeRest")
|
||||
@RequestMapping("/apiadmin/home")
|
||||
public class AdminHomeRest {
|
||||
public class GoodsAdminHomeRest {
|
||||
|
||||
}
|
||||
@@ -1,9 +1,10 @@
|
||||
package com.yxt.goods.apiadmin;
|
||||
|
||||
import com.yxt.goods.biz.base.basebrandinfo.*;
|
||||
import com.yxt.goods.biz.goodsbrandinfo.*;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
import com.yxt.goods.biz.goodsbrandinfo.*;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -18,30 +19,30 @@ import java.util.List;
|
||||
@Api(tags = "商品品牌")
|
||||
@RestController
|
||||
@RequestMapping("/apiadmin/base/basegoodsbrand")
|
||||
public class BaseGoodsBrandRest {
|
||||
public class GoodsBrandRest {
|
||||
|
||||
@Autowired
|
||||
BaseBrandInfoService baseBrandInfoService;
|
||||
GoodsBrandInfoService baseBrandInfoService;
|
||||
|
||||
@ApiOperation("分页列表")
|
||||
@PostMapping("/listPage")
|
||||
public ResultBean<PagerVo<BaseBrandInfoVo>> listPage(@RequestBody PagerQuery<BaseBrandInfoQuery> pq) {
|
||||
public ResultBean<PagerVo<GoodsBrandInfoVo>> listPage(@RequestBody PagerQuery<GoodsBrandInfoQuery> pq) {
|
||||
return baseBrandInfoService.listPage(pq);
|
||||
}
|
||||
@ApiOperation("查询所有的品牌")
|
||||
@GetMapping("/listAll")
|
||||
public ResultBean<List<BaseBrandInfo>> listAll() {
|
||||
public ResultBean<List<GoodsBrandInfo>> listAll() {
|
||||
return baseBrandInfoService.listAll();
|
||||
}
|
||||
@ApiOperation("保存修改")
|
||||
@PostMapping("/saveOrUpdate")
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody BaseBrandInfoDto dto) {
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody GoodsBrandInfoDto dto) {
|
||||
return baseBrandInfoService.saveOrUpdate(dto);
|
||||
}
|
||||
|
||||
@ApiOperation("初始化")
|
||||
@GetMapping("/initialization/{sid}")
|
||||
public ResultBean<BaseBrandInfoVo> initialization(@PathVariable("sid") String sid) {
|
||||
public ResultBean<GoodsBrandInfoVo> initialization(@PathVariable("sid") String sid) {
|
||||
return baseBrandInfoService.initialization(sid);
|
||||
}
|
||||
|
||||
@@ -59,7 +60,7 @@ public class BaseGoodsBrandRest {
|
||||
}
|
||||
@ApiOperation("根据品牌名查询")
|
||||
@GetMapping("/getBrandByName/{name}")
|
||||
public ResultBean<BaseBrandInfo> getBrandByName(@PathVariable("name") String name) {
|
||||
public ResultBean<GoodsBrandInfo> getBrandByName(@PathVariable("name") String name) {
|
||||
return baseBrandInfoService.getBrandByName(name);
|
||||
}
|
||||
}
|
||||
@@ -1,9 +1,9 @@
|
||||
package com.yxt.goods.apiadmin;
|
||||
|
||||
import com.yxt.goods.biz.base.basecategorybrand.BaseCategoryBrandDto;
|
||||
import com.yxt.goods.biz.base.basecategorybrand.BaseCategoryBrandQuery;
|
||||
import com.yxt.goods.biz.base.basecategorybrand.BaseCategoryBrandService;
|
||||
import com.yxt.goods.biz.base.basecategorybrand.BaseCategoryBrandVo;
|
||||
import com.yxt.goods.biz.goodscategorybrand.GoodsCategoryBrandDto;
|
||||
import com.yxt.goods.biz.goodscategorybrand.GoodsCategoryBrandQuery;
|
||||
import com.yxt.goods.biz.goodscategorybrand.GoodsCategoryBrandService;
|
||||
import com.yxt.goods.biz.goodscategorybrand.GoodsCategoryBrandVo;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
@@ -19,25 +19,25 @@ import org.springframework.web.bind.annotation.*;
|
||||
@Api(tags = "品牌与商品类别关联")
|
||||
@RestController
|
||||
@RequestMapping("/apiadmin/base/basecategorybrand")
|
||||
public class BaseCategoryBrandRest {
|
||||
public class GoodsCategoryBrandRest {
|
||||
@Autowired
|
||||
BaseCategoryBrandService baseCategoryBrandService;
|
||||
GoodsCategoryBrandService baseCategoryBrandService;
|
||||
|
||||
@ApiOperation("分页列表")
|
||||
@PostMapping("/listPage")
|
||||
public ResultBean<PagerVo<BaseCategoryBrandVo>> listPage(@RequestBody PagerQuery<BaseCategoryBrandQuery> pq) {
|
||||
public ResultBean<PagerVo<GoodsCategoryBrandVo>> listPage(@RequestBody PagerQuery<GoodsCategoryBrandQuery> pq) {
|
||||
return baseCategoryBrandService.listPage(pq);
|
||||
}
|
||||
|
||||
@ApiOperation("保存修改")
|
||||
@PostMapping("/saveOrUpdate")
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody BaseCategoryBrandDto dto) {
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody GoodsCategoryBrandDto dto) {
|
||||
return baseCategoryBrandService.saveOrUpdate(dto);
|
||||
}
|
||||
|
||||
@ApiOperation("初始化")
|
||||
@GetMapping("/initialization/{sid}")
|
||||
public ResultBean<BaseCategoryBrandVo> initialization(@PathVariable("sid") String sid) {
|
||||
public ResultBean<GoodsCategoryBrandVo> initialization(@PathVariable("sid") String sid) {
|
||||
return baseCategoryBrandService.initialization(sid);
|
||||
}
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
package com.yxt.goods.apiadmin;
|
||||
|
||||
import com.yxt.goods.biz.base.basemanufacturer.*;
|
||||
import com.yxt.goods.biz.goodsmanufacturer.*;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
import com.yxt.goods.biz.goodsmanufacturer.*;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -18,32 +19,32 @@ import java.util.List;
|
||||
@Api(tags = "厂家信息")
|
||||
@RestController
|
||||
@RequestMapping("/apiadmin/base/basemanufacturer")
|
||||
public class BaseManufacturerRest {
|
||||
public class GoodsManufacturerRest {
|
||||
|
||||
@Autowired
|
||||
BaseManufacturerService baseManufacturerService;
|
||||
GoodsManufacturerService baseManufacturerService;
|
||||
|
||||
@ApiOperation("分页列表")
|
||||
@PostMapping("/listPage")
|
||||
public ResultBean<PagerVo<BaseManufacturerVo>> listPage(@RequestBody PagerQuery<BaseManufacturerQuery> pq) {
|
||||
public ResultBean<PagerVo<GoodsManufacturerVo>> listPage(@RequestBody PagerQuery<GoodsManufacturerQuery> pq) {
|
||||
return baseManufacturerService.listPage(pq);
|
||||
}
|
||||
|
||||
@ApiOperation("查询所有的厂家")
|
||||
@GetMapping("/listAll")
|
||||
public ResultBean<List<BaseManufacturer>> listAll() {
|
||||
public ResultBean<List<GoodsManufacturer>> listAll() {
|
||||
return baseManufacturerService.listAll();
|
||||
}
|
||||
|
||||
@ApiOperation("保存修改")
|
||||
@PostMapping("/saveOrUpdate")
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody BaseManufacturerDto dto) {
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody GoodsManufacturerDto dto) {
|
||||
return baseManufacturerService.saveOrUpdate(dto);
|
||||
}
|
||||
|
||||
@ApiOperation("初始化")
|
||||
@GetMapping("/initialization/{sid}")
|
||||
public ResultBean<BaseManufacturerVo> initialization(@PathVariable("sid") String sid) {
|
||||
public ResultBean<GoodsManufacturerVo> initialization(@PathVariable("sid") String sid) {
|
||||
return baseManufacturerService.initialization(sid);
|
||||
}
|
||||
|
||||
@@ -62,12 +63,12 @@ public class BaseManufacturerRest {
|
||||
|
||||
@ApiOperation("查询分公司下所有的厂家")
|
||||
@GetMapping("/getAllTypeByUseOrgSid")
|
||||
public ResultBean<List<BaseManufacturerVo>> getAllTypeByUseOrgSid(@RequestParam("useOrgSid") String useOrgSid) {
|
||||
public ResultBean<List<GoodsManufacturerVo>> getAllTypeByUseOrgSid(@RequestParam("useOrgSid") String useOrgSid) {
|
||||
return baseManufacturerService.getAllTypeByUseOrgSid(useOrgSid);
|
||||
}
|
||||
@ApiOperation("根据厂家名查询")
|
||||
@GetMapping("/getManufacturerByName/{name}")
|
||||
public ResultBean<BaseManufacturer> getManufacturerByName(@PathVariable("name") String name) {
|
||||
public ResultBean<GoodsManufacturer> getManufacturerByName(@PathVariable("name") String name) {
|
||||
return baseManufacturerService.getManufacturerByName(name);
|
||||
}
|
||||
}
|
||||
@@ -2,9 +2,9 @@ package com.yxt.goods.apiadmin;
|
||||
|
||||
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.goods.biz.base.shoppingcart.ShoppingCartDto;
|
||||
import com.yxt.goods.biz.base.shoppingcart.ShoppingCartQuery;
|
||||
import com.yxt.goods.biz.base.shoppingcart.ShoppingCartService;
|
||||
import com.yxt.goods.biz.goodsshoppingcart.GoodsShoppingCartDto;
|
||||
import com.yxt.goods.biz.goodsshoppingcart.GoodsShoppingCartQuery;
|
||||
import com.yxt.goods.biz.goodsshoppingcart.GoodsShoppingCartService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -17,29 +17,29 @@ import org.springframework.web.bind.annotation.*;
|
||||
@Api(tags = "购物车")
|
||||
@RestController
|
||||
@RequestMapping("shoppingcart")
|
||||
public class ShoppingCartRest {
|
||||
public class GoodsShoppingCartRest {
|
||||
@Autowired
|
||||
ShoppingCartService shoppingCartService;
|
||||
GoodsShoppingCartService shoppingCartService;
|
||||
|
||||
|
||||
@ApiOperation("加入购物车")
|
||||
@PostMapping("/addShoppingCart")
|
||||
public ResultBean save(@RequestBody ShoppingCartDto dto) {
|
||||
public ResultBean save(@RequestBody GoodsShoppingCartDto dto) {
|
||||
return shoppingCartService.save(dto);
|
||||
}
|
||||
@ApiOperation("减购物车")
|
||||
@PostMapping("/minusShoppingCart")
|
||||
public ResultBean minusShoppingCart(@RequestBody ShoppingCartDto dto) {
|
||||
public ResultBean minusShoppingCart(@RequestBody GoodsShoppingCartDto dto) {
|
||||
return shoppingCartService.minusShoppingCart(dto);
|
||||
}
|
||||
@ApiOperation("修改购物车数量")
|
||||
@PostMapping("/updateShoppingCart")
|
||||
public ResultBean updateShoppingCart(@RequestBody ShoppingCartDto dto) {
|
||||
public ResultBean updateShoppingCart(@RequestBody GoodsShoppingCartDto dto) {
|
||||
return shoppingCartService.updateShoppingCart(dto);
|
||||
}
|
||||
@ApiOperation("购物车列表")
|
||||
@PostMapping("/shoppingCartList")
|
||||
public ResultBean shoppingCartList(@RequestBody ShoppingCartQuery query) {
|
||||
public ResultBean shoppingCartList(@RequestBody GoodsShoppingCartQuery query) {
|
||||
return shoppingCartService.shoppingCartList(query);
|
||||
}
|
||||
|
||||
@@ -50,7 +50,7 @@ public class ShoppingCartRest {
|
||||
}
|
||||
@ApiOperation("计算购物车价格和重量")
|
||||
@PostMapping("/getGoodsWeight")
|
||||
public ResultBean getGoodsWeight(@RequestBody ShoppingCartQuery query) {
|
||||
public ResultBean getGoodsWeight(@RequestBody GoodsShoppingCartQuery query) {
|
||||
return shoppingCartService.getGoodsWeight(query);
|
||||
}
|
||||
}
|
||||
62
src/main/java/com/yxt/goods/apiadmin/GoodsSkuExtendRest.java
Normal file
62
src/main/java/com/yxt/goods/apiadmin/GoodsSkuExtendRest.java
Normal file
@@ -0,0 +1,62 @@
|
||||
package com.yxt.goods.apiadmin;
|
||||
|
||||
import com.yxt.goods.biz.goodssku.GoodsSkuDto;
|
||||
import com.yxt.goods.biz.goodsskuextend.GoodsSkuExtendDto;
|
||||
import com.yxt.goods.biz.goodsskuextend.GoodsSkuExtendQuery;
|
||||
import com.yxt.goods.biz.goodsskuextend.GoodsSkuExtendService;
|
||||
import com.yxt.goods.biz.goodsskuextend.GoodsSkuExtendVo;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author wangpengfei
|
||||
* @date 2024/3/11 15:05
|
||||
*/
|
||||
@Api(tags = "商品sku扩展")
|
||||
@RestController
|
||||
@RequestMapping("/apiadmin/base/basegoodsskuextend")
|
||||
public class GoodsSkuExtendRest {
|
||||
|
||||
@Autowired
|
||||
GoodsSkuExtendService goodsSkuExtendService;
|
||||
|
||||
@ApiOperation("分页列表")
|
||||
@PostMapping("/listPage")
|
||||
public ResultBean<PagerVo<GoodsSkuExtendVo>> listPage(@RequestBody PagerQuery<GoodsSkuExtendQuery> pq) {
|
||||
return goodsSkuExtendService.listPage(pq);
|
||||
}
|
||||
|
||||
@ApiOperation("保存修改")
|
||||
@PostMapping("/saveOrUpdate")
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody GoodsSkuExtendDto dto) {
|
||||
return goodsSkuExtendService.saveOrUpdate(dto);
|
||||
}
|
||||
@ApiOperation("保存")
|
||||
@PostMapping("/batchSave")
|
||||
public ResultBean<String> batchSave(@RequestBody List<GoodsSkuDto> dtos) {
|
||||
return goodsSkuExtendService.skuEBatchSave(dtos);
|
||||
}
|
||||
@ApiOperation("初始化")
|
||||
@GetMapping("/initialization/{sid}")
|
||||
public ResultBean<GoodsSkuExtendVo> initialization(@PathVariable("sid") String sid) {
|
||||
return goodsSkuExtendService.initialization(sid);
|
||||
}
|
||||
|
||||
@ApiOperation("删除")
|
||||
@DeleteMapping("/delete/{sid}")
|
||||
public ResultBean delete(@PathVariable("sid") String sid) {
|
||||
return goodsSkuExtendService.delete(sid);
|
||||
}
|
||||
@ApiOperation("更改可用状态")
|
||||
@GetMapping("/updateIsEnable/{sid}/{isEnable}")
|
||||
public ResultBean updateIsEnable(@PathVariable("sid") String sid,@PathVariable("isEnable")String isEnable) {
|
||||
return goodsSkuExtendService.updateIsEnable(sid,isEnable);
|
||||
}
|
||||
}
|
||||
@@ -1,10 +1,11 @@
|
||||
package com.yxt.goods.apiadmin;
|
||||
|
||||
import com.yxt.goods.biz.base.basegoodssku.*;
|
||||
import com.yxt.goods.biz.goodssku.*;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
import com.yxt.goods.biz.base.basegoodsspu.BaseGoodsSpuDto;
|
||||
import com.yxt.goods.biz.goodssku.*;
|
||||
import com.yxt.goods.biz.goodsspu.GoodsSpuDto;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -19,61 +20,61 @@ import java.util.List;
|
||||
@Api(tags = "商品sku")
|
||||
@RestController
|
||||
@RequestMapping("/apiadmin/base/basegoodssku")
|
||||
public class BaseGoodsSkuRest {
|
||||
public class GoodsSkuRest {
|
||||
@Autowired
|
||||
BaseGoodsSkuService baseGoodsSkuService;
|
||||
GoodsSkuService goodsSkuService;
|
||||
|
||||
@ApiOperation("分页列表")
|
||||
@PostMapping("/listPage")
|
||||
public ResultBean<PagerVo<BaseGoodsSkuVo>> listPage(@RequestBody PagerQuery<BaseGoodsSkuQuery> pq) {
|
||||
return baseGoodsSkuService.listPage(pq);
|
||||
public ResultBean<PagerVo<GoodsSkuVo>> listPage(@RequestBody PagerQuery<GoodsSkuQuery> pq) {
|
||||
return goodsSkuService.listPage(pq);
|
||||
}
|
||||
|
||||
@ApiOperation("保存修改")
|
||||
@PostMapping("/saveOrUpdate")
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody BaseGoodsSkuDto dto) {
|
||||
return baseGoodsSkuService.saveOrUpdate(dto);
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody GoodsSkuDto dto) {
|
||||
return goodsSkuService.saveOrUpdate(dto);
|
||||
}
|
||||
@ApiOperation("保存")
|
||||
@PostMapping("/batchSave")
|
||||
public ResultBean<String> batchSave(@RequestBody List<BaseGoodsSpuDto> dtos) {
|
||||
return baseGoodsSkuService.skuBatchSave(dtos);
|
||||
public ResultBean<String> batchSave(@RequestBody List<GoodsSpuDto> dtos) {
|
||||
return goodsSkuService.skuBatchSave(dtos);
|
||||
}
|
||||
@ApiOperation("初始化")
|
||||
@GetMapping("/initialization/{sid}")
|
||||
public ResultBean<BaseGoodsSkuVo> initialization(@PathVariable("sid") String sid) {
|
||||
return baseGoodsSkuService.initialization(sid);
|
||||
public ResultBean<GoodsSkuVo> initialization(@PathVariable("sid") String sid) {
|
||||
return goodsSkuService.initialization(sid);
|
||||
}
|
||||
|
||||
@ApiOperation("删除")
|
||||
@DeleteMapping("/delete/{sid}")
|
||||
public ResultBean delete(@PathVariable("sid") String sid) {
|
||||
return baseGoodsSkuService.delete(sid);
|
||||
return goodsSkuService.delete(sid);
|
||||
}
|
||||
|
||||
@ApiOperation("更改可用状态")
|
||||
@GetMapping("/updateIsEnable/{sid}/{isEnable}")
|
||||
public ResultBean updateIsEnable(@PathVariable("sid") String sid, @PathVariable("isEnable") String isEnable) {
|
||||
return baseGoodsSkuService.updateIsEnable(sid, isEnable);
|
||||
return goodsSkuService.updateIsEnable(sid, isEnable);
|
||||
}
|
||||
|
||||
@ApiOperation("获取商品信息")
|
||||
@GetMapping("/getDetails")
|
||||
ResultBean<BaseGoodsSkuDetailsVo> getDetails(@RequestParam("sid") String sid) {
|
||||
return baseGoodsSkuService.getDetails(sid);
|
||||
ResultBean<GoodsSkuDetailsVo> getDetails(@RequestParam("sid") String sid) {
|
||||
return goodsSkuService.getDetails(sid);
|
||||
}
|
||||
|
||||
@ApiOperation("入库添加商品列表")
|
||||
@PostMapping("/getSelectList")
|
||||
ResultBean<PagerVo<BaseGoodsSkuSelectList>> getSelectList(@RequestBody PagerQuery<BaseGoodsSkuSelectQuery> pagerQuery) {
|
||||
ResultBean<PagerVo<BaseGoodsSkuSelectList>> rb = ResultBean.fireFail();
|
||||
PagerVo<BaseGoodsSkuSelectList> pv = baseGoodsSkuService.getSelectList(pagerQuery);
|
||||
ResultBean<PagerVo<SkuSelectList>> getSelectList(@RequestBody PagerQuery<GoodsSkuSelectQuery> pagerQuery) {
|
||||
ResultBean<PagerVo<SkuSelectList>> rb = ResultBean.fireFail();
|
||||
PagerVo<SkuSelectList> pv = goodsSkuService.getSelectList(pagerQuery);
|
||||
return rb.success().setData(pv);
|
||||
}
|
||||
|
||||
@ApiOperation("采购商品分页列表")
|
||||
@PostMapping("/purGoodsListPage")
|
||||
public ResultBean<PagerVo<BaseGoodsSkuPurSelectList>> purGoodsListPage(@RequestBody PagerQuery<BaseGoodsSkuPurSelectQuery> pq) {
|
||||
return baseGoodsSkuService.purGoodsListPage(pq);
|
||||
public ResultBean<PagerVo<GoodsSkuPurSelectList>> purGoodsListPage(@RequestBody PagerQuery<GoodsSkuPurSelectQuery> pq) {
|
||||
return goodsSkuService.purGoodsListPage(pq);
|
||||
}
|
||||
}
|
||||
@@ -1,10 +1,10 @@
|
||||
package com.yxt.goods.apiadmin;
|
||||
|
||||
|
||||
import com.yxt.goods.biz.base.basespecparam.BaseSpecParamDto;
|
||||
import com.yxt.goods.biz.base.basespecparam.BaseSpecParamQuery;
|
||||
import com.yxt.goods.biz.base.basespecparam.BaseSpecParamService;
|
||||
import com.yxt.goods.biz.base.basespecparam.BaseSpecParamVo;
|
||||
import com.yxt.goods.biz.goodsspecparam.GoodsSpecParamDto;
|
||||
import com.yxt.goods.biz.goodsspecparam.GoodsSpecParamQuery;
|
||||
import com.yxt.goods.biz.goodsspecparam.GoodsSpecParamService;
|
||||
import com.yxt.goods.biz.goodsspecparam.GoodsSpecParamVo;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
@@ -20,38 +20,38 @@ import org.springframework.web.bind.annotation.*;
|
||||
@Api(tags = "规格参数组表")
|
||||
@RestController
|
||||
@RequestMapping("/apiadmin/base/basespecgroup")
|
||||
public class BaseSpecGroupRest {
|
||||
public class GoodsSpecGroupRest {
|
||||
@Autowired
|
||||
BaseSpecParamService baseSpecParamService;
|
||||
GoodsSpecParamService goodsSpecParamService;
|
||||
|
||||
@ApiOperation("分页列表")
|
||||
@PostMapping("/listPage")
|
||||
public ResultBean<PagerVo<BaseSpecParamVo>> listPage(@RequestBody PagerQuery<BaseSpecParamQuery> pq) {
|
||||
return baseSpecParamService.listPage(pq);
|
||||
public ResultBean<PagerVo<GoodsSpecParamVo>> listPage(@RequestBody PagerQuery<GoodsSpecParamQuery> pq) {
|
||||
return goodsSpecParamService.listPage(pq);
|
||||
}
|
||||
|
||||
@ApiOperation("保存修改")
|
||||
@PostMapping("/saveOrUpdate")
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody BaseSpecParamDto dto) {
|
||||
return baseSpecParamService.saveOrUpdate(dto);
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody GoodsSpecParamDto dto) {
|
||||
return goodsSpecParamService.saveOrUpdate(dto);
|
||||
}
|
||||
|
||||
@ApiOperation("初始化")
|
||||
@GetMapping("/initialization/{sid}")
|
||||
public ResultBean<BaseSpecParamVo> initialization(@PathVariable("sid") String sid) {
|
||||
return baseSpecParamService.initialization(sid);
|
||||
public ResultBean<GoodsSpecParamVo> initialization(@PathVariable("sid") String sid) {
|
||||
return goodsSpecParamService.initialization(sid);
|
||||
}
|
||||
|
||||
@ApiOperation("删除")
|
||||
@DeleteMapping("/delete/{sid}")
|
||||
public ResultBean delete(@PathVariable("sid") String sid) {
|
||||
return baseSpecParamService.delete(sid);
|
||||
return goodsSpecParamService.delete(sid);
|
||||
}
|
||||
|
||||
@ApiOperation("更改可用状态")
|
||||
@GetMapping("/updateIsEnable/{sid}/{isEnable}")
|
||||
public ResultBean updateIsEnable(@PathVariable("sid") String sid, @PathVariable("isEnable") String isEnable) {
|
||||
return baseSpecParamService.updateIsEnable(sid, isEnable);
|
||||
return goodsSpecParamService.updateIsEnable(sid, isEnable);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,10 +1,10 @@
|
||||
package com.yxt.goods.apiadmin;
|
||||
|
||||
|
||||
import com.yxt.goods.biz.base.basespecparam.BaseSpecParamDto;
|
||||
import com.yxt.goods.biz.base.basespecparam.BaseSpecParamQuery;
|
||||
import com.yxt.goods.biz.base.basespecparam.BaseSpecParamService;
|
||||
import com.yxt.goods.biz.base.basespecparam.BaseSpecParamVo;
|
||||
import com.yxt.goods.biz.goodsspecparam.GoodsSpecParamDto;
|
||||
import com.yxt.goods.biz.goodsspecparam.GoodsSpecParamQuery;
|
||||
import com.yxt.goods.biz.goodsspecparam.GoodsSpecParamService;
|
||||
import com.yxt.goods.biz.goodsspecparam.GoodsSpecParamVo;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
@@ -20,38 +20,38 @@ import org.springframework.web.bind.annotation.*;
|
||||
@Api(tags = "规格参数定义表")
|
||||
@RestController
|
||||
@RequestMapping("/apiadmin/base/basespecparam")
|
||||
public class BaseSpecParamRest {
|
||||
public class GoodsSpecParamRest {
|
||||
@Autowired
|
||||
BaseSpecParamService baseSpecParamService;
|
||||
GoodsSpecParamService goodsSpecParamService;
|
||||
|
||||
@ApiOperation("分页列表")
|
||||
@PostMapping("/listPage")
|
||||
public ResultBean<PagerVo<BaseSpecParamVo>> listPage(@RequestBody PagerQuery<BaseSpecParamQuery> pq) {
|
||||
return baseSpecParamService.listPage(pq);
|
||||
public ResultBean<PagerVo<GoodsSpecParamVo>> listPage(@RequestBody PagerQuery<GoodsSpecParamQuery> pq) {
|
||||
return goodsSpecParamService.listPage(pq);
|
||||
}
|
||||
|
||||
@ApiOperation("保存修改")
|
||||
@PostMapping("/saveOrUpdate")
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody BaseSpecParamDto dto) {
|
||||
return baseSpecParamService.saveOrUpdate(dto);
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody GoodsSpecParamDto dto) {
|
||||
return goodsSpecParamService.saveOrUpdate(dto);
|
||||
}
|
||||
|
||||
@ApiOperation("初始化")
|
||||
@GetMapping("/initialization/{sid}")
|
||||
public ResultBean<BaseSpecParamVo> initialization(@PathVariable("sid") String sid) {
|
||||
return baseSpecParamService.initialization(sid);
|
||||
public ResultBean<GoodsSpecParamVo> initialization(@PathVariable("sid") String sid) {
|
||||
return goodsSpecParamService.initialization(sid);
|
||||
}
|
||||
|
||||
@ApiOperation("删除")
|
||||
@DeleteMapping("/delete/{sid}")
|
||||
public ResultBean delete(@PathVariable("sid") String sid) {
|
||||
return baseSpecParamService.delete(sid);
|
||||
return goodsSpecParamService.delete(sid);
|
||||
}
|
||||
|
||||
@ApiOperation("更改可用状态")
|
||||
@GetMapping("/updateIsEnable/{sid}/{isEnable}")
|
||||
public ResultBean updateIsEnable(@PathVariable("sid") String sid, @PathVariable("isEnable") String isEnable) {
|
||||
return baseSpecParamService.updateIsEnable(sid, isEnable);
|
||||
return goodsSpecParamService.updateIsEnable(sid, isEnable);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,10 +1,10 @@
|
||||
package com.yxt.goods.apiadmin;
|
||||
|
||||
import com.yxt.goods.biz.base.basegoodsspu.BaseGoodsSpuDto;
|
||||
import com.yxt.goods.biz.base.basegoodsspudetail.BaseGoodsSpuDetailDto;
|
||||
import com.yxt.goods.biz.base.basegoodsspudetail.BaseGoodsSpuDetailQuery;
|
||||
import com.yxt.goods.biz.base.basegoodsspudetail.BaseGoodsSpuDetailService;
|
||||
import com.yxt.goods.biz.base.basegoodsspudetail.BaseGoodsSpuDetailVo;
|
||||
import com.yxt.goods.biz.goodsspu.GoodsSpuDto;
|
||||
import com.yxt.goods.biz.goodsspudetail.GoodsSpuDetailDto;
|
||||
import com.yxt.goods.biz.goodsspudetail.BaseGoodsSpuDetailQuery;
|
||||
import com.yxt.goods.biz.goodsspudetail.BaseGoodsSpuDetailService;
|
||||
import com.yxt.goods.biz.goodsspudetail.BaseGoodsSpuDetailVo;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
@@ -23,7 +23,7 @@ import java.util.List;
|
||||
@Api(tags = "商品spu详情")
|
||||
@RestController
|
||||
@RequestMapping("/apiadmin/base/basegoodsspudetail")
|
||||
public class BaseGoodsSpuDetailRest {
|
||||
public class GoodsSpuDetailRest {
|
||||
|
||||
@Autowired
|
||||
BaseGoodsSpuDetailService baseGoodsSpuDetailService;
|
||||
@@ -36,12 +36,12 @@ public class BaseGoodsSpuDetailRest {
|
||||
|
||||
@ApiOperation("保存修改")
|
||||
@PostMapping("/saveOrUpdate")
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody BaseGoodsSpuDetailDto dto) {
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody GoodsSpuDetailDto dto) {
|
||||
return baseGoodsSpuDetailService.saveOrUpdate(dto);
|
||||
}
|
||||
@ApiOperation("保存")
|
||||
@PostMapping("/batchSave")
|
||||
public ResultBean<String> batchSave(@RequestBody List<BaseGoodsSpuDto> dtos) {
|
||||
public ResultBean<String> batchSave(@RequestBody List<GoodsSpuDto> dtos) {
|
||||
return baseGoodsSpuDetailService.batchSave(dtos);
|
||||
}
|
||||
@ApiOperation("初始化")
|
||||
@@ -1,9 +1,9 @@
|
||||
package com.yxt.goods.apiadmin;
|
||||
|
||||
import com.yxt.goods.biz.base.basegoodsspu.BaseGoodsSpuDto;
|
||||
import com.yxt.goods.biz.base.basegoodsspu.BaseGoodsSpuQuery;
|
||||
import com.yxt.goods.biz.base.basegoodsspu.BaseGoodsSpuService;
|
||||
import com.yxt.goods.biz.base.basegoodsspu.BaseGoodsSpuVo;
|
||||
import com.yxt.goods.biz.goodsspu.GoodsSpuDto;
|
||||
import com.yxt.goods.biz.goodsspu.GoodsSpuQuery;
|
||||
import com.yxt.goods.biz.goodsspu.GoodsSpuService;
|
||||
import com.yxt.goods.biz.goodsspu.GoodsSpuVo;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
@@ -24,25 +24,25 @@ import java.util.List;
|
||||
@Api(tags = "商品spu")
|
||||
@RestController
|
||||
@RequestMapping("/apiadmin/base/basegoodsspu")
|
||||
public class BaseGoodsSpuRest {
|
||||
public class GoodsSpuRest {
|
||||
@Autowired
|
||||
BaseGoodsSpuService baseGoodsSpuService;
|
||||
GoodsSpuService goodsSpuService;
|
||||
|
||||
@ApiOperation("分页列表")
|
||||
@PostMapping("/listPage")
|
||||
public ResultBean<PagerVo<BaseGoodsSpuVo>> listPage(@RequestBody PagerQuery<BaseGoodsSpuQuery> pq) {
|
||||
return baseGoodsSpuService.listPage(pq);
|
||||
public ResultBean<PagerVo<GoodsSpuVo>> listPage(@RequestBody PagerQuery<GoodsSpuQuery> pq) {
|
||||
return goodsSpuService.listPage(pq);
|
||||
}
|
||||
|
||||
@ApiOperation("保存修改")
|
||||
@PostMapping("/saveOrUpdate")
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody BaseGoodsSpuDto dto) {
|
||||
return baseGoodsSpuService.saveOrUpdate(dto);
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody GoodsSpuDto dto) {
|
||||
return goodsSpuService.saveOrUpdate(dto);
|
||||
}
|
||||
@ApiOperation("保存")
|
||||
@PostMapping("/batchSave")
|
||||
public ResultBean<String> batchSave(@RequestBody List<BaseGoodsSpuDto> dtos) {
|
||||
return baseGoodsSpuService.batchSave(dtos);
|
||||
public ResultBean<String> batchSave(@RequestBody List<GoodsSpuDto> dtos) {
|
||||
return goodsSpuService.batchSave(dtos);
|
||||
}
|
||||
// @ApiOperation("保存商品信息及sku")
|
||||
// @PostMapping("/save")
|
||||
@@ -51,23 +51,23 @@ public class BaseGoodsSpuRest {
|
||||
// }
|
||||
@ApiOperation("初始化")
|
||||
@GetMapping("/initialization/{sid}")
|
||||
public ResultBean<BaseGoodsSpuVo> initialization(@PathVariable("sid") String sid) {
|
||||
return baseGoodsSpuService.initialization(sid);
|
||||
public ResultBean<GoodsSpuVo> initialization(@PathVariable("sid") String sid) {
|
||||
return goodsSpuService.initialization(sid);
|
||||
}
|
||||
|
||||
@ApiOperation("删除")
|
||||
@DeleteMapping("/delete/{sid}")
|
||||
public ResultBean delete(@PathVariable("sid") String sid) {
|
||||
return baseGoodsSpuService.delete(sid);
|
||||
return goodsSpuService.delete(sid);
|
||||
}
|
||||
@ApiOperation("更改可用状态")
|
||||
@GetMapping("/updateIsEnable/{sid}/{isEnable}")
|
||||
public ResultBean updateIsEnable(@PathVariable("sid") String sid,@PathVariable("isEnable")String isEnable) {
|
||||
return baseGoodsSpuService.updateIsEnable(sid,isEnable);
|
||||
return goodsSpuService.updateIsEnable(sid,isEnable);
|
||||
}
|
||||
@ApiOperation("导入excel")
|
||||
@PostMapping(value ="/importExcel" ,consumes = MediaType.MULTIPART_FORM_DATA_VALUE)
|
||||
public ResultBean importExcel(@RequestParam("file") MultipartFile file) throws IOException {
|
||||
return baseGoodsSpuService.importExcel(file);
|
||||
return goodsSpuService.importExcel(file);
|
||||
}
|
||||
}
|
||||
@@ -1,9 +1,10 @@
|
||||
package com.yxt.goods.apiadmin;
|
||||
|
||||
import com.yxt.goods.biz.base.basegoodstype.*;
|
||||
import com.yxt.goods.biz.goodstype.*;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
import com.yxt.goods.biz.goodstype.*;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -18,49 +19,49 @@ import java.util.List;
|
||||
@Api(tags = "商品类型")
|
||||
@RestController
|
||||
@RequestMapping("/apiadmin/base/basegoodstype")
|
||||
public class BaseGoodsTypeRest {
|
||||
public class GoodsTypeRest {
|
||||
@Autowired
|
||||
BaseGoodsTypeService baseGoodsTypeService;
|
||||
GoodsTypeService goodsTypeService;
|
||||
|
||||
|
||||
@ApiOperation("分页列表")
|
||||
@PostMapping("/listPage")
|
||||
public ResultBean<PagerVo<BaseGoodsTypeVo>> listPage(@RequestBody PagerQuery<BaseGoodsTypeQuery> pq) {
|
||||
return baseGoodsTypeService.listPage(pq);
|
||||
public ResultBean<PagerVo<GoodsTypeVo>> listPage(@RequestBody PagerQuery<GoodsTypeQuery> pq) {
|
||||
return goodsTypeService.listPage(pq);
|
||||
}
|
||||
@ApiOperation("查询所有的类别")
|
||||
@GetMapping("/listAll")
|
||||
public ResultBean<List<BaseGoodsType>> listAll() {
|
||||
return baseGoodsTypeService.listAll();
|
||||
public ResultBean<List<GoodsType>> listAll() {
|
||||
return goodsTypeService.listAll();
|
||||
}
|
||||
|
||||
@ApiOperation("保存修改")
|
||||
@PostMapping("/saveOrUpdate")
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody BaseGoodsTypeDto dto) {
|
||||
return baseGoodsTypeService.saveOrUpdate(dto);
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody GoodsTypeDto dto) {
|
||||
return goodsTypeService.saveOrUpdate(dto);
|
||||
}
|
||||
|
||||
@ApiOperation("初始化")
|
||||
@GetMapping("/initialization/{sid}")
|
||||
public ResultBean<BaseGoodsTypeVo> initialization(@PathVariable("sid") String sid) {
|
||||
return baseGoodsTypeService.initialization(sid);
|
||||
public ResultBean<GoodsTypeVo> initialization(@PathVariable("sid") String sid) {
|
||||
return goodsTypeService.initialization(sid);
|
||||
}
|
||||
|
||||
@ApiOperation("删除")
|
||||
@DeleteMapping("/delete/{sid}")
|
||||
public ResultBean delete(@PathVariable("sid") String sid) {
|
||||
return baseGoodsTypeService.delete(sid);
|
||||
return goodsTypeService.delete(sid);
|
||||
}
|
||||
|
||||
|
||||
@ApiOperation("更改可用状态")
|
||||
@GetMapping("/updateIsEnable/{sid}/{isEnable}")
|
||||
public ResultBean updateIsEnable(@PathVariable("sid") String sid,@PathVariable("isEnable")String isEnable) {
|
||||
return baseGoodsTypeService.updateIsEnable(sid,isEnable);
|
||||
return goodsTypeService.updateIsEnable(sid,isEnable);
|
||||
}
|
||||
@ApiOperation("根据类型名查询")
|
||||
@GetMapping("/getTypeByName/{name}")
|
||||
public ResultBean<BaseGoodsType> getTypeByName(@PathVariable("name") String name) {
|
||||
return baseGoodsTypeService.getTypeByName(name);
|
||||
public ResultBean<GoodsType> getTypeByName(@PathVariable("name") String name) {
|
||||
return goodsTypeService.getTypeByName(name);
|
||||
}
|
||||
}
|
||||
@@ -1,9 +1,10 @@
|
||||
package com.yxt.goods.apiadmin;
|
||||
|
||||
import com.yxt.goods.biz.base.basegoodsunit.*;
|
||||
import com.yxt.goods.biz.goodsunit.*;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
import com.yxt.goods.biz.goodsunit.*;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -18,49 +19,49 @@ import java.util.List;
|
||||
@Api(tags = "商品类型")
|
||||
@RestController
|
||||
@RequestMapping("/apiadmin/base/basegoodsunit")
|
||||
public class BaseGoodsUnitRest {
|
||||
public class GoodsUnitRest {
|
||||
@Autowired
|
||||
BaseGoodsUnitService baseGoodsUnitService;
|
||||
GoodsUnitService goodsUnitService;
|
||||
|
||||
|
||||
@ApiOperation("分页列表")
|
||||
@PostMapping("/listPage")
|
||||
public ResultBean<PagerVo<BaseGoodsUnitVo>> listPage(@RequestBody PagerQuery<BaseGoodsUnitQuery> pq) {
|
||||
return baseGoodsUnitService.listPage(pq);
|
||||
public ResultBean<PagerVo<GoodsUnitVo>> listPage(@RequestBody PagerQuery<GoodsUnitQuery> pq) {
|
||||
return goodsUnitService.listPage(pq);
|
||||
}
|
||||
@ApiOperation("查询所有的类别")
|
||||
@GetMapping("/listAll")
|
||||
public ResultBean<List<BaseGoodsUnit>> listAll() {
|
||||
return baseGoodsUnitService.listAll();
|
||||
public ResultBean<List<GoodsUnit>> listAll() {
|
||||
return goodsUnitService.listAll();
|
||||
}
|
||||
|
||||
@ApiOperation("保存修改")
|
||||
@PostMapping("/saveOrUpdate")
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody BaseGoodsUnitDto dto) {
|
||||
return baseGoodsUnitService.saveOrUpdate(dto);
|
||||
public ResultBean<String> saveOrUpdate(@RequestBody GoodsUnitDto dto) {
|
||||
return goodsUnitService.saveOrUpdate(dto);
|
||||
}
|
||||
|
||||
@ApiOperation("初始化")
|
||||
@GetMapping("/initialization/{sid}")
|
||||
public ResultBean<BaseGoodsUnitVo> initialization(@PathVariable("sid") String sid) {
|
||||
return baseGoodsUnitService.initialization(sid);
|
||||
public ResultBean<GoodsUnitVo> initialization(@PathVariable("sid") String sid) {
|
||||
return goodsUnitService.initialization(sid);
|
||||
}
|
||||
|
||||
@ApiOperation("删除")
|
||||
@DeleteMapping("/delete/{sid}")
|
||||
public ResultBean delete(@PathVariable("sid") String sid) {
|
||||
return baseGoodsUnitService.delete(sid);
|
||||
return goodsUnitService.delete(sid);
|
||||
}
|
||||
|
||||
|
||||
@ApiOperation("更改可用状态")
|
||||
@GetMapping("/updateIsEnable/{sid}/{isEnable}")
|
||||
public ResultBean updateIsEnable(@PathVariable("sid") String sid,@PathVariable("isEnable")String isEnable) {
|
||||
return baseGoodsUnitService.updateIsEnable(sid,isEnable);
|
||||
return goodsUnitService.updateIsEnable(sid,isEnable);
|
||||
}
|
||||
@ApiOperation("根据单位名查询")
|
||||
@GetMapping("/getUnitByName/{name}")
|
||||
public ResultBean<BaseGoodsUnit> getUnitByName(@PathVariable("name") String name) {
|
||||
return baseGoodsUnitService.getUnitByName(name);
|
||||
public ResultBean<GoodsUnit> getUnitByName(@PathVariable("name") String name) {
|
||||
return goodsUnitService.getUnitByName(name);
|
||||
}
|
||||
}
|
||||
@@ -1,26 +0,0 @@
|
||||
package com.yxt.goods.biz.base.basegoodssku;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Constants;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author wangpengfei
|
||||
* @date 2024/2/26 13:40
|
||||
*/
|
||||
@Mapper
|
||||
public interface BaseGoodsSkuMapper extends BaseMapper<BaseGoodsSku> {
|
||||
|
||||
IPage<BaseGoodsSkuVo> listPage(IPage<BaseGoodsSku> page, @Param(Constants.WRAPPER) QueryWrapper<BaseGoodsSku> qw);
|
||||
List<BaseGoodsSkuVo> getSkusBySpuSid(@Param("spuSid")String spuSid);
|
||||
BaseGoodsSkuVo getSkuBySid(@Param("sid")String sid);
|
||||
|
||||
IPage<BaseGoodsSkuSelectList> getSelectList(IPage<BaseGoodsSku> page, @Param(Constants.WRAPPER)QueryWrapper<BaseGoodsSku> qw);
|
||||
|
||||
IPage<BaseGoodsSkuPurSelectList> purGoodsListPage(IPage<BaseGoodsSku> page, @Param(Constants.WRAPPER) QueryWrapper<BaseGoodsSku> qw);
|
||||
}
|
||||
@@ -1,20 +0,0 @@
|
||||
package com.yxt.goods.biz.base.basegoodsskuextend;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Constants;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
/**
|
||||
* @author wangpengfei
|
||||
* @date 2024/2/26 13:40
|
||||
*/
|
||||
@Mapper
|
||||
public interface BaseGoodsSkuExtendMapper extends BaseMapper<BaseGoodsSkuExtend> {
|
||||
|
||||
IPage<BaseGoodsSkuExtendVo> listPage(IPage<BaseGoodsSkuExtend> page, @Param(Constants.WRAPPER) QueryWrapper<BaseGoodsSkuExtend> qw);
|
||||
BaseGoodsSkuExtendVo getExtendBySkuSid(@Param("skuSid")String skuSid);
|
||||
BaseGoodsSkuExtendVo getExtendBySid(@Param("sid")String sid);
|
||||
}
|
||||
@@ -1,13 +0,0 @@
|
||||
package com.yxt.goods.biz.base.basegoodsskuextend;
|
||||
|
||||
import com.yxt.common.core.query.Query;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @author wangpengfei
|
||||
* @date 2024/2/26 13:37
|
||||
*/
|
||||
@Data
|
||||
public class BaseGoodsSkuExtendQuery implements Query {
|
||||
private String name;
|
||||
}
|
||||
@@ -1,13 +0,0 @@
|
||||
package com.yxt.goods.biz.base.basegoodsunit;
|
||||
|
||||
import com.yxt.common.core.query.Query;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @author wangpengfei
|
||||
* @date 2024/2/26 13:37
|
||||
*/
|
||||
@Data
|
||||
public class BaseGoodsUnitQuery implements Query {
|
||||
private String name;
|
||||
}
|
||||
@@ -1,13 +0,0 @@
|
||||
package com.yxt.goods.biz.base.basemanufacturer;
|
||||
|
||||
import com.yxt.common.core.query.Query;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @author wangpengfei
|
||||
* @date 2024/2/26 13:37
|
||||
*/
|
||||
@Data
|
||||
public class BaseManufacturerQuery implements Query {
|
||||
private String name;
|
||||
}
|
||||
@@ -1,76 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierBank;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.yxt.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(供应商管理) <br/>
|
||||
* File: BaseSupplierBank.java <br/>
|
||||
* Class: com.yxt.base.api.basesupplierbank.BaseSupplierBank <br/>
|
||||
* Description: 供应商开户行信息. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-18 13:33:13 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商开户行信息", description = "供应商开户行信息")
|
||||
@TableName("base_supplier_bank")
|
||||
public class BaseSupplierBank extends BaseEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("供应商sid")
|
||||
private String supplierSid; // 供应商sid
|
||||
@ApiModelProperty("开户行")
|
||||
private String bankName; // 开户行
|
||||
@ApiModelProperty("开户行帐号")
|
||||
private String bankAccount; // 开户行帐号
|
||||
@ApiModelProperty("账户名称")
|
||||
private String accountName; // 账户名称
|
||||
@ApiModelProperty("账户类型key")
|
||||
private String dueBankKey; // 账户类型key
|
||||
@ApiModelProperty("账户类型value")
|
||||
private String dueBankValue; // 账户类型value
|
||||
@ApiModelProperty("银行网点")
|
||||
private String bankingOutlets; // 银行网点
|
||||
@ApiModelProperty("开户行地址")
|
||||
private String bankAddress; // 开户行地址
|
||||
@ApiModelProperty("联行号")
|
||||
private String paymentLines; // 联行号
|
||||
@ApiModelProperty("银行代码")
|
||||
private String swiftCode; // 银行代码
|
||||
@ApiModelProperty("币种")
|
||||
private String currency; // 币种
|
||||
|
||||
}
|
||||
@@ -1,76 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierBank;
|
||||
|
||||
|
||||
import com.yxt.common.core.vo.Vo;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(供应商管理) <br/>
|
||||
* File: BaseSupplierBankVo.java <br/>
|
||||
* Class: com.yxt.base.api.basesupplierbank.BaseSupplierBankVo <br/>
|
||||
* Description: 供应商开户行信息 视图数据对象. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-18 13:33:13 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商开户行信息 视图数据详情", description = "供应商开户行信息 视图数据详情")
|
||||
public class BaseSupplierBankDetailsVo implements Vo {
|
||||
|
||||
private String sid; // sid
|
||||
|
||||
@ApiModelProperty("供应商sid")
|
||||
private String supplierSid; // 供应商sid
|
||||
@ApiModelProperty("开户行")
|
||||
private String bankName; // 开户行
|
||||
@ApiModelProperty("开户行帐号")
|
||||
private String bankAccount; // 开户行帐号
|
||||
@ApiModelProperty("账户名称")
|
||||
private String accountName; // 账户名称
|
||||
@ApiModelProperty("账户类型key")
|
||||
private String dueBankKey; // 账户类型key
|
||||
@ApiModelProperty("账户类型value")
|
||||
private String dueBankValue; // 账户类型value
|
||||
@ApiModelProperty("银行网点")
|
||||
private String bankingOutlets; // 银行网点
|
||||
@ApiModelProperty("开户行地址")
|
||||
private String bankAddress; // 开户行地址
|
||||
@ApiModelProperty("联行号")
|
||||
private String paymentLines; // 联行号
|
||||
@ApiModelProperty("银行代码")
|
||||
private String swiftCode; // 银行代码
|
||||
@ApiModelProperty("币种")
|
||||
private String currency; // 币种
|
||||
|
||||
}
|
||||
@@ -1,76 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierBank;
|
||||
|
||||
|
||||
import com.yxt.common.core.dto.Dto;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(供应商管理) <br/>
|
||||
* File: BaseSupplierBankDto.java <br/>
|
||||
* Class: com.yxt.base.api.basesupplierbank.BaseSupplierBankDto <br/>
|
||||
* Description: 供应商开户行信息 数据传输对象. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-18 13:33:13 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商开户行信息 数据传输对象", description = "供应商开户行信息 数据传输对象")
|
||||
public class BaseSupplierBankDto implements Dto {
|
||||
|
||||
private String sid; // sid
|
||||
|
||||
@ApiModelProperty("供应商sid")
|
||||
private String supplierSid; // 供应商sid
|
||||
@ApiModelProperty("开户行")
|
||||
private String bankName; // 开户行
|
||||
@ApiModelProperty("开户行帐号")
|
||||
private String bankAccount; // 开户行帐号
|
||||
@ApiModelProperty("账户名称")
|
||||
private String accountName; // 账户名称
|
||||
@ApiModelProperty("账户类型key")
|
||||
private String dueBankKey; // 账户类型key
|
||||
@ApiModelProperty("账户类型value")
|
||||
private String dueBankValue; // 账户类型value
|
||||
@ApiModelProperty("银行网点")
|
||||
private String bankingOutlets; // 银行网点
|
||||
@ApiModelProperty("开户行地址")
|
||||
private String bankAddress; // 开户行地址
|
||||
@ApiModelProperty("联行号")
|
||||
private String paymentLines; // 联行号
|
||||
@ApiModelProperty("银行代码")
|
||||
private String swiftCode; // 银行代码
|
||||
@ApiModelProperty("币种")
|
||||
private String currency; // 币种
|
||||
|
||||
}
|
||||
@@ -1,67 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierBank;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.Wrapper;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Constants;
|
||||
import org.apache.ibatis.annotations.Delete;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.apache.ibatis.annotations.Select;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(供应商管理) <br/>
|
||||
* File: BaseSupplierBankMapper.java <br/>
|
||||
* Class: com.yxt.base.biz.basesupplierbank.BaseSupplierBankMapper <br/>
|
||||
* Description: 供应商开户行信息. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-18 13:33:13 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Mapper
|
||||
public interface BaseSupplierBankMapper extends BaseMapper<BaseSupplierBank> {
|
||||
|
||||
IPage<BaseSupplierBankVo> selectPageVo(IPage<BaseSupplierBank> page, @Param(Constants.WRAPPER) Wrapper<BaseSupplierBank> qw);
|
||||
|
||||
List<BaseSupplierBankVo> selectListAllVo(@Param(Constants.WRAPPER) Wrapper<BaseSupplierBank> qw);
|
||||
|
||||
@Select("select * from base_supplier_bank")
|
||||
List<BaseSupplierBankVo> selectListVo();
|
||||
|
||||
@Delete("delete from base_supplier_bank where supplierSid = #{supplierSid}")
|
||||
int deleteBySupplierSid(String supplierSid);
|
||||
|
||||
@Select("select * from base_supplier_bank where supplierSid = #{supplierSid}")
|
||||
List<BaseSupplierBankDetailsVo> selectBySupplierSid(String supplierSid);
|
||||
}
|
||||
@@ -1,13 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.yxt.goods.biz.base.basesupplierBank.BaseSupplierBankMapper">
|
||||
<!-- <where> ${ew.sqlSegment} </where>-->
|
||||
<!-- ${ew.customSqlSegment} -->
|
||||
<select id="selectPageVo" resultType="com.yxt.goods.biz.base.basesupplierBank.BaseSupplierBankVo">
|
||||
SELECT * FROM base_supplier_bank <where> ${ew.sqlSegment} </where>
|
||||
</select>
|
||||
|
||||
<select id="selectListAllVo" resultType="com.yxt.goods.biz.base.basesupplierBank.BaseSupplierBankVo">
|
||||
SELECT * FROM base_supplier_bank <where> ${ew.sqlSegment} </where>
|
||||
</select>
|
||||
</mapper>
|
||||
@@ -1,74 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierBank;
|
||||
|
||||
|
||||
import com.yxt.common.core.query.Query;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(供应商管理) <br/>
|
||||
* File: BaseSupplierBankQuery.java <br/>
|
||||
* Class: com.yxt.base.api.basesupplierbank.BaseSupplierBankQuery <br/>
|
||||
* Description: 供应商开户行信息 查询条件. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-18 13:33:13 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商开户行信息 查询条件", description = "供应商开户行信息 查询条件")
|
||||
public class BaseSupplierBankQuery implements Query {
|
||||
|
||||
@ApiModelProperty("供应商sid")
|
||||
private String supplierSid; // 供应商sid
|
||||
@ApiModelProperty("开户行")
|
||||
private String bankName; // 开户行
|
||||
@ApiModelProperty("开户行帐号")
|
||||
private String bankAccount; // 开户行帐号
|
||||
@ApiModelProperty("账户名称")
|
||||
private String accountName; // 账户名称
|
||||
@ApiModelProperty("账户类型key")
|
||||
private String dueBankKey; // 账户类型key
|
||||
@ApiModelProperty("账户类型value")
|
||||
private String dueBankValue; // 账户类型value
|
||||
@ApiModelProperty("银行网点")
|
||||
private String bankingOutlets; // 银行网点
|
||||
@ApiModelProperty("开户行地址")
|
||||
private String bankAddress; // 开户行地址
|
||||
@ApiModelProperty("联行号")
|
||||
private String paymentLines; // 联行号
|
||||
@ApiModelProperty("银行代码")
|
||||
private String swiftCode; // 银行代码
|
||||
@ApiModelProperty("币种")
|
||||
private String currency; // 币种
|
||||
|
||||
}
|
||||
@@ -1,104 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierBank;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.yxt.common.base.service.MybatisBaseService;
|
||||
import com.yxt.common.base.utils.PagerUtil;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(供应商管理) <br/>
|
||||
* File: BaseSupplierBankService.java <br/>
|
||||
* Class: com.yxt.base.biz.basesupplierbank.BaseSupplierBankService <br/>
|
||||
* Description: 供应商开户行信息 业务逻辑. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-18 13:33:13 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Service
|
||||
public class BaseSupplierBankService extends MybatisBaseService<BaseSupplierBankMapper, BaseSupplierBank> {
|
||||
|
||||
public PagerVo<BaseSupplierBankVo> listPageVo(PagerQuery<BaseSupplierBankQuery> pq) {
|
||||
BaseSupplierBankQuery query = pq.getParams();
|
||||
QueryWrapper<BaseSupplierBank> qw = new QueryWrapper<>();
|
||||
IPage<BaseSupplierBank> page = PagerUtil.queryToPage(pq);
|
||||
IPage<BaseSupplierBankVo> pagging = baseMapper.selectPageVo(page, qw);
|
||||
PagerVo<BaseSupplierBankVo> p = PagerUtil.pageToVo(pagging, null);
|
||||
return p;
|
||||
}
|
||||
|
||||
public void saveOrUpdateDto(BaseSupplierBankDto dto){
|
||||
String dtoSid = dto.getSid();
|
||||
if (StringUtils.isBlank(dtoSid)) {
|
||||
this.insertByDto(dto);
|
||||
return;
|
||||
}
|
||||
this.updateByDto(dto);
|
||||
}
|
||||
|
||||
public void insertByDto(BaseSupplierBankDto dto){
|
||||
BaseSupplierBank entity = new BaseSupplierBank();
|
||||
BeanUtil.copyProperties(dto, entity, "id", "sid");
|
||||
baseMapper.insert(entity);
|
||||
}
|
||||
|
||||
public void updateByDto(BaseSupplierBankDto dto){
|
||||
String dtoSid = dto.getSid();
|
||||
if (StringUtils.isBlank(dtoSid)) {
|
||||
return;
|
||||
}
|
||||
BaseSupplierBank entity = fetchBySid(dtoSid);
|
||||
BeanUtil.copyProperties(dto, entity, "id", "sid");
|
||||
baseMapper.updateById(entity);
|
||||
}
|
||||
|
||||
public BaseSupplierBankDetailsVo fetchDetailsVoBySid(String sid){
|
||||
BaseSupplierBank entity = fetchBySid(sid);
|
||||
BaseSupplierBankDetailsVo vo = new BaseSupplierBankDetailsVo();
|
||||
BeanUtil.copyProperties(entity, vo);
|
||||
return vo;
|
||||
}
|
||||
|
||||
public int deleteBySupplierSid(String supplierSid) {
|
||||
return baseMapper.deleteBySupplierSid(supplierSid);
|
||||
}
|
||||
|
||||
public List<BaseSupplierBankDetailsVo> selectBySupplierSid(String supplierSid) {
|
||||
return baseMapper.selectBySupplierSid(supplierSid);
|
||||
}
|
||||
}
|
||||
@@ -1,76 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierBank;
|
||||
|
||||
|
||||
import com.yxt.common.core.vo.Vo;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(供应商管理) <br/>
|
||||
* File: BaseSupplierBankVo.java <br/>
|
||||
* Class: com.yxt.base.api.basesupplierbank.BaseSupplierBankVo <br/>
|
||||
* Description: 供应商开户行信息 视图数据对象. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-18 13:33:13 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商开户行信息 视图数据对象", description = "供应商开户行信息 视图数据对象")
|
||||
public class BaseSupplierBankVo implements Vo {
|
||||
|
||||
private String sid; // sid
|
||||
|
||||
@ApiModelProperty("供应商sid")
|
||||
private String supplierSid; // 供应商sid
|
||||
@ApiModelProperty("开户行")
|
||||
private String bankName; // 开户行
|
||||
@ApiModelProperty("开户行帐号")
|
||||
private String bankAccount; // 开户行帐号
|
||||
@ApiModelProperty("账户名称")
|
||||
private String accountName; // 账户名称
|
||||
@ApiModelProperty("账户类型key")
|
||||
private String dueBankKey; // 账户类型key
|
||||
@ApiModelProperty("账户类型value")
|
||||
private String dueBankValue; // 账户类型value
|
||||
@ApiModelProperty("银行网点")
|
||||
private String bankingOutlets; // 银行网点
|
||||
@ApiModelProperty("开户行地址")
|
||||
private String bankAddress; // 开户行地址
|
||||
@ApiModelProperty("联行号")
|
||||
private String paymentLines; // 联行号
|
||||
@ApiModelProperty("银行代码")
|
||||
private String swiftCode; // 银行代码
|
||||
@ApiModelProperty("币种")
|
||||
private String currency; // 币种
|
||||
|
||||
}
|
||||
@@ -1,66 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierfile;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.yxt.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(仓储基础信息供应商) <br/>
|
||||
* File: BaseSupplierFile.java <br/>
|
||||
* Class: com.yxt.anrui.as.api.basesupplierfile.BaseSupplierFile <br/>
|
||||
* Description: 供应商附件. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-13 16:51:56 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商附件", description = "供应商附件")
|
||||
@TableName("base_supplier_file")
|
||||
public class BaseSupplierFile extends BaseEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("文件名")
|
||||
private String fileName; // 文件名
|
||||
@ApiModelProperty("文件类型")
|
||||
private String fileType; // 文件类型
|
||||
@ApiModelProperty("关联业务对象sid")
|
||||
private String linkSid; // 关联业务对象sid
|
||||
@ApiModelProperty("附件类型")
|
||||
private String attachType; // 附件类型
|
||||
@ApiModelProperty("文件大小")
|
||||
private String fileSize; // 文件大小
|
||||
@ApiModelProperty("文件的路径")
|
||||
private String filePath; // 文件的路径
|
||||
|
||||
}
|
||||
@@ -1,66 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierfile;
|
||||
|
||||
|
||||
import com.yxt.common.core.vo.Vo;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(仓储基础信息供应商) <br/>
|
||||
* File: BaseSupplierFileVo.java <br/>
|
||||
* Class: com.yxt.anrui.as.api.basesupplierfile.BaseSupplierFileVo <br/>
|
||||
* Description: 供应商附件 视图数据对象. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-13 16:51:56 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商附件 视图数据详情", description = "供应商附件 视图数据详情")
|
||||
public class BaseSupplierFileDetailsVo implements Vo {
|
||||
|
||||
private String sid; // sid
|
||||
|
||||
@ApiModelProperty("文件名")
|
||||
private String fileName; // 文件名
|
||||
@ApiModelProperty("文件类型")
|
||||
private String fileType; // 文件类型
|
||||
@ApiModelProperty("关联业务对象sid")
|
||||
private String linkSid; // 关联业务对象sid
|
||||
@ApiModelProperty("附件类型")
|
||||
private String attachType; // 附件类型
|
||||
@ApiModelProperty("文件大小")
|
||||
private String fileSize; // 文件大小
|
||||
@ApiModelProperty("文件的路径")
|
||||
private String filePath; // 文件的路径
|
||||
|
||||
}
|
||||
@@ -1,66 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierfile;
|
||||
|
||||
|
||||
import com.yxt.common.core.dto.Dto;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(仓储基础信息供应商) <br/>
|
||||
* File: BaseSupplierFileDto.java <br/>
|
||||
* Class: com.yxt.anrui.as.api.basesupplierfile.BaseSupplierFileDto <br/>
|
||||
* Description: 供应商附件 数据传输对象. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-13 16:51:56 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商附件 数据传输对象", description = "供应商附件 数据传输对象")
|
||||
public class BaseSupplierFileDto implements Dto {
|
||||
|
||||
private String sid; // sid
|
||||
|
||||
@ApiModelProperty("文件名")
|
||||
private String fileName; // 文件名
|
||||
@ApiModelProperty("文件类型")
|
||||
private String fileType; // 文件类型
|
||||
@ApiModelProperty("关联业务对象sid")
|
||||
private String linkSid; // 关联业务对象sid
|
||||
@ApiModelProperty("附件类型")
|
||||
private String attachType; // 附件类型
|
||||
@ApiModelProperty("文件大小")
|
||||
private String fileSize; // 文件大小
|
||||
@ApiModelProperty("文件的路径")
|
||||
private String filePath; // 文件的路径
|
||||
|
||||
}
|
||||
@@ -1,60 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierfile;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.Wrapper;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Constants;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.apache.ibatis.annotations.Select;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(仓储基础信息供应商) <br/>
|
||||
* File: BaseSupplierFileMapper.java <br/>
|
||||
* Class: com.yxt.anrui.as.biz.basesupplierfile.BaseSupplierFileMapper <br/>
|
||||
* Description: 供应商附件. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-13 16:51:56 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Mapper
|
||||
public interface BaseSupplierFileMapper extends BaseMapper<BaseSupplierFile> {
|
||||
|
||||
IPage<BaseSupplierFileVo> selectPageVo(IPage<BaseSupplierFile> page, @Param(Constants.WRAPPER) Wrapper<BaseSupplierFile> qw);
|
||||
|
||||
List<BaseSupplierFileVo> selectListAllVo(@Param(Constants.WRAPPER) Wrapper<BaseSupplierFile> qw);
|
||||
|
||||
@Select("select * from base_supplier_file")
|
||||
List<BaseSupplierFileVo> selectListVo();
|
||||
}
|
||||
@@ -1,13 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.yxt.goods.biz.base.basesupplierfile.BaseSupplierFileMapper">
|
||||
<!-- <where> ${ew.sqlSegment} </where>-->
|
||||
<!-- ${ew.customSqlSegment} -->
|
||||
<select id="selectPageVo" resultType="com.yxt.goods.biz.base.basesupplierfile.BaseSupplierFileVo">
|
||||
SELECT * FROM base_supplier_file <where> ${ew.sqlSegment} </where>
|
||||
</select>
|
||||
|
||||
<select id="selectListAllVo" resultType="com.yxt.goods.biz.base.basesupplierfile.BaseSupplierFileVo">
|
||||
SELECT * FROM base_supplier_file <where> ${ew.sqlSegment} </where>
|
||||
</select>
|
||||
</mapper>
|
||||
@@ -1,64 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierfile;
|
||||
|
||||
|
||||
import com.yxt.common.core.query.Query;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(仓储基础信息供应商) <br/>
|
||||
* File: BaseSupplierFileQuery.java <br/>
|
||||
* Class: com.yxt.anrui.as.api.basesupplierfile.BaseSupplierFileQuery <br/>
|
||||
* Description: 供应商附件 查询条件. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-13 16:51:56 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商附件 查询条件", description = "供应商附件 查询条件")
|
||||
public class BaseSupplierFileQuery implements Query {
|
||||
|
||||
@ApiModelProperty("文件名")
|
||||
private String fileName; // 文件名
|
||||
@ApiModelProperty("文件类型")
|
||||
private String fileType; // 文件类型
|
||||
@ApiModelProperty("关联业务对象sid")
|
||||
private String linkSid; // 关联业务对象sid
|
||||
@ApiModelProperty("附件类型")
|
||||
private String attachType; // 附件类型
|
||||
@ApiModelProperty("文件大小")
|
||||
private String fileSize; // 文件大小
|
||||
@ApiModelProperty("文件的路径")
|
||||
private String filePath; // 文件的路径
|
||||
|
||||
}
|
||||
@@ -1,94 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierfile;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.yxt.common.base.service.MybatisBaseService;
|
||||
import com.yxt.common.base.utils.PagerUtil;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(仓储基础信息供应商) <br/>
|
||||
* File: BaseSupplierFileService.java <br/>
|
||||
* Class: com.yxt.anrui.as.biz.basesupplierfile.BaseSupplierFileService <br/>
|
||||
* Description: 供应商附件 业务逻辑. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-13 16:51:56 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Service
|
||||
public class BaseSupplierFileService extends MybatisBaseService<BaseSupplierFileMapper, BaseSupplierFile> {
|
||||
|
||||
public PagerVo<BaseSupplierFileVo> listPageVo(PagerQuery<BaseSupplierFileQuery> pq) {
|
||||
BaseSupplierFileQuery query = pq.getParams();
|
||||
QueryWrapper<BaseSupplierFile> qw = new QueryWrapper<>();
|
||||
IPage<BaseSupplierFile> page = PagerUtil.queryToPage(pq);
|
||||
IPage<BaseSupplierFileVo> pagging = baseMapper.selectPageVo(page, qw);
|
||||
PagerVo<BaseSupplierFileVo> p = PagerUtil.pageToVo(pagging, null);
|
||||
return p;
|
||||
}
|
||||
|
||||
public void saveOrUpdateDto(BaseSupplierFileDto dto){
|
||||
String dtoSid = dto.getSid();
|
||||
if (StringUtils.isBlank(dtoSid)) {
|
||||
this.insertByDto(dto);
|
||||
return;
|
||||
}
|
||||
this.updateByDto(dto);
|
||||
}
|
||||
|
||||
public void insertByDto(BaseSupplierFileDto dto){
|
||||
BaseSupplierFile entity = new BaseSupplierFile();
|
||||
BeanUtil.copyProperties(dto, entity, "id", "sid");
|
||||
baseMapper.insert(entity);
|
||||
}
|
||||
|
||||
public void updateByDto(BaseSupplierFileDto dto){
|
||||
String dtoSid = dto.getSid();
|
||||
if (StringUtils.isBlank(dtoSid)) {
|
||||
return;
|
||||
}
|
||||
BaseSupplierFile entity = fetchBySid(dtoSid);
|
||||
BeanUtil.copyProperties(dto, entity, "id", "sid");
|
||||
baseMapper.updateById(entity);
|
||||
}
|
||||
|
||||
public BaseSupplierFileDetailsVo fetchDetailsVoBySid(String sid){
|
||||
BaseSupplierFile entity = fetchBySid(sid);
|
||||
BaseSupplierFileDetailsVo vo = new BaseSupplierFileDetailsVo();
|
||||
BeanUtil.copyProperties(entity, vo);
|
||||
return vo;
|
||||
}
|
||||
}
|
||||
@@ -1,66 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierfile;
|
||||
|
||||
|
||||
import com.yxt.common.core.vo.Vo;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(仓储基础信息供应商) <br/>
|
||||
* File: BaseSupplierFileVo.java <br/>
|
||||
* Class: com.yxt.anrui.as.api.basesupplierfile.BaseSupplierFileVo <br/>
|
||||
* Description: 供应商附件 视图数据对象. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-13 16:51:56 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商附件 视图数据对象", description = "供应商附件 视图数据对象")
|
||||
public class BaseSupplierFileVo implements Vo {
|
||||
|
||||
private String sid; // sid
|
||||
|
||||
@ApiModelProperty("文件名")
|
||||
private String fileName; // 文件名
|
||||
@ApiModelProperty("文件类型")
|
||||
private String fileType; // 文件类型
|
||||
@ApiModelProperty("关联业务对象sid")
|
||||
private String linkSid; // 关联业务对象sid
|
||||
@ApiModelProperty("附件类型")
|
||||
private String attachType; // 附件类型
|
||||
@ApiModelProperty("文件大小")
|
||||
private String fileSize; // 文件大小
|
||||
@ApiModelProperty("文件的路径")
|
||||
private String filePath; // 文件的路径
|
||||
|
||||
}
|
||||
@@ -1,112 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierinfo;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.yxt.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(供应商管理) <br/>
|
||||
* File: BaseSupplierInfo.java <br/>
|
||||
* Class: com.yxt.base.api.basesupplierinfo.BaseSupplierInfo <br/>
|
||||
* Description: 供应商信息. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-18 13:33:13 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商信息", description = "供应商信息")
|
||||
@TableName("base_supplier_info")
|
||||
public class BaseSupplierInfo extends BaseEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("编码")
|
||||
private String supplierCode; // 编码
|
||||
@ApiModelProperty("供应商名称")
|
||||
private String supplierName; // 供应商名称
|
||||
@ApiModelProperty("供应商名称拼音")
|
||||
private String supplierPY; // 供应商名称拼音
|
||||
@ApiModelProperty("供应商类型sid")
|
||||
private String supplierTypeSid; // 供应商类型sid
|
||||
@ApiModelProperty("供应商类型")
|
||||
private String supplierTypeName; // 供应商类型
|
||||
@ApiModelProperty("省sid")
|
||||
private String provinceSid; // 省sid
|
||||
@ApiModelProperty("province")
|
||||
private String province; //
|
||||
@ApiModelProperty("市sid")
|
||||
private String citySid; // 市sid
|
||||
@ApiModelProperty("city")
|
||||
private String city; //
|
||||
@ApiModelProperty("收货县区sid")
|
||||
private String countySid; // 收货县区sid
|
||||
@ApiModelProperty("county")
|
||||
private String county; //
|
||||
@ApiModelProperty("详细地址")
|
||||
private String address; // 详细地址
|
||||
@ApiModelProperty("手机")
|
||||
private String contactMobile; // 手机
|
||||
@ApiModelProperty("电话")
|
||||
private String contactTelePhone; // 电话
|
||||
@ApiModelProperty("联系人")
|
||||
private String contactName; // 联系人
|
||||
@ApiModelProperty("传真")
|
||||
private String fax; // 传真
|
||||
@ApiModelProperty("邮编")
|
||||
private String zipCode; // 邮编
|
||||
@ApiModelProperty("电子邮件")
|
||||
private String email; // 电子邮件
|
||||
@ApiModelProperty("网址")
|
||||
private String website; // 网址
|
||||
@ApiModelProperty("开票公司名称")
|
||||
private String billingCompanyName; // 开票公司名称
|
||||
@ApiModelProperty("税号")
|
||||
private String registNum; // 税号
|
||||
@ApiModelProperty("法人")
|
||||
private String legalName; // 法人
|
||||
@ApiModelProperty("采购员")
|
||||
private String purchaser; // 采购员
|
||||
@ApiModelProperty("排序")
|
||||
private Integer sortNo; // 排序
|
||||
@ApiModelProperty("开票类型key")
|
||||
private String billingTypeKey; // 开票类型key
|
||||
@ApiModelProperty("开票类型value")
|
||||
private String billingTypeValue; // 开票类型value
|
||||
@ApiModelProperty("使用组织sid")
|
||||
private String useOrgSid; // 使用组织sid
|
||||
@ApiModelProperty("创建组织名称")
|
||||
private String createOrgName; // 创建组织名称
|
||||
@ApiModelProperty("创建组织sid")
|
||||
private String createOrgSid; // 创建组织sid
|
||||
|
||||
}
|
||||
@@ -1,54 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierinfo;
|
||||
|
||||
|
||||
import com.yxt.common.core.vo.Vo;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(供应商管理) <br/>
|
||||
* File: BaseSupplierInfoVo.java <br/>
|
||||
* Class: com.yxt.base.api.basesupplierinfo.BaseSupplierInfoVo <br/>
|
||||
* Description: 供应商信息 视图数据对象. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-18 13:33:13 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商信息 视图数据对象", description = "供应商信息 视图数据对象")
|
||||
public class BaseSupplierInfoChoice implements Vo {
|
||||
|
||||
private String sid;
|
||||
@ApiModelProperty("供应商名称")
|
||||
private String supplierName;
|
||||
}
|
||||
@@ -1,116 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierinfo;
|
||||
|
||||
|
||||
import com.yxt.goods.biz.base.basesupplierBank.BaseSupplierBankDetailsVo;
|
||||
import com.yxt.common.core.vo.Vo;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(供应商管理) <br/>
|
||||
* File: BaseSupplierInfoVo.java <br/>
|
||||
* Class: com.yxt.base.api.basesupplierinfo.BaseSupplierInfoVo <br/>
|
||||
* Description: 供应商信息 视图数据对象. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-18 13:33:13 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商信息 视图数据详情", description = "供应商信息 视图数据详情")
|
||||
public class BaseSupplierInfoDetailsVo implements Vo {
|
||||
|
||||
private String sid; // sid
|
||||
|
||||
@ApiModelProperty("编码")
|
||||
private String supplierCode; // 编码
|
||||
@ApiModelProperty("供应商名称")
|
||||
private String supplierName; // 供应商名称
|
||||
@ApiModelProperty("供应商名称拼音")
|
||||
private String supplierPY; // 供应商名称拼音
|
||||
@ApiModelProperty("供应商类型sid")
|
||||
private String supplierTypeSid; // 供应商类型sid
|
||||
@ApiModelProperty("供应商类型")
|
||||
private String supplierTypeName; // 供应商类型
|
||||
@ApiModelProperty("省sid")
|
||||
private String provinceSid; // 省sid
|
||||
@ApiModelProperty("province")
|
||||
private String province; //
|
||||
@ApiModelProperty("市sid")
|
||||
private String citySid; // 市sid
|
||||
@ApiModelProperty("city")
|
||||
private String city; //
|
||||
@ApiModelProperty("收货县区sid")
|
||||
private String countySid; // 收货县区sid
|
||||
@ApiModelProperty("county")
|
||||
private String county; //
|
||||
@ApiModelProperty("详细地址")
|
||||
private String address; // 详细地址
|
||||
@ApiModelProperty("手机")
|
||||
private String contactMobile; // 手机
|
||||
@ApiModelProperty("电话")
|
||||
private String contactTelePhone; // 电话
|
||||
@ApiModelProperty("联系人")
|
||||
private String contactName; // 联系人
|
||||
@ApiModelProperty("传真")
|
||||
private String fax; // 传真
|
||||
@ApiModelProperty("邮编")
|
||||
private String zipCode; // 邮编
|
||||
@ApiModelProperty("电子邮件")
|
||||
private String email; // 电子邮件
|
||||
@ApiModelProperty("网址")
|
||||
private String website; // 网址
|
||||
@ApiModelProperty("开票公司名称")
|
||||
private String billingCompanyName; // 开票公司名称
|
||||
@ApiModelProperty("税号")
|
||||
private String registNum; // 税号
|
||||
@ApiModelProperty("法人")
|
||||
private String legalName; // 法人
|
||||
@ApiModelProperty("采购员")
|
||||
private String purchaser; // 采购员
|
||||
@ApiModelProperty("排序")
|
||||
private Integer sortNo; // 排序
|
||||
@ApiModelProperty("开票类型key")
|
||||
private String billingTypeKey; // 开票类型key
|
||||
@ApiModelProperty("开票类型value")
|
||||
private String billingTypeValue; // 开票类型value
|
||||
@ApiModelProperty("使用组织sid")
|
||||
private String useOrgSid; // 使用组织sid
|
||||
@ApiModelProperty("创建组织名称")
|
||||
private String createOrgName; // 创建组织名称
|
||||
@ApiModelProperty("创建组织sid")
|
||||
private String createOrgSid; // 创建组织sid
|
||||
@ApiModelProperty("供应商开户行")
|
||||
private List<BaseSupplierBankDetailsVo> baseSupplierBankList;
|
||||
}
|
||||
@@ -1,116 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierinfo;
|
||||
|
||||
|
||||
import com.yxt.goods.biz.base.basesupplierBank.BaseSupplierBankDto;
|
||||
import com.yxt.common.core.dto.Dto;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(供应商管理) <br/>
|
||||
* File: BaseSupplierInfoDto.java <br/>
|
||||
* Class: com.yxt.base.api.basesupplierinfo.BaseSupplierInfoDto <br/>
|
||||
* Description: 供应商信息 数据传输对象. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-18 13:33:13 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商信息 数据传输对象", description = "供应商信息 数据传输对象")
|
||||
public class BaseSupplierInfoDto implements Dto {
|
||||
|
||||
private String sid; // sid
|
||||
|
||||
@ApiModelProperty("编码")
|
||||
private String supplierCode; // 编码
|
||||
@ApiModelProperty("供应商名称")
|
||||
private String supplierName; // 供应商名称
|
||||
@ApiModelProperty("供应商名称拼音")
|
||||
private String supplierPY; // 供应商名称拼音
|
||||
@ApiModelProperty("供应商类型sid")
|
||||
private String supplierTypeSid; // 供应商类型sid
|
||||
@ApiModelProperty("供应商类型")
|
||||
private String supplierTypeName; // 供应商类型
|
||||
@ApiModelProperty("省sid")
|
||||
private String provinceSid; // 省sid
|
||||
@ApiModelProperty("province")
|
||||
private String province; //
|
||||
@ApiModelProperty("市sid")
|
||||
private String citySid; // 市sid
|
||||
@ApiModelProperty("city")
|
||||
private String city; //
|
||||
@ApiModelProperty("收货县区sid")
|
||||
private String countySid; // 收货县区sid
|
||||
@ApiModelProperty("county")
|
||||
private String county; //
|
||||
@ApiModelProperty("详细地址")
|
||||
private String address; // 详细地址
|
||||
@ApiModelProperty("手机")
|
||||
private String contactMobile; // 手机
|
||||
@ApiModelProperty("电话")
|
||||
private String contactTelePhone; // 电话
|
||||
@ApiModelProperty("联系人")
|
||||
private String contactName; // 联系人
|
||||
@ApiModelProperty("传真")
|
||||
private String fax; // 传真
|
||||
@ApiModelProperty("邮编")
|
||||
private String zipCode; // 邮编
|
||||
@ApiModelProperty("电子邮件")
|
||||
private String email; // 电子邮件
|
||||
@ApiModelProperty("网址")
|
||||
private String website; // 网址
|
||||
@ApiModelProperty("开票公司名称")
|
||||
private String billingCompanyName; // 开票公司名称
|
||||
@ApiModelProperty("税号")
|
||||
private String registNum; // 税号
|
||||
@ApiModelProperty("法人")
|
||||
private String legalName; // 法人
|
||||
@ApiModelProperty("采购员")
|
||||
private String purchaser; // 采购员
|
||||
@ApiModelProperty("排序")
|
||||
private Integer sortNo; // 排序
|
||||
@ApiModelProperty("开票类型key")
|
||||
private String billingTypeKey; // 开票类型key
|
||||
@ApiModelProperty("开票类型value")
|
||||
private String billingTypeValue; // 开票类型value
|
||||
@ApiModelProperty("使用组织sid")
|
||||
private String useOrgSid; // 使用组织sid
|
||||
@ApiModelProperty("创建组织名称")
|
||||
private String createOrgName; // 创建组织名称
|
||||
@ApiModelProperty("创建组织sid")
|
||||
private String createOrgSid; // 创建组织sid
|
||||
@ApiModelProperty("开户行信息")
|
||||
private List<BaseSupplierBankDto> baseSupplierBankList;
|
||||
}
|
||||
@@ -1,67 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierinfo;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.Wrapper;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Constants;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.apache.ibatis.annotations.Select;
|
||||
import org.apache.ibatis.annotations.Update;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(仓储基础信息供应商) <br/>
|
||||
* File: BaseSupplierInfoMapper.java <br/>
|
||||
* Class: com.yxt.anrui.as.biz.basesupplierinfo.BaseSupplierInfoMapper <br/>
|
||||
* Description: 供应商信息. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-13 16:51:56 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Mapper
|
||||
public interface BaseSupplierInfoMapper extends BaseMapper<BaseSupplierInfo> {
|
||||
|
||||
IPage<BaseSupplierInfoVo> selectPageVo(IPage<BaseSupplierInfo> page, @Param(Constants.WRAPPER) Wrapper<BaseSupplierInfo> qw);
|
||||
|
||||
List<BaseSupplierInfoVo> selectListAllVo(@Param(Constants.WRAPPER) Wrapper<BaseSupplierInfo> qw);
|
||||
|
||||
@Select("select * from base_supplier_info")
|
||||
List<BaseSupplierInfoVo> selectListVo();
|
||||
|
||||
@Update("update base_supplier_info set isDelete = '1' where sid = #{sid}")
|
||||
int updateBySidIsDelete(String sid);
|
||||
|
||||
@Select("select * from base_supplier_info")
|
||||
List<BaseSupplierInfoChoice> choiceSupplierInfo(String createOrgSid);
|
||||
}
|
||||
@@ -1,13 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.yxt.goods.biz.base.basesupplierinfo.BaseSupplierInfoMapper">
|
||||
<!-- <where> ${ew.sqlSegment} </where>-->
|
||||
<!-- ${ew.customSqlSegment} -->
|
||||
<select id="selectPageVo" resultType="com.yxt.goods.biz.base.basesupplierinfo.BaseSupplierInfoVo">
|
||||
SELECT * FROM base_supplier_info <where> ${ew.sqlSegment} </where>
|
||||
</select>
|
||||
|
||||
<select id="selectListAllVo" resultType="com.yxt.goods.biz.base.basesupplierinfo.BaseSupplierInfoVo">
|
||||
SELECT * FROM base_supplier_info <where> ${ew.sqlSegment} </where>
|
||||
</select>
|
||||
</mapper>
|
||||
@@ -1,62 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierinfo;
|
||||
|
||||
|
||||
import com.yxt.common.core.query.Query;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(供应商管理) <br/>
|
||||
* File: BaseSupplierInfoQuery.java <br/>
|
||||
* Class: com.yxt.base.api.basesupplierinfo.BaseSupplierInfoQuery <br/>
|
||||
* Description: 供应商信息 查询条件. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-18 13:33:13 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商信息 查询条件", description = "供应商信息 查询条件")
|
||||
public class BaseSupplierInfoQuery implements Query {
|
||||
|
||||
@ApiModelProperty("供应商名称")
|
||||
private String supplierName;
|
||||
@ApiModelProperty("供应商类型")
|
||||
private String supplierTypeName;
|
||||
@ApiModelProperty("电话")
|
||||
private String contactTelePhone;
|
||||
@ApiModelProperty("联系人")
|
||||
private String contactName;
|
||||
|
||||
@ApiModelProperty("其他查询条件")
|
||||
private String otherQuery;
|
||||
}
|
||||
@@ -1,168 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierinfo;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.yxt.goods.biz.base.basesupplierBank.BaseSupplierBank;
|
||||
import com.yxt.goods.biz.base.basesupplierBank.BaseSupplierBankDetailsVo;
|
||||
import com.yxt.goods.biz.base.basesupplierBank.BaseSupplierBankDto;
|
||||
import com.yxt.goods.biz.base.basesupplierBank.BaseSupplierBankService;
|
||||
import com.yxt.goods.feign.portal.sysorganization.SysOrganizationFeign;
|
||||
import com.yxt.goods.feign.portal.sysstafforg.SysStaffOrgFeign;
|
||||
import com.yxt.common.base.service.MybatisBaseService;
|
||||
import com.yxt.common.base.utils.PagerUtil;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(仓储基础信息供应商) <br/>
|
||||
* File: BaseSupplierInfoService.java <br/>
|
||||
* Class: com.yxt.anrui.as.biz.basesupplierinfo.BaseSupplierInfoService <br/>
|
||||
* Description: 供应商信息 业务逻辑. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-13 16:51:56 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Service
|
||||
public class BaseSupplierInfoService extends MybatisBaseService<BaseSupplierInfoMapper, BaseSupplierInfo> {
|
||||
|
||||
@Autowired
|
||||
private SysStaffOrgFeign sysStaffOrgFeign;
|
||||
@Autowired
|
||||
private SysOrganizationFeign sysOrganizationFeign;
|
||||
@Autowired
|
||||
private BaseSupplierBankService baseSupplierBankService;
|
||||
|
||||
public PagerVo<BaseSupplierInfoVo> listPageVo(PagerQuery<BaseSupplierInfoQuery> pq) {
|
||||
BaseSupplierInfoQuery query = pq.getParams();
|
||||
QueryWrapper<BaseSupplierInfo> qw = new QueryWrapper<BaseSupplierInfo>();
|
||||
if (StringUtils.isNotBlank(query.getSupplierName())){
|
||||
qw.like("supplierName",query.getSupplierName());
|
||||
}
|
||||
if (StringUtils.isNotBlank(query.getSupplierTypeName())){
|
||||
qw.like("supplierTypeName",query.getSupplierTypeName());
|
||||
}
|
||||
if (StringUtils.isNotBlank(query.getContactTelePhone())){
|
||||
qw.like("contactTelePhone",query.getContactTelePhone());
|
||||
}
|
||||
if (StringUtils.isNotBlank(query.getContactName())){
|
||||
qw.like("contactName",query.getContactName());
|
||||
}
|
||||
if (StringUtils.isNotBlank(query.getOtherQuery())){
|
||||
qw.and(wrapper -> wrapper.like("supplierName", query.getOtherQuery()).or().like("supplierPY", query.getOtherQuery()).or().like("contactTelePhone",query.getOtherQuery()));
|
||||
}
|
||||
qw.eq("isDelete",0);
|
||||
IPage<BaseSupplierInfo> page = PagerUtil.queryToPage(pq);
|
||||
IPage<BaseSupplierInfoVo> pagging = baseMapper.selectPageVo(page, qw);
|
||||
PagerVo<BaseSupplierInfoVo> p = PagerUtil.pageToVo(pagging, null);
|
||||
return p;
|
||||
}
|
||||
|
||||
public ResultBean saveOrUpdateDto(BaseSupplierInfoDto dto){
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
String dtoSid = dto.getSid();
|
||||
List<BaseSupplierBankDto> baseSupplierBankDtoList = dto.getBaseSupplierBankList();
|
||||
if (baseSupplierBankDtoList == null || baseSupplierBankDtoList.size() == 0){
|
||||
return rb.setMsg("开户行信息不能为空");
|
||||
}
|
||||
if (StringUtils.isBlank(dtoSid)) {
|
||||
String sid = this.insertByDto(dto);
|
||||
for (BaseSupplierBankDto baseSupplierBankDto : baseSupplierBankDtoList) {
|
||||
baseSupplierBankDto.setSupplierSid(sid);
|
||||
baseSupplierBankService.saveOrUpdateDto(baseSupplierBankDto);
|
||||
}
|
||||
return rb.success();
|
||||
}
|
||||
this.updateByDto(dto);
|
||||
for (BaseSupplierBankDto baseSupplierBankDto : baseSupplierBankDtoList) {
|
||||
String bankSid = baseSupplierBankDto.getSid();
|
||||
if(StringUtils.isNotBlank(bankSid)){
|
||||
BaseSupplierBank baseSupplierBank = baseSupplierBankService.fetchBySid(bankSid);
|
||||
BeanUtil.copyProperties(baseSupplierBankDto,baseSupplierBank,"sid");
|
||||
baseSupplierBank.setSupplierSid(dtoSid);
|
||||
baseSupplierBankService.updateById(baseSupplierBank);
|
||||
}else{
|
||||
BaseSupplierBank baseSupplierBank = new BaseSupplierBank();
|
||||
BeanUtil.copyProperties(baseSupplierBankDto,baseSupplierBank,"sid");
|
||||
baseSupplierBank.setSupplierSid(dtoSid);
|
||||
baseSupplierBankService.insert(baseSupplierBank);
|
||||
}
|
||||
}
|
||||
return rb.success();
|
||||
}
|
||||
|
||||
public String insertByDto(BaseSupplierInfoDto dto){
|
||||
BaseSupplierInfo entity = new BaseSupplierInfo();
|
||||
BeanUtil.copyProperties(dto, entity, "id", "sid");
|
||||
baseMapper.insert(entity);
|
||||
return entity.getSid();
|
||||
}
|
||||
|
||||
public void updateByDto(BaseSupplierInfoDto dto){
|
||||
String dtoSid = dto.getSid();
|
||||
if (StringUtils.isBlank(dtoSid)) {
|
||||
return;
|
||||
}
|
||||
BaseSupplierInfo entity = fetchBySid(dtoSid);
|
||||
BeanUtil.copyProperties(dto, entity, "id", "sid");
|
||||
baseMapper.updateById(entity);
|
||||
}
|
||||
|
||||
public BaseSupplierInfoDetailsVo fetchDetailsVoBySid(String sid){
|
||||
BaseSupplierInfo entity = fetchBySid(sid);
|
||||
BaseSupplierInfoDetailsVo vo = new BaseSupplierInfoDetailsVo();
|
||||
BeanUtil.copyProperties(entity, vo);
|
||||
List<BaseSupplierBankDetailsVo> baseSupplierBankDetailsVos = baseSupplierBankService.selectBySupplierSid(sid);
|
||||
vo.setBaseSupplierBankList(baseSupplierBankDetailsVos);
|
||||
return vo;
|
||||
}
|
||||
|
||||
public void delAll(String[] sids) {
|
||||
for (String sid : sids) {
|
||||
//删除厂商基础信息
|
||||
int count = baseMapper.updateBySidIsDelete(sid);
|
||||
//删除厂商开户行信息
|
||||
int i = baseSupplierBankService.deleteBySupplierSid(sid);
|
||||
}
|
||||
}
|
||||
|
||||
public List<BaseSupplierInfoChoice> choiceSupplierInfo(String createOrgSid) {
|
||||
List<BaseSupplierInfoChoice> baseSupplierInfoChoiceList = baseMapper.choiceSupplierInfo(createOrgSid);
|
||||
return baseSupplierInfoChoiceList;
|
||||
}
|
||||
}
|
||||
@@ -1,65 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesupplierinfo;
|
||||
|
||||
|
||||
import com.yxt.common.core.vo.Vo;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(供应商管理) <br/>
|
||||
* File: BaseSupplierInfoVo.java <br/>
|
||||
* Class: com.yxt.base.api.basesupplierinfo.BaseSupplierInfoVo <br/>
|
||||
* Description: 供应商信息 视图数据对象. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-18 13:33:13 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商信息 视图数据对象", description = "供应商信息 视图数据对象")
|
||||
public class BaseSupplierInfoVo implements Vo {
|
||||
|
||||
private String sid; // sid
|
||||
|
||||
@ApiModelProperty("供应商名称")
|
||||
private String supplierName;
|
||||
@ApiModelProperty("供应商类型")
|
||||
private String supplierTypeName;
|
||||
@ApiModelProperty("详细地址")
|
||||
private String address;
|
||||
@ApiModelProperty("电话")
|
||||
private String contactTelePhone;
|
||||
@ApiModelProperty("联系人")
|
||||
private String contactName;
|
||||
@ApiModelProperty("手机")
|
||||
private String contactMobile;
|
||||
}
|
||||
@@ -1,62 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesuppliertype;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.yxt.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(仓储基础信息供应商) <br/>
|
||||
* File: BaseSupplierType.java <br/>
|
||||
* Class: com.yxt.anrui.as.api.basesuppliertype.BaseSupplierType <br/>
|
||||
* Description: 供应商类型. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-13 16:51:56 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商类型", description = "供应商类型")
|
||||
@TableName("base_supplier_type")
|
||||
public class BaseSupplierType extends BaseEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("供应商类型名称")
|
||||
private String supplierTypeName; // 供应商类型名称
|
||||
@ApiModelProperty("使用组织sid")
|
||||
private String useOrgSid; // 使用组织sid
|
||||
@ApiModelProperty("创建组织名称")
|
||||
private String createOrgName; // 创建组织名称
|
||||
@ApiModelProperty("创建组织sid")
|
||||
private String createOrgSid; // 创建组织sid
|
||||
|
||||
}
|
||||
@@ -1,61 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesuppliertype;
|
||||
|
||||
|
||||
import com.yxt.common.core.vo.Vo;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(仓储基础信息供应商) <br/>
|
||||
* File: BaseSupplierTypeVo.java <br/>
|
||||
* Class: com.yxt.anrui.as.api.basesuppliertype.BaseSupplierTypeVo <br/>
|
||||
* Description: 供应商类型 视图数据对象. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-13 16:51:56 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商类型 视图数据详情", description = "供应商类型 视图数据详情")
|
||||
public class BaseSupplierTypeDetailsVo implements Vo {
|
||||
private String sid; // sid
|
||||
|
||||
@ApiModelProperty("供应商类型名称")
|
||||
private String supplierTypeName; // 供应商类型名称
|
||||
@ApiModelProperty("使用组织sid")
|
||||
private String useOrgSid; // 使用组织sid
|
||||
@ApiModelProperty("创建组织名称")
|
||||
private String createOrgName; // 创建组织名称
|
||||
@ApiModelProperty("创建组织sid")
|
||||
private String createOrgSid; // 创建组织sid
|
||||
|
||||
}
|
||||
@@ -1,62 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesuppliertype;
|
||||
|
||||
|
||||
import com.yxt.common.core.dto.Dto;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(仓储基础信息供应商) <br/>
|
||||
* File: BaseSupplierTypeDto.java <br/>
|
||||
* Class: com.yxt.anrui.as.api.basesuppliertype.BaseSupplierTypeDto <br/>
|
||||
* Description: 供应商类型 数据传输对象. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-13 16:51:56 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商类型 数据传输对象", description = "供应商类型 数据传输对象")
|
||||
public class BaseSupplierTypeDto implements Dto {
|
||||
|
||||
private String sid; // sid
|
||||
|
||||
@ApiModelProperty("供应商类型名称")
|
||||
private String supplierTypeName; // 供应商类型名称
|
||||
@ApiModelProperty("使用组织sid")
|
||||
private String useOrgSid; // 使用组织sid
|
||||
@ApiModelProperty("创建组织名称")
|
||||
private String createOrgName; // 创建组织名称
|
||||
@ApiModelProperty("创建组织sid")
|
||||
private String createOrgSid; // 创建组织sid
|
||||
|
||||
}
|
||||
@@ -1,60 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesuppliertype;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.Wrapper;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Constants;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.apache.ibatis.annotations.Select;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(仓储基础信息供应商) <br/>
|
||||
* File: BaseSupplierTypeMapper.java <br/>
|
||||
* Class: com.yxt.anrui.as.biz.basesuppliertype.BaseSupplierTypeMapper <br/>
|
||||
* Description: 供应商类型. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-13 16:51:56 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Mapper
|
||||
public interface BaseSupplierTypeMapper extends BaseMapper<BaseSupplierType> {
|
||||
|
||||
IPage<BaseSupplierTypeVo> selectPageVo(IPage<BaseSupplierType> page, @Param(Constants.WRAPPER) Wrapper<BaseSupplierType> qw);
|
||||
|
||||
List<BaseSupplierTypeVo> selectListAllVo(@Param(Constants.WRAPPER) Wrapper<BaseSupplierType> qw);
|
||||
|
||||
@Select("select * from base_supplier_type")
|
||||
List<BaseSupplierTypeVo> selectListVo();
|
||||
}
|
||||
@@ -1,13 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.yxt.goods.biz.base.basesuppliertype.BaseSupplierTypeMapper">
|
||||
<!-- <where> ${ew.sqlSegment} </where>-->
|
||||
<!-- ${ew.customSqlSegment} -->
|
||||
<select id="selectPageVo" resultType="com.yxt.goods.biz.base.basesuppliertype.BaseSupplierTypeVo">
|
||||
SELECT * FROM base_supplier_type <where> ${ew.sqlSegment} </where>
|
||||
</select>
|
||||
|
||||
<select id="selectListAllVo" resultType="com.yxt.goods.biz.base.basesuppliertype.BaseSupplierTypeVo">
|
||||
SELECT * FROM base_supplier_type <where> ${ew.sqlSegment} </where>
|
||||
</select>
|
||||
</mapper>
|
||||
@@ -1,60 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesuppliertype;
|
||||
|
||||
|
||||
import com.yxt.common.core.query.Query;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(仓储基础信息供应商) <br/>
|
||||
* File: BaseSupplierTypeQuery.java <br/>
|
||||
* Class: com.yxt.anrui.as.api.basesuppliertype.BaseSupplierTypeQuery <br/>
|
||||
* Description: 供应商类型 查询条件. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-13 16:51:56 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商类型 查询条件", description = "供应商类型 查询条件")
|
||||
public class BaseSupplierTypeQuery implements Query {
|
||||
|
||||
@ApiModelProperty("供应商类型名称")
|
||||
private String supplierTypeName; // 供应商类型名称
|
||||
@ApiModelProperty("使用组织sid")
|
||||
private String useOrgSid; // 使用组织sid
|
||||
@ApiModelProperty("创建组织名称")
|
||||
private String createOrgName; // 创建组织名称
|
||||
@ApiModelProperty("创建组织sid")
|
||||
private String createOrgSid; // 创建组织sid
|
||||
|
||||
}
|
||||
@@ -1,94 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesuppliertype;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.yxt.common.base.service.MybatisBaseService;
|
||||
import com.yxt.common.base.utils.PagerUtil;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(仓储基础信息供应商) <br/>
|
||||
* File: BaseSupplierTypeService.java <br/>
|
||||
* Class: com.yxt.anrui.as.biz.basesuppliertype.BaseSupplierTypeService <br/>
|
||||
* Description: 供应商类型 业务逻辑. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-13 16:51:56 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Service
|
||||
public class BaseSupplierTypeService extends MybatisBaseService<BaseSupplierTypeMapper, BaseSupplierType> {
|
||||
|
||||
public PagerVo<BaseSupplierTypeVo> listPageVo(PagerQuery<BaseSupplierTypeQuery> pq) {
|
||||
BaseSupplierTypeQuery query = pq.getParams();
|
||||
QueryWrapper<BaseSupplierType> qw = new QueryWrapper<>();
|
||||
IPage<BaseSupplierType> page = PagerUtil.queryToPage(pq);
|
||||
IPage<BaseSupplierTypeVo> pagging = baseMapper.selectPageVo(page, qw);
|
||||
PagerVo<BaseSupplierTypeVo> p = PagerUtil.pageToVo(pagging, null);
|
||||
return p;
|
||||
}
|
||||
|
||||
public void saveOrUpdateDto(BaseSupplierTypeDto dto){
|
||||
String dtoSid = dto.getSid();
|
||||
if (StringUtils.isBlank(dtoSid)) {
|
||||
this.insertByDto(dto);
|
||||
return;
|
||||
}
|
||||
this.updateByDto(dto);
|
||||
}
|
||||
|
||||
public void insertByDto(BaseSupplierTypeDto dto){
|
||||
BaseSupplierType entity = new BaseSupplierType();
|
||||
BeanUtil.copyProperties(dto, entity, "id", "sid");
|
||||
baseMapper.insert(entity);
|
||||
}
|
||||
|
||||
public void updateByDto(BaseSupplierTypeDto dto){
|
||||
String dtoSid = dto.getSid();
|
||||
if (StringUtils.isBlank(dtoSid)) {
|
||||
return;
|
||||
}
|
||||
BaseSupplierType entity = fetchBySid(dtoSid);
|
||||
BeanUtil.copyProperties(dto, entity, "id", "sid");
|
||||
baseMapper.updateById(entity);
|
||||
}
|
||||
|
||||
public BaseSupplierTypeDetailsVo fetchDetailsVoBySid(String sid){
|
||||
BaseSupplierType entity = fetchBySid(sid);
|
||||
BaseSupplierTypeDetailsVo vo = new BaseSupplierTypeDetailsVo();
|
||||
BeanUtil.copyProperties(entity, vo);
|
||||
return vo;
|
||||
}
|
||||
}
|
||||
@@ -1,62 +0,0 @@
|
||||
/*********************************************************
|
||||
*********************************************************
|
||||
******************** *******************
|
||||
************* ************
|
||||
******* _oo0oo_ *******
|
||||
*** o8888888o ***
|
||||
* 88" . "88 *
|
||||
* (| -_- |) *
|
||||
* 0\ = /0 *
|
||||
* ___/`---'\___ *
|
||||
* .' \\| |// '. *
|
||||
* / \\||| : |||// \ *
|
||||
* / _||||| -:- |||||- \ *
|
||||
* | | \\\ - /// | | *
|
||||
* | \_| ''\---/'' |_/ | *
|
||||
* \ .-\__ '-' ___/-. / *
|
||||
* ___'. .' /--.--\ `. .'___ *
|
||||
* ."" '< `.___\_<|>_/___.' >' "". *
|
||||
* | | : `- \`.;`\ _ /`;.`/ - ` : | | *
|
||||
* \ \ `_. \_ __\ /__ _/ .-` / / *
|
||||
* =====`-.____`.___ \_____/___.-`___.-'===== *
|
||||
* `=---=' *
|
||||
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ *
|
||||
*********__佛祖保佑__永无BUG__验收通过__钞票多多__*********
|
||||
*********************************************************/
|
||||
package com.yxt.goods.biz.base.basesuppliertype;
|
||||
|
||||
|
||||
import com.yxt.common.core.vo.Vo;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Project: yxt-base(仓储基础信息供应商) <br/>
|
||||
* File: BaseSupplierTypeVo.java <br/>
|
||||
* Class: com.yxt.anrui.as.api.basesuppliertype.BaseSupplierTypeVo <br/>
|
||||
* Description: 供应商类型 视图数据对象. <br/>
|
||||
* Copyright: Copyright (c) 2011 <br/>
|
||||
* Company: https://gitee.com/liuzp315 <br/>
|
||||
* Makedate: 2024-03-13 16:51:56 <br/>
|
||||
*
|
||||
* @author liupopo
|
||||
* @version 1.0
|
||||
* @since 1.0
|
||||
*/
|
||||
@Data
|
||||
@ApiModel(value = "供应商类型 视图数据对象", description = "供应商类型 视图数据对象")
|
||||
public class BaseSupplierTypeVo implements Vo {
|
||||
|
||||
private String sid; // sid
|
||||
|
||||
@ApiModelProperty("供应商类型名称")
|
||||
private String supplierTypeName; // 供应商类型名称
|
||||
@ApiModelProperty("使用组织sid")
|
||||
private String useOrgSid; // 使用组织sid
|
||||
@ApiModelProperty("创建组织名称")
|
||||
private String createOrgName; // 创建组织名称
|
||||
@ApiModelProperty("创建组织sid")
|
||||
private String createOrgSid; // 创建组织sid
|
||||
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
package com.yxt.goods.biz.base.shoppingcart;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author wangpengfei
|
||||
* @date 2023/12/8 9:19
|
||||
*/
|
||||
@Mapper
|
||||
public interface ShoppingCartMapper extends BaseMapper<ShoppingCart> {
|
||||
List<ShoppingCartVo> ShoppingCartList(@Param("customerSid")String customerSid,
|
||||
@Param("brandId")String brandId,
|
||||
@Param("periodValidity")String periodValidity);
|
||||
}
|
||||
@@ -1,8 +0,0 @@
|
||||
package com.yxt.goods.biz.base.shoppingcart;
|
||||
|
||||
/**
|
||||
* @author wangpengfei
|
||||
* @date 2024/1/17 14:03
|
||||
*/
|
||||
public class ShoppingGoodsVo {
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basebrandinfo;
|
||||
package com.yxt.goods.biz.goodsbrandinfo;
|
||||
|
||||
import com.yxt.common.core.domain.BaseEntity;
|
||||
import lombok.Data;
|
||||
@@ -8,7 +8,7 @@ import lombok.Data;
|
||||
* @date 2024/2/26 13:36
|
||||
*/
|
||||
@Data
|
||||
public class BaseBrandInfo extends BaseEntity {
|
||||
public class GoodsBrandInfo extends BaseEntity {
|
||||
|
||||
private String brandName;//品牌代码
|
||||
private String brandCode;//品牌名称
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basebrandinfo;
|
||||
package com.yxt.goods.biz.goodsbrandinfo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.yxt.common.core.dto.Dto;
|
||||
@@ -11,7 +11,7 @@ import java.util.Date;
|
||||
* @date 2024/2/26 13:38
|
||||
*/
|
||||
@Data
|
||||
public class BaseBrandInfoDto implements Dto {
|
||||
public class GoodsBrandInfoDto implements Dto {
|
||||
private String id;
|
||||
private String sid;
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basegoodstype;
|
||||
package com.yxt.goods.biz.goodsbrandinfo;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
@@ -12,6 +12,7 @@ import org.apache.ibatis.annotations.Param;
|
||||
* @date 2024/2/26 13:40
|
||||
*/
|
||||
@Mapper
|
||||
public interface BaseGoodsTypeMapper extends BaseMapper<BaseGoodsType> {
|
||||
IPage<BaseGoodsTypeVo> listPage(IPage<BaseGoodsType> page, @Param(Constants.WRAPPER) QueryWrapper<BaseGoodsType> qw);
|
||||
public interface GoodsBrandInfoMapper extends BaseMapper<GoodsBrandInfo> {
|
||||
|
||||
IPage<GoodsBrandInfoVo> listPage(IPage<GoodsBrandInfo> page, @Param(Constants.WRAPPER) QueryWrapper<GoodsBrandInfo> qw);
|
||||
}
|
||||
@@ -1,10 +1,10 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.yxt.goods.biz.base.basebrandinfo.BaseBrandInfoMapper">
|
||||
<mapper namespace="com.yxt.goods.biz.goodsbrandinfo.GoodsBrandInfoMapper">
|
||||
<!-- <where> ${ew.sqlSegment} </where>-->
|
||||
<!-- ${ew.customSqlSegment} -->
|
||||
|
||||
<select id="listPage" resultType="com.yxt.goods.biz.base.basebrandinfo.BaseBrandInfoVo">
|
||||
<select id="listPage" resultType="com.yxt.goods.biz.goodsbrandinfo.GoodsBrandInfoVo">
|
||||
select
|
||||
*
|
||||
from base_brand_info
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basegoodssku;
|
||||
package com.yxt.goods.biz.goodsbrandinfo;
|
||||
|
||||
import com.yxt.common.core.query.Query;
|
||||
import lombok.Data;
|
||||
@@ -8,6 +8,6 @@ import lombok.Data;
|
||||
* @date 2024/2/26 13:37
|
||||
*/
|
||||
@Data
|
||||
public class BaseGoodsSkuQuery implements Query {
|
||||
public class GoodsBrandInfoQuery implements Query {
|
||||
private String name;
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basebrandinfo;
|
||||
package com.yxt.goods.biz.goodsbrandinfo;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import cn.hutool.core.date.DateTime;
|
||||
@@ -11,7 +11,6 @@ import com.yxt.common.base.utils.StringUtils;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
import com.yxt.goods.biz.base.basegoodstype.BaseGoodsType;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
@@ -25,22 +24,22 @@ import java.util.List;
|
||||
* @date 2024/2/26 13:40
|
||||
*/
|
||||
@Service
|
||||
public class BaseBrandInfoService extends MybatisBaseService<BaseBrandInfoMapper, BaseBrandInfo> {
|
||||
public class GoodsBrandInfoService extends MybatisBaseService<GoodsBrandInfoMapper, GoodsBrandInfo> {
|
||||
@Autowired
|
||||
private FileUploadComponent fileUploadComponent;
|
||||
|
||||
public ResultBean<PagerVo<BaseBrandInfoVo>> listPage(PagerQuery<BaseBrandInfoQuery> pq) {
|
||||
public ResultBean<PagerVo<GoodsBrandInfoVo>> listPage(PagerQuery<GoodsBrandInfoQuery> pq) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseBrandInfoQuery query = pq.getParams();
|
||||
QueryWrapper<BaseBrandInfo> qw = new QueryWrapper<>();
|
||||
GoodsBrandInfoQuery query = pq.getParams();
|
||||
QueryWrapper<GoodsBrandInfo> qw = new QueryWrapper<>();
|
||||
|
||||
if(StringUtils.isNotBlank(query.getName())){
|
||||
qw.like("brandName",query.getName());
|
||||
}
|
||||
IPage<BaseBrandInfo> page = PagerUtil.queryToPage(pq);
|
||||
IPage<BaseBrandInfoVo> pagging = baseMapper.listPage(page, qw);
|
||||
PagerVo<BaseBrandInfoVo> p = PagerUtil.pageToVo(pagging, null);
|
||||
List<BaseBrandInfoVo> records = pagging.getRecords();
|
||||
IPage<GoodsBrandInfo> page = PagerUtil.queryToPage(pq);
|
||||
IPage<GoodsBrandInfoVo> pagging = baseMapper.listPage(page, qw);
|
||||
PagerVo<GoodsBrandInfoVo> p = PagerUtil.pageToVo(pagging, null);
|
||||
List<GoodsBrandInfoVo> records = pagging.getRecords();
|
||||
records.removeAll(Collections.singleton(null));
|
||||
// if (!records.isEmpty()) {
|
||||
// for (BaseBrandInfoVo record : records) {
|
||||
@@ -51,17 +50,17 @@ public class BaseBrandInfoService extends MybatisBaseService<BaseBrandInfoMapper
|
||||
// }
|
||||
return rb.success().setData(p);
|
||||
}
|
||||
public ResultBean<List<BaseBrandInfo>> listAll() {
|
||||
public ResultBean<List<GoodsBrandInfo>> listAll() {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
List<BaseBrandInfo> pagging = baseMapper.selectList(new QueryWrapper<BaseBrandInfo>().eq("isEnable",1));
|
||||
List<GoodsBrandInfo> pagging = baseMapper.selectList(new QueryWrapper<GoodsBrandInfo>().eq("isEnable",1));
|
||||
return rb.success().setData(pagging);
|
||||
}
|
||||
public ResultBean<String> saveOrUpdate(BaseBrandInfoDto dto) {
|
||||
public ResultBean<String> saveOrUpdate(GoodsBrandInfoDto dto) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
String sid = "";
|
||||
if (StringUtils.isNotBlank(dto.getSid())) {
|
||||
sid = dto.getSid();
|
||||
BaseBrandInfo wmsGoodsBrand = fetchBySid(dto.getSid());
|
||||
GoodsBrandInfo wmsGoodsBrand = fetchBySid(dto.getSid());
|
||||
BeanUtil.copyProperties(dto, wmsGoodsBrand, "id", "sid");
|
||||
// if (StringUtils.isNotBlank(dto.getBigPic())) {
|
||||
// String urlPrefix = fileUploadComponent.getUrlPrefix();
|
||||
@@ -71,11 +70,11 @@ public class BaseBrandInfoService extends MybatisBaseService<BaseBrandInfoMapper
|
||||
wmsGoodsBrand.setModifyTime(new Date());
|
||||
baseMapper.updateById(wmsGoodsBrand);
|
||||
} else {
|
||||
BaseBrandInfo goods=baseMapper.selectOne(new QueryWrapper<BaseBrandInfo>().eq("brandName",dto.getBrandName()));
|
||||
GoodsBrandInfo goods=baseMapper.selectOne(new QueryWrapper<GoodsBrandInfo>().eq("brandName",dto.getBrandName()));
|
||||
if(null!=goods){
|
||||
return rb.setMsg("商品名不能重复");
|
||||
}
|
||||
BaseBrandInfo wmsGoodsBrand = new BaseBrandInfo();
|
||||
GoodsBrandInfo wmsGoodsBrand = new GoodsBrandInfo();
|
||||
sid = wmsGoodsBrand.getSid();
|
||||
BeanUtil.copyProperties(dto, wmsGoodsBrand, "id", "sid");
|
||||
wmsGoodsBrand.setCreateTime(new DateTime());
|
||||
@@ -89,10 +88,10 @@ public class BaseBrandInfoService extends MybatisBaseService<BaseBrandInfoMapper
|
||||
return rb.success().setMsg("成功");
|
||||
}
|
||||
|
||||
public ResultBean<BaseBrandInfoVo> initialization(String sid) {
|
||||
public ResultBean<GoodsBrandInfoVo> initialization(String sid) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseBrandInfoVo vo = new BaseBrandInfoVo();
|
||||
BaseBrandInfo wmsGoodsBrand = fetchBySid(sid);
|
||||
GoodsBrandInfoVo vo = new GoodsBrandInfoVo();
|
||||
GoodsBrandInfo wmsGoodsBrand = fetchBySid(sid);
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
|
||||
BeanUtil.copyProperties(wmsGoodsBrand, vo);
|
||||
// if (null != wmsGoodsBrand) {
|
||||
@@ -109,7 +108,7 @@ public class BaseBrandInfoService extends MybatisBaseService<BaseBrandInfoMapper
|
||||
|
||||
public ResultBean delete(String sid) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseBrandInfo wmsGoodsBrand = fetchBySid(sid);
|
||||
GoodsBrandInfo wmsGoodsBrand = fetchBySid(sid);
|
||||
if (null != wmsGoodsBrand) {
|
||||
baseMapper.deleteById(wmsGoodsBrand.getId());
|
||||
}
|
||||
@@ -117,16 +116,16 @@ public class BaseBrandInfoService extends MybatisBaseService<BaseBrandInfoMapper
|
||||
}
|
||||
public ResultBean updateIsEnable(String sid,String isEnable) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseBrandInfo wmsGoodsBrand = fetchBySid(sid);
|
||||
GoodsBrandInfo wmsGoodsBrand = fetchBySid(sid);
|
||||
if (null != wmsGoodsBrand) {
|
||||
wmsGoodsBrand.setIsEnable(Integer.parseInt(isEnable));
|
||||
baseMapper.updateById(wmsGoodsBrand);
|
||||
}
|
||||
return rb.success().setMsg("成功");
|
||||
}
|
||||
public ResultBean<BaseBrandInfo> getBrandByName(String name) {
|
||||
public ResultBean<GoodsBrandInfo> getBrandByName(String name) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseBrandInfo type=baseMapper.selectOne(new QueryWrapper<BaseBrandInfo>().eq("brandName",name));
|
||||
GoodsBrandInfo type=baseMapper.selectOne(new QueryWrapper<GoodsBrandInfo>().eq("brandName",name));
|
||||
return rb.success().setData(type);
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basebrandinfo;
|
||||
package com.yxt.goods.biz.goodsbrandinfo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.yxt.common.core.vo.Vo;
|
||||
@@ -11,7 +11,7 @@ import java.util.Date;
|
||||
* @date 2024/2/26 13:37
|
||||
*/
|
||||
@Data
|
||||
public class BaseBrandInfoVo implements Vo {
|
||||
public class GoodsBrandInfoVo implements Vo {
|
||||
private String id;
|
||||
private String sid;
|
||||
private String lockVersion;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basecategorybrand;
|
||||
package com.yxt.goods.biz.goodscategorybrand;
|
||||
|
||||
import com.yxt.common.core.domain.BaseEntity;
|
||||
import lombok.Data;
|
||||
@@ -8,7 +8,7 @@ import lombok.Data;
|
||||
* @date 2024/4/8 9:34
|
||||
*/
|
||||
@Data
|
||||
public class BaseCategoryBrand extends BaseEntity {
|
||||
public class GoodsCategoryBrand extends BaseEntity {
|
||||
private String categorySid;//商品分类sid
|
||||
private String brandSid;//品牌sid
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basecategorybrand;
|
||||
package com.yxt.goods.biz.goodscategorybrand;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Data;
|
||||
@@ -10,7 +10,7 @@ import java.util.Date;
|
||||
* @date 2024/4/8 9:34
|
||||
*/
|
||||
@Data
|
||||
public class BaseCategoryBrandDto {
|
||||
public class GoodsCategoryBrandDto {
|
||||
private String id;
|
||||
private String sid;
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basecategorybrand;
|
||||
package com.yxt.goods.biz.goodscategorybrand;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
@@ -14,10 +14,10 @@ import java.util.List;
|
||||
* @date 2024/2/26 13:40
|
||||
*/
|
||||
@Mapper
|
||||
public interface BaseCategoryBrandMapper extends BaseMapper<BaseCategoryBrand> {
|
||||
public interface GoodsCategoryBrandMapper extends BaseMapper<GoodsCategoryBrand> {
|
||||
|
||||
IPage<BaseCategoryBrandVo> listPage(IPage<BaseCategoryBrand> page, @Param(Constants.WRAPPER) QueryWrapper<BaseCategoryBrand> qw);
|
||||
List<BaseCategoryBrandVo> getSkusBySpuSid(@Param("spuSid")String spuSid);
|
||||
BaseCategoryBrandVo getVoBySid(@Param("sid")String sid);
|
||||
IPage<GoodsCategoryBrandVo> listPage(IPage<GoodsCategoryBrand> page, @Param(Constants.WRAPPER) QueryWrapper<GoodsCategoryBrand> qw);
|
||||
List<GoodsCategoryBrandVo> getSkusBySpuSid(@Param("spuSid")String spuSid);
|
||||
GoodsCategoryBrandVo getVoBySid(@Param("sid")String sid);
|
||||
|
||||
}
|
||||
@@ -1,10 +1,10 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.yxt.goods.biz.base.basecategorybrand.BaseCategoryBrandMapper">
|
||||
<mapper namespace="com.yxt.goods.biz.goodscategorybrand.GoodsCategoryBrandMapper">
|
||||
<!-- <where> ${ew.sqlSegment} </where>-->
|
||||
<!-- ${ew.customSqlSegment} -->
|
||||
|
||||
<select id="listPage" resultType="com.yxt.goods.biz.base.basecategorybrand.BaseCategoryBrandVo">
|
||||
<select id="listPage" resultType="com.yxt.goods.biz.goodscategorybrand.GoodsCategoryBrandVo">
|
||||
select s.*,a.goodsTypeName as categoryName ,b.brandName as brandName;
|
||||
from base_category_brand s
|
||||
left join base_goods_type a on a.sid =s.ceategorySid
|
||||
@@ -13,13 +13,13 @@
|
||||
${ew.sqlSegment}
|
||||
</where>
|
||||
</select>
|
||||
<select id="getSkusBySpuSid" resultType="com.yxt.goods.biz.base.basecategorybrand.BaseCategoryBrandVo">
|
||||
<select id="getSkusBySpuSid" resultType="com.yxt.goods.biz.goodscategorybrand.GoodsCategoryBrandVo">
|
||||
select s.*,
|
||||
s.own_spec as ownSpec
|
||||
from base_goods_sku s
|
||||
where s.goodsSpuSid = #{spuSid}
|
||||
</select>
|
||||
<select id="getVoBySid" resultType="com.yxt.goods.biz.base.basecategorybrand.BaseCategoryBrandVo">
|
||||
<select id="getVoBySid" resultType="com.yxt.goods.biz.goodscategorybrand.GoodsCategoryBrandVo">
|
||||
select s.*,a.goodsTypeName as categoryName ,b.brandName as brandName;
|
||||
from base_category_brand s
|
||||
left join base_goods_type a on a.sid =s.ceategorySid
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basecategorybrand;
|
||||
package com.yxt.goods.biz.goodscategorybrand;
|
||||
|
||||
import com.yxt.common.core.query.Query;
|
||||
import lombok.Data;
|
||||
@@ -8,6 +8,6 @@ import lombok.Data;
|
||||
* @date 2024/4/8 9:34
|
||||
*/
|
||||
@Data
|
||||
public class BaseCategoryBrandQuery implements Query {
|
||||
public class GoodsCategoryBrandQuery implements Query {
|
||||
private String name;
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basecategorybrand;
|
||||
package com.yxt.goods.biz.goodscategorybrand;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import cn.hutool.core.date.DateTime;
|
||||
@@ -23,35 +23,35 @@ import java.util.List;
|
||||
* @date 2024/2/26 13:40
|
||||
*/
|
||||
@Service
|
||||
public class BaseCategoryBrandService extends MybatisBaseService<BaseCategoryBrandMapper, BaseCategoryBrand> {
|
||||
public class GoodsCategoryBrandService extends MybatisBaseService<GoodsCategoryBrandMapper, GoodsCategoryBrand> {
|
||||
@Autowired
|
||||
private FileUploadComponent fileUploadComponent;
|
||||
|
||||
|
||||
public ResultBean<PagerVo<BaseCategoryBrandVo>> listPage(PagerQuery<BaseCategoryBrandQuery> pq) {
|
||||
public ResultBean<PagerVo<GoodsCategoryBrandVo>> listPage(PagerQuery<GoodsCategoryBrandQuery> pq) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseCategoryBrandQuery query = pq.getParams();
|
||||
QueryWrapper<BaseCategoryBrand> qw = new QueryWrapper<>();
|
||||
GoodsCategoryBrandQuery query = pq.getParams();
|
||||
QueryWrapper<GoodsCategoryBrand> qw = new QueryWrapper<>();
|
||||
if (StringUtils.isNotBlank(query.getName())) {
|
||||
qw.like("goodsName", query.getName());
|
||||
}
|
||||
IPage<BaseCategoryBrand> page = PagerUtil.queryToPage(pq);
|
||||
IPage<BaseCategoryBrandVo> pagging = baseMapper.listPage(page, qw);
|
||||
PagerVo<BaseCategoryBrandVo> p = PagerUtil.pageToVo(pagging, null);
|
||||
IPage<GoodsCategoryBrand> page = PagerUtil.queryToPage(pq);
|
||||
IPage<GoodsCategoryBrandVo> pagging = baseMapper.listPage(page, qw);
|
||||
PagerVo<GoodsCategoryBrandVo> p = PagerUtil.pageToVo(pagging, null);
|
||||
return rb.success().setData(p);
|
||||
}
|
||||
@Transactional
|
||||
public ResultBean<String> saveOrUpdate(BaseCategoryBrandDto dto) {
|
||||
public ResultBean<String> saveOrUpdate(GoodsCategoryBrandDto dto) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
String sid = "";
|
||||
if (StringUtils.isNotBlank(dto.getSid())) {
|
||||
sid = dto.getSid();
|
||||
BaseCategoryBrand wmsGoods = fetchBySid(dto.getSid());
|
||||
GoodsCategoryBrand wmsGoods = fetchBySid(dto.getSid());
|
||||
BeanUtil.copyProperties(dto, wmsGoods, "id", "sid");
|
||||
wmsGoods.setModifyTime(new Date());
|
||||
baseMapper.updateById(wmsGoods);
|
||||
} else {
|
||||
BaseCategoryBrand wmsGoods = new BaseCategoryBrand();
|
||||
GoodsCategoryBrand wmsGoods = new GoodsCategoryBrand();
|
||||
BeanUtil.copyProperties(dto, wmsGoods, "id", "sid");
|
||||
wmsGoods.setCreateTime(new DateTime());
|
||||
baseMapper.insert(wmsGoods);
|
||||
@@ -59,19 +59,19 @@ public class BaseCategoryBrandService extends MybatisBaseService<BaseCategoryBra
|
||||
return rb.success().setMsg("成功");
|
||||
}
|
||||
@Transactional
|
||||
public ResultBean<String> saveOrUpdate(List<BaseCategoryBrandDto> dtos) {
|
||||
public ResultBean<String> saveOrUpdate(List<GoodsCategoryBrandDto> dtos) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
for (BaseCategoryBrandDto dto : dtos) {
|
||||
BaseCategoryBrand sku=baseMapper.selectOne(new QueryWrapper<BaseCategoryBrand>().eq("sid",dto.getSid()));
|
||||
for (GoodsCategoryBrandDto dto : dtos) {
|
||||
GoodsCategoryBrand sku=baseMapper.selectOne(new QueryWrapper<GoodsCategoryBrand>().eq("sid",dto.getSid()));
|
||||
String sid = "";
|
||||
if (null!=sku) {
|
||||
sid = dto.getSid();
|
||||
BaseCategoryBrand wmsGoods = fetchBySid(dto.getSid());
|
||||
GoodsCategoryBrand wmsGoods = fetchBySid(dto.getSid());
|
||||
BeanUtil.copyProperties(dto, wmsGoods);
|
||||
wmsGoods.setModifyTime(new Date());
|
||||
baseMapper.updateById(wmsGoods);
|
||||
} else {
|
||||
BaseCategoryBrand wmsGoods = new BaseCategoryBrand();
|
||||
GoodsCategoryBrand wmsGoods = new GoodsCategoryBrand();
|
||||
BeanUtil.copyProperties(dto, wmsGoods);
|
||||
wmsGoods.setCreateTime(new DateTime());
|
||||
baseMapper.insert(wmsGoods);
|
||||
@@ -81,22 +81,22 @@ public class BaseCategoryBrandService extends MybatisBaseService<BaseCategoryBra
|
||||
return rb.success().setMsg("成功");
|
||||
}
|
||||
|
||||
public ResultBean<BaseCategoryBrandVo> initialization(String sid) {
|
||||
public ResultBean<GoodsCategoryBrandVo> initialization(String sid) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseCategoryBrandVo vo = baseMapper.getVoBySid(sid);
|
||||
GoodsCategoryBrandVo vo = baseMapper.getVoBySid(sid);
|
||||
return rb.success().setData(vo);
|
||||
}
|
||||
|
||||
public ResultBean<List<BaseCategoryBrandVo>> getSkusBySpuSid(String sid) {
|
||||
public ResultBean<List<GoodsCategoryBrandVo>> getSkusBySpuSid(String sid) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
List<BaseCategoryBrandVo> vo = baseMapper.getSkusBySpuSid(sid);
|
||||
List<GoodsCategoryBrandVo> vo = baseMapper.getSkusBySpuSid(sid);
|
||||
return rb.success().setData(vo);
|
||||
}
|
||||
|
||||
|
||||
public ResultBean delete(String sid) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseCategoryBrand wmsGoods = fetchBySid(sid);
|
||||
GoodsCategoryBrand wmsGoods = fetchBySid(sid);
|
||||
if (null != wmsGoods) {
|
||||
baseMapper.deleteById(wmsGoods.getId());
|
||||
}
|
||||
@@ -105,7 +105,7 @@ public class BaseCategoryBrandService extends MybatisBaseService<BaseCategoryBra
|
||||
|
||||
public ResultBean updateIsEnable(String sid, String isEnable) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseCategoryBrand wmsGoods = fetchBySid(sid);
|
||||
GoodsCategoryBrand wmsGoods = fetchBySid(sid);
|
||||
if (null != wmsGoods) {
|
||||
wmsGoods.setIsEnable(Integer.parseInt(isEnable));
|
||||
baseMapper.updateById(wmsGoods);
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basecategorybrand;
|
||||
package com.yxt.goods.biz.goodscategorybrand;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Data;
|
||||
@@ -10,7 +10,7 @@ import java.util.Date;
|
||||
* @date 2024/4/8 9:34
|
||||
*/
|
||||
@Data
|
||||
public class BaseCategoryBrandVo {
|
||||
public class GoodsCategoryBrandVo {
|
||||
private String id;
|
||||
private String sid;
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basemanufacturer;
|
||||
package com.yxt.goods.biz.goodsmanufacturer;
|
||||
|
||||
import com.yxt.common.core.domain.BaseEntity;
|
||||
import lombok.Data;
|
||||
@@ -8,7 +8,7 @@ import lombok.Data;
|
||||
* @date 2024/2/26 13:36
|
||||
*/
|
||||
@Data
|
||||
public class BaseManufacturer extends BaseEntity {
|
||||
public class GoodsManufacturer extends BaseEntity {
|
||||
private String manufacturerName;//厂家名称
|
||||
private String manufacturerCode;//厂家编码
|
||||
private String address;//地址
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basemanufacturer;
|
||||
package com.yxt.goods.biz.goodsmanufacturer;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.yxt.common.core.dto.Dto;
|
||||
@@ -11,7 +11,7 @@ import java.util.Date;
|
||||
* @date 2024/2/26 13:38
|
||||
*/
|
||||
@Data
|
||||
public class BaseManufacturerDto implements Dto {
|
||||
public class GoodsManufacturerDto implements Dto {
|
||||
private String id;
|
||||
private String sid;
|
||||
private String lockVersion;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basemanufacturer;
|
||||
package com.yxt.goods.biz.goodsmanufacturer;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
@@ -14,8 +14,8 @@ import java.util.List;
|
||||
* @date 2024/2/26 13:40
|
||||
*/
|
||||
@Mapper
|
||||
public interface BaseManufacturerMapper extends BaseMapper<BaseManufacturer> {
|
||||
IPage<BaseManufacturerVo> listPage(IPage<BaseManufacturer> page, @Param(Constants.WRAPPER) QueryWrapper<BaseManufacturer> qw);
|
||||
public interface GoodsManufacturerMapper extends BaseMapper<GoodsManufacturer> {
|
||||
IPage<GoodsManufacturerVo> listPage(IPage<GoodsManufacturer> page, @Param(Constants.WRAPPER) QueryWrapper<GoodsManufacturer> qw);
|
||||
|
||||
List<BaseManufacturerVo> getAllTypeByUseOrgSid(@Param("useOrgSid") String useOrgSid);
|
||||
List<GoodsManufacturerVo> getAllTypeByUseOrgSid(@Param("useOrgSid") String useOrgSid);
|
||||
}
|
||||
@@ -1,10 +1,10 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.yxt.goods.biz.base.basemanufacturer.BaseManufacturerMapper">
|
||||
<mapper namespace="com.yxt.goods.biz.goodsmanufacturer.GoodsManufacturerMapper">
|
||||
<!-- <where> ${ew.sqlSegment} </where>-->
|
||||
<!-- ${ew.customSqlSegment} -->
|
||||
|
||||
<select id="listPage" resultType="com.yxt.goods.biz.base.basemanufacturer.BaseManufacturerVo">
|
||||
<select id="listPage" resultType="com.yxt.goods.biz.goodsmanufacturer.GoodsManufacturerVo">
|
||||
select
|
||||
*
|
||||
from base_manufacturer
|
||||
@@ -12,7 +12,7 @@
|
||||
${ew.sqlSegment}
|
||||
</where>
|
||||
</select>
|
||||
<select id="getAllTypeByUseOrgSid" resultType="com.yxt.goods.biz.base.basemanufacturer.BaseManufacturerVo">
|
||||
<select id="getAllTypeByUseOrgSid" resultType="com.yxt.goods.biz.goodsmanufacturer.GoodsManufacturerVo">
|
||||
select *
|
||||
from base_manufacturer
|
||||
where useOrgSid = #{useOrgSid}
|
||||
@@ -0,0 +1,13 @@
|
||||
package com.yxt.goods.biz.goodsmanufacturer;
|
||||
|
||||
import com.yxt.common.core.query.Query;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @author wangpengfei
|
||||
* @date 2024/2/26 13:37
|
||||
*/
|
||||
@Data
|
||||
public class GoodsManufacturerQuery implements Query {
|
||||
private String name;
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basemanufacturer;
|
||||
package com.yxt.goods.biz.goodsmanufacturer;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import cn.hutool.core.date.DateTime;
|
||||
@@ -10,7 +10,6 @@ import com.yxt.common.base.utils.StringUtils;
|
||||
import com.yxt.common.core.query.PagerQuery;
|
||||
import com.yxt.common.core.result.ResultBean;
|
||||
import com.yxt.common.core.vo.PagerVo;
|
||||
import com.yxt.goods.biz.base.basegoodsunit.BaseGoodsUnit;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
@@ -22,40 +21,40 @@ import java.util.List;
|
||||
* @date 2024/2/26 13:40
|
||||
*/
|
||||
@Service
|
||||
public class BaseManufacturerService extends MybatisBaseService<BaseManufacturerMapper, BaseManufacturer> {
|
||||
public class GoodsManufacturerService extends MybatisBaseService<GoodsManufacturerMapper, GoodsManufacturer> {
|
||||
|
||||
|
||||
public ResultBean<PagerVo<BaseManufacturerVo>> listPage(PagerQuery<BaseManufacturerQuery> pq) {
|
||||
public ResultBean<PagerVo<GoodsManufacturerVo>> listPage(PagerQuery<GoodsManufacturerQuery> pq) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseManufacturerQuery query = pq.getParams();
|
||||
QueryWrapper<BaseManufacturer> qw = new QueryWrapper<>();
|
||||
GoodsManufacturerQuery query = pq.getParams();
|
||||
QueryWrapper<GoodsManufacturer> qw = new QueryWrapper<>();
|
||||
if(StringUtils.isNotBlank(query.getName())){
|
||||
qw.like("goodsTypeName",query.getName());
|
||||
}
|
||||
|
||||
IPage<BaseManufacturer> page = PagerUtil.queryToPage(pq);
|
||||
IPage<BaseManufacturerVo> pagging = baseMapper.listPage(page, qw);
|
||||
PagerVo<BaseManufacturerVo> p = PagerUtil.pageToVo(pagging, null);
|
||||
List<BaseManufacturerVo> records = pagging.getRecords();
|
||||
IPage<GoodsManufacturer> page = PagerUtil.queryToPage(pq);
|
||||
IPage<GoodsManufacturerVo> pagging = baseMapper.listPage(page, qw);
|
||||
PagerVo<GoodsManufacturerVo> p = PagerUtil.pageToVo(pagging, null);
|
||||
List<GoodsManufacturerVo> records = pagging.getRecords();
|
||||
return rb.success().setData(p);
|
||||
}
|
||||
public ResultBean<List<BaseManufacturer>> listAll() {
|
||||
public ResultBean<List<GoodsManufacturer>> listAll() {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
List<BaseManufacturer> pagging = baseMapper.selectList(new QueryWrapper<BaseManufacturer>().eq("isEnable",1));
|
||||
List<GoodsManufacturer> pagging = baseMapper.selectList(new QueryWrapper<GoodsManufacturer>().eq("isEnable",1));
|
||||
return rb.success().setData(pagging);
|
||||
}
|
||||
|
||||
public ResultBean<String> saveOrUpdate(BaseManufacturerDto dto) {
|
||||
public ResultBean<String> saveOrUpdate(GoodsManufacturerDto dto) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
String sid = "";
|
||||
if (StringUtils.isNotBlank(dto.getSid())) {
|
||||
sid = dto.getSid();
|
||||
BaseManufacturer wmsManufacturer = fetchBySid(dto.getSid());
|
||||
GoodsManufacturer wmsManufacturer = fetchBySid(dto.getSid());
|
||||
BeanUtil.copyProperties(dto, wmsManufacturer, "id", "sid");
|
||||
wmsManufacturer.setModifyTime(new Date());
|
||||
baseMapper.updateById(wmsManufacturer);
|
||||
} else {
|
||||
BaseManufacturer wmsManufacturer = new BaseManufacturer();
|
||||
GoodsManufacturer wmsManufacturer = new GoodsManufacturer();
|
||||
sid = wmsManufacturer.getSid();
|
||||
BeanUtil.copyProperties(dto, wmsManufacturer, "id", "sid");
|
||||
wmsManufacturer.setCreateTime(new DateTime());
|
||||
@@ -69,10 +68,10 @@ public class BaseManufacturerService extends MybatisBaseService<BaseManufacturer
|
||||
return rb.success().setMsg("成功");
|
||||
}
|
||||
|
||||
public ResultBean<BaseManufacturerVo> initialization(String sid) {
|
||||
public ResultBean<GoodsManufacturerVo> initialization(String sid) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseManufacturerVo vo = new BaseManufacturerVo();
|
||||
BaseManufacturer wmsManufacturer = fetchBySid(sid);
|
||||
GoodsManufacturerVo vo = new GoodsManufacturerVo();
|
||||
GoodsManufacturer wmsManufacturer = fetchBySid(sid);
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
|
||||
if (null != wmsManufacturer) {
|
||||
BeanUtil.copyProperties(wmsManufacturer, vo);
|
||||
@@ -88,7 +87,7 @@ public class BaseManufacturerService extends MybatisBaseService<BaseManufacturer
|
||||
|
||||
public ResultBean delete(String sid) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseManufacturer wmsManufacturer = fetchBySid(sid);
|
||||
GoodsManufacturer wmsManufacturer = fetchBySid(sid);
|
||||
if (null != wmsManufacturer) {
|
||||
baseMapper.deleteById(wmsManufacturer.getId());
|
||||
}
|
||||
@@ -96,7 +95,7 @@ public class BaseManufacturerService extends MybatisBaseService<BaseManufacturer
|
||||
}
|
||||
public ResultBean updateIsEnable(String sid,String isEnable) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseManufacturer wmsManufacturer = fetchBySid(sid);
|
||||
GoodsManufacturer wmsManufacturer = fetchBySid(sid);
|
||||
if (null != wmsManufacturer) {
|
||||
wmsManufacturer.setIsEnable(Integer.parseInt(isEnable));
|
||||
baseMapper.updateById(wmsManufacturer);
|
||||
@@ -104,14 +103,14 @@ public class BaseManufacturerService extends MybatisBaseService<BaseManufacturer
|
||||
return rb.success().setMsg("成功");
|
||||
}
|
||||
|
||||
public ResultBean<List<BaseManufacturerVo>> getAllTypeByUseOrgSid(String useOrgSid) {
|
||||
public ResultBean<List<GoodsManufacturerVo>> getAllTypeByUseOrgSid(String useOrgSid) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
List<BaseManufacturerVo> list = baseMapper.getAllTypeByUseOrgSid(useOrgSid);
|
||||
List<GoodsManufacturerVo> list = baseMapper.getAllTypeByUseOrgSid(useOrgSid);
|
||||
return rb.success().setData(list);
|
||||
}
|
||||
public ResultBean<BaseManufacturer> getManufacturerByName(String name) {
|
||||
public ResultBean<GoodsManufacturer> getManufacturerByName(String name) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseManufacturer type=baseMapper.selectOne(new QueryWrapper<BaseManufacturer>().eq("manufacturerName",name));
|
||||
GoodsManufacturer type=baseMapper.selectOne(new QueryWrapper<GoodsManufacturer>().eq("manufacturerName",name));
|
||||
return rb.success().setData(type);
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basemanufacturer;
|
||||
package com.yxt.goods.biz.goodsmanufacturer;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.yxt.common.core.vo.Vo;
|
||||
@@ -11,7 +11,7 @@ import java.util.Date;
|
||||
* @date 2024/2/26 13:37
|
||||
*/
|
||||
@Data
|
||||
public class BaseManufacturerVo implements Vo {
|
||||
public class GoodsManufacturerVo implements Vo {
|
||||
private String id;
|
||||
private String sid;
|
||||
private String lockVersion;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.shoppingcart;
|
||||
package com.yxt.goods.biz.goodsshoppingcart;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.Data;
|
||||
@@ -11,7 +11,7 @@ import java.util.UUID;
|
||||
* @date 2023/12/8 9:10
|
||||
*/
|
||||
@Data
|
||||
public class ShoppingCart {
|
||||
public class GoodsShoppingCart {
|
||||
private String id;
|
||||
private String sid= UUID.randomUUID().toString();
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.shoppingcart;
|
||||
package com.yxt.goods.biz.goodsshoppingcart;
|
||||
|
||||
import com.yxt.common.core.dto.Dto;
|
||||
import lombok.Data;
|
||||
@@ -8,7 +8,7 @@ import lombok.Data;
|
||||
* @date 2023/12/8 9:11
|
||||
*/
|
||||
@Data
|
||||
public class ShoppingCartDto implements Dto {
|
||||
public class GoodsShoppingCartDto implements Dto {
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
package com.yxt.goods.biz.goodsshoppingcart;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author wangpengfei
|
||||
* @date 2023/12/8 9:19
|
||||
*/
|
||||
@Mapper
|
||||
public interface GoodsShoppingCartMapper extends BaseMapper<GoodsShoppingCart> {
|
||||
List<GoodsShoppingCartVo> ShoppingCartList(@Param("customerSid")String customerSid,
|
||||
@Param("brandId")String brandId,
|
||||
@Param("periodValidity")String periodValidity);
|
||||
}
|
||||
@@ -1,11 +1,11 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.yxt.goods.biz.base.shoppingcart.ShoppingCartMapper">
|
||||
<mapper namespace="com.yxt.goods.biz.goodsshoppingcart.GoodsShoppingCartMapper">
|
||||
<!-- <where> ${ew.sqlSegment} </where>-->
|
||||
<!-- ${ew.customSqlSegment} -->
|
||||
|
||||
|
||||
<select id="ShoppingCartList" resultType="com.yxt.goods.biz.base.shoppingcart.ShoppingCartVo">
|
||||
<select id="ShoppingCartList" resultType="com.yxt.goods.biz.goodsshoppingcart.GoodsShoppingCartVo">
|
||||
select
|
||||
r.*,s.unitName,
|
||||
s.price as jPrice,
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.shoppingcart;
|
||||
package com.yxt.goods.biz.goodsshoppingcart;
|
||||
|
||||
import com.yxt.common.core.query.Query;
|
||||
import lombok.Data;
|
||||
@@ -8,7 +8,7 @@ import lombok.Data;
|
||||
* @date 2023/12/8 9:11
|
||||
*/
|
||||
@Data
|
||||
public class ShoppingCartQuery implements Query {
|
||||
public class GoodsShoppingCartQuery implements Query {
|
||||
private String customerSid; //客户
|
||||
private String affiliation; //类型
|
||||
private String brandId;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.shoppingcart;
|
||||
package com.yxt.goods.biz.goodsshoppingcart;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
@@ -19,26 +19,26 @@ import java.util.List;
|
||||
* @date 2023/12/8 9:19
|
||||
*/
|
||||
@Service
|
||||
public class ShoppingCartService extends MybatisBaseService<ShoppingCartMapper, ShoppingCart> {
|
||||
public class GoodsShoppingCartService extends MybatisBaseService<GoodsShoppingCartMapper, GoodsShoppingCart> {
|
||||
@Autowired
|
||||
private FileUploadComponent fileUploadComponent;
|
||||
|
||||
public ResultBean save(ShoppingCartDto dto) {
|
||||
public ResultBean save(GoodsShoppingCartDto dto) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
ShoppingCart entity = new ShoppingCart();
|
||||
GoodsShoppingCart entity = new GoodsShoppingCart();
|
||||
if(StringUtils.isBlank(dto.getCustomerSid())){
|
||||
return rb.setMsg("参数不全");
|
||||
}
|
||||
if(StringUtils.isBlank(dto.getGoodsSid())){
|
||||
return rb.setMsg("参数不全");
|
||||
}
|
||||
List<ShoppingCart> list = baseMapper.selectList(new QueryWrapper<ShoppingCart>().eq("customerSid", dto.getCustomerSid())
|
||||
List<GoodsShoppingCart> list = baseMapper.selectList(new QueryWrapper<GoodsShoppingCart>().eq("customerSid", dto.getCustomerSid())
|
||||
.eq("goodsSid", dto.getGoodsSid())
|
||||
.eq("affiliation", dto.getAffiliation()));
|
||||
if (list.size() > 0) {
|
||||
// list.get(0).setGoodsNumber(String.valueOf(Double.valueOf(dto.getGoodsNumber())+Double.valueOf(list.get(0).getGoodsNumber())));
|
||||
if (dto.getGoodsNumber().equals("0")) {
|
||||
baseMapper.delete(new QueryWrapper<ShoppingCart>().eq("customerSid", dto.getCustomerSid())
|
||||
baseMapper.delete(new QueryWrapper<GoodsShoppingCart>().eq("customerSid", dto.getCustomerSid())
|
||||
.eq("goodsSid", dto.getGoodsSid())
|
||||
.eq("affiliation", dto.getAffiliation()));
|
||||
} else {
|
||||
@@ -52,9 +52,9 @@ public class ShoppingCartService extends MybatisBaseService<ShoppingCartMapper,
|
||||
return rb.success().setMsg("成功");
|
||||
}
|
||||
|
||||
public ResultBean<List<ShoppingCartVo>> shoppingCartList(ShoppingCartQuery query) {
|
||||
public ResultBean<List<GoodsShoppingCartVo>> shoppingCartList(GoodsShoppingCartQuery query) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
ShoppingCart entity = new ShoppingCart();
|
||||
GoodsShoppingCart entity = new GoodsShoppingCart();
|
||||
if(StringUtils.isBlank(query.getCustomerSid())){
|
||||
return rb.setMsg("参数不全");
|
||||
}
|
||||
@@ -64,7 +64,7 @@ public class ShoppingCartService extends MybatisBaseService<ShoppingCartMapper,
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
|
||||
Date date=new Date();
|
||||
String periodValidity=sdf.format(date);
|
||||
List<ShoppingCartVo> list = baseMapper.ShoppingCartList(query.getCustomerSid(), query.getBrandId(),periodValidity);
|
||||
List<GoodsShoppingCartVo> list = baseMapper.ShoppingCartList(query.getCustomerSid(), query.getBrandId(),periodValidity);
|
||||
list.forEach(s -> {
|
||||
s.setTotalPrice(removeZeros(String.valueOf((Double.valueOf(s.getJPrice()) * Double.valueOf(s.getGoodsNumber())))));
|
||||
s.setIconUrl(fileUploadComponent.getUrlPrefix() + s.getIconUrl());
|
||||
@@ -73,11 +73,11 @@ public class ShoppingCartService extends MybatisBaseService<ShoppingCartMapper,
|
||||
return rb.success().setData(list).setMsg("成功");
|
||||
}
|
||||
|
||||
public ResultBean minusShoppingCart(ShoppingCartDto dto) {
|
||||
public ResultBean minusShoppingCart(GoodsShoppingCartDto dto) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
ShoppingCart entity = new ShoppingCart();
|
||||
GoodsShoppingCart entity = new GoodsShoppingCart();
|
||||
// List<ShoppingCart> list= baseMapper.selectList(new QueryWrapper<ShoppingCart>().eq("sid",dto.getSid()));
|
||||
List<ShoppingCart> list = baseMapper.selectList(new QueryWrapper<ShoppingCart>().eq("customerSid", dto.getCustomerSid())
|
||||
List<GoodsShoppingCart> list = baseMapper.selectList(new QueryWrapper<GoodsShoppingCart>().eq("customerSid", dto.getCustomerSid())
|
||||
.eq("goodsSid", dto.getGoodsSid())
|
||||
.eq("affiliation", dto.getAffiliation()));
|
||||
if (list.size() > 0) {
|
||||
@@ -89,11 +89,11 @@ public class ShoppingCartService extends MybatisBaseService<ShoppingCartMapper,
|
||||
// baseMapper.insert(entity);
|
||||
return rb.success().setMsg("成功");
|
||||
}
|
||||
public ResultBean updateShoppingCart(ShoppingCartDto dto) {
|
||||
public ResultBean updateShoppingCart(GoodsShoppingCartDto dto) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
ShoppingCart entity = new ShoppingCart();
|
||||
GoodsShoppingCart entity = new GoodsShoppingCart();
|
||||
// List<ShoppingCart> list= baseMapper.selectList(new QueryWrapper<ShoppingCart>().eq("sid",dto.getSid()));
|
||||
List<ShoppingCart> list = baseMapper.selectList(new QueryWrapper<ShoppingCart>().eq("customerSid", dto.getCustomerSid())
|
||||
List<GoodsShoppingCart> list = baseMapper.selectList(new QueryWrapper<GoodsShoppingCart>().eq("customerSid", dto.getCustomerSid())
|
||||
.eq("goodsSid", dto.getGoodsSid())
|
||||
.eq("affiliation", dto.getAffiliation()));
|
||||
if (list.size() > 0) {
|
||||
@@ -106,12 +106,12 @@ public class ShoppingCartService extends MybatisBaseService<ShoppingCartMapper,
|
||||
|
||||
public ResultBean delShoppingCart(String sid) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
ShoppingCart entity = new ShoppingCart();
|
||||
baseMapper.delete(new QueryWrapper<ShoppingCart>().eq("sid ", sid));
|
||||
GoodsShoppingCart entity = new GoodsShoppingCart();
|
||||
baseMapper.delete(new QueryWrapper<GoodsShoppingCart>().eq("sid ", sid));
|
||||
return rb.success().setMsg("成功");
|
||||
}
|
||||
|
||||
public ResultBean getGoodsWeight(ShoppingCartQuery query) {
|
||||
public ResultBean getGoodsWeight(GoodsShoppingCartQuery query) {
|
||||
ResultBean rb = new ResultBean().fail();
|
||||
if(StringUtils.isBlank(query.getCustomerSid())){
|
||||
return rb.setMsg("参数不全");
|
||||
@@ -122,7 +122,7 @@ public class ShoppingCartService extends MybatisBaseService<ShoppingCartMapper,
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
|
||||
Date date=new Date();
|
||||
String periodValidity=sdf.format(date);
|
||||
List<ShoppingCartVo> list = baseMapper.ShoppingCartList(query.getCustomerSid(), query.getBrandId(),periodValidity);
|
||||
List<GoodsShoppingCartVo> list = baseMapper.ShoppingCartList(query.getCustomerSid(), query.getBrandId(),periodValidity);
|
||||
double price = 0;
|
||||
double standbyPrice =0;
|
||||
double weight = 0;
|
||||
@@ -158,7 +158,7 @@ public class ShoppingCartService extends MybatisBaseService<ShoppingCartMapper,
|
||||
// weight = Double.valueOf(vo.getWeight()) * Double.valueOf(vo.getGoodsNumber()) + weight;
|
||||
// }
|
||||
// }
|
||||
ShoppingCartVo vo = new ShoppingCartVo();
|
||||
GoodsShoppingCartVo vo = new GoodsShoppingCartVo();
|
||||
// 1.20斤起订量。
|
||||
// 2.0-99斤加10%附加额。
|
||||
// 3.100斤-199斤加5%附加额。
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.shoppingcart;
|
||||
package com.yxt.goods.biz.goodsshoppingcart;
|
||||
|
||||
import com.yxt.common.core.vo.Vo;
|
||||
import lombok.Data;
|
||||
@@ -8,7 +8,7 @@ import lombok.Data;
|
||||
* @date 2023/12/8 9:11
|
||||
*/
|
||||
@Data
|
||||
public class ShoppingCartVo implements Vo {
|
||||
public class GoodsShoppingCartVo implements Vo {
|
||||
private String id;
|
||||
private String sid;
|
||||
private String createTime;
|
||||
@@ -0,0 +1,8 @@
|
||||
package com.yxt.goods.biz.goodsshoppingcart;
|
||||
|
||||
/**
|
||||
* @author wangpengfei
|
||||
* @date 2024/1/17 14:03
|
||||
*/
|
||||
public class GoodsShoppingGoodsVo {
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basegoodssku;
|
||||
package com.yxt.goods.biz.goodssku;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.yxt.common.core.domain.BaseEntity;
|
||||
@@ -9,7 +9,7 @@ import lombok.Data;
|
||||
* @date 2024/2/26 13:36
|
||||
*/
|
||||
@Data
|
||||
public class BaseGoodsSku extends BaseEntity {
|
||||
public class GoodsSku extends BaseEntity {
|
||||
private String goodsSkuCode;//商品Sku代码
|
||||
private String title;//商品标题
|
||||
private String goodsSpuSid;//商品基础信息Sid
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basegoodssku;
|
||||
package com.yxt.goods.biz.goodssku;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
@@ -10,7 +10,7 @@ import lombok.Data;
|
||||
* @date: 2024/3/19
|
||||
**/
|
||||
@Data
|
||||
public class BaseGoodsSkuDetailsVo {
|
||||
public class GoodsSkuDetailsVo {
|
||||
|
||||
@ApiModelProperty("商品代码")
|
||||
private String goodsCode;
|
||||
@@ -1,8 +1,8 @@
|
||||
package com.yxt.goods.biz.base.basegoodssku;
|
||||
package com.yxt.goods.biz.goodssku;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.yxt.goods.biz.base.basegoodsskuextend.BaseGoodsSkuExtendDto;
|
||||
import com.yxt.goods.biz.goodsskuextend.GoodsSkuExtendDto;
|
||||
import com.yxt.common.core.dto.Dto;
|
||||
import lombok.Data;
|
||||
|
||||
@@ -13,7 +13,7 @@ import java.util.Date;
|
||||
* @date 2024/2/26 13:38
|
||||
*/
|
||||
@Data
|
||||
public class BaseGoodsSkuDto implements Dto {
|
||||
public class GoodsSkuDto implements Dto {
|
||||
private String id;
|
||||
private String sid;
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
||||
@@ -27,5 +27,5 @@ public class BaseGoodsSkuDto implements Dto {
|
||||
private String indexes;//特有规格属性在spu表中special_spec字段对应每个参数值数组下标的组合,如0_0_0,1_0_0,相当于SKU这条记录的编码。
|
||||
@TableField(value = "own_spec")
|
||||
private String ownSpec;//sku的特有规格参数键值对,json格式,反序列化时请使用linkedHashMap,保证有序
|
||||
private BaseGoodsSkuExtendDto baseGoodsSkuExtend;//sku扩展
|
||||
private GoodsSkuExtendDto baseGoodsSkuExtend;//sku扩展
|
||||
}
|
||||
26
src/main/java/com/yxt/goods/biz/goodssku/GoodsSkuMapper.java
Normal file
26
src/main/java/com/yxt/goods/biz/goodssku/GoodsSkuMapper.java
Normal file
@@ -0,0 +1,26 @@
|
||||
package com.yxt.goods.biz.goodssku;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Constants;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author wangpengfei
|
||||
* @date 2024/2/26 13:40
|
||||
*/
|
||||
@Mapper
|
||||
public interface GoodsSkuMapper extends BaseMapper<GoodsSku> {
|
||||
|
||||
IPage<GoodsSkuVo> listPage(IPage<GoodsSku> page, @Param(Constants.WRAPPER) QueryWrapper<GoodsSku> qw);
|
||||
List<GoodsSkuVo> getSkusBySpuSid(@Param("spuSid")String spuSid);
|
||||
GoodsSkuVo getSkuBySid(@Param("sid")String sid);
|
||||
|
||||
IPage<SkuSelectList> getSelectList(IPage<GoodsSku> page, @Param(Constants.WRAPPER)QueryWrapper<GoodsSku> qw);
|
||||
|
||||
IPage<GoodsSkuPurSelectList> purGoodsListPage(IPage<GoodsSku> page, @Param(Constants.WRAPPER) QueryWrapper<GoodsSku> qw);
|
||||
}
|
||||
@@ -1,10 +1,10 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.yxt.goods.biz.base.basegoodssku.BaseGoodsSkuMapper">
|
||||
<mapper namespace="com.yxt.goods.biz.goodssku.GoodsSkuMapper">
|
||||
<!-- <where> ${ew.sqlSegment} </where>-->
|
||||
<!-- ${ew.customSqlSegment} -->
|
||||
|
||||
<select id="listPage" resultType="com.yxt.goods.biz.base.basegoodssku.BaseGoodsSkuVo">
|
||||
<select id="listPage" resultType="com.yxt.goods.biz.goodssku.GoodsSkuVo">
|
||||
select s.*,s.own_spec as ownSpec,a.goodsName
|
||||
from base_goods_sku s
|
||||
left join base_goods_spu a on a.sid=s.goodsSpuSid
|
||||
@@ -12,20 +12,20 @@
|
||||
${ew.sqlSegment}
|
||||
</where>
|
||||
</select>
|
||||
<select id="getSkusBySpuSid" resultType="com.yxt.goods.biz.base.basegoodssku.BaseGoodsSkuVo">
|
||||
<select id="getSkusBySpuSid" resultType="com.yxt.goods.biz.goodssku.GoodsSkuVo">
|
||||
select s.*,
|
||||
s.own_spec as ownSpec
|
||||
from base_goods_sku s
|
||||
where s.goodsSpuSid = #{spuSid}
|
||||
</select>
|
||||
<select id="getSkuBySid" resultType="com.yxt.goods.biz.base.basegoodssku.BaseGoodsSkuVo">
|
||||
<select id="getSkuBySid" resultType="com.yxt.goods.biz.goodssku.GoodsSkuVo">
|
||||
select *,
|
||||
s.own_spec as ownSpec
|
||||
from base_goods_sku s
|
||||
where s.sid = #{sid}
|
||||
</select>
|
||||
|
||||
<select id="getSelectList" resultType="com.yxt.goods.biz.base.basegoodssku.BaseGoodsSkuSelectList">
|
||||
<select id="getSelectList" resultType="com.yxt.goods.biz.goodssku.SkuSelectList">
|
||||
select sku.sid goodsSkuSid,
|
||||
spu.sid as goodsSpuSid,
|
||||
spu.goodsName goodsSpuName,
|
||||
@@ -40,7 +40,7 @@
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="purGoodsListPage" resultType="com.yxt.goods.biz.base.basegoodssku.BaseGoodsSkuPurSelectList">
|
||||
<select id="purGoodsListPage" resultType="com.yxt.goods.biz.goodssku.GoodsSkuPurSelectList">
|
||||
SELECT
|
||||
s.sid,
|
||||
s.goodsSkuCode,
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basegoodssku;
|
||||
package com.yxt.goods.biz.goodssku;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
@@ -8,7 +8,7 @@ import lombok.Data;
|
||||
* @date: 2024/3/21
|
||||
**/
|
||||
@Data
|
||||
public class BaseGoodsSkuPurSelectList {
|
||||
public class GoodsSkuPurSelectList {
|
||||
|
||||
//sid
|
||||
private String sid;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basegoodssku;
|
||||
package com.yxt.goods.biz.goodssku;
|
||||
|
||||
import com.yxt.common.core.query.Query;
|
||||
import lombok.Data;
|
||||
@@ -9,7 +9,7 @@ import lombok.Data;
|
||||
* @date: 2024/3/21
|
||||
**/
|
||||
@Data
|
||||
public class BaseGoodsSkuPurSelectQuery implements Query {
|
||||
public class GoodsSkuPurSelectQuery implements Query {
|
||||
|
||||
//组织sid
|
||||
private String orgSid;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basegoodsspu;
|
||||
package com.yxt.goods.biz.goodssku;
|
||||
|
||||
import com.yxt.common.core.query.Query;
|
||||
import lombok.Data;
|
||||
@@ -8,6 +8,6 @@ import lombok.Data;
|
||||
* @date 2024/2/26 13:37
|
||||
*/
|
||||
@Data
|
||||
public class BaseGoodsSpuQuery implements Query {
|
||||
public class GoodsSkuQuery implements Query {
|
||||
private String name;
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basegoodssku;
|
||||
package com.yxt.goods.biz.goodssku;
|
||||
|
||||
import com.yxt.common.core.query.Query;
|
||||
import lombok.Data;
|
||||
@@ -9,7 +9,7 @@ import lombok.Data;
|
||||
* @date: 2024/3/21
|
||||
**/
|
||||
@Data
|
||||
public class BaseGoodsSkuSelectQuery implements Query {
|
||||
public class GoodsSkuSelectQuery implements Query {
|
||||
|
||||
private String goodsSkuCode;
|
||||
}
|
||||
@@ -1,18 +1,17 @@
|
||||
package com.yxt.goods.biz.base.basegoodssku;
|
||||
package com.yxt.goods.biz.goodssku;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import cn.hutool.core.date.DateTime;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.yxt.goods.biz.base.basegoodsskuextend.BaseGoodsSkuExtendService;
|
||||
import com.yxt.goods.biz.base.basegoodsskuextend.BaseGoodsSkuExtendVo;
|
||||
import com.yxt.goods.biz.base.basegoodsspu.BaseGoodsSpu;
|
||||
import com.yxt.goods.biz.base.basegoodsspu.BaseGoodsSpuDto;
|
||||
import com.yxt.goods.biz.base.basegoodsspu.BaseGoodsSpuService;
|
||||
import com.yxt.goods.biz.base.basegoodsspudetail.BaseGoodsSpuDetail;
|
||||
import com.yxt.goods.biz.base.basegoodsspudetail.BaseGoodsSpuDetailService;
|
||||
import com.yxt.goods.biz.base.basegoodstype.BaseGoodsType;
|
||||
import com.yxt.goods.biz.base.basegoodstype.BaseGoodsTypeService;
|
||||
import com.yxt.goods.biz.goodsskuextend.GoodsSkuExtendService;
|
||||
import com.yxt.goods.biz.goodsskuextend.GoodsSkuExtendVo;
|
||||
import com.yxt.goods.biz.goodsspu.GoodsSpu;
|
||||
import com.yxt.goods.biz.goodsspu.GoodsSpuDto;
|
||||
import com.yxt.goods.biz.goodsspu.GoodsSpuService;
|
||||
import com.yxt.goods.biz.goodsspudetail.BaseGoodsSpuDetailService;
|
||||
import com.yxt.goods.biz.goodstype.GoodsType;
|
||||
import com.yxt.goods.biz.goodstype.GoodsTypeService;
|
||||
import com.yxt.common.base.config.component.FileUploadComponent;
|
||||
import com.yxt.common.base.service.MybatisBaseService;
|
||||
import com.yxt.common.base.utils.PagerUtil;
|
||||
@@ -33,60 +32,60 @@ import java.util.List;
|
||||
* @date 2024/2/26 13:40
|
||||
*/
|
||||
@Service
|
||||
public class BaseGoodsSkuService extends MybatisBaseService<BaseGoodsSkuMapper, BaseGoodsSku> {
|
||||
public class GoodsSkuService extends MybatisBaseService<GoodsSkuMapper, GoodsSku> {
|
||||
@Autowired
|
||||
private FileUploadComponent fileUploadComponent;
|
||||
@Autowired
|
||||
BaseGoodsSpuDetailService baseGoodsSpuDetailService;
|
||||
@Autowired
|
||||
BaseGoodsSkuExtendService baseGoodsSkuExtendService;
|
||||
GoodsSkuExtendService goodsSkuExtendService;
|
||||
@Autowired
|
||||
private BaseGoodsSpuService baseGoodsSpuService;
|
||||
private GoodsSpuService goodsSpuService;
|
||||
@Autowired
|
||||
BaseGoodsTypeService baseGoodsTypeService;
|
||||
GoodsTypeService goodsTypeService;
|
||||
|
||||
public ResultBean<PagerVo<BaseGoodsSkuVo>> listPage(PagerQuery<BaseGoodsSkuQuery> pq) {
|
||||
public ResultBean<PagerVo<GoodsSkuVo>> listPage(PagerQuery<GoodsSkuQuery> pq) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseGoodsSkuQuery query = pq.getParams();
|
||||
QueryWrapper<BaseGoodsSku> qw = new QueryWrapper<>();
|
||||
GoodsSkuQuery query = pq.getParams();
|
||||
QueryWrapper<GoodsSku> qw = new QueryWrapper<>();
|
||||
if (StringUtils.isNotBlank(query.getName())) {
|
||||
qw.like("goodsName", query.getName());
|
||||
}
|
||||
IPage<BaseGoodsSku> page = PagerUtil.queryToPage(pq);
|
||||
IPage<BaseGoodsSkuVo> pagging = baseMapper.listPage(page, qw);
|
||||
PagerVo<BaseGoodsSkuVo> p = PagerUtil.pageToVo(pagging, null);
|
||||
IPage<GoodsSku> page = PagerUtil.queryToPage(pq);
|
||||
IPage<GoodsSkuVo> pagging = baseMapper.listPage(page, qw);
|
||||
PagerVo<GoodsSkuVo> p = PagerUtil.pageToVo(pagging, null);
|
||||
return rb.success().setData(p);
|
||||
}
|
||||
@Transactional
|
||||
public ResultBean<String> saveOrUpdate(BaseGoodsSkuDto dto) {
|
||||
public ResultBean<String> saveOrUpdate(GoodsSkuDto dto) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
String sid = "";
|
||||
if (StringUtils.isNotBlank(dto.getSid())) {
|
||||
sid = dto.getSid();
|
||||
BaseGoodsSku wmsGoods = fetchBySid(dto.getSid());
|
||||
GoodsSku wmsGoods = fetchBySid(dto.getSid());
|
||||
BeanUtil.copyProperties(dto, wmsGoods, "id", "sid");
|
||||
wmsGoods.setModifyTime(new Date());
|
||||
baseMapper.updateById(wmsGoods);
|
||||
dto.getBaseGoodsSkuExtend().setGoodsSkuSid(wmsGoods.getSid());
|
||||
baseGoodsSkuExtendService.saveOrUpdate(dto.getBaseGoodsSkuExtend());
|
||||
goodsSkuExtendService.saveOrUpdate(dto.getBaseGoodsSkuExtend());
|
||||
} else {
|
||||
BaseGoodsSku wmsGoods = new BaseGoodsSku();
|
||||
GoodsSku wmsGoods = new GoodsSku();
|
||||
BeanUtil.copyProperties(dto, wmsGoods, "id", "sid");
|
||||
wmsGoods.setCreateTime(new DateTime());
|
||||
baseMapper.insert(wmsGoods);
|
||||
dto.getBaseGoodsSkuExtend().setGoodsSkuSid(wmsGoods.getSid());
|
||||
baseGoodsSkuExtendService.saveOrUpdate(dto.getBaseGoodsSkuExtend());
|
||||
goodsSkuExtendService.saveOrUpdate(dto.getBaseGoodsSkuExtend());
|
||||
}
|
||||
return rb.success().setMsg("成功");
|
||||
}
|
||||
@Transactional
|
||||
public ResultBean<String> skuBatchSave(List<BaseGoodsSpuDto> dtos) {
|
||||
public ResultBean<String> skuBatchSave(List<GoodsSpuDto> dtos) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
List<BaseGoodsSku> skus = new ArrayList<>();
|
||||
List<BaseGoodsSkuDto> dtos1=new ArrayList<>();
|
||||
for (BaseGoodsSpuDto dto : dtos) {
|
||||
for (BaseGoodsSkuDto baseGoodsSkus : dto.getBaseGoodsSkus()) {
|
||||
BaseGoodsSku sku = new BaseGoodsSku();
|
||||
List<GoodsSku> skus = new ArrayList<>();
|
||||
List<GoodsSkuDto> dtos1=new ArrayList<>();
|
||||
for (GoodsSpuDto dto : dtos) {
|
||||
for (GoodsSkuDto baseGoodsSkus : dto.getBaseGoodsSkus()) {
|
||||
GoodsSku sku = new GoodsSku();
|
||||
BeanUtil.copyProperties(baseGoodsSkus, sku, "id");
|
||||
sku.setCreateTime(new DateTime());
|
||||
skus.add(sku);
|
||||
@@ -94,57 +93,57 @@ public class BaseGoodsSkuService extends MybatisBaseService<BaseGoodsSkuMapper,
|
||||
}
|
||||
}
|
||||
this.saveBatch(skus);
|
||||
baseGoodsSkuExtendService.skuEBatchSave(dtos1);
|
||||
goodsSkuExtendService.skuEBatchSave(dtos1);
|
||||
return rb.success().setMsg("成功");
|
||||
}
|
||||
@Transactional
|
||||
public ResultBean<String> saveOrUpdate(List<BaseGoodsSkuDto> dtos) {
|
||||
public ResultBean<String> saveOrUpdate(List<GoodsSkuDto> dtos) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
for (BaseGoodsSkuDto dto : dtos) {
|
||||
BaseGoodsSku sku=baseMapper.selectOne(new QueryWrapper<BaseGoodsSku>().eq("sid",dto.getSid()));
|
||||
for (GoodsSkuDto dto : dtos) {
|
||||
GoodsSku sku=baseMapper.selectOne(new QueryWrapper<GoodsSku>().eq("sid",dto.getSid()));
|
||||
String sid = "";
|
||||
if (null!=sku) {
|
||||
sid = dto.getSid();
|
||||
BaseGoodsSku wmsGoods = fetchBySid(dto.getSid());
|
||||
GoodsSku wmsGoods = fetchBySid(dto.getSid());
|
||||
BeanUtil.copyProperties(dto, wmsGoods);
|
||||
wmsGoods.setModifyTime(new Date());
|
||||
baseMapper.updateById(wmsGoods);
|
||||
dto.getBaseGoodsSkuExtend().setGoodsSkuSid(wmsGoods.getSid());
|
||||
baseGoodsSkuExtendService.saveOrUpdate(dto.getBaseGoodsSkuExtend());
|
||||
goodsSkuExtendService.saveOrUpdate(dto.getBaseGoodsSkuExtend());
|
||||
} else {
|
||||
BaseGoodsSku wmsGoods = new BaseGoodsSku();
|
||||
GoodsSku wmsGoods = new GoodsSku();
|
||||
BeanUtil.copyProperties(dto, wmsGoods);
|
||||
wmsGoods.setCreateTime(new DateTime());
|
||||
baseMapper.insert(wmsGoods);
|
||||
dto.getBaseGoodsSkuExtend().setGoodsSkuSid(wmsGoods.getSid());
|
||||
baseGoodsSkuExtendService.saveOrUpdate(dto.getBaseGoodsSkuExtend());
|
||||
goodsSkuExtendService.saveOrUpdate(dto.getBaseGoodsSkuExtend());
|
||||
}
|
||||
}
|
||||
|
||||
return rb.success().setMsg("成功");
|
||||
}
|
||||
|
||||
public ResultBean<BaseGoodsSkuVo> initialization(String sid) {
|
||||
public ResultBean<GoodsSkuVo> initialization(String sid) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseGoodsSkuVo vo = baseMapper.getSkuBySid(sid);
|
||||
BaseGoodsSkuExtendVo vo1=baseGoodsSkuExtendService.getExtendBySkuSid(vo.getSid()).getData();
|
||||
GoodsSkuVo vo = baseMapper.getSkuBySid(sid);
|
||||
GoodsSkuExtendVo vo1= goodsSkuExtendService.getExtendBySkuSid(vo.getSid()).getData();
|
||||
if(vo1==null){
|
||||
vo.setBaseGoodsSkuExtend(new BaseGoodsSkuExtendVo());
|
||||
vo.setBaseGoodsSkuExtend(new GoodsSkuExtendVo());
|
||||
}
|
||||
vo.setBaseGoodsSkuExtend(vo1);
|
||||
return rb.success().setData(vo);
|
||||
}
|
||||
|
||||
public ResultBean<List<BaseGoodsSkuVo>> getSkusBySpuSid(String sid) {
|
||||
public ResultBean<List<GoodsSkuVo>> getSkusBySpuSid(String sid) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
List<BaseGoodsSkuVo> vo = baseMapper.getSkusBySpuSid(sid);
|
||||
List<GoodsSkuVo> vo = baseMapper.getSkusBySpuSid(sid);
|
||||
return rb.success().setData(vo);
|
||||
}
|
||||
|
||||
|
||||
public ResultBean delete(String sid) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseGoodsSku wmsGoods = fetchBySid(sid);
|
||||
GoodsSku wmsGoods = fetchBySid(sid);
|
||||
if (null != wmsGoods) {
|
||||
baseMapper.deleteById(wmsGoods.getId());
|
||||
}
|
||||
@@ -153,7 +152,7 @@ public class BaseGoodsSkuService extends MybatisBaseService<BaseGoodsSkuMapper,
|
||||
|
||||
public ResultBean updateIsEnable(String sid, String isEnable) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseGoodsSku wmsGoods = fetchBySid(sid);
|
||||
GoodsSku wmsGoods = fetchBySid(sid);
|
||||
if (null != wmsGoods) {
|
||||
wmsGoods.setIsEnable(Integer.parseInt(isEnable));
|
||||
baseMapper.updateById(wmsGoods);
|
||||
@@ -161,42 +160,42 @@ public class BaseGoodsSkuService extends MybatisBaseService<BaseGoodsSkuMapper,
|
||||
return rb.success().setMsg("成功");
|
||||
}
|
||||
|
||||
public ResultBean<BaseGoodsSkuDetailsVo> getDetails(String sid) {
|
||||
ResultBean<BaseGoodsSkuDetailsVo> rb = ResultBean.fireFail();
|
||||
BaseGoodsSkuDetailsVo baseGoodsSkuDetailsVo = new BaseGoodsSkuDetailsVo();
|
||||
BaseGoodsSku baseGoodsSku = fetchBySid(sid);
|
||||
BaseGoodsSpu baseGoodsSpu = baseGoodsSpuService.fetchBySid(baseGoodsSku.getGoodsSpuSid());
|
||||
BeanUtil.copyProperties(baseGoodsSku, baseGoodsSkuDetailsVo);
|
||||
BeanUtil.copyProperties(baseGoodsSpu, baseGoodsSkuDetailsVo);
|
||||
BaseGoodsType baseGoodsType = baseGoodsTypeService.fetchBySid(baseGoodsSpu.getGoodsTypeSid());
|
||||
if (baseGoodsType != null && StringUtils.isNotBlank(baseGoodsType.getIsGoodsID())) {
|
||||
baseGoodsSkuDetailsVo.setIsGoodsID(Integer.parseInt(baseGoodsType.getIsGoodsID()));
|
||||
baseGoodsSkuDetailsVo.setGoodsTypeName(baseGoodsType.getGoodsTypeName());
|
||||
public ResultBean<GoodsSkuDetailsVo> getDetails(String sid) {
|
||||
ResultBean<GoodsSkuDetailsVo> rb = ResultBean.fireFail();
|
||||
GoodsSkuDetailsVo goodsSkuDetailsVo = new GoodsSkuDetailsVo();
|
||||
GoodsSku goodsSku = fetchBySid(sid);
|
||||
GoodsSpu goodsSpu = goodsSpuService.fetchBySid(goodsSku.getGoodsSpuSid());
|
||||
BeanUtil.copyProperties(goodsSku, goodsSkuDetailsVo);
|
||||
BeanUtil.copyProperties(goodsSpu, goodsSkuDetailsVo);
|
||||
GoodsType goodsType = goodsTypeService.fetchBySid(goodsSpu.getGoodsTypeSid());
|
||||
if (goodsType != null && StringUtils.isNotBlank(goodsType.getIsGoodsID())) {
|
||||
goodsSkuDetailsVo.setIsGoodsID(Integer.parseInt(goodsType.getIsGoodsID()));
|
||||
goodsSkuDetailsVo.setGoodsTypeName(goodsType.getGoodsTypeName());
|
||||
} else {
|
||||
baseGoodsSkuDetailsVo.setIsGoodsID(0);
|
||||
goodsSkuDetailsVo.setIsGoodsID(0);
|
||||
}
|
||||
return rb.success().setData(baseGoodsSkuDetailsVo);
|
||||
return rb.success().setData(goodsSkuDetailsVo);
|
||||
}
|
||||
|
||||
public PagerVo<BaseGoodsSkuSelectList> getSelectList(PagerQuery<BaseGoodsSkuSelectQuery> pagerQuery) {
|
||||
BaseGoodsSkuSelectQuery query = pagerQuery.getParams();
|
||||
QueryWrapper<BaseGoodsSku> qw = new QueryWrapper<>();
|
||||
public PagerVo<SkuSelectList> getSelectList(PagerQuery<GoodsSkuSelectQuery> pagerQuery) {
|
||||
GoodsSkuSelectQuery query = pagerQuery.getParams();
|
||||
QueryWrapper<GoodsSku> qw = new QueryWrapper<>();
|
||||
if (query != null) {
|
||||
//商品编码
|
||||
if (StringUtils.isNotBlank(query.getGoodsSkuCode())) {
|
||||
qw.like("sku.goodsSkuCode", query.getGoodsSkuCode());
|
||||
}
|
||||
}
|
||||
IPage<BaseGoodsSku> page = PagerUtil.queryToPage(pagerQuery);
|
||||
IPage<BaseGoodsSkuSelectList> pagging = baseMapper.getSelectList(page, qw);
|
||||
PagerVo<BaseGoodsSkuSelectList> p = PagerUtil.pageToVo(pagging, null);
|
||||
IPage<GoodsSku> page = PagerUtil.queryToPage(pagerQuery);
|
||||
IPage<SkuSelectList> pagging = baseMapper.getSelectList(page, qw);
|
||||
PagerVo<SkuSelectList> p = PagerUtil.pageToVo(pagging, null);
|
||||
return p;
|
||||
}
|
||||
|
||||
public ResultBean<PagerVo<BaseGoodsSkuPurSelectList>> purGoodsListPage(PagerQuery<BaseGoodsSkuPurSelectQuery> pq) {
|
||||
public ResultBean<PagerVo<GoodsSkuPurSelectList>> purGoodsListPage(PagerQuery<GoodsSkuPurSelectQuery> pq) {
|
||||
ResultBean rb = ResultBean.fireFail();
|
||||
BaseGoodsSkuPurSelectQuery query = pq.getParams();
|
||||
QueryWrapper<BaseGoodsSku> qw = new QueryWrapper<>();
|
||||
GoodsSkuPurSelectQuery query = pq.getParams();
|
||||
QueryWrapper<GoodsSku> qw = new QueryWrapper<>();
|
||||
if (StringUtils.isNotBlank(query.getOrgSid())){
|
||||
qw.eq("s.createOrgSid",query.getOrgSid());
|
||||
}
|
||||
@@ -221,9 +220,9 @@ public class BaseGoodsSkuService extends MybatisBaseService<BaseGoodsSkuMapper,
|
||||
if (org.apache.commons.lang3.StringUtils.isNotBlank(query.getOtherQuery())){
|
||||
qw.and(wrapper -> wrapper.like("a.goodsName", query.getOtherQuery()).or().like("s.goodsSkuCode", query.getOtherQuery()).or().like("a.goodsPY",query.getOtherQuery()));
|
||||
}
|
||||
IPage<BaseGoodsSku> page = PagerUtil.queryToPage(pq);
|
||||
IPage<BaseGoodsSkuPurSelectList> pagging = baseMapper.purGoodsListPage(page, qw);
|
||||
PagerVo<BaseGoodsSkuPurSelectList> p = PagerUtil.pageToVo(pagging, null);
|
||||
IPage<GoodsSku> page = PagerUtil.queryToPage(pq);
|
||||
IPage<GoodsSkuPurSelectList> pagging = baseMapper.purGoodsListPage(page, qw);
|
||||
PagerVo<GoodsSkuPurSelectList> p = PagerUtil.pageToVo(pagging, null);
|
||||
return rb.success().setData(p);
|
||||
}
|
||||
}
|
||||
@@ -1,8 +1,8 @@
|
||||
package com.yxt.goods.biz.base.basegoodssku;
|
||||
package com.yxt.goods.biz.goodssku;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.yxt.goods.biz.base.basegoodsskuextend.BaseGoodsSkuExtendVo;
|
||||
import com.yxt.goods.biz.goodsskuextend.GoodsSkuExtendVo;
|
||||
import com.yxt.common.core.vo.Vo;
|
||||
import lombok.Data;
|
||||
|
||||
@@ -13,7 +13,7 @@ import java.util.Date;
|
||||
* @date 2024/2/26 13:37
|
||||
*/
|
||||
@Data
|
||||
public class BaseGoodsSkuVo implements Vo {
|
||||
public class GoodsSkuVo implements Vo {
|
||||
private String id;
|
||||
private String sid;
|
||||
private String lockVersion;
|
||||
@@ -33,6 +33,6 @@ public class BaseGoodsSkuVo implements Vo {
|
||||
@TableField(value = "own_spec")
|
||||
private String ownSpec;//sku的特有规格参数键值对,json格式,反序列化时请使用linkedHashMap,保证有序
|
||||
private String goodsName;
|
||||
private BaseGoodsSkuExtendVo baseGoodsSkuExtend;
|
||||
private GoodsSkuExtendVo baseGoodsSkuExtend;
|
||||
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basegoodssku;
|
||||
package com.yxt.goods.biz.goodssku;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
@@ -8,7 +8,7 @@ import lombok.Data;
|
||||
* @date: 2024/3/21
|
||||
**/
|
||||
@Data
|
||||
public class BaseGoodsSkuSelectList {
|
||||
public class SkuSelectList {
|
||||
|
||||
//商品名称
|
||||
private String goodsSpuSid;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.yxt.goods.biz.base.basegoodsskuextend;
|
||||
package com.yxt.goods.biz.goodsskuextend;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.yxt.common.core.domain.BaseEntity;
|
||||
@@ -9,7 +9,7 @@ import lombok.Data;
|
||||
* @date 2024/2/26 13:36
|
||||
*/
|
||||
@Data
|
||||
public class BaseGoodsSkuExtend extends BaseEntity {
|
||||
public class GoodsSkuExtend extends BaseEntity {
|
||||
private String goodsSkuSid;//商品Sku代码
|
||||
private String finalPurchasePrice;//最后采购价
|
||||
private String safetyStockDays;//安全库存天数
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user