|
@@ -190,19 +190,19 @@ public class TenantAlbumServiceImpl extends ServiceImpl<TenantAlbumMapper, Tenan
|
|
|
|
|
|
//检查曲目数量
|
|
|
//机构专辑曲目数
|
|
|
- List<TenantAlbumMusic> tenantAlbumMusiclist = tenantAlbumMusicService.lambdaQuery().eq(TenantAlbumMusic::getTenantAlbumId, orderGoodsInfo.getBizId())
|
|
|
- .eq(TenantAlbumMusic::getDelFlag,false).list();
|
|
|
- List<Long> musicSheetIds = tenantAlbumMusiclist.stream().map(TenantAlbumMusic::getMusicSheetId).collect(Collectors.toList());
|
|
|
- if(CollectionUtils.isNotEmpty(musicSheetIds)){
|
|
|
- Integer count = musicSheetService.lambdaQuery().in(MusicSheet::getId, musicSheetIds)
|
|
|
- .eq(MusicSheet::getState, true)
|
|
|
- .eq(MusicSheet::getDelFlag, false).count();
|
|
|
- if(count < 1){
|
|
|
- throw new BizException("当前教程不可购买");
|
|
|
- }
|
|
|
- }else {
|
|
|
- throw new BizException("当前教程不可购买");
|
|
|
- }
|
|
|
+// List<TenantAlbumMusic> tenantAlbumMusiclist = tenantAlbumMusicService.lambdaQuery().eq(TenantAlbumMusic::getTenantAlbumId, orderGoodsInfo.getBizId())
|
|
|
+// .eq(TenantAlbumMusic::getDelFlag,false).list();
|
|
|
+// List<Long> musicSheetIds = tenantAlbumMusiclist.stream().map(TenantAlbumMusic::getMusicSheetId).collect(Collectors.toList());
|
|
|
+// if(CollectionUtils.isNotEmpty(musicSheetIds)){
|
|
|
+// Integer count = musicSheetService.lambdaQuery().in(MusicSheet::getId, musicSheetIds)
|
|
|
+// .eq(MusicSheet::getState, true)
|
|
|
+// .eq(MusicSheet::getDelFlag, false).count();
|
|
|
+// if(count < 1){
|
|
|
+// throw new BizException("当前教程不可购买");
|
|
|
+// }
|
|
|
+// }else {
|
|
|
+// throw new BizException("当前教程不可购买");
|
|
|
+// }
|
|
|
if (orderGoodsInfo == null) {
|
|
|
log.error("订单创建前检测,订单商品信息为空");
|
|
|
throw new BizException("订单商品信息为空");
|