feat: 增加根据用户id获取收件地址列表接口

This commit is contained in:
sdhkjh 2024-09-18 15:04:25 +08:00
parent 9495618ca4
commit d1c9dff531
2 changed files with 9 additions and 4 deletions

View file

@ -84,12 +84,17 @@ public class ShopAddressController {
shopAddressService.queryList(inputObject, outputObject);
}
@ApiOperation(id = "queryShopAddressByCreateId", value = "获取默认收件地址信息", method = "POST", allUse = "2")
/**
* 获取用户收件地址信息
*
* @param inputObject 入参以及用户信息等获取对象
* @param outputObject 出参以及提示信息的返回值对象
*/
@ApiOperation(id = "queryShopAddressByCreateId", value = "获取用户收件地址信息", method = "POST", allUse = "2")
@ApiImplicitParams({
@ApiImplicitParam(id = "userId", name = "userId", value = "用户主键id", required = "required")})
@RequestMapping("/post/ShopAddressController/queryShopAddressByCreateId")
public void queryShopAddressByCreateId(InputObject inputObject, OutputObject outputObject) {
shopAddressService.queryShopAddressByCreateId(inputObject, outputObject);
}
}
}

View file

@ -72,7 +72,7 @@ public class ShopAddressServiceImpl extends SkyeyeBusinessServiceImpl<ShopAddres
}
@Override
public List<Map<String, Object>> queryDataList(InputObject inputObject){
public List<Map<String, Object>> queryDataList(InputObject inputObject) {
String userId = InputObject.getLogParamsStatic().get("id").toString();
QueryWrapper<ShopAddress> queryWrapper = new QueryWrapper<>();
queryWrapper.eq(MybatisPlusUtil.toColumns(ShopAddress::getCreateId), userId);