add 风控业务事件增加模板选择

master
luoyang 6 years ago
parent 58c4947aa5
commit dc87e9b82e

@ -787,6 +787,7 @@ public class RiskBusinessServiceImpl implements RiskBusinessService, ManagerTodo
ctx.setVariable("warning_order_type", event.getIntValue("warning_order_type"));
ctx.setVariable("description", event.getString("description"));
ctx.setVariable("is_send_client",event.getIntValue("is_send_client"));
ctx.setVariable("mail_template",event.get("mail_template")==null?0:event.getIntValue("mail_template"));
String realOrderIdsStr = event.getString("real_order_ids");
String[] realOrderIds = {};
if (StringUtils.isNotBlank(realOrderIdsStr)) {
@ -1202,6 +1203,21 @@ public class RiskBusinessServiceImpl implements RiskBusinessService, ManagerTodo
"Other pictures"
);
}
if (riskEvent.get("mail_template") != null) {
switch (riskEvent.getIntValue("mail_template")) {
case 1:
materialsRemark = getShopTemplate();
break;
case 2:
materialsRemark = getTicketTemplate();
break;
case 3:
materialsRemark = getStudyTemplate();
break;
default:
break;
}
}
JSONObject material = getRiskMaterial(riskEvent);
for (int i = 0; i < materialsRemark.size(); i++) {
@ -1279,4 +1295,42 @@ public class RiskBusinessServiceImpl implements RiskBusinessService, ManagerTodo
}
}
}
private List<String> getShopTemplate() {
return Arrays.asList("1.与调查交易金额对应的购物小票/发票存根照片 要求:照片应清晰,必须显示商户名称、商户地址、购物时间、物品名称、购物金额等;\n" +
"Photos of shopping receipts/ invoice stubs Requirement corresponding with the investigated orders Requirement: The photos should be clear and must show Merchant name, Business address, Transaction time, Product information, Quantity purchased, etc;",
"2.购买物品如邮寄至国内,需提供物流公司发货单据,并提供对应物流公司的查询网址;澳洲本地销售则不需要提供物流单据 要求:每笔交易对应的物流单必须提供,且单据必须清晰可见;\n" +
"Photos of logistics companiesgoods-delivery documents if trading across borders with Logistics company inquiry website for verifying; no need for local sales Requirement: The logistics order record corresponding to each transaction must be provided, and details of records should be clearly visible;",
"3.线上用户购买虚拟物品需要提供聊天记录、订单信息、发货凭证截图、 虚拟物品最终消费场景(例如何种游戏、软件)、提供消费场景网址/下载链接(公司官网、公众号等) 要求:每笔交易对应的截图必须清晰可见;\n" +
"Users need to provide chat records, order information, screenshots of delivery documents, final consumption scenarios of virtual goods (such as games, software); provide consumer scene URL / download link(official website/official accounts/other official platforms). Requirement: The screenshot corresponding to each transaction must be clearly visible;",
"4.商户线下门店提供显示商户门牌号码和店头名称的照片;显示商户营业场景所场内部情况(如店内商品陈列、收银台等)的照片 要求照片清晰外景至少一张内景能清楚显示商户实际售卖物品或服务至少三张Photos of Merchant Street number & Merchant name\n" +
"Photos of internal environment of merchant business (such as in-store merchandise display, checkout counter, etc.) Requirements: At least one visible photo of store location; The photos (at least three) showing merchant activities including actual selling-goods or services obviously;",
"5.其它补充材料包含调单任务描述中要求提供的商户后台入驻材料等;商户的经营业务模式说明:介绍售卖的主要物品种类或是提供的服务内容、客单价均值、营业时间等);\n" +
"Other materials including onboarding materials as task description requiredExplanation of business model for your merchant including actual selling-goods or services, per customer transaction, business hours, etc;"
);
}
private List<String> getTicketTemplate() {
return Arrays.asList("1.与调查交易金额对应的购物小票/发票存根照片 要求:照片应清晰,必须显示商户名称、商户地址、购物时间、物品名称、购物金额等;\n" +
"Photos of shopping receipts/ invoice stubs Requirement corresponding with the investigated orders Requirement: The photos should be clear and must show Merchant name, Business address, Transaction time, Product information, Quantity purchased, etc;",
"2.与调查交易相对应的客户旅游行程明细(包含行程单、机票、酒店预订信息等),线上用户购买行程/机票等的聊天记录、订单信息、购买凭证截图、提供消费场景网址/下载链接(公司官网、公众号等) 要求:每笔交易对应的截图必须清晰可见;\n" +
"Users need to provide travel itinerary, hotel reservation Information and journey times of customers about the orders, provide records of investigated orders, provide consumer scene URL / download link(official website/official accounts/other official platforms). Requirement: The screenshot corresponding to each transaction must be clearly visible;",
"3.商户线下门店提供显示商户门牌号码和店头名称的照片(清晰可见,至少一张);显示商户营业场景所场内部情况(如店内商品陈列、收银台等)的照片(照片清晰,且能清楚显示商户实际售卖物品或服务,至少三张 \n" +
"Photos of Merchant Street number & Merchant name; Photos of internal environment of merchant business (such as in-store merchandise display, checkout counter, etc.) Requirements: At least one visible photo of store location; The photos (at least three) showing merchant activities including actual selling-goods or services obviously;",
"4.其它补充材料包含调单任务描述中要求提供的商户后台入驻材料等;商户的经营业务模式说明:介绍售卖的主要物品种类或是提供的服务内容、客单价均值、营业时间等);\n" +
"Other materials including onboarding materials as task description requiredExplanation of business model for your merchant including actual selling-goods or services, per customer transaction, business hours, etc;"
);
}
private List<String> getStudyTemplate() {
return Arrays.asList("1.与调查交易金额对应的购物小票/发票存根照片 要求:照片应清晰,必须显示商户名称、商户地址、购物时间、物品名称、购物金额等;\n" +
"Photos of shopping receipts/ invoice stubs Requirement corresponding with the investigated orders Requirement: The photos should be clear and must show Merchant name, Business address, Transaction time, Product information, Quantity purchased, etc;",
"2.与调查交易相对应的客户支付购买的课程明细、教育服务(签证、咨询等)明细,单价,数量,具体购买服务内容,线上用户购买的聊天记录、购买凭证截图、提供消费场景网址/下载链接(公司官网、公众号等) 要求:每笔交易对应的截图必须清晰可见;\n" +
"Users need to provide the details of purchased courses/education services(visa services/consulting/others) including price, quantity, service details, chat records online, order information, screenshots of system ordered details; provide consumer scene URL / download link(official website/official accounts/other official platforms). Requirement: The screenshot corresponding to each transaction must be clearly visible;",
"3.商户线下门店提供显示商户门牌号码和店头名称的照片(清晰可见,至少一张);显示商户营业场景所场内部情况(如店内商品陈列、收银台等)的照片(照片清晰,且能清楚显示商户实际售卖物品或服务,至少三张 \n" +
"Photos of Merchant Street number & Merchant name; Photos of internal environment of merchant business (such as in-store merchandise display, checkout counter, etc.) Requirements: At least one visible photo of store location; The photos (at least three) showing merchant activities including actual selling-goods or services obviously;",
"4.其它补充材料包含调单任务描述中要求提供的商户后台入驻材料等;商户的经营业务模式说明:介绍售卖的主要物品种类或是提供的服务内容、客单价均值、营业时间等);\n" +
"Other materials including onboarding materials as task description requiredExplanation of business model for your merchant including actual selling-goods or services, per customer transaction, business hours, etc;"
);
}
}

