|
@@ -3,17 +3,23 @@ package com.ruoyi.system.service.impl;
|
|
|
import java.sql.Time;
|
|
|
import java.text.SimpleDateFormat;
|
|
|
import java.time.LocalDateTime;
|
|
|
+import java.util.Arrays;
|
|
|
import java.util.Date;
|
|
|
import java.util.List;
|
|
|
import java.util.stream.Collectors;
|
|
|
|
|
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
|
|
+import com.ruoyi.common.exception.ServiceException;
|
|
|
+import com.ruoyi.common.exception.base.BaseException;
|
|
|
import com.ruoyi.common.utils.DateUtils;
|
|
|
import com.ruoyi.system.domain.vo.CollectionsVo;
|
|
|
import com.ruoyi.system.mapper.PostCollectionsMapper;
|
|
|
import com.ruoyi.system.service.IPostCollectionsService;
|
|
|
+import com.ruoyi.system.utils.CollectionStatusJudgment;
|
|
|
+import com.sun.xml.internal.ws.api.message.ExceptionHasMessage;
|
|
|
import org.apache.commons.lang3.builder.ToStringExclude;
|
|
|
import org.apache.ibatis.type.LocalDateTimeTypeHandler;
|
|
|
+import org.apache.poi.ss.formula.functions.Count;
|
|
|
import org.springframework.beans.BeanUtils;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.format.annotation.DateTimeFormat;
|
|
@@ -39,6 +45,9 @@ public class PostCollectionsSystemServiceImpl implements IPostCollectionsSystemS
|
|
|
@Autowired
|
|
|
private PostCollectionsSystemMapper postCollectionsSystemMapper;
|
|
|
|
|
|
+ @Autowired
|
|
|
+ private PostCollectionsMapper postCollectionsMapper;
|
|
|
+
|
|
|
/**
|
|
|
* 查询藏品套系
|
|
|
*
|
|
@@ -154,8 +163,17 @@ public class PostCollectionsSystemServiceImpl implements IPostCollectionsSystemS
|
|
|
* @return 结果
|
|
|
*/
|
|
|
@Override
|
|
|
- public int deletePostCollectionsSystemByIds(Long[] ids)
|
|
|
- {
|
|
|
+ public int deletePostCollectionsSystemByIds(Long[] ids) {
|
|
|
+
|
|
|
+
|
|
|
+ List<PostCollectionsSystem> postCollectionsSystemList = postCollectionsSystemMapper.selectListEqStatus(ids);
|
|
|
+ if (postCollectionsSystemList.size()!= 0){
|
|
|
+ throw new BaseException("套系已上架");
|
|
|
+ }
|
|
|
+
|
|
|
+ postCollectionsMapper.deletePostCollectionsBySystemIds(ids);
|
|
|
+
|
|
|
+
|
|
|
return postCollectionsSystemMapper.deletePostCollectionsSystemByIds(ids);
|
|
|
}
|
|
|
|