|
|
|
@ -41,8 +41,13 @@ public class SynchronizedAmountServiceImpl implements SynchronizedAmountService
|
|
|
|
|
public CommonResult<Object> synchronizedAmount(SubAccountsVo subAccountsVo) {
|
|
|
|
|
PayTwoOrder payTwoOrder = new PayTwoOrder();
|
|
|
|
|
//获取同步时间内的历史订单数
|
|
|
|
|
Integer taoBaoSaleSize = requestCore.getTaoBaoSaleSize(subAccountsVo.getStartTime(), subAccountsVo.getEndTime(), subAccountsVo.getSessionKey());
|
|
|
|
|
|
|
|
|
|
Integer taoBaoSaleSize;
|
|
|
|
|
try {
|
|
|
|
|
taoBaoSaleSize = requestCore.getTaoBaoSaleSize(subAccountsVo.getStartTime(), subAccountsVo.getEndTime(), subAccountsVo.getSessionKey());
|
|
|
|
|
} catch (Exception e) {
|
|
|
|
|
log.error("==========获取淘宝历史订单数错误,{}", e.getMessage());
|
|
|
|
|
return new CommonResult<>().error("请求错误,检查是否账号过期");
|
|
|
|
|
}
|
|
|
|
|
double historyAmount = 0.00;
|
|
|
|
|
int day = Math.toIntExact(DateUtil.betweenDay(DateUtil.parse(subAccountsVo.getStartTime()), DateUtil.parse(subAccountsVo.getEndTime()), true));
|
|
|
|
|
int average;
|
|
|
|
|