master
wangning 7 years ago
commit 4efcb964b5

@ -32,8 +32,8 @@
## 支付宝渠道区分
支付宝根据调用接口不同分为线上和线下两个渠道,两个渠道分别使用不同的汇率和手续费费率,为避免混淆在此区分:
+ 线上渠道包含H5 Mobile、Web支付以及APP SDK三种支付方式
+ 线下渠道:包含JSAPI、QR Code、Retail Pay 3种支付方式
+ 线上渠道包含H5 Mobile、Web支付、APP SDK、JSAPI、QR Code 5种支付方式
+ 线下渠道Retail Pay 支付方式
相似接口区别
- JSAPI和H5 MobileJSAPI只能在支付宝客户端内访问的页面调起支付H5可以在移动设备任意浏览器或App的WebView调起支付

@ -37,8 +37,8 @@ System error message supports Simplified Chinese and English. The system by defa
## Alipay Channels
According to different Api used, Alipay channel was distributed to Retail channel and Online channel. Two channels has different exchange rate and surcharge rate.
+ Online Channel: Including H5 Mobile, Online Payment and APP SDK
+ Retail Channel: Including JSAPI, QR Code Api, Retail Pay
+ Online Channel: Including H5 Mobile, Online Payment, APP SDK, JSAPI and QR Code Api
+ Retail Channel: Including Retail Pay
Difference
- JSAPI and H5 Mobile: JSAPI can only be called in the web page opened in Alipay Client. H5 Mobile can call the payment panel in any browser or webview in App in the mobile device.

@ -404,6 +404,10 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
}
})
}
if(!window.frames['merchant_detail'].merchant_location){
alert("Please Locate Merchant's Location");
return;
}
$http.post('/sys/partners', $scope.partner).then(function (resp) {
commonDialog.alert({title: 'Success', content: 'Register new partner successfully', type: 'success'});
$scope.updateMerchantLocation();
@ -473,8 +477,6 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
if (params) {
$http.put('/sys/partners/modify/' + $scope.partner.client_moniker + '/location', params).then(function () {
});
} else {
alert("Please Locate Merchant's Location");
}
}
}]);
@ -954,11 +956,14 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
}
})
}
$scope.updateMerchantLocation();
var content = '';
if (!origin_referrer_id && $scope.partner.referrer_id) {
content = 'Update partner info successfully,But You Had add new Referrer,Please Change the BD Commission Proportion!';
}
if(!window.frames['merchant_detail'].merchant_location){
alert("Please Locate Merchant Location!");
return;
}
$http.put('/sys/partners/' + $scope.partner.client_moniker, $scope.partner).then(function () {
if (content != '') {
commonDialog.alert({
@ -973,6 +978,7 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
type: 'success'
});
}
$scope.updateMerchantLocation();
$scope.loadPartners();
$state.go('^.detail', {clientMoniker: $scope.partner.client_moniker}, {reload: true});
}, function (resp) {
@ -1046,12 +1052,6 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
if (params) {
$http.put('/sys/partners/modify/' + $scope.partner.client_moniker + '/location', params).then(function () {
});
} else {
commonDialog.alert({
title: 'Warning',
content: 'Please Locate Merchant Location',
type: 'error'
});
}
}
}]);
@ -1495,6 +1495,10 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
};
$scope.getRates();
$scope.saveBankAccount = function () {
if(isNaN($scope.bankaccount.account_no)){
alert("Account No应输入数字!");
return;
};
$http.put('/sys/partners/' + $scope.partner.client_moniker + '/bank_account', $scope.bankaccount).then(function () {
$scope.getBankAccount();
}, function (resp) {
@ -1823,6 +1827,24 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
return;
}
}
if (!$scope.partner.logo_url) {
alert("Logo is necessary!");
return;
}
if($scope.partner.partner_type == 'photo'){
if (!$scope.partner.company_photo) {
alert('Shop Photo1 is necessary');
return;
}
if (!$scope.partner.store_photo) {
alert('Shop Photo2 is necessary');
return;
}
}
if(!window.frames['merchant_detail'].merchant_location){
alert("Please Locate Merchant Location!");
return;
}
$http.post('/sys/partners/' + clientMoniker + '/sub_clients', $scope.partner).then(function () {
$scope.updateMerchantLocation();
$scope.$close();
@ -1851,18 +1873,36 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
$scope.uploadShopPhoto = function (file) {
if (file != null) {
$scope.photoProgress = {value: 0};
$scope.shopPhotoProgress = {value: 0};
Upload.upload({
url: '/attachment/files',
data: {file: file}
}).then(function (resp) {
delete $scope.photoProgress;
delete $scope.shopPhotoProgress;
$scope.partner.company_photo = resp.data.url;
}, function (resp) {
delete $scope.photoProgress;
delete $scope.shopPhotoProgress;
commonDialog.alert({title: 'Upload Failed', content: resp.data.message, type: 'error'})
}, function (evt) {
$scope.photoProgress.value = parseInt(100 * evt.loaded / evt.total);
$scope.shopPhotoProgress.value = parseInt(100 * evt.loaded / evt.total);
})
}
};
$scope.uploadStorePhoto = function (file) {
if (file != null) {
$scope.storePhotoProgress = {value: 0};
Upload.upload({
url: '/attachment/files',
data: {file: file}
}).then(function (resp) {
delete $scope.storePhotoProgress;
$scope.partner.store_photo = resp.data.url;
}, function (resp) {
delete $scope.storePhotoProgress;
commonDialog.alert({title: 'Upload Failed', content: resp.data.message, type: 'error'})
}, function (evt) {
$scope.storePhotoProgress.value = parseInt(100 * evt.loaded / evt.total);
})
}
};
@ -1871,12 +1911,6 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
if (params) {
$http.put('/sys/partners/modify/' + $scope.partner.client_moniker + '/location', params).then(function () {
});
} else {
commonDialog.alert({
title: 'Warning',
content: 'Please Locate Merchant Location',
type: 'error'
});
}
}
}]);

