商品缓存问题处理

This commit is contained in:
Chopper
2021-08-09 11:46:12 +08:00
parent 8ceb214252
commit 50f27e57d4
3 changed files with 19 additions and 25 deletions

View File

@@ -94,7 +94,7 @@ public class GoodsStoreController {
@GetMapping(value = "/get/{id}")
public ResultMessage<GoodsVO> get(@PathVariable String id) {
AuthUser tokenUser = UserContext.getCurrentUser();
GoodsVO goods = goodsService.getGoodsVOFromDB(id);
GoodsVO goods = goodsService.getGoodsVO(id);
assert tokenUser != null;
if (tokenUser.getStoreId().equals(goods.getStoreId())) {
return ResultUtil.data(goods);