@ -23,8 +23,15 @@
before <span style="background: #FCE824;" th:text="${reply_date_english}"></span>(Sydney time).
</p>
<p>1、请提供以下被查单号的小票 物流单据(如有邮寄产品的情况), 以及消费者与买家的聊天记录等来佐证被查交易单号。 被查交易单号如下:</p>
<p>1. Please submit the materials including invoices, courier receipts (if have posted products), and chatting records or scene of consumption which can prove the facticity of the following reviewed orders. The reviewed orders as follows:</p>
<p th:if="${mail_template==0}">1、请提供以下被查单号的小票 物流单据(如有邮寄产品的情况), 以及消费者与买家的聊天记录等来佐证被查交易单号。 被查交易单号如下:</p>
<p th:if="${mail_template==0}">1. Please submit the materials including invoices, courier receipts (if have posted products), and chatting records or scene of consumption which can prove the facticity of the following reviewed orders. The reviewed orders as follows:</p>
<p th:if="${mail_template==1}">1、请提供以下被查单号的交易相关发票对应的物流单据如有邮寄产品的情况 以及体现消费场景的聊天截图等来佐证被查交易单号。 被查交易单号如下:</p>
<p th:if="${mail_template==1}">1. Please submit the materials including invoices, courier receipts (if have posted products), and chatting records or scene of consumption which can prove the facticity of the following reviewed orders. The reviewed orders as follows:</p>
<p th:if="${mail_template==2}">1、请提供以下被查单号的交易相关票据对应消费项目的行程单、机票、酒店预定凭证等 以及体现消费场景的聊天截图等来佐证被查交易单号。 被查交易单号如下:</p>
<p th:if="${mail_template==2}">1. Please submit the materials including invoices, courier receipts (if have posted products), and chatting records or scene of consumption which can prove the facticity of the following reviewed orders. The reviewed orders as follows:</p>
<p th:if="${mail_template==3}">1、请提供以下被查单号的交易相关票据详细购买的具体课程、服务、咨询明细 以及体现消费场景的聊天截图等来佐证被查交易单号。 被查交易单号如下:</p>
<p th:if="${mail_template==3}">1. Please submit the materials including invoices, courier receipts (if have posted products), and chatting records or scene of consumption which can prove the facticity of the following reviewed orders. The reviewed orders as follows:</p>
<table style="border: 1.0px solid;border-collapse: collapse;">
<thead>
<tr>

