| | |
| | | return Result.success(); |
| | | } |
| | | |
| | | @ApiOperation("商品搜索历史记录--全部清空") |
| | | @PostMapping(value = "/goods/delAllSearch") |
| | | public Result<String> delAllSearch (@RequestBody GoodsSearchDto goodsSearchDto, HttpServletRequest request) { |
| | | goodsService.delAllSearch(getUserId(request)); |
| | | return Result.success(); |
| | | } |
| | | |
| | | } |
| | |
| | | criteriaSearch.andEqualTo("userId",userId); |
| | | scoreGoodsSearchMapper.deleteByExample(exampleSearch); |
| | | } |
| | | |
| | | public void delAllSearch(String userId) { |
| | | Example exampleSearch = new Example(ScoreGoodsSearch.class); |
| | | Example.Criteria criteriaSearch = exampleSearch.createCriteria(); |
| | | criteriaSearch.andEqualTo("userId",userId); |
| | | scoreGoodsSearchMapper.deleteByExample(exampleSearch); |
| | | } |
| | | } |