过滤 已参团的

This commit is contained in:
2025-12-17 11:49:07 +08:00
parent 8a7d63911e
commit ec51a38f51
6 changed files with 40 additions and 10 deletions

View File

@@ -78,6 +78,16 @@ public class GbWareServiceImpl extends ServiceImpl<GbWareMapper, GbWare> impleme
return remove(query().eq(GbWare::getId, id).eq(GbWare::getShopId, StpKit.USER.getShopId()));
}
@Override
public void upGbWareGroupedNum(Long id) {
GbWare ware = getById(id);
if (ware != null) {
GbWare upWare = new GbWare();
upWare.setGroupedNum(ware.getGroupedNum() == null ? 1 : ware.getGroupedNum() + 1);
update(upWare, query().eq(GbWare::getId, id));
}
}
private void checkStatus(Long id) {
GbWare ware = getById(id);
AssertUtil.isNotEqual(ware.getOnlineStatus(), 0, "操作失败,请下架后,重试");