fix 制作合同返还数据

master
luoyang 5 years ago
parent 8cd237cd44
commit 7e9b36605c

@ -85,6 +85,7 @@ public class ClientComplianceApplyImpl implements ClientComplianceApply
} }
complianceDetail.put("operator_id", manager.getString("manager_id")); complianceDetail.put("operator_id", manager.getString("manager_id"));
complianceDetail.put("status",1); complianceDetail.put("status",1);
complianceDetail.put("description",' ');
clientComplianceCompanyMapper.update(complianceDetail); clientComplianceCompanyMapper.update(complianceDetail);
clientFilesMapper.passCompliance(clientId); clientFilesMapper.passCompliance(clientId);
} }

@ -2005,47 +2005,46 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
if (client == null) { if (client == null) {
throw new InvalidShortIdException(); throw new InvalidShortIdException();
} }
JSONObject result = new JSONObject();
String address = client.getString("address").trim(); String address = client.getString("address").trim();
if (address.contains(",")) { if (address.contains(",")) {
result.put("address", address.substring(0, address.lastIndexOf(",")).trim()); client.put("address", address.substring(0, address.lastIndexOf(",")).trim());
result.put("address_sub", address.substring(address.lastIndexOf(",") + 1).trim()); client.put("address_sub", address.substring(address.lastIndexOf(",") + 1).trim());
} }
if (client.getString("acn") != null && !client.getString("acn").equals("")) { if (client.getString("acn") != null && !client.getString("acn").equals("")) {
result.put("acn_type", "ACN: (" + client.getString("acn") + ")"); client.put("acn_type", "ACN: (" + client.getString("acn") + ")");
result.put("company_name_acn", client.getString("company_name") + " (ACN " + client.getString("acn") + ")"); client.put("company_name_acn", client.getString("company_name") + " (ACN " + client.getString("acn") + ")");
} else { } else {
result.put("acn_type", "ABN: (" + client.getString("abn") + ")"); client.put("acn_type", "ABN: (" + client.getString("abn") + ")");
result.put("company_name_acn", client.getString("company_name") + " (ABN " + client.getString("abn") + ")"); client.put("company_name_acn", client.getString("company_name") + " (ABN " + client.getString("abn") + ")");
} }
JSONObject weChatRate = merchantInfoProvider.clientCurrentRate(client.getIntValue("client_id"), new Date(), "Wechat"); JSONObject weChatRate = merchantInfoProvider.clientCurrentRate(client.getIntValue("client_id"), new Date(), "Wechat");
if (weChatRate == null) { if (weChatRate == null) {
throw new BadRequestException("The Partner's Rate is not config!"); throw new BadRequestException("The Partner's Rate is not config!");
} }
result.put("wechat_rate", weChatRate.getBigDecimal("rate_value").setScale(2, BigDecimal.ROUND_DOWN)); client.put("wechat_rate", weChatRate.getBigDecimal("rate_value").setScale(2, BigDecimal.ROUND_DOWN));
result.put("clean", "T+" + weChatRate.getString("clean_days")); client.put("clean", "T+" + weChatRate.getString("clean_days"));
result.put("clean_days", weChatRate.getString("clean_days")); client.put("clean_days", weChatRate.getString("clean_days"));
try { try {
JSONObject alipayRate = merchantInfoProvider.clientCurrentRate(client.getIntValue("client_id"), new Date(), "Alipay"); JSONObject alipayRate = merchantInfoProvider.clientCurrentRate(client.getIntValue("client_id"), new Date(), "Alipay");
if (alipayRate != null) { if (alipayRate != null) {
result.put("alipay_rate", alipayRate.getBigDecimal("rate_value").setScale(2, BigDecimal.ROUND_DOWN)); client.put("alipay_rate", alipayRate.getBigDecimal("rate_value").setScale(2, BigDecimal.ROUND_DOWN));
} }
JSONObject bestPayRate = merchantInfoProvider.clientCurrentRate(client.getIntValue("client_id"), new Date(), "Bestpay"); JSONObject bestPayRate = merchantInfoProvider.clientCurrentRate(client.getIntValue("client_id"), new Date(), "Bestpay");
if (bestPayRate != null) { if (bestPayRate != null) {
result.put("bestpay_rate", bestPayRate.getBigDecimal("rate_value").setScale(2, BigDecimal.ROUND_DOWN)); client.put("bestpay_rate", bestPayRate.getBigDecimal("rate_value").setScale(2, BigDecimal.ROUND_DOWN));
} }
JSONObject jdRate = merchantInfoProvider.clientCurrentRate(client.getIntValue("client_id"), new Date(), "jd"); JSONObject jdRate = merchantInfoProvider.clientCurrentRate(client.getIntValue("client_id"), new Date(), "jd");
if (jdRate != null) { if (jdRate != null) {
result.put("jd_rate", jdRate.getBigDecimal("rate_value").setScale(2, BigDecimal.ROUND_DOWN)); client.put("jd_rate", jdRate.getBigDecimal("rate_value").setScale(2, BigDecimal.ROUND_DOWN));
} }
JSONObject alipayOnlineRate = merchantInfoProvider.clientCurrentRate(client.getIntValue("client_id"), new Date(), "AlipayOnline"); JSONObject alipayOnlineRate = merchantInfoProvider.clientCurrentRate(client.getIntValue("client_id"), new Date(), "AlipayOnline");
if (alipayOnlineRate != null) { if (alipayOnlineRate != null) {
result.put("alipay_online_rate", alipayOnlineRate.getBigDecimal("rate_value").setScale(2, BigDecimal.ROUND_DOWN)); client.put("alipay_online_rate", alipayOnlineRate.getBigDecimal("rate_value").setScale(2, BigDecimal.ROUND_DOWN));
} }
JSONObject cbBankPayRate = merchantInfoProvider.clientCurrentRate(client.getIntValue("client_id"), new Date(), "CB_BankPay"); JSONObject cbBankPayRate = merchantInfoProvider.clientCurrentRate(client.getIntValue("client_id"), new Date(), "CB_BankPay");
@ -2069,7 +2068,7 @@ public class ClientManagerImpl implements ClientManager, ManagerTodoNoticeProvid
Date endDate = TimeZoneUtils.nextYearByCurrDay(); Date endDate = TimeZoneUtils.nextYearByCurrDay();
String end_date = DateFormatUtils.format(endDate, "dd/MM/yyyy"); String end_date = DateFormatUtils.format(endDate, "dd/MM/yyyy");
result.put("end_date", end_date); result.put("end_date", end_date);
return result; return client;
} }
@Override @Override

@ -3808,7 +3808,7 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
title: 'Warning', title: 'Warning',
content: 'This operation will delete the file, Are you sure?' content: 'This operation will delete the file, Are you sure?'
}).then(function () { }).then(function () {
$http.put('/sys/partners/auth_file/' + $scope.file_id + '/delete').then(function (resp) { $http.put('/sys/partners/auth_file/' + file_id + '/delete').then(function (resp) {
commonDialog.alert({ commonDialog.alert({
title: 'Success', title: 'Success',
content: 'Delete Successful', content: 'Delete Successful',

@ -56,7 +56,7 @@ define(['angular', 'static/commons/commons', 'uiBootstrap', 'uiRouter', 'ngBootS
$scope.passPartnerComplianceFiles = function () { $scope.passPartnerComplianceFiles = function () {
$http.put('/compliance/audit/'+$scope.file.client.client_id+'/pass/complianceFile',{}).then(function (resp) { $http.put('/compliance/audit/'+$scope.file.client.client_id+'/pass/complianceFile',{}).then(function (resp) {
$scope.reload(); $state.reload();
}, function (resp) { }, function (resp) {
commonDialog.alert({title: 'Error', content: resp.data.message, type: 'error'}); commonDialog.alert({title: 'Error', content: resp.data.message, type: 'error'});
}) })

Loading…
Cancel
Save