|
@@ -6,10 +6,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
|
import com.winhc.common.model.base.VOPage;
|
|
import com.winhc.common.model.base.VOPage;
|
|
import com.winhc.repal.constant.Constant;
|
|
import com.winhc.repal.constant.Constant;
|
|
-import com.winhc.repal.entity.RepalBook;
|
|
|
|
-import com.winhc.repal.entity.RepalGroup;
|
|
|
|
-import com.winhc.repal.entity.RepalGroupMember;
|
|
|
|
-import com.winhc.repal.entity.UserExt;
|
|
|
|
|
|
+import com.winhc.repal.entity.*;
|
|
import com.winhc.repal.enums.DeletedStatusEnum;
|
|
import com.winhc.repal.enums.DeletedStatusEnum;
|
|
import com.winhc.repal.enums.RoleTypeEnum;
|
|
import com.winhc.repal.enums.RoleTypeEnum;
|
|
import com.winhc.repal.model.dto.InitGroupDTO;
|
|
import com.winhc.repal.model.dto.InitGroupDTO;
|
|
@@ -25,6 +22,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.stereotype.Service;
|
|
import org.springframework.stereotype.Service;
|
|
import org.springframework.transaction.annotation.Transactional;
|
|
import org.springframework.transaction.annotation.Transactional;
|
|
|
|
|
|
|
|
+import java.time.LocalDateTime;
|
|
import java.util.ArrayList;
|
|
import java.util.ArrayList;
|
|
import java.util.Objects;
|
|
import java.util.Objects;
|
|
import java.util.stream.Collectors;
|
|
import java.util.stream.Collectors;
|
|
@@ -54,6 +52,9 @@ public class RepalGroupServiceImpl extends ServiceImpl<RepalGroupMapper, RepalGr
|
|
@Autowired
|
|
@Autowired
|
|
private UserExtService userExtService;
|
|
private UserExtService userExtService;
|
|
|
|
|
|
|
|
+ @Autowired
|
|
|
|
+ private RepalVipService repalVipService;
|
|
|
|
+
|
|
@Override
|
|
@Override
|
|
@Transactional(rollbackFor = Exception.class)
|
|
@Transactional(rollbackFor = Exception.class)
|
|
public Boolean initGroup(InitGroupDTO dto) {
|
|
public Boolean initGroup(InitGroupDTO dto) {
|
|
@@ -112,4 +113,27 @@ public class RepalGroupServiceImpl extends ServiceImpl<RepalGroupMapper, RepalGr
|
|
voPage.setDataList(page.getRecords().stream().map(t -> new GroupMemberVo(t.getUserId(), t.getMemberUserName())).collect(Collectors.toList()));
|
|
voPage.setDataList(page.getRecords().stream().map(t -> new GroupMemberVo(t.getUserId(), t.getMemberUserName())).collect(Collectors.toList()));
|
|
return voPage;
|
|
return voPage;
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ @Override
|
|
|
|
+ @Transactional(rollbackFor = Exception.class)
|
|
|
|
+ public Boolean vipCallback(Long repalGroupId) {
|
|
|
|
+ RepalVip repalVip = new RepalVip();
|
|
|
|
+ repalVip.setRepalGroupId(repalGroupId);
|
|
|
|
+ //repalVip.setRepalVipSign();
|
|
|
|
+ repalVip.setRepalVipStartTime(LocalDateTime.now());
|
|
|
|
+ //repalVip.setRepalVipEndTime();
|
|
|
|
+ //repalVip.setCurrentOrder();
|
|
|
|
+ // remainCount
|
|
|
|
+// repalVip.setSmsRemainCount();
|
|
|
|
+// repalVip.setLetterRemainCount();
|
|
|
|
+// repalVip.setConsultRemainCount();
|
|
|
|
+// repalVip.setLawsuitRemainCount();
|
|
|
|
+ // total
|
|
|
|
+// repalVip.setSmsTotalCount();
|
|
|
|
+// repalVip.setLetterTotalCount();
|
|
|
|
+// repalVip.setConsultTotalCount();
|
|
|
|
+// repalVip.setLawsuitTotalCount();
|
|
|
|
+ repalVipService.save(repalVip);
|
|
|
|
+ return true;
|
|
|
|
+ }
|
|
}
|
|
}
|