@ -1,6 +1,6 @@
<style>
.img-size{
height: 100px;
max-height: 100px;
margin-left: 20px;
}
</style>
@ -237,7 +237,7 @@
</div>
<uib-progressbar value="shopPhotoProgress.value"
ng-if="shopPhotoProgress"></uib-progressbar>
<img ng-src="{{partner.company_photo}}" ng-if="partner.company_photo" class="thumbnail img-size">
<img ng-src="{{partner.company_photo}}" ng-if="partner.company_photo" class="thumbnail img-size col-sm-9">
</div>
<div class="col-sm-4">
<div class="form-control-static"><em>2:</em>&nbsp;
@ -249,7 +249,7 @@
</div>
<uib-progressbar value="storePhotoProgress.value"
ng-if="storePhotoProgress"></uib-progressbar>
<img ng-src="{{partner.store_photo}}" ng-if="partner.store_photo" class="thumbnail img-size">
<img ng-src="{{partner.store_photo}}" ng-if="partner.store_photo" class="thumbnail img-size col-sm-9">
</div>
</div>
@ -372,7 +372,7 @@
</div>
<!--end 商户基本资料-->
<div class="panel panel-default">
<div class="panel-heading">Alipay Information</div>
<div class="panel-heading">Alipay Information &nbsp;<em class="small"><b>(Optional)</b></em></div>
<div class="panel-body">
<div class="form-horizontal">
<div class="form-group">
@ -402,7 +402,8 @@
<label class="control-label col-sm-2">
Video Introduction<br><em class="small">(youtube link)</em></label>
<div class="col-sm-8">
<input type="url" class="form-control" ng-model="partner.merchant_video_url">
<input type="text" class="form-control" ng-model="partner.merchant_video_url">
<p class="small text-info">eg:https://www.baidu.com</p>
</div>
</div>
</div>