@ -4,6 +4,14 @@
define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
function (angular, $) {
'use strict';
var mailTemplate = {
"1": "代购、综合商城类",
"2": "飞机票、旅行社类",
"3": "教育类、中介类"
};
var orderTypesMap = {
"1": "微信调单",
"2": "支付宝调单",
@ -129,7 +137,7 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
}]);
app.controller('riskBusinessCtrl', ['$scope', '$state', '$http', '$uibModal', '$filter', 'commonDialog', 'industryMap','chartParser',
app.controller('riskBusinessCtrl', ['$scope', '$state', '$http', '$uibModal', '$filter', 'commonDialog', 'industryMap', 'chartParser',
function ($scope, $state, $http, $uibModal, $filter, commonDialog, industryMap, chartParser) {
$scope.orderTypes = orderTypesMap;
$scope.orderTypesForBD = orderTypesMapForBD;
@ -165,11 +173,11 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
});
$http.get('/risk/business/events/analysis/industry', {params: params}).then(function (resp) {
$scope.riskEventsByIndustry = resp.data;
$scope.risk_industry_chart = chartParser.parse(industryAmount(industries),$scope.riskEventsByIndustry);
$scope.risk_industry_chart = chartParser.parse(industryAmount(industries), $scope.riskEventsByIndustry);
});
$http.get('/risk/business/events/analysis/amount', {params: params}).then(function (resp) {
$scope.riskEventsByAmount = resp.data;
$scope.risk_amount_chart = chartParser.parse(intervalsAmount(),$scope.riskEventsByAmount);
$scope.risk_amount_chart = chartParser.parse(intervalsAmount(), $scope.riskEventsByAmount);
});
};
@ -193,15 +201,15 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
name: '风控事件单量', type: 'pie',
radius: '80%',
center: ['50%', '58%'],
label:{ //饼图图形上的文本标签
normal:{
show:true,
position:'outer', //标签的位置
textStyle : {
fontWeight : 300 ,
fontSize : 16 //文字的字体大小
label: { //饼图图形上的文本标签
normal: {
show: true,
position: 'outer', //标签的位置
textStyle: {
fontWeight: 300,
fontSize: 16 //文字的字体大小
},
formatter:'{d}%'
formatter: '{d}%'
}
},
itemStyle: {
@ -228,8 +236,8 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
legend: {
orient: 'vertical',
left: 'right',
data: [ '0-500','500-1000','1000-1500','1500-2000','2000-2500','2500-3000','3000-3500','3500-4000','4000-4500','4500-5000','5000-5500','5500-6000',
'6000-6500','6500-7000','7000-7500','7500-8000','8000-8500','8500-9000','>9000']
data: ['0-500', '500-1000', '1000-1500', '1500-2000', '2000-2500', '2500-3000', '3000-3500', '3500-4000', '4000-4500', '4500-5000', '5000-5500', '5500-6000',
'6000-6500', '6500-7000', '7000-7500', '7500-8000', '8000-8500', '8500-9000', '>9000']
}
},
series: [{
@ -237,15 +245,15 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
name: '风控事件单量', type: 'pie',
radius: '80%',
center: ['50%', '58%'],
label:{ //饼图图形上的文本标签
normal:{
show:true,
position:'outer', //标签的位置
textStyle : {
fontWeight : 300 ,
fontSize : 16 //文字的字体大小
label: { //饼图图形上的文本标签
normal: {
show: true,
position: 'outer', //标签的位置
textStyle: {
fontWeight: 300,
fontSize: 16 //文字的字体大小
},
formatter:'{d}%'
formatter: '{d}%'
}
},
itemStyle: {
@ -269,12 +277,32 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
function ($scope, $state, $http, $uibModal, $filter, Upload, commonDialog, riskEvent, orderService) {
$scope.orderTypes = orderTypesMap;
$scope.mailTemplate = mailTemplate;
$scope.resultTypes = resultTypesMap;
$scope.channelResults = channelResultArray;
if (riskEvent.data.is_send_client == 1)
riskEvent.data.is_send_client = true;
$scope.riskEvent = riskEvent.data;
$scope.checkTemplate = function () {
var url = "";
switch ($scope.riskEvent.mail_template) {
case "1":
url = "https://file.royalpay.com.au/open/2019/03/27/1553658222567_BzfAtsEgsBdMQLl3jGOAlfcYmFUL1F.png";
break;
case "2":
url = "https://file.royalpay.com.au/open/2019/03/27/1553658193577_ddF4FAQYBaMx2oCEUlD2f2NtW3SxYD.png";
break;
case "3":
url = "https://file.royalpay.com.au/open/2019/03/27/1553658238130_VJPI3RNmyKtcOgsV8w8yswUsYMFvGs.png\n";
break;
default:
break;
}
window.open(url, '_blank');
};
$http.get('/risk/business/process/logs/' + $scope.riskEvent.risk_id).then(function (resp) {
$scope.riskEvent.process_logs = resp.data;
});
@ -300,7 +328,11 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
}).then(function () {
$http.delete('/risk/business/ban/' + $scope.riskEvent.risk_id).then(function () {
$state.go('analysis_monitoring.risk_business');
commonDialog.alert({title: 'Delete', content: 'Risk Event Already Disabled', type: 'error'});
commonDialog.alert({
title: 'Delete',
content: 'Risk Event Already Disabled',
type: 'error'
});
}, function (resp) {
commonDialog.alert({title: 'Error', content: resp.data.message, type: 'error'});
})
@ -344,7 +376,7 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
// 控制编辑表格的显示
$scope.editFlag = false;
$scope.changeEditFlag = function(editFlag) {
$scope.changeEditFlag = function (editFlag) {
$scope.editFlag = !editFlag;
// 如果是在编辑状态需要将日期转换为date类型前端控件需要
// 如果是在非编辑状态需要将日期转换为yyyy-MM-dd格式
@ -357,7 +389,7 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
}
};
$scope.save = function(form) {
$scope.save = function (form) {
if (form.$invalid) {
angular.forEach(form, function (item, key) {
if (key.indexOf('$') < 0) {
@ -416,7 +448,7 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
};
// 关停商户
$scope.updateClient = function(isValid, temporaryFlag) {
$scope.updateClient = function (isValid, temporaryFlag) {
$scope.riskEvent.temporary_close_merchant = temporaryFlag;
commonDialog.confirm({
title: 'Warning',
@ -453,8 +485,8 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
};
// 以下为BD上传材料相关
$scope.material={};
$scope.uploadFile = function(files, index) {
$scope.material = {};
$scope.uploadFile = function (files, index) {
if (files && files.length) {
var urls = new Array();
var value = 0;
@ -470,8 +502,8 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
delete $scope.allMaterialInfo.material[index].fileProgressValue;
alert('Upload Failed');
}, function (evt) {
value += parseInt(100 * evt.loaded / evt.total );
$scope.allMaterialInfo.material[index].fileProgressValue = value/(files.length*2);
value += parseInt(100 * evt.loaded / evt.total);
$scope.allMaterialInfo.material[index].fileProgressValue = value / (files.length * 2);
})
}
$scope.allMaterialInfo.material[index].uploadFile = urls;
@ -480,7 +512,7 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
$scope.submit = function (form) {
var codeKey = $scope.riskEvent.submit_url.substring($scope.riskEvent.submit_url.lastIndexOf('=') + 1) || $scope.riskEvent.submit_url.substring($scope.riskEvent.submit_url.lastIndexOf('/') + 1);
$scope.material.update_time=$filter('date')(new Date(), 'yyyy-MM-dd HH:mm:ss');
$scope.material.update_time = $filter('date')(new Date(), 'yyyy-MM-dd HH:mm:ss');
$scope.material.risk_id = $scope.riskEvent.risk_id;
for (var i = 0; i < $scope.allMaterialInfo.material.length; i++) {
var key = 'file' + (i + 1) + "_url";
@ -504,12 +536,12 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
};
// 加载提交材料
$scope.loadRiskMaterial = function() {
$scope.loadRiskMaterial = function () {
// $http.get('/risk/business/' + $scope.riskEvent.risk_id + '/material').then(function(resp) {
// $scope.material = resp.data;
// });
$http.get('/risk/business/' + $scope.riskEvent.risk_id + '/all_material_info').then(function(resp) {
$http.get('/risk/business/' + $scope.riskEvent.risk_id + '/all_material_info').then(function (resp) {
$scope.allMaterialInfo = resp.data;
if ($scope.uploadShowFlag) {
$scope.allMaterialInfo.description = '';
@ -534,7 +566,7 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
// 加载提交材料
// $scope.fileObject = {};
$scope.loadRiskMaterial = function() {
$scope.loadRiskMaterial = function () {
// $http.get('/risk/business/' + $scope.riskEvent.risk_id + '/material').then(function(resp) {
// $scope.riskMaterial = resp.data;
// $scope.file1 = resp.data.file1;
@ -552,7 +584,7 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
// // $scope.fileLength = Object.keys($scope.fileObject).length;
// })
$http.get('/risk/business/' + $scope.riskEvent.risk_id + '/all_material_info').then(function(resp) {
$http.get('/risk/business/' + $scope.riskEvent.risk_id + '/all_material_info').then(function (resp) {
$scope.riskMaterial = resp.data;
});
};
@ -562,7 +594,7 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
$scope.uploadShowFlag = ($scope.riskEvent.result_type == 1 || $scope.riskEvent.result_type == 3 || $scope.riskEvent.result_type == 4) ? true : false;
// 材料上传
$scope.uploadFile = function(files, index) {
$scope.uploadFile = function (files, index) {
if (files && files.length) {
var urls = new Array();
var value = 0;
@ -579,8 +611,8 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
delete $scope.riskMaterial.material[index].fileProgressValue;
alert('Upload Failed');
}, function (evt) {
value += parseInt(100 * evt.loaded / evt.total );
$scope.riskMaterial.material[index].fileProgressValue = value/(files.length*2);
value += parseInt(100 * evt.loaded / evt.total);
$scope.riskMaterial.material[index].fileProgressValue = value / (files.length * 2);
})
}
$scope.riskMaterial.material[index].file = urls;
@ -592,7 +624,7 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
if (index < 0)
index = $scope.riskEvent.submit_url.lastIndexOf('/');
var codeKey = $scope.riskEvent.submit_url.substring(index + 1);
$scope.material.update_time=$filter('date')(new Date(), 'yyyy-MM-dd HH:mm:ss');
$scope.material.update_time = $filter('date')(new Date(), 'yyyy-MM-dd HH:mm:ss');
$scope.material.risk_id = $scope.riskEvent.risk_id;
for (var i = 0; i < $scope.riskMaterial.material.length; i++) {
var key = 'file' + (i + 1) + "_url";
@ -616,7 +648,7 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
};
// 材料审核
$scope.auditMaterial = function(auditType) {
$scope.auditMaterial = function (auditType) {
var url = '/risk/business/events/pass';
var warningMessageHTML = '是否确定<span style="color: green; font-weight: bolder; font-size: 20px;">通过</span>该材料?';
@ -665,31 +697,50 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
$scope.receive_email_date = new Date();
$scope.today = new Date();
$scope.orderTypes = orderTypesMap;
$scope.mailTemplate = mailTemplate;
$scope.royapayOrderTypes = royalpayOrderTypesMap;
$scope.warningOrderTypes = warningOrderTypesMap;
$scope.materials = [{key: 0, value: ""}];
$scope.canMinus = false;
$scope.riskEvent = {};
$scope.increase = function($index) {
$scope.checkTemplate = function () {
var url = "";
switch ($scope.riskEvent.mail_template) {
case "1":
url = "https://file.royalpay.com.au/open/2019/03/27/1553658222567_BzfAtsEgsBdMQLl3jGOAlfcYmFUL1F.png";
break;
case "2":
url = "https://file.royalpay.com.au/open/2019/03/27/1553658193577_ddF4FAQYBaMx2oCEUlD2f2NtW3SxYD.png";
break;
case "3":
url = "https://file.royalpay.com.au/open/2019/03/27/1553658238130_VJPI3RNmyKtcOgsV8w8yswUsYMFvGs.png\n";
break;
default:
break;
}
window.open(url, '_blank');
};
$scope.increase = function ($index) {
$scope.materials.splice($index + 1, 0,
{key: new Date().getTime(), value: ""}); // 用时间戳作为每个item的key
// 增加新的input后允许删除
{key: new Date().getTime(), value: ""}); // 用时间戳作为每个item的key
// 增加新的input后允许删除
$scope.canMinus = true;
};
$scope.decrease = function($index) {
$scope.decrease = function ($index) {
// 如果input大于1删除
if ($scope.materials.length > 1) {
$scope.materials.splice($index, 1);
}
// 如果回复数为1不允许删除
if ($scope.materials.length == 1) {
$scope.canMinus = false;
}
if ($scope.materials.length > 1) {
$scope.materials.splice($index, 1);
}
// 如果回复数为1不允许删除
if ($scope.materials.length == 1) {
$scope.canMinus = false;
}
};
var array=new Array();
var array = new Array();
var validIndex = 0;
$scope.combineMaterials = function() {
$scope.combineMaterials = function () {
for (var i = 0; i < $scope.materials.length; i++) {
var value = $scope.materials[i].value;
if (value == '')
@ -705,10 +756,10 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
};
$scope.is_send_client = false;
$scope.changeIsSendClient = function(flag) {
$scope.changeIsSendClient = function (flag) {
$scope.is_send_client = flag
};
$scope.save = function(form) {
$scope.save = function (form) {
if (form.$invalid) {
angular.forEach(form, function (item, key) {
if (key.indexOf('$') < 0) {
@ -746,7 +797,7 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
content: 'Register new riskEvent successfully',
type: 'success'
});
$state.go('^',{}, {reload: true});
$state.go('^', {}, {reload: true});
}, function (resp) {
saveRiskBtn.innerHTML = saveRiskBtnInnerHtmlBak;
saveRiskBtn.disabled = false;
@ -758,7 +809,7 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
});
};
$scope.partnerParam = {};
$scope.loadParnters = function() {
$scope.loadParnters = function () {
$scope.partnerParam.sub_merchant_id = $scope.riskEvent.sub_merchant_id;
$http.get('/risk/business/partners', {params: $scope.partnerParam}).then(function (resp) {
$scope.partners = resp.data;
@ -793,34 +844,40 @@ define(['angular', 'jquery', 'uiRouter', './monitoring/analysis-monitoring'],
]);
// 调单类型过滤器
app.filter('orderType', function() {
return function(type) {
app.filter('orderType', function () {
return function (type) {
return orderTypesMap[type];
}
});
app.filter('royalPayOrderType', function() {
return function(type) {
app.filter('templateType', function () {
return function (type) {
return mailTemplate[type];
}
});
app.filter('royalPayOrderType', function () {
return function (type) {
return royalpayOrderTypesMap[type];
}
});
app.filter('warningOrderType', function() {
return function(type) {
app.filter('warningOrderType', function () {
return function (type) {
return warningOrderTypesMap[type];
}
});
// 处理结果过滤器
app.filter('resultType', function() {
return function(type, resultTypesMap) {
app.filter('resultType', function () {
return function (type, resultTypesMap) {
return resultTypesMap[type];
}
});
// 邮件发送状态过滤器
app.filter('emailStatus', function() {
return function(status) {
app.filter('emailStatus', function () {
return function (status) {
return emailStatusMap[status];
}
});

@ -230,6 +230,32 @@
</div>
</div>
<div class="form-group"
ng-class="{'has-error':riskEventForm.mail_template.$invalid && riskEventForm.mail_template.$dirty}">
<label class="control-label col-sm-2"
for="mail-template-input">WEB/Mail Template
</label>
<div class="col-sm-6">
<select class="form-control"
name="mail_template"
ng-model="riskEvent.mail_template"
id="mail-template-input"
required
ng-options="key as value for (key, value) in mailTemplate">
<option value="">Please Choose</option>
</select>
<div ng-messages="riskEventForm.mail_template.$error"
ng-if="riskEventForm.mail_template.$dirty">
<p class="small text-danger"
ng-message="required">required field
</p>
</div>
</div>
<div class="col-sm-2" ng-if="riskEvent.mail_template">
<button class="btn btn-link" ng-click="checkTemplate()">查看模板</button>
</div>
</div>
<div class="form-group" ng-if="riskEvent.order_type != 5">
<label class="control-label col-sm-2">是否发送商户</label>
<div class="col-xs-6">

@ -156,6 +156,15 @@
</div>
</div>
<div class="form-group" ng-if="riskEvent.mail_template">
<label class="control-label col-sm-2">WEB/Mail Template</label>
<div class="col-sm-10">
<p class="form-control-static"
ng-bind="riskEvent.mail_template | templateType">
</p>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">是否发送商户</label>
<div class="col-xs-6">
@ -524,6 +533,33 @@
</div>
</div>
<div class="form-group"
ng-class="{'has-error':riskEventForm.mail_template.$invalid && riskEventForm.mail_template.$dirty}">
<label class="control-label col-sm-2"
for="mail-template-input">WEB/Mail Template
</label>
<div class="col-sm-6">
<select class="form-control"
name="mail_template"
ng-model="riskEvent.mail_template"
id="mail-template-input"
required
ng-options="key as value for (key, value) in mailTemplate">
<option value="">Please Choose</option>
</select>
<div ng-messages="riskEventForm.mail_template.$error"
ng-if="riskEventForm.mail_template.$dirty">
<p class="small text-danger"
ng-message="required">required field
</p>
</div>
</div>
<div class="col-sm-2" ng-if="riskEvent.mail_template">
<button class="btn btn-link" ng-click="checkTemplate()">查看模板</button>
</div>
</div>
<div class="form-group" ng-if="riskEvent.order_type != 5">
<label class="control-label col-sm-2">是否发送商户</label>
<div class="col-xs-6">

Loading…
Cancel
Save