|
|
|
@ -23,7 +23,7 @@ define(['angular', 'uiBootstrap', 'uiRouter'], function (angular) {
|
|
|
|
|
});
|
|
|
|
|
}]);
|
|
|
|
|
|
|
|
|
|
app.controller('partnerIncrementalServiceCtrl', ['$scope', '$http', '$state', 'partner', function ($scope, $http, $state, partner) {
|
|
|
|
|
app.controller('partnerIncrementalServiceCtrl', ['$scope', '$http', '$state', 'partner', '$stateParams' , function ($scope, $http, $state, partner,$stateParams) {
|
|
|
|
|
$scope.serviceAll = [];
|
|
|
|
|
$scope.channelOptions = [];
|
|
|
|
|
$scope.windowHeight = document.body.clientWidth;
|
|
|
|
@ -41,6 +41,18 @@ define(['angular', 'uiBootstrap', 'uiRouter'], function (angular) {
|
|
|
|
|
})
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$scope.getGeekSsoLoginUrl = function () {
|
|
|
|
|
var url = "http://mch.dev.geekforbest.com/#/sso_login?token=";
|
|
|
|
|
$http.get("/client/partner_info/incremental_service/RP跨境商城/login_token").then(function (res) {
|
|
|
|
|
url += res.data.token;
|
|
|
|
|
window.open(url, '_blank');
|
|
|
|
|
}, function (resp) {
|
|
|
|
|
console.log(resp.data.message)
|
|
|
|
|
window.open("https://mch.geekforbest.com/#/login", '_blank');
|
|
|
|
|
});
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
$scope.CheckImgExists =function (url) {
|
|
|
|
|
var xmlHttp ;
|
|
|
|
|
if (window.ActiveXObject)
|
|
|
|
@ -67,8 +79,15 @@ define(['angular', 'uiBootstrap', 'uiRouter'], function (angular) {
|
|
|
|
|
$scope.initDate = function () {
|
|
|
|
|
$http.get("/client/partner_info/"+partner.data.client_moniker+"/incremental_service/"+$stateParams.channel+"/info").then(function(res){
|
|
|
|
|
$scope.serviceInfo =res.data
|
|
|
|
|
$scope.serviceInfo.logo_url = '/static/images/'+$scope.serviceInfo.channel+'.jpg'
|
|
|
|
|
$scope.serviceInfo.logo_url = $scope.CheckImgExists($scope.serviceInfo.logo_url)?$scope.serviceInfo.logo_url:'/static/images/royalpay_sign.png'
|
|
|
|
|
if ($scope.serviceInfo == undefined || $scope.serviceInfo =='') {
|
|
|
|
|
$scope.serviceInfo = {};
|
|
|
|
|
}
|
|
|
|
|
if ($scope.serviceInfo.logo_url) {
|
|
|
|
|
$scope.serviceInfo.logo_url = '/static/images/'+$scope.serviceInfo.channel+'.jpg';
|
|
|
|
|
$scope.serviceInfo.logo_url = $scope.CheckImgExists($scope.serviceInfo.logo_url)?$scope.serviceInfo.logo_url:'/static/images/royalpay_sign.png';
|
|
|
|
|
}else {
|
|
|
|
|
$scope.serviceInfo.logo_url = '/static/images/R跨境商城.jpg';
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|