同步任务修改,逐日数据统计修改
parent
3d3c4f90f0
commit
a0bc0282f7
|
|
@ -101,6 +101,9 @@ public class OrderEndService extends BaseService {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
public void queryList(String stm,String etm,String supermarketId) {
|
||||||
|
queryList(null,null,null,stm,etm);
|
||||||
|
}
|
||||||
public void queryList(String tm,String customerId,String supermarketId,String stm,String etm) {
|
public void queryList(String tm,String customerId,String supermarketId,String stm,String etm) {
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -968,8 +968,16 @@ public class OrderStatService {
|
||||||
String productParams = "";
|
String productParams = "";
|
||||||
|
|
||||||
if (supermarket_id != null && supermarket_id > 0) {
|
if (supermarket_id != null && supermarket_id > 0) {
|
||||||
productParams += " and t.supermarket_id = ?\n";
|
if (6 == supermarket_id){
|
||||||
paramsArray.add(supermarket_id);
|
productParams += " and (t.supermarket_id = ? OR t.supermarket_id = ? OR t.supermarket_id = ?)\n";
|
||||||
|
paramsArray.add(6);
|
||||||
|
paramsArray.add(8);
|
||||||
|
paramsArray.add(10);
|
||||||
|
}else{
|
||||||
|
productParams += " and t.supermarket_id = ?\n";
|
||||||
|
paramsArray.add(supermarket_id);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
if (stat_product) {
|
if (stat_product) {
|
||||||
if (product_id != null && product_id > 0) {
|
if (product_id != null && product_id > 0) {
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,8 @@ public class OrderEndJob implements Job {
|
||||||
public void execute(JobExecutionContext jobExecutionContext) throws JobExecutionException {
|
public void execute(JobExecutionContext jobExecutionContext) throws JobExecutionException {
|
||||||
// 获取前一天的数据
|
// 获取前一天的数据
|
||||||
log.info("开始同步");
|
log.info("开始同步");
|
||||||
OrderEndService.me.syncOrderTemp(LocalDate.now().minusDays(1).toString()); // 每天早上更新数据
|
LocalDate localDate = LocalDate.now().minusDays(1);
|
||||||
|
OrderEndService.me.queryList(localDate.minusDays(60).toString(),localDate.toString()); // 最近60天的数据
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue