add 风控确认收到风控材料按钮

master
luoyang 5 years ago
parent 603ce4bfde
commit af7885d671

@ -10,7 +10,7 @@
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<artifactId>manage</artifactId> <artifactId>manage</artifactId>
<version>1.1.12</version> <version>1.1.13</version>
<properties> <properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>

@ -135,6 +135,8 @@ public interface RiskBusinessService {
void banRiskEvent(String riskId); void banRiskEvent(String riskId);
void commitWaitRiskStatus(String riskId, String codeKey, JSONObject manager);
JSONObject riskEventMaterialPass(JSONObject params, JSONObject manager); JSONObject riskEventMaterialPass(JSONObject params, JSONObject manager);
JSONObject updateIsSendClient(String riskId); JSONObject updateIsSendClient(String riskId);

@ -18,6 +18,7 @@ import au.com.royalpay.payment.manage.pushMessage.bean.AppManagerMessageBuilder;
import au.com.royalpay.payment.manage.riskbusiness.core.RiskBusinessService; import au.com.royalpay.payment.manage.riskbusiness.core.RiskBusinessService;
import au.com.royalpay.payment.manage.riskbusiness.core.RiskMaterialService; import au.com.royalpay.payment.manage.riskbusiness.core.RiskMaterialService;
import au.com.royalpay.payment.manage.riskbusiness.core.RiskProcessLogService; import au.com.royalpay.payment.manage.riskbusiness.core.RiskProcessLogService;
import au.com.royalpay.payment.manage.riskbusiness.core.RiskUploadService;
import au.com.royalpay.payment.manage.riskbusiness.enums.RiskEmailStatusEnum; import au.com.royalpay.payment.manage.riskbusiness.enums.RiskEmailStatusEnum;
import au.com.royalpay.payment.manage.riskbusiness.enums.RiskResultTypeEnum; import au.com.royalpay.payment.manage.riskbusiness.enums.RiskResultTypeEnum;
import au.com.royalpay.payment.manage.signin.beans.TodoNotice; import au.com.royalpay.payment.manage.signin.beans.TodoNotice;
@ -100,6 +101,8 @@ public class RiskBusinessServiceImpl implements RiskBusinessService, ManagerTodo
@Resource @Resource
private TradeLogService tradeLogService; private TradeLogService tradeLogService;
@Resource @Resource
private RiskUploadService riskUploadService;
@Resource
private RoyalThreadPoolExecutor royalThreadPoolExecutor; private RoyalThreadPoolExecutor royalThreadPoolExecutor;
private final String UPLOAD_MAIL_PREFIX = "UPLOAD_MAIL"; private final String UPLOAD_MAIL_PREFIX = "UPLOAD_MAIL";
@ -1247,6 +1250,25 @@ public class RiskBusinessServiceImpl implements RiskBusinessService, ManagerTodo
riskEventMapper.update(params); riskEventMapper.update(params);
} }
@Override
public void commitWaitRiskStatus(String riskId, String codeKey, JSONObject manager) {
JSONObject event = riskEventMapper.findById(riskId);
if (event.getIntValue("result_type") != RiskResultTypeEnum.SEND_EMAIL_TO_BD.getResultType() &&event.getIntValue("result_type") != RiskResultTypeEnum.MATERIAL_NOT_PASS.getResultType()) {
throw new BadRequestException("风控调单不存在或资料已补全");
}
if(event.getIntValue("result_type")!= RiskResultTypeEnum.MATERIAL_AUDIT_PASS.getResultType()){
event.put("result_type", RiskResultTypeEnum.WAIT_FOR_AUDIT.getResultType());
riskEventMapper.update(event);
}
riskProcessLogService.addRiskProcessLog(riskId,
manager.getString("manager_id"),
manager.getString("display_name"),
RiskResultTypeEnum.WAIT_FOR_AUDIT.getRemark(),
RiskResultTypeEnum.SEND_EMAIL_TO_BD.getResultType(),
RiskResultTypeEnum.WAIT_FOR_AUDIT.getResultType());
riskUploadService.deleteUploadMailKey(codeKey);
}
@Transactional @Transactional
@Override @Override
public JSONObject riskEventMaterialPass(JSONObject params, JSONObject manager) { public JSONObject riskEventMaterialPass(JSONObject params, JSONObject manager) {

@ -170,6 +170,11 @@ public class RiskBusinessController {
riskBusinessService.banRiskEvent(risk_id); riskBusinessService.banRiskEvent(risk_id);
} }
@RequestMapping(value = "/commitWaitRiskStatus/{risk_id}/{codeKey}", method = RequestMethod.PUT)
public void commitWaitRiskStatus(@PathVariable String risk_id,@PathVariable String codeKey,@ModelAttribute(CommonConsts.MANAGER_STATUS) JSONObject manager) {
riskBusinessService.commitWaitRiskStatus(risk_id, codeKey, manager);
}
@GetMapping(value = "/partners") @GetMapping(value = "/partners")
public List<JSONObject> getPartners(PartnerQuery partnerQuery) { public List<JSONObject> getPartners(PartnerQuery partnerQuery) {
JSONObject param = partnerQuery.toJsonParam(); JSONObject param = partnerQuery.toJsonParam();

@ -335,6 +335,22 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
}) })
}; };
$scope.commitWaitRiskStatus = function () {
var codeKey = $scope.riskEvent.submit_url.substring($scope.riskEvent.submit_url.lastIndexOf('=') + 1) || $scope.riskEvent.submit_url.substring($scope.riskEvent.submit_url.lastIndexOf('/') + 1);
commonDialog.confirm({
title: '确认已提交资料',
content: '确认已收到商户资料,更新风控状态为等待风控审核?'
}).then(function () {
$http.put('/risk/business/commitWaitRiskStatus/' + $scope.riskEvent.risk_id + '/' + codeKey).then(function () {
$state.go('analysis_monitoring.risk_business');
commonDialog.alert({title: 'Success', content: '风控状态已修改为等待风控审核状态', type: 'success'});
}, function (resp) {
commonDialog.alert({title: 'Error', content: resp.data.message, type: 'error'});
});
})
};
/** /**
* order_ids在指定位置换行 * order_ids在指定位置换行
* @param str * @param str

@ -23,6 +23,11 @@
<li ui-sref-active="active"> <li ui-sref-active="active">
<a ui-sref=".audit_material" ui-sref-opts="{reload:true}">Audit material</a> <a ui-sref=".audit_material" ui-sref-opts="{reload:true}">Audit material</a>
</li> </li>
<li>
<div class="btn-group pull-right" role="group" aria-label="..." ng-if="('10000000000'|withRole) && (riskEvent.result_type==1 || riskEvent.result_type==4)">
<button type="button" class="btn btn-success" ng-click="commitWaitRiskStatus()">已收到风控材料</button>
</div>
</li>
</ul> </ul>
<div class="tab-content" ui-view> <div class="tab-content" ui-view>
<div class="row" ng-if="!editFlag"> <div class="row" ng-if="!editFlag">

Loading…
Cancel
Save