|
|
@ -5431,24 +5431,65 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}]);
|
|
|
|
}]);
|
|
|
|
// Merchant Id Management
|
|
|
|
// MID Management
|
|
|
|
app.controller('subMerchantIdApplicaitonsCtrl', ['$scope', '$http', '$uibModal', '$state', 'commonDialog', '$sce', function ($scope, $http, $uibModal, $state, commonDialog, $sce) {
|
|
|
|
app.controller('subMerchantIdApplicaitonsCtrl', ['$scope', '$http', '$uibModal', '$state', 'commonDialog', '$sce', function ($scope, $http, $uibModal, $state, commonDialog, $sce) {
|
|
|
|
|
|
|
|
// 初始化子商户
|
|
|
|
|
|
|
|
$scope.loadSubMerchantInfos = function () {
|
|
|
|
|
|
|
|
$http.get('/sys/partners/' + $scope.partner.client_moniker + '/list_sub_applices', { params: {} }).then(function (resp) {
|
|
|
|
|
|
|
|
$scope.subMerchantInfos = resp.data;
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
// $http.get('/sys/partners/' + $scope.partner.client_moniker + '/list_rpay_sub_applices', {params: {}}).then(function (resp) {
|
|
|
|
|
|
|
|
// $scope.subRpayMerchantInfos = resp.data;
|
|
|
|
|
|
|
|
// });
|
|
|
|
|
|
|
|
//
|
|
|
|
|
|
|
|
// $http.get('/sys/partners/' + $scope.partner.client_moniker + '/list_yeepay_sub_applices', {params: {}}).then(function (resp) {
|
|
|
|
|
|
|
|
// $scope.subYeepayMerchantInfos = resp.data;
|
|
|
|
|
|
|
|
// });
|
|
|
|
|
|
|
|
// $http.get('/sys/partners/' + $scope.partner.client_moniker + '/queryMWMerchantIdStatus').then(function (resp) {
|
|
|
|
|
|
|
|
// $scope.partner.cardInfo = resp.data;
|
|
|
|
|
|
|
|
// });
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
$scope.loadSubMerchantInfos();
|
|
|
|
|
|
|
|
// 加载卡支付信息
|
|
|
|
|
|
|
|
$scope.loadCardInfos = function () {
|
|
|
|
|
|
|
|
$http.get('/sys/partners/' + $scope.partner.client_moniker + '/queryMWMerchantIdStatus').then(function (resp) {
|
|
|
|
|
|
|
|
$scope.cardInfo = resp.data;
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
$scope.loadCardInfos();
|
|
|
|
|
|
|
|
// 初始化信息
|
|
|
|
$scope.loadPartnerInfo = function () {
|
|
|
|
$scope.loadPartnerInfo = function () {
|
|
|
|
$http.get('/sys/partners/' + $scope.partner.client_moniker).then(function (resp) {
|
|
|
|
$http.get('/sys/partners/' + $scope.partner.client_moniker).then(function (resp) {
|
|
|
|
$scope.partnerInfo = resp.data;
|
|
|
|
$scope.partnerInfo = resp.data;
|
|
|
|
$scope.doSwitchCommonSubMerchantId();
|
|
|
|
$scope.doSwitchCommonSubMerchantId();
|
|
|
|
})
|
|
|
|
})
|
|
|
|
};
|
|
|
|
};
|
|
|
|
$scope.loadPartnerInfo()
|
|
|
|
$scope.loadPartnerInfo();
|
|
|
|
// 编辑Wechat Sub Merchant Id
|
|
|
|
// 编辑Wechat Sub Merchant Id
|
|
|
|
$scope.saveSubMerchantId = function () {
|
|
|
|
$scope.saveSubMerchantId = function () {
|
|
|
|
$http.put('/sys/partners/' + $scope.partner.client_moniker + '/payment_config', { sub_merchant_id: $scope.partnerInfo.sub_merchant_id }).then(function (resp) {
|
|
|
|
$http.put('/sys/partners/' + $scope.partner.client_moniker + '/payment_config', { sub_merchant_id: $scope.partnerInfo.sub_merchant_id }).then(function (resp) {
|
|
|
|
$scope.loadPartnerInfo();
|
|
|
|
$scope.loadPartnerInfo();
|
|
|
|
$scope.ctrl.editSubMerchant = false;
|
|
|
|
|
|
|
|
}, function (resp) {
|
|
|
|
}, function (resp) {
|
|
|
|
commonDialog.alert({ title: 'Error', content: resp.data.message, type: 'error' })
|
|
|
|
commonDialog.alert({ title: 'Error', content: resp.data.message, type: 'error' })
|
|
|
|
});
|
|
|
|
});
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
// Wechat-applay
|
|
|
|
|
|
|
|
$scope.applyWxSubMerchantId = function () {
|
|
|
|
|
|
|
|
$uibModal.open({
|
|
|
|
|
|
|
|
templateUrl: '/static/payment/partner/templates/new_apply_wx_sub_merchant_id.html',
|
|
|
|
|
|
|
|
controller: 'newApplyWxSubMerchantIdCtrl',
|
|
|
|
|
|
|
|
resolve: {
|
|
|
|
|
|
|
|
subMerchantInfo: function () {
|
|
|
|
|
|
|
|
return $scope.partner;
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
merchantIds: ['$http', '$stateParams', function ($http) {
|
|
|
|
|
|
|
|
return $http.get('/sys/partners/' + $scope.partner.client_moniker + '/get_merchant_ids');
|
|
|
|
|
|
|
|
}]
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}).result.then(function () {
|
|
|
|
|
|
|
|
$scope.loadSubMerchantInfos();
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
};
|
|
|
|
// 刷新Wechat Sub Merchant Id
|
|
|
|
// 刷新Wechat Sub Merchant Id
|
|
|
|
$scope.queryWechatSubMerchantIdStatus = function () {
|
|
|
|
$scope.queryWechatSubMerchantIdStatus = function () {
|
|
|
|
$http.get('/sys/partners/' + $scope.partner.client_moniker + '/get_merchant_ids/' + $scope.partnerInfo.sub_merchant_id + '/status').then(function (resp) {
|
|
|
|
$http.get('/sys/partners/' + $scope.partner.client_moniker + '/get_merchant_ids/' + $scope.partnerInfo.sub_merchant_id + '/status').then(function (resp) {
|
|
|
@ -5458,6 +5499,8 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
|
|
|
|
type: 'info'
|
|
|
|
type: 'info'
|
|
|
|
})
|
|
|
|
})
|
|
|
|
$scope.loadPartnerInfo();
|
|
|
|
$scope.loadPartnerInfo();
|
|
|
|
|
|
|
|
}, function (resp) {
|
|
|
|
|
|
|
|
commonDialog.alert({ title: 'Error', content: resp.data.message, type: 'error' })
|
|
|
|
})
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
// history
|
|
|
|
// history
|
|
|
@ -5476,7 +5519,7 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
|
|
|
|
// 刷新Wechat Institution Merchant Id
|
|
|
|
// 刷新Wechat Institution Merchant Id
|
|
|
|
$scope.refreshWechatInstitutionMerchantId = function () {
|
|
|
|
$scope.refreshWechatInstitutionMerchantId = function () {
|
|
|
|
$http.put('/sys/partners/' + $scope.partner.client_moniker + '/wechat_institution_merchant_id', { wechat_institution_merchant_id: $scope.partnerInfo.wechat_institution_merchant_id }).then(function (resp) {
|
|
|
|
$http.put('/sys/partners/' + $scope.partner.client_moniker + '/wechat_institution_merchant_id', { wechat_institution_merchant_id: $scope.partnerInfo.wechat_institution_merchant_id }).then(function (resp) {
|
|
|
|
$scope.loadPartnerInfo()
|
|
|
|
$scope.loadPartnerInfo();
|
|
|
|
}, function (resp) {
|
|
|
|
}, function (resp) {
|
|
|
|
commonDialog.alert({ title: 'Error', content: resp.data.message, type: 'error' })
|
|
|
|
commonDialog.alert({ title: 'Error', content: resp.data.message, type: 'error' })
|
|
|
|
});
|
|
|
|
});
|
|
|
@ -5542,6 +5585,7 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
|
|
|
|
}).then(function () {
|
|
|
|
}).then(function () {
|
|
|
|
$http.post('/sys/partners/' + $scope.partner.client_moniker + '/register/alipay_gms').then(function () {
|
|
|
|
$http.post('/sys/partners/' + $scope.partner.client_moniker + '/register/alipay_gms').then(function () {
|
|
|
|
commonDialog.alert({ title: 'Success', content: 'Alipay进件成功', type: 'success' });
|
|
|
|
commonDialog.alert({ title: 'Success', content: 'Alipay进件成功', type: 'success' });
|
|
|
|
|
|
|
|
$scope.loadPartnerInfo();
|
|
|
|
}, function (resp) {
|
|
|
|
}, function (resp) {
|
|
|
|
commonDialog.alert({ title: 'Error', content: "进件失败:" + resp.data.message, type: 'error' });
|
|
|
|
commonDialog.alert({ title: 'Error', content: "进件失败:" + resp.data.message, type: 'error' });
|
|
|
|
})
|
|
|
|
})
|
|
|
@ -5559,6 +5603,7 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
|
|
|
|
}).then(function () {
|
|
|
|
}).then(function () {
|
|
|
|
$http.post('/sys/partners/' + $scope.partner.client_moniker + '/register/alipayOnline_gms').then(function () {
|
|
|
|
$http.post('/sys/partners/' + $scope.partner.client_moniker + '/register/alipayOnline_gms').then(function () {
|
|
|
|
commonDialog.alert({ title: 'Success', content: '提示:AlipayOnline进件成功', type: 'success' });
|
|
|
|
commonDialog.alert({ title: 'Success', content: '提示:AlipayOnline进件成功', type: 'success' });
|
|
|
|
|
|
|
|
$scope.loadPartnerInfo();
|
|
|
|
}, function (resp) {
|
|
|
|
}, function (resp) {
|
|
|
|
commonDialog.alert({ title: 'Error', content: "进件失败:" + resp.data.message, type: 'error' });
|
|
|
|
commonDialog.alert({ title: 'Error', content: "进件失败:" + resp.data.message, type: 'error' });
|
|
|
|
});
|
|
|
|
});
|
|
|
@ -5573,7 +5618,7 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
|
|
|
|
content: 'Modify Wechat Sub Merchant ID successfully',
|
|
|
|
content: 'Modify Wechat Sub Merchant ID successfully',
|
|
|
|
type: 'success'
|
|
|
|
type: 'success'
|
|
|
|
});
|
|
|
|
});
|
|
|
|
$state.reload();
|
|
|
|
$scope.loadPartnerInfo();
|
|
|
|
}, function (resp) {
|
|
|
|
}, function (resp) {
|
|
|
|
commonDialog.alert({ title: 'Error', content: resp.data.message, type: 'error' })
|
|
|
|
commonDialog.alert({ title: 'Error', content: resp.data.message, type: 'error' })
|
|
|
|
});
|
|
|
|
});
|
|
|
@ -5610,109 +5655,15 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}).result.then(function () {
|
|
|
|
}).result.then(function () {
|
|
|
|
$state.reload();
|
|
|
|
|
|
|
|
commonDialog.alert({
|
|
|
|
commonDialog.alert({
|
|
|
|
title: 'Success',
|
|
|
|
title: 'Success',
|
|
|
|
content: 'Modify successfully',
|
|
|
|
content: 'Modify successfully',
|
|
|
|
type: 'success'
|
|
|
|
type: 'success'
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
$scope.loadPartnerInfo();
|
|
|
|
})
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// 卡支付apply
|
|
|
|
$scope.showMoreMerchantInfo = false;
|
|
|
|
|
|
|
|
$scope.hideMerchantInfo = function () {
|
|
|
|
|
|
|
|
$scope.showMoreMerchantInfo = !$scope.showMoreMerchantInfo;
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
$scope.loadSubMerchantInfos = function () {
|
|
|
|
|
|
|
|
$http.get('/sys/partners/' + $scope.partner.client_moniker + '/list_sub_applices', { params: {} }).then(function (resp) {
|
|
|
|
|
|
|
|
$scope.subMerchantInfos = resp.data;
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
// $http.get('/sys/partners/' + $scope.partner.client_moniker + '/list_rpay_sub_applices', {params: {}}).then(function (resp) {
|
|
|
|
|
|
|
|
// $scope.subRpayMerchantInfos = resp.data;
|
|
|
|
|
|
|
|
// });
|
|
|
|
|
|
|
|
//
|
|
|
|
|
|
|
|
// $http.get('/sys/partners/' + $scope.partner.client_moniker + '/list_yeepay_sub_applices', {params: {}}).then(function (resp) {
|
|
|
|
|
|
|
|
// $scope.subYeepayMerchantInfos = resp.data;
|
|
|
|
|
|
|
|
// });
|
|
|
|
|
|
|
|
$http.get('/sys/partners/' + $scope.partner.client_moniker + '/queryMWMerchantIdStatus').then(function (resp) {
|
|
|
|
|
|
|
|
$scope.partner.cardInfo = resp.data;
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
$scope.updateSubMerchantId = function (merchant_app_id) {
|
|
|
|
|
|
|
|
$uibModal.open({
|
|
|
|
|
|
|
|
templateUrl: '/static/payment/partner/templates/update_apply_wx_sub_merchant_id.html',
|
|
|
|
|
|
|
|
controller: 'updateApplyWxSubMerchantIdCtrl',
|
|
|
|
|
|
|
|
resolve: {
|
|
|
|
|
|
|
|
merchantInfo: $scope.partner,
|
|
|
|
|
|
|
|
merchantIds: ['$http', '$stateParams', function ($http) {
|
|
|
|
|
|
|
|
return $http.get('/sys/partners/' + $scope.partner.client_moniker + '/get_merchant_ids');
|
|
|
|
|
|
|
|
}],
|
|
|
|
|
|
|
|
subMerchantInfo: ['$http', '$stateParams', function ($http) {
|
|
|
|
|
|
|
|
return $http.get('/sys/partners/' + $scope.partner.client_moniker + '/get_merchant_ids/' + merchant_app_id);
|
|
|
|
|
|
|
|
}]
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}).result.then(function () {
|
|
|
|
|
|
|
|
$scope.loadSubMerchantInfos();
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
$scope.useRpaySubMerchantId = function (sub_merchant_id) {
|
|
|
|
|
|
|
|
$http.put('/sys/partners/' + $scope.partner.client_moniker + '/rpay_payment_config', { rpay_enterprise_id: sub_merchant_id }).then(function (resp) {
|
|
|
|
|
|
|
|
commonDialog.alert({
|
|
|
|
|
|
|
|
title: 'Success',
|
|
|
|
|
|
|
|
content: 'Modify Rpay+ Sub Merchant ID successfully',
|
|
|
|
|
|
|
|
type: 'success'
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
$state.reload();
|
|
|
|
|
|
|
|
}, function (resp) {
|
|
|
|
|
|
|
|
commonDialog.alert({ title: 'Error', content: resp.data.message, type: 'error' })
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
$scope.useYeepaySubMerchantId = function (sub_merchant_id) {
|
|
|
|
|
|
|
|
$http.put('/sys/partners/' + $scope.partner.client_moniker + '/yeepay_payment_config', { yeepay_sub_merchant_id: sub_merchant_id }).then(function (resp) {
|
|
|
|
|
|
|
|
commonDialog.alert({
|
|
|
|
|
|
|
|
title: 'Success',
|
|
|
|
|
|
|
|
content: 'Modify Yeepay Sub Merchant ID successfully',
|
|
|
|
|
|
|
|
type: 'success'
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
$state.reload();
|
|
|
|
|
|
|
|
}, function (resp) {
|
|
|
|
|
|
|
|
commonDialog.alert({ title: 'Error', content: resp.data.message, type: 'error' })
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
/*$scope.applyWxSubMerchantId = function () {
|
|
|
|
|
|
|
|
$uibModal.open({
|
|
|
|
|
|
|
|
templateUrl: '/static/payment/partner/templates/apply_wx_sub_merchant_id.html',
|
|
|
|
|
|
|
|
controller: 'applyWxSubMerchantIdCtrl',
|
|
|
|
|
|
|
|
resolve: {
|
|
|
|
|
|
|
|
subMerchantInfo: function () {
|
|
|
|
|
|
|
|
return $scope.partner;
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
merchantIds: ['$http', '$stateParams', function ($http) {
|
|
|
|
|
|
|
|
return $http.get('/sys/partners/' + $scope.partner.client_moniker + '/get_merchant_ids');
|
|
|
|
|
|
|
|
}]
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}).result.then(function () {
|
|
|
|
|
|
|
|
$scope.loadSubMerchantInfos();
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
};*/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$scope.applyWxSubMerchantId = function () {
|
|
|
|
|
|
|
|
$uibModal.open({
|
|
|
|
|
|
|
|
templateUrl: '/static/payment/partner/templates/new_apply_wx_sub_merchant_id.html',
|
|
|
|
|
|
|
|
controller: 'newApplyWxSubMerchantIdCtrl',
|
|
|
|
|
|
|
|
resolve: {
|
|
|
|
|
|
|
|
subMerchantInfo: function () {
|
|
|
|
|
|
|
|
return $scope.partner;
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
merchantIds: ['$http', '$stateParams', function ($http) {
|
|
|
|
|
|
|
|
return $http.get('/sys/partners/' + $scope.partner.client_moniker + '/get_merchant_ids');
|
|
|
|
|
|
|
|
}]
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}).result.then(function () {
|
|
|
|
|
|
|
|
$scope.loadSubMerchantInfos();
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$scope.applyMWSubMerchantId = function () {
|
|
|
|
$scope.applyMWSubMerchantId = function () {
|
|
|
|
$http.get('/sys/partners/' + $scope.partner.client_moniker + '/query/mw_info').then(function (resp) {
|
|
|
|
$http.get('/sys/partners/' + $scope.partner.client_moniker + '/query/mw_info').then(function (resp) {
|
|
|
|
commonDialog.confirm({
|
|
|
|
commonDialog.confirm({
|
|
|
@ -5726,69 +5677,130 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
|
|
|
|
content: 'Apply Merchant Warrior Sub Merchant ID successfully',
|
|
|
|
content: 'Apply Merchant Warrior Sub Merchant ID successfully',
|
|
|
|
type: 'success'
|
|
|
|
type: 'success'
|
|
|
|
});
|
|
|
|
});
|
|
|
|
$scope.partner.cardInfo = res.data;
|
|
|
|
$scope.cardInfo = res.data;
|
|
|
|
}, function (resp) {
|
|
|
|
}, function (resp) {
|
|
|
|
commonDialog.alert({ title: 'Error', content: resp.data.message, type: 'error' });
|
|
|
|
commonDialog.alert({ title: 'Error', content: resp.data.message, type: 'error' });
|
|
|
|
})
|
|
|
|
})
|
|
|
|
})
|
|
|
|
})
|
|
|
|
});
|
|
|
|
});
|
|
|
|
};
|
|
|
|
};
|
|
|
|
$scope.applyRpaySubMerchantId = function () {
|
|
|
|
|
|
|
|
$uibModal.open({
|
|
|
|
// $scope.showMoreMerchantInfo = false;
|
|
|
|
templateUrl: '/static/payment/partner/templates/apply_rpay_sub_merchant_id.html',
|
|
|
|
// $scope.hideMerchantInfo = function () {
|
|
|
|
controller: 'applyRpaySubMerchantIdCtrl',
|
|
|
|
// $scope.showMoreMerchantInfo = !$scope.showMoreMerchantInfo;
|
|
|
|
resolve: {
|
|
|
|
// };
|
|
|
|
subMerchantInfo: function () {
|
|
|
|
// $scope.updateSubMerchantId = function (merchant_app_id) {
|
|
|
|
return $scope.partner;
|
|
|
|
// $uibModal.open({
|
|
|
|
}
|
|
|
|
// templateUrl: '/static/payment/partner/templates/update_apply_wx_sub_merchant_id.html',
|
|
|
|
}
|
|
|
|
// controller: 'updateApplyWxSubMerchantIdCtrl',
|
|
|
|
}).result.then(function () {
|
|
|
|
// resolve: {
|
|
|
|
$scope.loadSubMerchantInfos();
|
|
|
|
// merchantInfo: $scope.partner,
|
|
|
|
})
|
|
|
|
// merchantIds: ['$http', '$stateParams', function ($http) {
|
|
|
|
};
|
|
|
|
// return $http.get('/sys/partners/' + $scope.partner.client_moniker + '/get_merchant_ids');
|
|
|
|
$scope.applyYeepaySubMerchantId = function () {
|
|
|
|
// }],
|
|
|
|
$uibModal.open({
|
|
|
|
// subMerchantInfo: ['$http', '$stateParams', function ($http) {
|
|
|
|
templateUrl: '/static/payment/partner/templates/apply_yeepay_sub_merchant_id.html',
|
|
|
|
// return $http.get('/sys/partners/' + $scope.partner.client_moniker + '/get_merchant_ids/' + merchant_app_id);
|
|
|
|
controller: 'applyYeepaySubMerchantIdCtrl',
|
|
|
|
// }]
|
|
|
|
resolve: {
|
|
|
|
// }
|
|
|
|
subMerchantInfo: function () {
|
|
|
|
// }).result.then(function () {
|
|
|
|
return $scope.partner;
|
|
|
|
// $scope.loadSubMerchantInfos();
|
|
|
|
}
|
|
|
|
// })
|
|
|
|
}
|
|
|
|
// }
|
|
|
|
}).result.then(function () {
|
|
|
|
// $scope.useRpaySubMerchantId = function (sub_merchant_id) {
|
|
|
|
$scope.loadSubMerchantInfos();
|
|
|
|
// $http.put('/sys/partners/' + $scope.partner.client_moniker + '/rpay_payment_config', { rpay_enterprise_id: sub_merchant_id }).then(function (resp) {
|
|
|
|
})
|
|
|
|
// commonDialog.alert({
|
|
|
|
};
|
|
|
|
// title: 'Success',
|
|
|
|
$scope.addYeepaySubMerchantId = function () {
|
|
|
|
// content: 'Modify Rpay+ Sub Merchant ID successfully',
|
|
|
|
$uibModal.open({
|
|
|
|
// type: 'success'
|
|
|
|
templateUrl: '/static/payment/partner/templates/add_yeepay_sub_merchant_id.html',
|
|
|
|
// });
|
|
|
|
controller: 'addYeepaySubMerchantIdCtrl',
|
|
|
|
// $state.reload();
|
|
|
|
resolve: {
|
|
|
|
// }, function (resp) {
|
|
|
|
subMerchantInfo: function () {
|
|
|
|
// commonDialog.alert({ title: 'Error', content: resp.data.message, type: 'error' })
|
|
|
|
return $scope.partner;
|
|
|
|
// });
|
|
|
|
}
|
|
|
|
// }
|
|
|
|
}
|
|
|
|
// $scope.useYeepaySubMerchantId = function (sub_merchant_id) {
|
|
|
|
}).result.then(function () {
|
|
|
|
// $http.put('/sys/partners/' + $scope.partner.client_moniker + '/yeepay_payment_config', { yeepay_sub_merchant_id: sub_merchant_id }).then(function (resp) {
|
|
|
|
$scope.loadSubMerchantInfos();
|
|
|
|
// commonDialog.alert({
|
|
|
|
})
|
|
|
|
// title: 'Success',
|
|
|
|
};
|
|
|
|
// content: 'Modify Yeepay Sub Merchant ID successfully',
|
|
|
|
$scope.updateYeepaySubMerchantId = function (sub_merchant_id) {
|
|
|
|
// type: 'success'
|
|
|
|
$uibModal.open({
|
|
|
|
// });
|
|
|
|
templateUrl: '/static/payment/partner/templates/update_yeepay_sub_merchant_id.html',
|
|
|
|
// $state.reload();
|
|
|
|
controller: 'updateYeepaySubMerchantIdCtrl',
|
|
|
|
// }, function (resp) {
|
|
|
|
resolve: {
|
|
|
|
// commonDialog.alert({ title: 'Error', content: resp.data.message, type: 'error' })
|
|
|
|
subMerchantInfo: function () {
|
|
|
|
// });
|
|
|
|
return $scope.partner;
|
|
|
|
// }
|
|
|
|
},
|
|
|
|
// $scope.applyWxSubMerchantId = function () {
|
|
|
|
subMerchantId: function () {
|
|
|
|
// $uibModal.open({
|
|
|
|
return sub_merchant_id;
|
|
|
|
// templateUrl: '/static/payment/partner/templates/apply_wx_sub_merchant_id.html',
|
|
|
|
}
|
|
|
|
// controller: 'applyWxSubMerchantIdCtrl',
|
|
|
|
}
|
|
|
|
// resolve: {
|
|
|
|
}).result.then(function () {
|
|
|
|
// subMerchantInfo: function () {
|
|
|
|
$scope.loadSubMerchantInfos();
|
|
|
|
// return $scope.partner;
|
|
|
|
})
|
|
|
|
// },
|
|
|
|
};
|
|
|
|
// merchantIds: ['$http', '$stateParams', function ($http) {
|
|
|
|
$scope.loadSubMerchantInfos();
|
|
|
|
// return $http.get('/sys/partners/' + $scope.partner.client_moniker + '/get_merchant_ids');
|
|
|
|
|
|
|
|
// }]
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// }).result.then(function () {
|
|
|
|
|
|
|
|
// $scope.loadSubMerchantInfos();
|
|
|
|
|
|
|
|
// })
|
|
|
|
|
|
|
|
// };
|
|
|
|
|
|
|
|
// $scope.applyRpaySubMerchantId = function () {
|
|
|
|
|
|
|
|
// $uibModal.open({
|
|
|
|
|
|
|
|
// templateUrl: '/static/payment/partner/templates/apply_rpay_sub_merchant_id.html',
|
|
|
|
|
|
|
|
// controller: 'applyRpaySubMerchantIdCtrl',
|
|
|
|
|
|
|
|
// resolve: {
|
|
|
|
|
|
|
|
// subMerchantInfo: function () {
|
|
|
|
|
|
|
|
// return $scope.partner;
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// }).result.then(function () {
|
|
|
|
|
|
|
|
// $scope.loadSubMerchantInfos();
|
|
|
|
|
|
|
|
// })
|
|
|
|
|
|
|
|
// };
|
|
|
|
|
|
|
|
// $scope.applyYeepaySubMerchantId = function () {
|
|
|
|
|
|
|
|
// $uibModal.open({
|
|
|
|
|
|
|
|
// templateUrl: '/static/payment/partner/templates/apply_yeepay_sub_merchant_id.html',
|
|
|
|
|
|
|
|
// controller: 'applyYeepaySubMerchantIdCtrl',
|
|
|
|
|
|
|
|
// resolve: {
|
|
|
|
|
|
|
|
// subMerchantInfo: function () {
|
|
|
|
|
|
|
|
// return $scope.partner;
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// }).result.then(function () {
|
|
|
|
|
|
|
|
// $scope.loadSubMerchantInfos();
|
|
|
|
|
|
|
|
// })
|
|
|
|
|
|
|
|
// };
|
|
|
|
|
|
|
|
// $scope.addYeepaySubMerchantId = function () {
|
|
|
|
|
|
|
|
// $uibModal.open({
|
|
|
|
|
|
|
|
// templateUrl: '/static/payment/partner/templates/add_yeepay_sub_merchant_id.html',
|
|
|
|
|
|
|
|
// controller: 'addYeepaySubMerchantIdCtrl',
|
|
|
|
|
|
|
|
// resolve: {
|
|
|
|
|
|
|
|
// subMerchantInfo: function () {
|
|
|
|
|
|
|
|
// return $scope.partner;
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// }).result.then(function () {
|
|
|
|
|
|
|
|
// $scope.loadSubMerchantInfos();
|
|
|
|
|
|
|
|
// })
|
|
|
|
|
|
|
|
// };
|
|
|
|
|
|
|
|
// $scope.updateYeepaySubMerchantId = function (sub_merchant_id) {
|
|
|
|
|
|
|
|
// $uibModal.open({
|
|
|
|
|
|
|
|
// templateUrl: '/static/payment/partner/templates/update_yeepay_sub_merchant_id.html',
|
|
|
|
|
|
|
|
// controller: 'updateYeepaySubMerchantIdCtrl',
|
|
|
|
|
|
|
|
// resolve: {
|
|
|
|
|
|
|
|
// subMerchantInfo: function () {
|
|
|
|
|
|
|
|
// return $scope.partner;
|
|
|
|
|
|
|
|
// },
|
|
|
|
|
|
|
|
// subMerchantId: function () {
|
|
|
|
|
|
|
|
// return sub_merchant_id;
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
// }).result.then(function () {
|
|
|
|
|
|
|
|
// $scope.loadSubMerchantInfos();
|
|
|
|
|
|
|
|
// })
|
|
|
|
|
|
|
|
// };
|
|
|
|
}]);
|
|
|
|
}]);
|
|
|
|
app.controller('applyWxSubMerchantIdCtrl', ['$scope', '$http', '$uibModal', '$state', 'subMerchantInfo', '$filter', 'merchantIds', 'commonDialog', function ($scope, $http, $uibModal, $state, subMerchantInfo, $filter, merchantIds, commonDialog) {
|
|
|
|
app.controller('applyWxSubMerchantIdCtrl', ['$scope', '$http', '$uibModal', '$state', 'subMerchantInfo', '$filter', 'merchantIds', 'commonDialog', function ($scope, $http, $uibModal, $state, subMerchantInfo, $filter, merchantIds, commonDialog) {
|
|
|
|
$scope.wxIndustries = angular.copy(wxMerchantIndustries);
|
|
|
|
$scope.wxIndustries = angular.copy(wxMerchantIndustries);
|
|
|
|