Browse Source

Merge remote-tracking branch 'origin/dev_screen_data_2.0' into dev_temp

dev_shibei_match
zxc 5 years ago
parent
commit
6ce5e6bf8a
  1. 12
      epmet-module/epmet-job/epmet-job-server/src/main/java/com/epmet/service/impl/DimPartyMemberServiceImpl.java

12
epmet-module/epmet-job/epmet-job-server/src/main/java/com/epmet/service/impl/DimPartyMemberServiceImpl.java

@ -1,5 +1,7 @@
package com.epmet.service.impl;
import com.alibaba.druid.util.StringUtils;
import com.epmet.commons.tools.constant.NumConstant;
import com.epmet.commons.tools.utils.Result;
import com.epmet.dto.stats.form.CustomerIdAndDateIdFormDTO;
import com.epmet.feign.DataStatisticalOpenFeignClient;
@ -7,6 +9,8 @@ import com.epmet.service.DimPartyMemberService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.time.LocalDate;
/**
* @Author zxc
* @DateTime 2020/9/17 3:06 下午
@ -21,7 +25,13 @@ public class DimPartyMemberServiceImpl implements DimPartyMemberService {
@Override
public Result getPartyInfo(String dateId) {
CustomerIdAndDateIdFormDTO c = new CustomerIdAndDateIdFormDTO();
c.setDateId(dateId);
if (!StringUtils.isEmpty(dateId)) {
c.setDateId(dateId);
}else {
String now = LocalDate.now().minusDays(NumConstant.ONE).toString();
String concat = now.substring(NumConstant.ZERO, NumConstant.FOUR).concat(now.substring(NumConstant.FIVE, NumConstant.SEVEN)).concat(now.substring(NumConstant.EIGHT, NumConstant.TEN));
c.setDateId(concat);
}
return statsFeignClient.getPartyInfo(c);
}
}

Loading…
Cancel
Save