Upd:添加指定商户消费者数据重生接口

master
dulingling 5 years ago
parent b19d14ab7a
commit 2b921b92c3

@ -9,7 +9,7 @@
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>manage</artifactId>
<version>1.3.91</version>
<version>1.3.92</version>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<jib-maven-plugin.version>1.8.0</jib-maven-plugin.version>

@ -57,7 +57,7 @@ public interface DashboardService {
void generateCustomersAndOrdersStatistics(Date analysisDate);
void generateCustomersAndOrdersStatisticsByClientMoniker(Date analysisDate,String clientMoniker);
void generateCustomersAndOrdersStatisticsByClientMoniker(Date analysisDate,String clientId);
JSONObject getOrderAndCustomerPerDay(JSONObject partner,AnalysisBean partnerAnalysisBean);

@ -493,14 +493,14 @@ public class DashboardServiceImpl implements DashboardService,DashboardAnalysisT
/**
*
* @param analysisDate
* @param clientMoniker
* @param clientId
*/
public void generateCustomersAndOrdersStatisticsByClientMoniker(Date analysisDate,String clientMoniker){
public void generateCustomersAndOrdersStatisticsByClientMoniker(Date analysisDate,String clientId){
DateFormat format = new SimpleDateFormat("yyyyMMdd");
String date = format.format(analysisDate);
List<JSONObject> clients =clientMapper.listClients();
for (JSONObject client:clients){
if(client.getString("client_moniker").equals(clientMoniker)){
if(client.getString("client_id").equals(clientId)){
generateData(format, date, client);
}
}

@ -579,12 +579,12 @@ public class TestController implements ApplicationEventPublisherAware {
/**
*
* @param date
* @param clientMoniker
* @param clientId
*/
@GetMapping("/task/analysisCustomerDashboard")
public void analysisCustomerDashboardForClientMoniker(@RequestParam("date") String date,String clientMoniker){
public void analysisCustomerDashboardForClientMoniker(@RequestParam("date") String date,@RequestParam("clientId")String clientId){
try {
dashboardService.generateCustomersAndOrdersStatisticsByClientMoniker(DateUtils.addDays(new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").parse(date), -1),clientMoniker);
dashboardService.generateCustomersAndOrdersStatisticsByClientMoniker(DateUtils.addDays(new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").parse(date), -1),clientId);
} catch (ParseException e) {
e.printStackTrace();
}

Loading…
Cancel
Save