diff --git a/pom.xml b/pom.xml
index 4a40f3fcd..c731eaa54 100644
--- a/pom.xml
+++ b/pom.xml
@@ -10,7 +10,7 @@
4.0.0
manage
- 1.1.5
+ 1.1.6
UTF-8
diff --git a/src/main/java/au/com/royalpay/payment/manage/analysis/web/AmountAnalysisController.java b/src/main/java/au/com/royalpay/payment/manage/analysis/web/AmountAnalysisController.java
index 4e75a2934..6bacc82fc 100644
--- a/src/main/java/au/com/royalpay/payment/manage/analysis/web/AmountAnalysisController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/analysis/web/AmountAnalysisController.java
@@ -3,6 +3,7 @@ package au.com.royalpay.payment.manage.analysis.web;
import au.com.royalpay.payment.manage.analysis.beans.AnalysisBean;
import au.com.royalpay.payment.manage.analysis.core.AmountAnalysisService;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.tools.CommonConsts;
import au.com.royalpay.payment.tools.exceptions.ForbiddenException;
import com.alibaba.fastjson.JSONObject;
@@ -25,6 +26,7 @@ public class AmountAnalysisController {
private AmountAnalysisService amountAnalysisService;
@ManagerMapping("")
+ @ReadOnlyConnection
public List getAmountList(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
if (manager.getIntValue("org_id") > 0) {
throw new ForbiddenException("You have no permission");
@@ -34,6 +36,7 @@ public class AmountAnalysisController {
}
@ManagerMapping("/orders")
+ @ReadOnlyConnection
public JSONObject getRangeOrders(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
if (manager.getIntValue("org_id") > 0) {
throw new ForbiddenException("You have no permission");
diff --git a/src/main/java/au/com/royalpay/payment/manage/analysis/web/AreaMerchantTradeController.java b/src/main/java/au/com/royalpay/payment/manage/analysis/web/AreaMerchantTradeController.java
index e6735aaac..f9c48e8c7 100644
--- a/src/main/java/au/com/royalpay/payment/manage/analysis/web/AreaMerchantTradeController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/analysis/web/AreaMerchantTradeController.java
@@ -3,6 +3,7 @@ package au.com.royalpay.payment.manage.analysis.web;
import au.com.royalpay.payment.manage.analysis.beans.AreaMerchantTradeQueryBean;
import au.com.royalpay.payment.manage.analysis.core.AreaMerchantTradeAnalysis;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.tools.CommonConsts;
import au.com.royalpay.payment.tools.permission.enums.ManagerRole;
import com.alibaba.fastjson.JSONObject;
@@ -25,11 +26,13 @@ public class AreaMerchantTradeController {
private AreaMerchantTradeAnalysis areaMerchantTradeAnalysis;
@ManagerMapping(value = "",method = RequestMethod.GET,role = ManagerRole.ADMIN)
+ @ReadOnlyConnection
public JSONObject listClientAmount(@ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager,AreaMerchantTradeQueryBean queryBean){
return areaMerchantTradeAnalysis.listAreaMerchantTrade(manager,queryBean);
}
@ManagerMapping(value = "/excel",method = RequestMethod.GET,role = ManagerRole.ADMIN)
+ @ReadOnlyConnection
public void exportExcel(@ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager,AreaMerchantTradeQueryBean queryBean,HttpServletResponse httpResponse)throws Exception{
areaMerchantTradeAnalysis.importTradeExcel(manager,queryBean,httpResponse);
}
diff --git a/src/main/java/au/com/royalpay/payment/manage/analysis/web/BDSaleAnalysisController.java b/src/main/java/au/com/royalpay/payment/manage/analysis/web/BDSaleAnalysisController.java
index 03e2e0944..9da8b63dd 100644
--- a/src/main/java/au/com/royalpay/payment/manage/analysis/web/BDSaleAnalysisController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/analysis/web/BDSaleAnalysisController.java
@@ -3,6 +3,7 @@ package au.com.royalpay.payment.manage.analysis.web;
import au.com.royalpay.payment.manage.analysis.beans.AnalysisBean;
import au.com.royalpay.payment.manage.analysis.core.BDAnalysisService;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.tools.permission.enums.ManagerRole;
import au.com.royalpay.payment.tools.CommonConsts;
import com.alibaba.fastjson.JSONObject;
@@ -25,6 +26,7 @@ public class BDSaleAnalysisController {
private BDAnalysisService bdAnalysisService;
@ManagerMapping("/sales")
+ @ReadOnlyConnection
public List getSalesAnalysis(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(null);
if (manager.getInteger("org_id") != null) {
@@ -37,26 +39,31 @@ public class BDSaleAnalysisController {
}
@ManagerMapping("/sales/partners")
+ @ReadOnlyConnection
public List getSalesPartnerAnalysis(AnalysisBean analysis) {
return bdAnalysisService.getSalesPartnersByBD(analysis.toParams(null));
}
@ManagerMapping("/sales/partners/excel")
+ @ReadOnlyConnection
public void exportExcel(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager, HttpServletResponse httpResponse) throws Exception {
bdAnalysisService.exportSalesExcel(analysis,httpResponse,manager);
}
@ManagerMapping("/sales/partners/report")
+ @ReadOnlyConnection
public List getBDSalePartnerReport(AnalysisBean analysis){
return bdAnalysisService.getSalesPartnersReportByBD(analysis.toParams(null));
}
@ManagerMapping("/sales/partners/excel_bd")
+ @ReadOnlyConnection
public void exportPartnerExcelByBd(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager, HttpServletResponse httpResponse) throws Exception {
bdAnalysisService.exportPartnerExcelByBd(analysis,httpResponse,manager);
}
@ManagerMapping("/sales/partners/excel_data")
+ @ReadOnlyConnection
public void exportPartnerExcelByData(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager, HttpServletResponse httpResponse) throws Exception {
bdAnalysisService.exportPartnerExcelByData(analysis,httpResponse,manager);
}
diff --git a/src/main/java/au/com/royalpay/payment/manage/analysis/web/ChannelsAnalysisController.java b/src/main/java/au/com/royalpay/payment/manage/analysis/web/ChannelsAnalysisController.java
index 7efe709f7..8b767158a 100644
--- a/src/main/java/au/com/royalpay/payment/manage/analysis/web/ChannelsAnalysisController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/analysis/web/ChannelsAnalysisController.java
@@ -3,6 +3,7 @@ package au.com.royalpay.payment.manage.analysis.web;
import au.com.royalpay.payment.manage.analysis.beans.AnalysisBean;
import au.com.royalpay.payment.manage.analysis.core.ChannelsAnalysisService;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.tools.permission.enums.ManagerRole;
import au.com.royalpay.payment.tools.CommonConsts;
import com.alibaba.fastjson.JSONObject;
@@ -55,6 +56,7 @@ public class ChannelsAnalysisController {
}
@ManagerMapping(value = "/alipay/data/export")
+ @ReadOnlyConnection
public void exportAlipayData(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager, HttpServletResponse reps) {
JSONObject params = analysis.toParams(null);
if (manager.getInteger("org_id") != null) {
diff --git a/src/main/java/au/com/royalpay/payment/manage/analysis/web/ClientRatesController.java b/src/main/java/au/com/royalpay/payment/manage/analysis/web/ClientRatesController.java
index fa2015d96..016289979 100644
--- a/src/main/java/au/com/royalpay/payment/manage/analysis/web/ClientRatesController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/analysis/web/ClientRatesController.java
@@ -4,6 +4,7 @@ import au.com.royalpay.payment.core.exceptions.ParamInvalidException;
import au.com.royalpay.payment.manage.analysis.beans.ClientRateQueryBean;
import au.com.royalpay.payment.manage.analysis.core.ClientRatesAnalysisService;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.tools.permission.enums.ManagerRole;
import au.com.royalpay.payment.manage.signin.core.ManagerAccountsService;
import au.com.royalpay.payment.tools.CommonConsts;
@@ -33,6 +34,7 @@ public class ClientRatesController {
private ManagerAccountsService managerAccountsService;
@RequestMapping("/bd_users")
+ @ReadOnlyConnection
public JSONObject listAnalysisOfBDUsers(@ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager,
@RequestParam(name = "org_id", required = false) String orgId,
@RequestParam(name = "org_id2", required = false) String orgId2,
@@ -53,6 +55,7 @@ public class ClientRatesController {
}
@RequestMapping("/orgs/all")
+ @ReadOnlyConnection
public JSONObject analysisAllClientsRates(@ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager,
@Valid ClientRateQueryBean query, Errors errors) {
if (manager.getIntValue("org_id") > 0) {
@@ -73,6 +76,7 @@ public class ClientRatesController {
}
@RequestMapping("/bd_users/{bdId}")
+ @ReadOnlyConnection
public JSONObject analysisClientsOfBdUser(@ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager, @PathVariable String bdId,
@Valid ClientRateQueryBean query, Errors errors) {
if (ManagerRole.BD_USER.hasRole(manager.getIntValue("role")) && !manager.getString("manager_id").equals(bdId) ) {
diff --git a/src/main/java/au/com/royalpay/payment/manage/analysis/web/CustomersAnalysisController.java b/src/main/java/au/com/royalpay/payment/manage/analysis/web/CustomersAnalysisController.java
index 221fd493a..ba4049c23 100644
--- a/src/main/java/au/com/royalpay/payment/manage/analysis/web/CustomersAnalysisController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/analysis/web/CustomersAnalysisController.java
@@ -3,6 +3,7 @@ package au.com.royalpay.payment.manage.analysis.web;
import au.com.royalpay.payment.manage.analysis.beans.AnalysisBean;
import au.com.royalpay.payment.manage.analysis.core.CustomersAnalysisService;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.manage.tradelog.beans.TradeLogQuery;
import au.com.royalpay.payment.tools.CommonConsts;
import au.com.royalpay.payment.tools.permission.enums.ManagerRole;
@@ -29,6 +30,7 @@ public class CustomersAnalysisController {
private CustomersAnalysisService customersAnalysisService;
@ManagerMapping("/sys")
+ @ReadOnlyConnection
public List getCustomersAnalysis(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(null);
if (manager.getInteger("org_id") != null) {
@@ -44,6 +46,7 @@ public class CustomersAnalysisController {
}
@ManagerMapping("/sys/monthly")
+ @ReadOnlyConnection
public List getCustomersAnalysisMonthly(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(null);
if (manager.getInteger("org_id") != null) {
@@ -60,6 +63,7 @@ public class CustomersAnalysisController {
@ManagerMapping("/sys/channel")
+ @ReadOnlyConnection
public JSONObject getCustomersChannelAnalysis(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(null);
if (manager.getInteger("org_id") != null) {
@@ -75,6 +79,7 @@ public class CustomersAnalysisController {
}
@ManagerMapping("/sys/cbbank_channel")
+ @ReadOnlyConnection
public JSONObject getCBBankChannelAnalysis(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(null);
if (manager.getInteger("org_id") != null) {
@@ -90,6 +95,7 @@ public class CustomersAnalysisController {
}
@ManagerMapping(value = "/ranking/{openid_type}",role = ManagerRole.DEVELOPER)
+ @ReadOnlyConnection
public JSONObject getCustomersRanking(@PathVariable int openid_type, AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(null);
params.put("openid_type",openid_type);
@@ -101,6 +107,7 @@ public class CustomersAnalysisController {
}
@ManagerMapping(value = "/ranking/{openid_type}/total",role = ManagerRole.RISK_MANAGER)
+ @ReadOnlyConnection
public JSONObject getCustomersTotal(@PathVariable int openid_type, AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(null);
params.put("openid_type",openid_type);
@@ -112,6 +119,7 @@ public class CustomersAnalysisController {
}
@ManagerMapping(value = "/{customer_id}/orders",role = ManagerRole.DEVELOPER)
+ @ReadOnlyConnection
public JSONObject getCustomerOrders(@PathVariable String customer_id, TradeLogQuery tradeLogQuery, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = tradeLogQuery.toParams(null);
params.put("customer_id",customer_id);
diff --git a/src/main/java/au/com/royalpay/payment/manage/analysis/web/DailyReportController.java b/src/main/java/au/com/royalpay/payment/manage/analysis/web/DailyReportController.java
index ca37cb795..3283dab27 100644
--- a/src/main/java/au/com/royalpay/payment/manage/analysis/web/DailyReportController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/analysis/web/DailyReportController.java
@@ -3,6 +3,7 @@ package au.com.royalpay.payment.manage.analysis.web;
import au.com.royalpay.payment.manage.analysis.core.DailyReport;
import au.com.royalpay.payment.manage.application.core.SimpleClientService;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.tools.permission.enums.ManagerRole;
import au.com.royalpay.payment.tools.CommonConsts;
import au.com.royalpay.payment.tools.permission.wechat.WechatMapping;
@@ -43,6 +44,7 @@ public class DailyReportController {
}
@WechatMapping(value = "/greenChannel", method = RequestMethod.GET)
+ @ReadOnlyConnection
public ModelAndView greenChannel(@ModelAttribute(CommonConsts.WECHATINFO) JSONObject wxUser) {
Map clients = simpleClientService.getGreenChannelClients(null);
List resultWaringClients = new ArrayList<>();
@@ -84,6 +86,7 @@ public class DailyReportController {
}
@WechatMapping(value = "/greenChannelBD/{manager_id}", method = RequestMethod.GET)
+ @ReadOnlyConnection
public ModelAndView greenChanneasdl(@ModelAttribute(CommonConsts.WECHATINFO) JSONObject wxUser, @PathVariable String manager_id) {
Map clients = simpleClientService.getGreenChannelClients(manager_id);
String resultWaringClients = "";
diff --git a/src/main/java/au/com/royalpay/payment/manage/analysis/web/DashboardController.java b/src/main/java/au/com/royalpay/payment/manage/analysis/web/DashboardController.java
index 56cc96a55..48c58e309 100644
--- a/src/main/java/au/com/royalpay/payment/manage/analysis/web/DashboardController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/analysis/web/DashboardController.java
@@ -4,6 +4,7 @@ import au.com.royalpay.payment.manage.analysis.beans.AnalysisBean;
import au.com.royalpay.payment.manage.analysis.core.DashboardService;
import au.com.royalpay.payment.manage.organizations.core.OrgManager;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.tools.env.SysConfigManager;
import au.com.royalpay.payment.tools.permission.enums.ManagerRole;
import au.com.royalpay.payment.manage.permission.manager.RequirePartner;
@@ -30,6 +31,7 @@ public class DashboardController {
@ManagerMapping("/common_analysis_1")
+ @ReadOnlyConnection
public JSONObject commonAnalysis1(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(analysis.getTimezone());
orgManager.checkOrg(manager,params);
@@ -37,6 +39,7 @@ public class DashboardController {
}
@ManagerMapping("/common_analysis_3")
+ @ReadOnlyConnection
public JSONObject commonAnalysis3(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(analysis.getTimezone());
orgManager.checkOrg(manager,params);
@@ -44,6 +47,7 @@ public class DashboardController {
}
@ManagerMapping("/common_analysis_4")
+ @ReadOnlyConnection
public JSONObject commonAnalysis4(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(analysis.getTimezone());
orgManager.checkOrg(manager,params);
@@ -51,6 +55,7 @@ public class DashboardController {
}
@ManagerMapping("/common_analysis_2")
+ @ReadOnlyConnection
public JSONObject commonAnalysis2(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(analysis.getTimezone());
orgManager.checkOrg(manager,params);
@@ -58,6 +63,7 @@ public class DashboardController {
}
@ManagerMapping("/trade_in_types")
+ @ReadOnlyConnection
public List tradeInTypes(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(analysis.getTimezone());
orgManager.checkOrg(manager,params);
@@ -65,6 +71,7 @@ public class DashboardController {
}
@ManagerMapping("/top_trade_partners")
+ @ReadOnlyConnection
public List topTradePartners(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager,
@RequestParam(defaultValue = "10") int limit) {
@@ -75,6 +82,7 @@ public class DashboardController {
}
@ManagerMapping("/rank_trade_partners")
+ @ReadOnlyConnection
public List rankTradePartners(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(null);
orgManager.checkOrg(manager, params);
@@ -88,6 +96,7 @@ public class DashboardController {
}
@ManagerMapping("/trade_in_hours")
+ @ReadOnlyConnection
public List tradeInHours(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(null);
orgManager.checkOrg(manager,params);
@@ -101,6 +110,7 @@ public class DashboardController {
}
@ManagerMapping("/fee_analysis")
+ @ReadOnlyConnection
public List tradeInDays(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(null);
orgManager.checkOrg(manager,params);
@@ -108,6 +118,7 @@ public class DashboardController {
}
@ManagerMapping("/new_clients")
+ @ReadOnlyConnection
public List clientsTradeInDays(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(null);
orgManager.checkOrg(manager,params);
@@ -115,6 +126,7 @@ public class DashboardController {
}
@ManagerMapping("/partners_in_types")
+ @ReadOnlyConnection
public List partnersInTypes(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(analysis.getTimezone());
orgManager.checkOrg(manager,params);
@@ -128,6 +140,7 @@ public class DashboardController {
}
@ManagerMapping("/gateway/{trade_type}/partners")
+ @ReadOnlyConnection
public List getPartnersByTradeType(@PathVariable String trade_type, AnalysisBean analysis,
@ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(null);
@@ -144,6 +157,7 @@ public class DashboardController {
}
@ManagerMapping("/trade_in_time")
+ @ReadOnlyConnection
public List tradeInTime(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(null);
orgManager.checkOrg(manager,params);
@@ -151,17 +165,20 @@ public class DashboardController {
}
@ManagerMapping("/exchange_rates")
+ @ReadOnlyConnection
@RequirePartner
public List getExchangeRateHistory(@RequestParam String begin, @RequestParam String end) {
return dashboardService.listExchangeRateHistory(begin, end);
}
@ManagerMapping("/max_record")
+ @ReadOnlyConnection
public JSONObject getMaxRecord(@ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
return dashboardService.getNewRecord();
}
@ManagerMapping("/Total_platform_amount")
+ @ReadOnlyConnection
public JSONObject getPlatformAmount(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager){
JSONObject params = analysis.toParams(analysis.getTimezone());
orgManager.checkOrg(manager,params);
@@ -169,6 +186,7 @@ public class DashboardController {
}
@ManagerMapping(value = "/dashboard_base", method = RequestMethod.GET)
+ @ReadOnlyConnection
public JSONObject getDashBoardBaseConfig() {
JSONObject config = sysConfigManager.getSysConfig();
JSONObject limits = new JSONObject();
diff --git a/src/main/java/au/com/royalpay/payment/manage/analysis/web/EstimateAnalysisController.java b/src/main/java/au/com/royalpay/payment/manage/analysis/web/EstimateAnalysisController.java
index afa6c1e87..55b92b058 100644
--- a/src/main/java/au/com/royalpay/payment/manage/analysis/web/EstimateAnalysisController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/analysis/web/EstimateAnalysisController.java
@@ -2,6 +2,7 @@ package au.com.royalpay.payment.manage.analysis.web;
import au.com.royalpay.payment.manage.analysis.core.EstimateAnalysisService;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import com.alibaba.fastjson.JSONObject;
import org.springframework.web.bind.annotation.*;
@@ -19,6 +20,7 @@ public class EstimateAnalysisController {
private EstimateAnalysisService estimateAnalysisService;
@ManagerMapping(value = "/future",method = RequestMethod.GET)
+ @ReadOnlyConnection
public List getFutureSettleInfo() throws Exception {
return estimateAnalysisService.listFutureInfo();
}
@@ -29,17 +31,20 @@ public class EstimateAnalysisController {
}
@ManagerMapping(value = "/log/{date}", method = RequestMethod.GET)
+ @ReadOnlyConnection
public List getEstimateLogInfo(@PathVariable String date) throws Exception {
return estimateAnalysisService.listEstimateLog(1, date);
}
@ManagerMapping(value = "/transaction/log/{date}",method = RequestMethod.GET)
+ @ReadOnlyConnection
public List getTransactionLogInfo(@PathVariable String date) throws Exception {
return estimateAnalysisService.listEstimateLog(2,date);
}
@ManagerMapping(value = "/query", method = RequestMethod.GET)
+ @ReadOnlyConnection
public List queryEstimateLogInfo(@RequestParam String start_date, @RequestParam String end_date) throws Exception {
return estimateAnalysisService.listEstimateLogs(start_date,end_date);
}
diff --git a/src/main/java/au/com/royalpay/payment/manage/analysis/web/OrderSuccessRateController.java b/src/main/java/au/com/royalpay/payment/manage/analysis/web/OrderSuccessRateController.java
index 19989ae5f..5f0f9a578 100644
--- a/src/main/java/au/com/royalpay/payment/manage/analysis/web/OrderSuccessRateController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/analysis/web/OrderSuccessRateController.java
@@ -3,6 +3,7 @@ package au.com.royalpay.payment.manage.analysis.web;
import au.com.royalpay.payment.core.exceptions.ParamInvalidException;
import au.com.royalpay.payment.manage.analysis.core.OrderSuccessRateAnalysisService;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.tools.permission.enums.ManagerRole;
import com.alibaba.fastjson.JSONObject;
import org.apache.commons.lang3.time.DateUtils;
@@ -24,6 +25,7 @@ public class OrderSuccessRateController {
private OrderSuccessRateAnalysisService orderSuccessRateAnalysisService;
@RequestMapping("/chart_view")
+ @ReadOnlyConnection
public JSONObject analysisAllInTypes(@RequestParam String begin, @RequestParam String end) {
Date beginDate;
try {
@@ -41,6 +43,7 @@ public class OrderSuccessRateController {
}
@RequestMapping("/dates/{pattern}/detail")
+ @ReadOnlyConnection
public JSONObject getDetailOfDate(@PathVariable String pattern) {
Date dt = null;
try {
diff --git a/src/main/java/au/com/royalpay/payment/manage/analysis/web/OrgSaleAnalysisController.java b/src/main/java/au/com/royalpay/payment/manage/analysis/web/OrgSaleAnalysisController.java
index 17ef61598..a02c9f237 100644
--- a/src/main/java/au/com/royalpay/payment/manage/analysis/web/OrgSaleAnalysisController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/analysis/web/OrgSaleAnalysisController.java
@@ -3,6 +3,7 @@ package au.com.royalpay.payment.manage.analysis.web;
import au.com.royalpay.payment.manage.analysis.beans.AnalysisBean;
import au.com.royalpay.payment.manage.analysis.core.OrgAnalysisService;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.tools.permission.enums.ManagerRole;
import au.com.royalpay.payment.tools.CommonConsts;
import com.alibaba.fastjson.JSONObject;
@@ -21,12 +22,14 @@ public class OrgSaleAnalysisController {
private OrgAnalysisService orgAnalysisService;
@ManagerMapping(value = "/sales",role = {ManagerRole.DIRECTOR,ManagerRole.OPERATOR,ManagerRole.ADMIN,ManagerRole.FINANCIAL_STAFF})
+ @ReadOnlyConnection
public List getSalesAnalysis(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(null);
return orgAnalysisService.getSalesAnalysis(params,manager);
}
@ManagerMapping(value = "/{org_id}/partners",role = {ManagerRole.DIRECTOR,ManagerRole.OPERATOR,ManagerRole.ADMIN,ManagerRole.FINANCIAL_STAFF})
+ @ReadOnlyConnection
public List getPartnersSales(@PathVariable String org_id, AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
analysis.setOrg_id(org_id);
JSONObject params = analysis.toParams(null);
diff --git a/src/main/java/au/com/royalpay/payment/manage/analysis/web/PartnerCardDashboardController.java b/src/main/java/au/com/royalpay/payment/manage/analysis/web/PartnerCardDashboardController.java
index 74f41b6e5..8bd73549f 100644
--- a/src/main/java/au/com/royalpay/payment/manage/analysis/web/PartnerCardDashboardController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/analysis/web/PartnerCardDashboardController.java
@@ -4,6 +4,7 @@ import au.com.royalpay.payment.manage.analysis.core.PartnerCardDashboardService;
import au.com.royalpay.payment.manage.logview.beans.ClientLoginLogQueryBean;
import au.com.royalpay.payment.manage.management.clearing.core.CleanService;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.tools.permission.enums.ManagerRole;
import au.com.royalpay.payment.manage.signin.core.ClientLoginLogRepository;
import au.com.royalpay.payment.manage.tradelog.beans.TradeLogQuery;
@@ -34,52 +35,62 @@ public class PartnerCardDashboardController {
private CleanService cleanService;
@RequestMapping("{client_moniker}/basic_info")
+ @ReadOnlyConnection
public JSONObject commonAnalysis(@PathVariable String client_moniker, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
return partnerCardDashboardService.getCommonAnalysis(client_moniker);
}
@RequestMapping("{client_moniker}/trans_common")
+ @ReadOnlyConnection
public JSONObject getTransactionAnalysis(@PathVariable String client_moniker, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
return partnerCardDashboardService.getTransactionAnalysis(client_moniker);
}
@RequestMapping("{client_moniker}/order_customer_chart")
+ @ReadOnlyConnection
public List getOrderCustomerChartAnalysis(@PathVariable String client_moniker, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
return partnerCardDashboardService.getOrderCustomerChartAnalysis(client_moniker);
}
@RequestMapping("{client_moniker}/trans_type_analysis")
+ @ReadOnlyConnection
public List getTransTypesAnalysis(@PathVariable String client_moniker, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
return partnerCardDashboardService.getTransTypesAnalysis(client_moniker);
}
@RequestMapping("{client_moniker}/avg_order_customer")
+ @ReadOnlyConnection
public JSONObject getAvgOrderAndCustomer(@PathVariable String client_moniker, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
return partnerCardDashboardService.getOrderAndCustomerPerDay(client_moniker);
}
@RequestMapping("{client_moniker}/trade_in_hours")
+ @ReadOnlyConnection
public List getTradeAnalysisInHours(@PathVariable String client_moniker, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
return partnerCardDashboardService.getTradeAnalysisInHours(client_moniker);
}
@RequestMapping("{client_moniker}/settlement_logs")
+ @ReadOnlyConnection
public JSONObject getPartnerSettlementLog(@PathVariable String client_moniker, TradeLogQuery query, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
return partnerCardDashboardService.getSettlementLog(client_moniker, query);
}
@RequestMapping("{client_moniker}/login_logs")
+ @ReadOnlyConnection
public JSONObject getPartnerLoginLog(@PathVariable String client_moniker, ClientLoginLogQueryBean query, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
return clientLoginLogRepository.listClientLoginLogs(client_moniker, query.getPage(), query.getLimit());
}
@RequestMapping("/{client_id}/settlement_logs/{detailId}")
+ @ReadOnlyConnection
public JSONObject listClearingTransactions(@PathVariable int client_id, @PathVariable int detailId,@ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
return cleanService.getCleanLogTransactions(detailId, manager);
}
@RequestMapping("/settlement_logs/{detailId}/analysis/{channel}")
+ @ReadOnlyConnection
public Map getDayAndChannelOfAnalysisMap(@PathVariable int detailId,
@PathVariable String channel, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
return cleanService.getDayAndChannelOfAnalysisMap(detailId,channel, manager);
diff --git a/src/main/java/au/com/royalpay/payment/manage/analysis/web/PartnerDashboardController.java b/src/main/java/au/com/royalpay/payment/manage/analysis/web/PartnerDashboardController.java
index 75e8f2337..58645d1a3 100644
--- a/src/main/java/au/com/royalpay/payment/manage/analysis/web/PartnerDashboardController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/analysis/web/PartnerDashboardController.java
@@ -6,6 +6,7 @@ import au.com.royalpay.payment.manage.analysis.core.PartnerCardDashboardService;
import au.com.royalpay.payment.manage.logview.beans.ClientLoginLogQueryBean;
import au.com.royalpay.payment.manage.management.clearing.core.CleanService;
import au.com.royalpay.payment.manage.permission.manager.PartnerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.manage.signin.core.ClientLoginLogRepository;
import au.com.royalpay.payment.manage.tradelog.beans.TradeLogQuery;
import au.com.royalpay.payment.tools.CommonConsts;
@@ -31,25 +32,30 @@ public class PartnerDashboardController {
private CleanService cleanService;
@PartnerMapping("/common_analysis")
+ @ReadOnlyConnection
public JSONObject commonAnalysis(@ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject partner, AnalysisBean partnerAnalysisBean) {
return dashboardService.getCommonAnalysis(partner,partnerAnalysisBean);
}
@PartnerMapping("/trade_in_hours")
+ @ReadOnlyConnection
public List tradeInHours(@ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject partner,AnalysisBean partnerAnalysisBean) {
return dashboardService.getTradeAnalysisInHours(partner,partnerAnalysisBean);
}
@PartnerMapping("/fee_analysis")
+ @ReadOnlyConnection
public List tradeInDays(@ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject partner,AnalysisBean partnerAnalysisBean) {
return dashboardService.getStatisticsCustomersAndOrdersInDays(partner,partnerAnalysisBean);
}
@PartnerMapping("/customers")
+ @ReadOnlyConnection
public List customersInDays(@ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject partner,AnalysisBean partnerAnalysisBean) {
return dashboardService.getCustomersAndOrdersInDays(partner,partnerAnalysisBean);
}
@PartnerMapping("/trans_type_analysis")
+ @ReadOnlyConnection
public List getTransTypesAnalysis(@ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject partner,AnalysisBean partnerAnalysisBean) {
JSONObject params = partnerAnalysisBean.toParams("timezone");
params.put("client_id",partner.getString("client_id"));
@@ -57,6 +63,7 @@ public class PartnerDashboardController {
}
@PartnerMapping("/avg_order_customer")
+ @ReadOnlyConnection
public JSONObject getAvgOrderAndCustomer(@ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject partner,AnalysisBean partnerAnalysisBean) {
return dashboardService.getOrderAndCustomerPerDay(partner,partnerAnalysisBean);
}
diff --git a/src/main/java/au/com/royalpay/payment/manage/analysis/web/PartnersAnalysisController.java b/src/main/java/au/com/royalpay/payment/manage/analysis/web/PartnersAnalysisController.java
index 74608a157..7b25695b1 100644
--- a/src/main/java/au/com/royalpay/payment/manage/analysis/web/PartnersAnalysisController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/analysis/web/PartnersAnalysisController.java
@@ -3,6 +3,7 @@ package au.com.royalpay.payment.manage.analysis.web;
import au.com.royalpay.payment.manage.analysis.beans.AnalysisBean;
import au.com.royalpay.payment.manage.analysis.core.PartnersAnalysisService;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.tools.permission.enums.ManagerRole;
import au.com.royalpay.payment.tools.CommonConsts;
import com.alibaba.fastjson.JSONObject;
@@ -24,6 +25,7 @@ public class PartnersAnalysisController {
private PartnersAnalysisService partnersAnalysisService;
@ManagerMapping("/new")
+ @ReadOnlyConnection
public List getNewPartnersAnalysis(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(null);
if (manager.getInteger("org_id") != null) {
@@ -39,6 +41,7 @@ public class PartnersAnalysisController {
}
@ManagerMapping("/trade")
+ @ReadOnlyConnection
public List getTradePartnersAnalysis(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(null);
if (manager.getInteger("org_id") != null) {
@@ -53,6 +56,7 @@ public class PartnersAnalysisController {
return partnersAnalysisService.getTradePartnersAnalysis(params);
}
@ManagerMapping("/types")
+ @ReadOnlyConnection
public List getPartnersTypesAnalysis(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(null);
if (manager.getInteger("org_id") != null) {
@@ -68,6 +72,7 @@ public class PartnersAnalysisController {
}
@ManagerMapping("/settlement")
+ @ReadOnlyConnection
public List getPartnersSettlementAnalysis(AnalysisBean analysis, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
JSONObject params = analysis.toParams(null);
if (manager.getInteger("org_id") != null) {
diff --git a/src/main/java/au/com/royalpay/payment/manage/analysis/web/PlatformClearAController.java b/src/main/java/au/com/royalpay/payment/manage/analysis/web/PlatformClearAController.java
index 669478b5d..7310285a3 100644
--- a/src/main/java/au/com/royalpay/payment/manage/analysis/web/PlatformClearAController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/analysis/web/PlatformClearAController.java
@@ -2,6 +2,7 @@ package au.com.royalpay.payment.manage.analysis.web;
import au.com.royalpay.payment.manage.analysis.core.PlatformClearService;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.tools.permission.enums.ManagerRole;
import com.alibaba.fastjson.JSONObject;
@@ -25,21 +26,25 @@ public class PlatformClearAController {
private PlatformClearService platformClearService;
@ManagerMapping(value = "/settle/log", method = RequestMethod.GET, role = {ManagerRole.ADMIN, ManagerRole.OPERATOR, ManagerRole.DEVELOPER})
+ @ReadOnlyConnection
public JSONObject getPlatformSettleLog(@RequestParam String channel, @RequestParam(defaultValue = "1") int page, @RequestParam(defaultValue = "20") int limit) {
return platformClearService.getPlatformSettleLog(channel, page, limit);
}
@ManagerMapping(value = "/settle/{channel}",method = RequestMethod.GET, role = {ManagerRole.ADMIN, ManagerRole.OPERATOR, ManagerRole.DEVELOPER})
+ @ReadOnlyConnection
public JSONObject getChannelSettleLog(@PathVariable String channel) {
return platformClearService.getChannelSettleLog(channel);
}
@ManagerMapping(value = "/settle/verify",method = RequestMethod.GET,role = {ManagerRole.ADMIN, ManagerRole.OPERATOR, ManagerRole.DEVELOPER})
+ @ReadOnlyConnection
public void verifySettleLogByDate(@RequestParam("start_date") String start_date, @RequestParam("end_date") String end_date, @RequestParam("channel") String channel) throws ParseException {
platformClearService.verifySettleLogByDate(start_date,end_date,channel);
}
@ManagerMapping(value = "/generate/settle/log", method = RequestMethod.GET, role = {ManagerRole.ADMIN, ManagerRole.OPERATOR, ManagerRole.DEVELOPER})
+ @ReadOnlyConnection
public void generateSettleLogs() {
platformClearService.generateSettleLogs();
}
diff --git a/src/main/java/au/com/royalpay/payment/manage/analysis/web/PlatformRevenueController.java b/src/main/java/au/com/royalpay/payment/manage/analysis/web/PlatformRevenueController.java
index 6383e0500..c26d6e1e9 100644
--- a/src/main/java/au/com/royalpay/payment/manage/analysis/web/PlatformRevenueController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/analysis/web/PlatformRevenueController.java
@@ -3,6 +3,7 @@ package au.com.royalpay.payment.manage.analysis.web;
import au.com.royalpay.payment.core.exceptions.ParamInvalidException;
import au.com.royalpay.payment.manage.analysis.core.PlatformRevenueService;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import com.alibaba.fastjson.JSONObject;
import org.apache.commons.lang3.time.DateUtils;
import org.joda.time.DateTime;
@@ -29,6 +30,7 @@ public class PlatformRevenueController {
PlatformRevenueService platformRevenueService;
@RequestMapping(value = "/revenue/month_reports/{month}", method = RequestMethod.GET)
+ @ReadOnlyConnection
public JSONObject getMonthPlatformRevenueReport(@PathVariable String month) {
try {
Date dt = DateUtils.parseDate(month, new String[]{"yyyy-MM"});
@@ -42,6 +44,7 @@ public class PlatformRevenueController {
}
@RequestMapping(value = "/revenue/year_reports/{year}", method = RequestMethod.GET)
+ @ReadOnlyConnection
public List getYearPlatformRevenueReport(@PathVariable int year) {
List platformRevenueYearReport = new ArrayList();
int MonthIndex = 13;
diff --git a/src/main/java/au/com/royalpay/payment/manage/analysis/web/WeekReportController.java b/src/main/java/au/com/royalpay/payment/manage/analysis/web/WeekReportController.java
index f3017eee8..79e6bd2f5 100644
--- a/src/main/java/au/com/royalpay/payment/manage/analysis/web/WeekReportController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/analysis/web/WeekReportController.java
@@ -2,6 +2,7 @@ package au.com.royalpay.payment.manage.analysis.web;
import au.com.royalpay.payment.manage.analysis.core.WeekReporter;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.tools.permission.enums.ManagerRole;
import au.com.royalpay.payment.tools.CommonConsts;
import au.com.royalpay.payment.tools.permission.wechat.WechatMapping;
@@ -21,6 +22,7 @@ public class WeekReportController {
private WeekReporter weekReporter;
@WechatMapping(value = "/{reportId}", method = RequestMethod.GET)
+ @ReadOnlyConnection
public ModelAndView reportView(@PathVariable String reportId, @ModelAttribute(CommonConsts.WECHATINFO) JSONObject wxUser) {
ModelAndView mav = new ModelAndView("reports/week_report");
JSONObject report = weekReporter.getReport(reportId, wxUser.getString("openid"));
@@ -29,6 +31,7 @@ public class WeekReportController {
}
@WechatMapping(value = "/partners/{reportId}", method = RequestMethod.GET)
+ @ReadOnlyConnection
public ModelAndView reportPartnersView(@PathVariable String reportId, @ModelAttribute(CommonConsts.WECHATINFO) JSONObject wxUser) {
ModelAndView mav = new ModelAndView("reports/week_report_partners");
JSONObject report = weekReporter.getReport(reportId, wxUser.getString("openid"));
diff --git a/src/main/java/au/com/royalpay/payment/manage/cashback/web/ManageCashbackController.java b/src/main/java/au/com/royalpay/payment/manage/cashback/web/ManageCashbackController.java
index 6c3acaece..bc1b0cb90 100644
--- a/src/main/java/au/com/royalpay/payment/manage/cashback/web/ManageCashbackController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/cashback/web/ManageCashbackController.java
@@ -3,6 +3,7 @@ package au.com.royalpay.payment.manage.cashback.web;
import au.com.royalpay.payment.manage.cashback.bean.CashbackQuery;
import au.com.royalpay.payment.manage.cashback.core.CashbackService;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.tools.permission.enums.ManagerRole;
import com.alibaba.fastjson.JSONObject;
@@ -25,16 +26,19 @@ public class ManageCashbackController {
private CashbackService cashbackService;
@RequestMapping(value = "/daily",method = RequestMethod.GET)
+ @ReadOnlyConnection
public List getCashbackDaily(CashbackQuery query){
return cashbackService.getCashbackDaily(query);
}
@RequestMapping(value = "/partners",method = RequestMethod.GET)
+ @ReadOnlyConnection
public JSONObject getCashbackPartners(CashbackQuery query){
return cashbackService.getPartnerCashback(query);
}
@RequestMapping(value = "/analysis",method = RequestMethod.GET)
+ @ReadOnlyConnection
public JSONObject getCashbackAnalysis(){
return cashbackService.getCashbackAnalysis();
}
diff --git a/src/main/java/au/com/royalpay/payment/manage/dataAnalysis/web/DataAnalysisController.java b/src/main/java/au/com/royalpay/payment/manage/dataAnalysis/web/DataAnalysisController.java
index a5fb11304..92a07c834 100644
--- a/src/main/java/au/com/royalpay/payment/manage/dataAnalysis/web/DataAnalysisController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/dataAnalysis/web/DataAnalysisController.java
@@ -2,6 +2,7 @@ package au.com.royalpay.payment.manage.dataAnalysis.web;
import au.com.royalpay.payment.manage.dataAnalysis.core.DataAnalysisService;
import au.com.royalpay.payment.manage.dataAnalysis.util.MyUtil;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import com.alibaba.fastjson.JSONObject;
import org.apache.commons.lang3.time.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
@@ -26,6 +27,7 @@ public class DataAnalysisController {
private DataAnalysisService dataAnalysisService;
@RequestMapping(value = "/data_analysis")
+ @ReadOnlyConnection
public JSONObject dataAnalysis(@RequestParam(value = "begin", required = false) String begin,
@RequestParam(value = "offset", defaultValue = "1") Integer offset) throws ParseException {
diff --git a/src/main/java/au/com/royalpay/payment/manage/merchants/web/PartnerManageController.java b/src/main/java/au/com/royalpay/payment/manage/merchants/web/PartnerManageController.java
index 1fb19d5d2..b32ff4b9b 100644
--- a/src/main/java/au/com/royalpay/payment/manage/merchants/web/PartnerManageController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/merchants/web/PartnerManageController.java
@@ -5,6 +5,7 @@ import au.com.royalpay.payment.manage.merchants.beans.*;
import au.com.royalpay.payment.manage.merchants.core.ClientManager;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
import au.com.royalpay.payment.manage.permission.manager.RequireManager;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.manage.tradelog.beans.TradeLogQuery;
import au.com.royalpay.payment.manage.tradelog.core.TradeLogService;
import au.com.royalpay.payment.tools.CommonConsts;
@@ -430,16 +431,19 @@ public class PartnerManageController {
}
@ManagerMapping(value = "/{clientMoniker}/account/transactions", method = RequestMethod.GET, role = {ManagerRole.ADMIN, ManagerRole.OPERATOR})
+ @ReadOnlyConnection
public List accountTransactions(@ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager, @PathVariable String clientMoniker) {
return clientManager.getAccountTransactions(manager, clientMoniker);
}
@ManagerMapping(value = "/{clientMoniker}/account/transactions/date", method = RequestMethod.GET, role = {ManagerRole.ADMIN, ManagerRole.OPERATOR})
+ @ReadOnlyConnection
public List accountTransactionsByDate(@ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager, @PathVariable String clientMoniker, @RequestParam String detailId) {
return clientManager.getAccountTransactionsByDetailId(manager, clientMoniker, detailId);
}
@ManagerMapping(value = "/{clientMoniker}/account/save", method = RequestMethod.POST, role = {ManagerRole.ADMIN, ManagerRole.OPERATOR})
+ @ReadOnlyConnection
public void saveAccountTransaction(@ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager, @PathVariable String clientMoniker, @RequestBody JSONObject transaction) {
clientManager.saveAccountTransaction(manager, clientMoniker, transaction);
}
@@ -592,6 +596,7 @@ public class PartnerManageController {
}
@ManagerMapping(value = "/{clientMoniker}/lists_settlements", method = RequestMethod.GET, role = {ManagerRole.ADMIN, ManagerRole.BD_USER, ManagerRole.OPERATOR})
+ @ReadOnlyConnection
public JSONObject getSettlements(@PathVariable String clientMoniker, TradeLogQuery query, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
return clientManager.getSettlementLog(manager, clientMoniker, query);
}
diff --git a/src/main/java/au/com/royalpay/payment/manage/merchants/web/PartnerViewController.java b/src/main/java/au/com/royalpay/payment/manage/merchants/web/PartnerViewController.java
index 58d389800..b43d8d5d1 100644
--- a/src/main/java/au/com/royalpay/payment/manage/merchants/web/PartnerViewController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/merchants/web/PartnerViewController.java
@@ -9,6 +9,7 @@ import au.com.royalpay.payment.manage.merchants.core.ClientManager;
import au.com.royalpay.payment.manage.merchants.core.ClientSignEventSupport;
import au.com.royalpay.payment.manage.permission.manager.PartnerMapping;
import au.com.royalpay.payment.manage.permission.manager.RequirePartner;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.manage.support.wechatclients.KangaLandWechatApiImpl;
import au.com.royalpay.payment.manage.support.wechatclients.RedpackWechatApiImpl;
import au.com.royalpay.payment.manage.system.core.ClientContractService;
@@ -178,12 +179,14 @@ public class PartnerViewController {
}
@PartnerMapping(value = "/{clientMoniker}/account/transactions", method = RequestMethod.GET, roles = {PartnerRole.ADMIN, PartnerRole.MANAGER})
+ @ReadOnlyConnection
@ResponseBody
public List accountTransactions(@ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject manager, @PathVariable String clientMoniker) {
return clientManager.getAccountTransactions(manager, clientMoniker);
}
@PartnerMapping(value = "/{clientMoniker}/account/transactions/date", method = RequestMethod.GET, roles = {PartnerRole.ADMIN, PartnerRole.MANAGER})
+ @ReadOnlyConnection
@ResponseBody
public List accountTransactionsByDate(@ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject manager, @PathVariable String clientMoniker,@RequestParam String date) {
return clientManager.getAccountTransactionsByDetailId(manager, clientMoniker, date);
diff --git a/src/main/java/au/com/royalpay/payment/manage/settlement/web/ClientManualSettleController.java b/src/main/java/au/com/royalpay/payment/manage/settlement/web/ClientManualSettleController.java
index c2e984976..3a4ada1ea 100644
--- a/src/main/java/au/com/royalpay/payment/manage/settlement/web/ClientManualSettleController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/settlement/web/ClientManualSettleController.java
@@ -2,6 +2,7 @@ package au.com.royalpay.payment.manage.settlement.web;
import au.com.royalpay.payment.core.exceptions.ParamInvalidException;
import au.com.royalpay.payment.manage.permission.manager.PartnerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.manage.settlement.core.ManualSettleSupport;
import au.com.royalpay.payment.tools.CommonConsts;
import au.com.royalpay.payment.tools.permission.enums.PartnerRole;
@@ -23,6 +24,7 @@ public class ClientManualSettleController {
private ManualSettleSupport manualSettleSupport;
@PartnerMapping(value = "/today", method = RequestMethod.GET, roles = {PartnerRole.ADMIN})
+ @ReadOnlyConnection
public JSONObject checkRequestInToday(@ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject account) {
return manualSettleSupport.findCurrentSettle(account.getIntValue("client_id"), true);
}
diff --git a/src/main/java/au/com/royalpay/payment/manage/system/web/contractController.java b/src/main/java/au/com/royalpay/payment/manage/system/web/contractController.java
index 61f5e931f..d6eeaf32b 100644
--- a/src/main/java/au/com/royalpay/payment/manage/system/web/contractController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/system/web/contractController.java
@@ -1,6 +1,7 @@
package au.com.royalpay.payment.manage.system.web;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.manage.settlement.core.ManualSettleSupport;
import au.com.royalpay.payment.manage.system.core.ClientContractService;
@@ -25,6 +26,7 @@ public class contractController {
private ManualSettleSupport manualSettleSupport;
@ManagerMapping(value = "/contract/list", method = RequestMethod.GET)
+ @ReadOnlyConnection
public JSONObject contractList(@RequestParam(value = "page", defaultValue = "1") int page, @RequestParam(value = "limit", defaultValue = "10") int limit,@RequestParam(required = false) String client_moniker) {
JSONObject params = new JSONObject();
params.put("client_moniker",client_moniker);
@@ -32,11 +34,13 @@ public class contractController {
}
@ManagerMapping(value = "/contract", method = RequestMethod.GET)
+ @ReadOnlyConnection
public JSONObject contractAnalysis() {
return clientContractService.analysis();
}
@ManagerMapping(value = "/manualSettle/list", method = RequestMethod.GET)
+ @ReadOnlyConnection
public List manualList() {
return manualSettleSupport.listWithClearInfo();
}
diff --git a/src/main/java/au/com/royalpay/payment/manage/tradelog/web/ManageTradelogController.java b/src/main/java/au/com/royalpay/payment/manage/tradelog/web/ManageTradelogController.java
index 69b5b6eed..68337775e 100644
--- a/src/main/java/au/com/royalpay/payment/manage/tradelog/web/ManageTradelogController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/tradelog/web/ManageTradelogController.java
@@ -2,6 +2,7 @@ package au.com.royalpay.payment.manage.tradelog.web;
import au.com.royalpay.payment.manage.merchants.core.ClientManager;
import au.com.royalpay.payment.manage.permission.manager.ManagerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.tools.permission.enums.ManagerRole;
import au.com.royalpay.payment.manage.permission.manager.RequireManager;
import au.com.royalpay.payment.manage.permission.manager.RequirePartner;
@@ -27,12 +28,14 @@ public class ManageTradelogController {
@Resource
private ClientManager clientManager;
@RequestMapping(method = RequestMethod.GET)
+ @ReadOnlyConnection
@RequireManager(role = {ManagerRole.ADMIN, ManagerRole.BD_USER, ManagerRole.OPERATOR, ManagerRole.FINANCIAL_STAFF, ManagerRole.SERVANT, ManagerRole.DIRECTOR})
public JSONObject listAllTradeLogs(TradeLogQuery query, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
return tradeLogService.listAllTradeLogs(query, manager);
}
@ManagerMapping(value = "/{tradeId}/refunds", method = RequestMethod.GET, role = {ManagerRole.ADMIN, ManagerRole.OPERATOR, ManagerRole.FINANCIAL_STAFF, ManagerRole.SERVANT, ManagerRole.DIRECTOR})
+ @ReadOnlyConnection
@RequirePartner
public List listTradeRefunds(@PathVariable String tradeId, @ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject partner,
@ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
@@ -40,16 +43,19 @@ public class ManageTradelogController {
}
@ManagerMapping(value = "/report/excel", method = RequestMethod.GET)
+ @ReadOnlyConnection
public void exportExcel(TradeLogQuery query, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager, HttpServletResponse httpResponse) throws Exception {
tradeLogService.exportTransLog(query,manager,httpResponse);
}
@ManagerMapping(value = "/trans_flow",method = RequestMethod.GET,role = {ManagerRole.FINANCIAL_STAFF})
+ @ReadOnlyConnection
public JSONObject listTransFlow(TradeLogQuery query,@RequestParam(required = true) String client_moniker) throws Exception {
return tradeLogService.listPartnerTransFlowPage(query,getPartnerParams(client_moniker));
}
@ManagerMapping(value = "/trans_flow/pdf", method = RequestMethod.GET,role = {ManagerRole.FINANCIAL_STAFF})
+ @ReadOnlyConnection
public void exportTransFlowPDF(TradeLogQuery query, @RequestParam(required = true) String client_moniker, HttpServletResponse httpResponse) throws Exception {
tradeLogService.exportTransFlow(query,getPartnerParams(client_moniker),httpResponse);
}
diff --git a/src/main/java/au/com/royalpay/payment/manage/tradelog/web/PayNoticeController.java b/src/main/java/au/com/royalpay/payment/manage/tradelog/web/PayNoticeController.java
index da6ddbb18..d5ec2225e 100644
--- a/src/main/java/au/com/royalpay/payment/manage/tradelog/web/PayNoticeController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/tradelog/web/PayNoticeController.java
@@ -1,5 +1,6 @@
package au.com.royalpay.payment.manage.tradelog.web;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.manage.tradelog.core.TradeLogService;
import au.com.royalpay.payment.tools.CommonConsts;
import au.com.royalpay.payment.tools.connections.mpsupport.beans.WxOauthType;
@@ -26,12 +27,14 @@ public class PayNoticeController {
private TradeLogService tradeLogService;
@WechatMapping(value = "/orders/{orderId}/notice", method = RequestMethod.GET, oauthType = WxOauthType.USERBASE)
+ @ReadOnlyConnection
public String noticeView(Model model, @PathVariable String clientMoniker, @PathVariable String orderId, @ModelAttribute(CommonConsts.WECHATINFO) JSONObject wechat) {
tradeLogService.getOrderDetail(model, clientMoniker, orderId, wechat.getString("openid"));
return "paynotice";
}
@WechatMapping(value = "/refunds/{refundId}/status", method = RequestMethod.GET, oauthType = WxOauthType.USERBASE)
+ @ReadOnlyConnection
public String refundStatus(Model model, @PathVariable String clientMoniker, @PathVariable String refundId, @ModelAttribute(CommonConsts.WECHATINFO) JSONObject wechat) {
tradeLogService.getRefundStatus(model, clientMoniker, refundId, wechat.getString("openid"));
return "refund_status";
diff --git a/src/main/java/au/com/royalpay/payment/manage/tradelog/web/RefundController.java b/src/main/java/au/com/royalpay/payment/manage/tradelog/web/RefundController.java
index a2985308b..72a4c6368 100644
--- a/src/main/java/au/com/royalpay/payment/manage/tradelog/web/RefundController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/tradelog/web/RefundController.java
@@ -5,6 +5,7 @@ import au.com.royalpay.payment.manage.mappers.payment.RefundReviewMapper;
import au.com.royalpay.payment.manage.permission.manager.PartnerMapping;
import au.com.royalpay.payment.manage.permission.manager.RequireManager;
import au.com.royalpay.payment.manage.permission.manager.RequirePartner;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.manage.tradelog.refund.RefundService;
import au.com.royalpay.payment.tools.CommonConsts;
import au.com.royalpay.payment.tools.exceptions.BadRequestException;
@@ -31,6 +32,7 @@ public class RefundController {
@RequestMapping(value = "/orders/{orderId}/refund_check", method = RequestMethod.GET)
+ @ReadOnlyConnection
@RequireManager(role = {ManagerRole.ADMIN, ManagerRole.OPERATOR, ManagerRole.FINANCIAL_STAFF, ManagerRole.SERVANT})
@RequirePartner
public JSONObject refundCheck(@PathVariable String orderId, @ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject account) {
@@ -44,24 +46,28 @@ public class RefundController {
}
@RequestMapping(value = "/orders/{orderId}/refund_orderInfo", method = RequestMethod.GET)
+ @ReadOnlyConnection
@RequireManager(role = {ManagerRole.ADMIN, ManagerRole.OPERATOR, ManagerRole.FINANCIAL_STAFF, ManagerRole.SERVANT})
public JSONObject refundOrderInfo(@PathVariable String orderId) {
return refundService.checkOrderRefundInfo(orderId);
}
@RequestMapping(value = "/orders/needReview", method = RequestMethod.GET)
+ @ReadOnlyConnection
@RequireManager(role = {ManagerRole.ADMIN, ManagerRole.OPERATOR, ManagerRole.FINANCIAL_STAFF, ManagerRole.SERVANT})
public JSONObject listNeedReviewRefundOrders(RefundReviewBean reviewBean) {
return refundService.listNeedReviewRefundOrders(reviewBean);
}
@RequestMapping(value = "/orders/notifyReview", method = RequestMethod.GET)
+ @ReadOnlyConnection
@RequireManager(role = {ManagerRole.ADMIN, ManagerRole.OPERATOR, ManagerRole.FINANCIAL_STAFF, ManagerRole.SERVANT})
public int notifyReviewRefundOrders() {
return refundService.notifyRefundReview();
}
@WechatMapping(value = "/auditions", method = RequestMethod.GET)
+ @ReadOnlyConnection
public ModelAndView auditionListPage(@ModelAttribute(CommonConsts.WECHATINFO) JSONObject user) {
ModelAndView view = new ModelAndView("refund_audit_list");
view.addAllObjects(refundService.auditionsFromOpenId(user.getString("openid")));
@@ -69,6 +75,7 @@ public class RefundController {
}
@WechatMapping(value = "/auditions/{auditionId}", method = RequestMethod.GET)
+ @ReadOnlyConnection
public ModelAndView auditionPage(@PathVariable String auditionId, @ModelAttribute(CommonConsts.WECHATINFO) JSONObject user) {
ModelAndView view = new ModelAndView("refund_audit");
view.addAllObjects(refundService.auditionInfo(auditionId, user.getString("openid")));
@@ -76,11 +83,13 @@ public class RefundController {
}
@RequestMapping(value = "/json/auditions", method = RequestMethod.GET)
+ @ReadOnlyConnection
public JSONObject auditionListPageJson(@ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject account) {
return refundService.auditionsFromAccount(account);
}
@RequestMapping(value = "/json/auditions/{auditionId}", method = RequestMethod.GET)
+ @ReadOnlyConnection
public JSONObject auditionPageJson(@PathVariable String auditionId, @ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject account) {
return refundService.auditionInfoByAccount(auditionId, account);
}
@@ -91,6 +100,7 @@ public class RefundController {
}
@RequestMapping(value = "/review/{reviewId}", method = RequestMethod.GET)
+ @ReadOnlyConnection
public ModelAndView reviewRefundPage(@PathVariable String reviewId, @ModelAttribute(CommonConsts.WECHATINFO) JSONObject user) {
ModelAndView view = new ModelAndView("refund_review");
view.addObject("review", refundService.findReviewOrder(reviewId));
@@ -98,6 +108,7 @@ public class RefundController {
}
@RequestMapping(value = "/review/check/{reviewId}", method = RequestMethod.GET)
+ @ReadOnlyConnection
public ModelAndView refundStatusCheck(@PathVariable String reviewId, @ModelAttribute(CommonConsts.WECHATINFO) JSONObject user) {
ModelAndView view = new ModelAndView("refund_review_client");
view.addObject("review", refundService.findReviewOrder(reviewId));
diff --git a/src/main/java/au/com/royalpay/payment/manage/tradelog/web/ReportConfigController.java b/src/main/java/au/com/royalpay/payment/manage/tradelog/web/ReportConfigController.java
index 0aedfb16a..a7f0732ea 100644
--- a/src/main/java/au/com/royalpay/payment/manage/tradelog/web/ReportConfigController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/tradelog/web/ReportConfigController.java
@@ -1,5 +1,6 @@
package au.com.royalpay.payment.manage.tradelog.web;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.tools.permission.enums.ManagerRole;
import au.com.royalpay.payment.manage.permission.manager.RequireManager;
import au.com.royalpay.payment.manage.tradelog.core.ReportConfigService;
@@ -19,12 +20,14 @@ public class ReportConfigController {
private ReportConfigService reportConfigService;
@RequestMapping(method = RequestMethod.GET)
+ @ReadOnlyConnection
@RequireManager(role = {ManagerRole.ADMIN, ManagerRole.OPERATOR,ManagerRole.FINANCIAL_STAFF})
public JSONObject listReprtConfg(@ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
return reportConfigService.getReportConfig();
}
@RequestMapping(value = "/{pkid}",method = RequestMethod.GET)
+ @ReadOnlyConnection
@RequireManager(role = {ManagerRole.ADMIN, ManagerRole.OPERATOR,ManagerRole.FINANCIAL_STAFF})
public JSONObject getReportConfigDetail(@PathVariable int pkid, @ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
return reportConfigService.findOne(pkid);
diff --git a/src/main/java/au/com/royalpay/payment/manage/tradelog/web/TradeFlowController.java b/src/main/java/au/com/royalpay/payment/manage/tradelog/web/TradeFlowController.java
index fcaa29b04..ea0d8da24 100644
--- a/src/main/java/au/com/royalpay/payment/manage/tradelog/web/TradeFlowController.java
+++ b/src/main/java/au/com/royalpay/payment/manage/tradelog/web/TradeFlowController.java
@@ -1,6 +1,7 @@
package au.com.royalpay.payment.manage.tradelog.web;
import au.com.royalpay.payment.manage.permission.manager.PartnerMapping;
+import au.com.royalpay.payment.manage.pos.datasource.ReadOnlyConnection;
import au.com.royalpay.payment.manage.tradelog.beans.TradeLogQuery;
import au.com.royalpay.payment.manage.tradelog.core.TradeLogService;
import au.com.royalpay.payment.tools.CommonConsts;
@@ -25,6 +26,7 @@ public class TradeFlowController {
private TradeLogService tradeLogService;
@PartnerMapping(value = "", method = RequestMethod.GET)
+ @ReadOnlyConnection
@ResponseBody
public JSONObject listTransFlow(TradeLogQuery query, @ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject partner) throws Exception {
return tradeLogService.listPartnerTransFlowPage(query, partner);
@@ -32,26 +34,31 @@ public class TradeFlowController {
@PartnerMapping(value = "/report/pdf", method = RequestMethod.GET)
+ @ReadOnlyConnection
public void exportPDF(TradeLogQuery query, @ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject partner, HttpServletResponse httpResponse) throws Exception {
tradeLogService.exportTransFlow(query,partner,httpResponse);
}
@PartnerMapping(value = "/report/excel", method = RequestMethod.GET)
+ @ReadOnlyConnection
public void exportExcel(TradeLogQuery query, @ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject partner, HttpServletResponse httpResponse) throws Exception {
tradeLogService.exportExcelNew(query,partner,httpResponse);
}
@PartnerMapping(value = "/report/excel_detail", method = RequestMethod.GET)
+ @ReadOnlyConnection
public void exportExcelDetail(TradeLogQuery query, @ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject partner, HttpServletResponse httpResponse) throws Exception {
tradeLogService.exportExcel(query,partner,httpResponse);
}
@PartnerMapping(value = "/settlement/log",method = RequestMethod.GET)
+ @ReadOnlyConnection
@ResponseBody
public JSONObject listSettlementLog(TradeLogQuery query,@ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject partner){
return tradeLogService.listSettlementLog(query,partner);
}
@PartnerMapping(value = "/settlement/unclear",method = RequestMethod.GET)
+ @ReadOnlyConnection
@ResponseBody
public String getClientUnClearedAmount(@ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject partner){
// JSONObject res = new JSONObject();
@@ -60,18 +67,21 @@ public class TradeFlowController {
}
@PartnerMapping(value = "/settlement/log/excel",method = RequestMethod.GET)
+ @ReadOnlyConnection
@ResponseBody
public void exportSettlementLog(TradeLogQuery query, @ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject partner, HttpServletResponse response) {
tradeLogService.exportSettlementLog(query, partner, response);
}
@PartnerMapping(value = "/settlement/log/pdf",method = RequestMethod.GET)
+ @ReadOnlyConnection
@ResponseBody
public void exportLogPDF(TradeLogQuery query, @ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject partner, HttpServletResponse response) {
tradeLogService.exportPDFSettlement(query, partner, response);
}
@PartnerMapping(value = "/report/excel_detail_all", method = RequestMethod.GET)
+ @ReadOnlyConnection
public void exportExcelDetailAllPartner(TradeLogQuery query, @ModelAttribute(CommonConsts.PARTNER_STATUS) JSONObject partner, HttpServletResponse httpResponse) throws Exception {
tradeLogService.exportExcelAllPartner(query,partner,httpResponse);
}
diff --git a/src/main/resources/logback_cfg.xml b/src/main/resources/logback_cfg.xml
index 086174451..62b90eee2 100644
--- a/src/main/resources/logback_cfg.xml
+++ b/src/main/resources/logback_cfg.xml
@@ -2,8 +2,8 @@
-
-
+
+