|
|
|
@ -231,7 +231,6 @@ public class DashboardServiceImpl implements DashboardService,DashboardAnalysisT
|
|
|
|
|
public JSONObject getCommonAnalysis(JSONObject partner, AnalysisBean partnerAnalysisBean) {
|
|
|
|
|
String timezone = partner.getJSONObject("client").getString("timezone");
|
|
|
|
|
JSONObject params = partnerAnalysisBean.toParams(timezone);
|
|
|
|
|
JSONObject params1 = partnerAnalysisBean.toParams(timezone);
|
|
|
|
|
try {
|
|
|
|
|
clientManager.validateClients(partner.getIntValue("client_id"), params);
|
|
|
|
|
} catch (Exception e) {
|
|
|
|
@ -241,9 +240,9 @@ public class DashboardServiceImpl implements DashboardService,DashboardAnalysisT
|
|
|
|
|
JSONObject res = new JSONObject();
|
|
|
|
|
params.put("client_id", partner.getIntValue("client_id"));
|
|
|
|
|
JSONObject today = getTransJSONO(params);
|
|
|
|
|
params1.put("begin",DateUtils.addDays(params1.getDate("begin"),-1));
|
|
|
|
|
params1.put("end",DateUtils.addDays(params1.getDate("end"),-1));
|
|
|
|
|
JSONObject yes = getTransJSONO(params1);
|
|
|
|
|
params.put("begin",DateUtils.addDays(params.getDate("begin"),-1));
|
|
|
|
|
params.put("end",DateUtils.addDays(params.getDate("end"),-1));
|
|
|
|
|
JSONObject yes = getTransJSONO(params);
|
|
|
|
|
res.put("today",today);
|
|
|
|
|
res.put("yes",yes);
|
|
|
|
|
res.put("not_settled", new BigDecimal(transactionAnalysisMapper.analysisNotSettled(params)));
|
|
|
|
@ -261,7 +260,6 @@ public class DashboardServiceImpl implements DashboardService,DashboardAnalysisT
|
|
|
|
|
JSONObject object = transactionAnalysisMapper.getClientTransaction(params);
|
|
|
|
|
res.put("trade_amount", object.getBigDecimal("trade_amount"));
|
|
|
|
|
res.put("trade_count", object.getIntValue("trade_count"));
|
|
|
|
|
params.remove("begin");
|
|
|
|
|
res.put("customers", transactionAnalysisMapper.countCustomers(params));
|
|
|
|
|
return res;
|
|
|
|
|
}
|
|
|
|
|