yanite 3 лет назад
Родитель
Сommit
eda2fa55a8

+ 13 - 3
mec-biz/src/main/java/com/ym/mec/biz/service/impl/IndexBaseMonthDataServiceImpl.java

@@ -3,23 +3,29 @@ package com.ym.mec.biz.service.impl;
 import com.alibaba.fastjson.JSON;
 import com.ym.mec.auth.api.client.SysUserFeignService;
 import com.ym.mec.auth.api.entity.SysUser;
+import com.ym.mec.auth.api.entity.SysUserRole;
 import com.ym.mec.biz.dal.dao.*;
 import com.ym.mec.biz.dal.dto.*;
 import com.ym.mec.biz.dal.entity.*;
 import com.ym.mec.biz.dal.enums.*;
 import com.ym.mec.biz.dal.page.IndexDataQueryInfo;
 import com.ym.mec.biz.dal.page.OrganCloudStudyStudentDataQueryInfo;
+import com.ym.mec.biz.dal.page.OrganizationQueryInfo;
 import com.ym.mec.biz.service.*;
 import com.ym.mec.common.constant.CommonConstants;
 import com.ym.mec.common.dal.BaseDAO;
 import com.ym.mec.common.exception.BizException;
+import com.ym.mec.common.filters.TenantIdThreadLocal;
 import com.ym.mec.common.page.PageInfo;
 import com.ym.mec.common.service.impl.BaseServiceImpl;
 import com.ym.mec.common.tenant.TenantContextHolder;
 import com.ym.mec.util.collection.MapUtil;
 import com.ym.mec.util.date.DateUtil;
+
+import io.swagger.models.auth.In;
 import org.apache.commons.lang3.StringUtils;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.http.HttpStatus;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
 import org.springframework.util.CollectionUtils;
@@ -28,10 +34,12 @@ import java.math.BigDecimal;
 import java.time.DayOfWeek;
 import java.time.LocalDate;
 import java.time.LocalDateTime;
+import java.time.format.DateTimeFormatter;
 import java.util.*;
 import java.util.stream.Collectors;
 
 import static com.ym.mec.biz.dal.enums.IndexDataType.*;
+import static com.ym.mec.biz.dal.enums.IndexErrorType.WAIT_CREATE_PAYMENT_CALENDER;
 import static com.ym.mec.biz.dal.enums.SysUserRoleEnum.EDUCATION;
 
 @Service
@@ -42,6 +50,8 @@ public class IndexBaseMonthDataServiceImpl extends BaseServiceImpl<Long, IndexBa
 	@Autowired
 	private OrganizationService organizationService;
 	@Autowired
+	private EmployeeDao employeeDao;
+	@Autowired
 	private MusicGroupDao musicGroupDao;
 	@Autowired
 	private SysConfigDao sysConfigDao;
@@ -56,6 +66,8 @@ public class IndexBaseMonthDataServiceImpl extends BaseServiceImpl<Long, IndexBa
 	@Autowired
 	private ClassGroupDao classGroupDao;
 	@Autowired
+	private EmployeeService employeeService;
+	@Autowired
 	private StudentRegistrationDao studentRegistrationDao;
 	@Autowired
 	private MusicGroupPerformanceDao musicGroupPerformanceDao;
@@ -86,7 +98,7 @@ public class IndexBaseMonthDataServiceImpl extends BaseServiceImpl<Long, IndexBa
 		if(Objects.nonNull(queryInfo.getStartDate())){
 			startDate = LocalDateTime.ofInstant(queryInfo.getStartDate().toInstant(), DateUtil.zoneId).toLocalDate();
 		}
-		startDate = startDate.plusDays(-180);
+
 		LocalDate endDate = nowDate.plusDays(-1);
 		if(Objects.nonNull(queryInfo.getEndDate())){
 			endDate = LocalDateTime.ofInstant(queryInfo.getEndDate().toInstant(), DateUtil.zoneId).toLocalDate();
@@ -277,7 +289,6 @@ public class IndexBaseMonthDataServiceImpl extends BaseServiceImpl<Long, IndexBa
 			}
 			IndexBaseDto indexBaseData = new IndexBaseDto(typeDateMapEntry.getKey(),typeDateMapEntry.getKey().getMsg());
 			indexBaseData.setIndexMonthData(value, currentMonth);
-			indexBaseData.setPercent(value.stream().map(IndexBaseMonthData::getPercent).reduce(BigDecimal.ZERO, BigDecimal::add));
 			if(OTHER_AMOUNT.equals(typeDateMapEntry.getKey())){
 				List<IndexBaseMonthData> otherAmountDetails = new ArrayList<>();
 				if(value != null && value.size() > 0){
@@ -311,7 +322,6 @@ public class IndexBaseMonthDataServiceImpl extends BaseServiceImpl<Long, IndexBa
 					}
 				}
 			}
-
 			result.add(indexBaseData);
 		}
 		return result;

+ 2 - 1
mec-web/src/main/java/com/ym/mec/web/controller/ExportController.java

@@ -1367,7 +1367,8 @@ public class ExportController extends BaseController {
         queryInfo.setIsExport(1);
         queryInfo.setPage(1);
         queryInfo.setRows(49999);
-        PageInfo<CourseReviewDto> practiceGroupReviews = courseReviewService.findPracticeGroupReviews(queryInfo);
+        // PageInfo<CourseReviewDto> practiceGroupReviews = courseReviewService.findPracticeGroupReviews(queryInfo);
+        PageInfo<CourseReviewDto> practiceGroupReviews = courseReviewService.getVipCourseReviews(queryInfo);
         if (practiceGroupReviews.getTotal() <= 0) {
             response.setStatus(500);
             response.setContentType("Content-Type: application/json;charset=UTF-8");