@ -1,3 +1,9 @@
<style>
.img-size{
max-height: 100px;
margin-left: 20px;
}
</style>
<div class="modal-header bg-success">
<h4>New Sub Partner</h4>
</div>
@ -169,6 +175,8 @@
</select>
<p class="small text-info">If the partner is a offline shop then a photo of shop is
required while an online store shall choose companyWebsite</p>
<p class="small text-info">
只要有可能产生线下交易商户静态码、POS就必须上传照片否则支付宝会禁止交易</p>
<div ng-messages="partnerForm.partner_type.$error"
ng-if="partnerForm.partner_type.$dirty">
<p class="small text-danger" ng-message="required">Required Field</p>
@ -177,16 +185,29 @@
</div>
<div class="form-group" ng-if="partner.partner_type == 'photo'">
<label class="control-label col-sm-2">* Shop Photo</label>
<div class="col-sm-8">
<div class="form-control-static">
<div class="col-sm-4">
<div class="form-control-static"><em>1:</em>&nbsp;
<button class="btn btn-primary" type="button"
ngf-select="uploadShopPhoto($file)" accept="image/*"
ngf-max-size="2MB">
<i class="fa fa-upload"></i> Upload Shop Photo1
</button>
</div>
<uib-progressbar value="shopPhotoProgress.value"
ng-if="shopPhotoProgress"></uib-progressbar>
<img ng-src="{{partner.company_photo}}" ng-if="partner.company_photo" class="thumbnail img-size col-sm-9">
</div>
<div class="col-sm-4">
<div class="form-control-static"><em>2:</em>&nbsp;
<button class="btn btn-primary" type="button"
ngf-select="uploadShopPhoto($file)" accept="image/*" ngf-max-size="2MB">
<i class="fa fa-upload"></i> Upload Shop Photo
ngf-select="uploadStorePhoto($file)" accept="image/*"
ngf-max-size="2MB">
<i class="fa fa-upload"></i> Upload Shop Photo2
</button>
</div>
<uib-progressbar value="photoProgress.value"
ng-if="photoProgress"></uib-progressbar>
<img ng-src="{{partner.company_photo}}" class="col-sm-4">
<uib-progressbar value="storePhotoProgress.value"
ng-if="storePhotoProgress"></uib-progressbar>
<img ng-src="{{partner.store_photo}}" ng-if="partner.store_photo" class="thumbnail img-size col-sm-9">
</div>
</div>
<div class="form-group" ng-if="partner.partner_type == 'companyWebsite'"
@ -282,6 +303,45 @@
</div>
</div>
<!--end 商户基本资料-->
<div class="panel panel-default">
<div class="panel-heading">Alipay Information &nbsp;<em class="small"><b>(Optional)</b></em></div>
<div class="panel-body">
<div class="form-horizontal">
<div class="form-group">
<label class="control-label col-sm-2">
Business Hours</label>
<div class="col-sm-8">
<input type="text" class="form-control" ng-model="partner.business_hours">
<p class="small text-info">
eg:Monday-Friday 09:00-20:00,Saturday-Sunday 10:00-22:00</p>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">
Merchant Tag<em class="small">(Chinese)</em></label>
<div class="col-sm-8">
<input type="text" class="form-control" ng-model="partner.merchant_tag">
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">
Merchant Introduction<em class="small">(Chinese)</em></label>
<div class="col-sm-8">
<textarea class="form-control" ng-model="partner.merchant_introduction"></textarea>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">
Video Introduction<br><em class="small">(youtube link)</em></label>
<div class="col-sm-8">
<input type="text" class="form-control" ng-model="partner.merchant_video_url">
<p class="small text-info">eg:https://www.baidu.com</p>
</div>
</div>
</div>
</div>
</div>
<!--支付宝资料-->
<div class="panel panel-default">
<div class="panel-heading">Contact Information</div>
<div class="panel-body">

@ -308,7 +308,7 @@
<div class="form-group">
<label class="control-label col-sm-2">Logo</label>
<div class="col-sm-10">
<img ng-src="{{partner.logo_url}}" class="col-sm-3 col-xs-5" style="max-height: 100px;width: auto;">
<img ng-src="{{partner.logo_url}}" style="max-height: 100px;">
</div>
</div>
<div class="form-group" ng-if="partner.abn">
@ -454,7 +454,7 @@
<!--end 商户基本资料-->
<!--支付宝资料-->
<div class="panel panel-default">
<div class="panel-heading">Alipay Information</div>
<div class="panel-heading">Alipay Information &nbsp;<em class="small"><b>(Optional)</b></em></div>
<div class="panel-body">
<div class="form-horizontal">
<div class="form-group">

@ -1,6 +1,6 @@
<style>
.img-size{
height: 100px;
max-height: 100px;
margin-left: 20px;
}
</style>
@ -186,7 +186,7 @@
</div>
<uib-progressbar value="shopPhotoProgress.value"
ng-if="shopPhotoProgress"></uib-progressbar>
<img ng-src="{{partner.company_photo}}" ng-if="partner.company_photo" class="thumbnail img-size">
<img ng-src="{{partner.company_photo}}" ng-if="partner.company_photo" class="thumbnail img-size col-sm-9">
</div>
<div class="col-sm-5">
<div class="form-control-static"><em>2:</em>&nbsp;
@ -198,7 +198,7 @@
</div>
<uib-progressbar value="storePhotoProgress.value"
ng-if="storePhotoProgress"></uib-progressbar>
<img ng-src="{{partner.store_photo}}" ng-if="partner.store_photo" class="thumbnail img-size">
<img ng-src="{{partner.store_photo}}" ng-if="partner.store_photo" class="thumbnail img-size col-sm-9">
</div>
</div>
<div class="form-group"
@ -264,7 +264,7 @@
</div>
<!--end 商户基本资料-->
<div class="panel panel-default">
<div class="panel-heading">Alipay Information</div>
<div class="panel-heading">Alipay Information &nbsp; <em class="small"><b>(Optional)</b></em></div>
<div class="panel-body">
<div class="form-horizontal">
<div class="form-group">
@ -294,7 +294,8 @@
<label class="control-label col-sm-2">
Video Introduction<br><em class="small">(youtube link)</em></label>
<div class="col-sm-8">
<input type="url" class="form-control" ng-model="partner.merchant_video_url">
<input type="text" class="form-control" ng-model="partner.merchant_video_url">
<p class="small text-info">eg:https://www.baidu.com</p>
</div>
</div>
</div>

Loading…
Cancel
Save