|
|
@ -58,7 +58,7 @@ angular.module('applyPartnerApp', ['ngMessages']).controller('applyPartnerCtrl',
|
|
|
|
$scope.seconds = 6;
|
|
|
|
$scope.seconds = 6;
|
|
|
|
$scope.canClick=false;
|
|
|
|
$scope.canClick=false;
|
|
|
|
$scope.description = "Send Code";
|
|
|
|
$scope.description = "Send Code";
|
|
|
|
$scope.partner = {};
|
|
|
|
$scope.partner = {nation_code:"+61"};
|
|
|
|
$scope.bankaccount = {};
|
|
|
|
$scope.bankaccount = {};
|
|
|
|
$scope.rate = {};
|
|
|
|
$scope.rate = {};
|
|
|
|
|
|
|
|
|
|
|
@ -70,9 +70,9 @@ angular.module('applyPartnerApp', ['ngMessages']).controller('applyPartnerCtrl',
|
|
|
|
$scope.loadRoyalpayindustry();
|
|
|
|
$scope.loadRoyalpayindustry();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$scope.checkUserName = function (username) {
|
|
|
|
$scope.checkUserName = function (phone,nation_code) {
|
|
|
|
if(username != null && username != ''){
|
|
|
|
if(phone && nation_code){
|
|
|
|
$http.get('/register/account/' + $scope.partner.username+'/check').then(function (resp) {
|
|
|
|
$http.get('/register/account/check?phone='+phone+'&nation_code='+nation_code).then(function (resp) {
|
|
|
|
$scope.name_exist = false;
|
|
|
|
$scope.name_exist = false;
|
|
|
|
}, function (resp) {
|
|
|
|
}, function (resp) {
|
|
|
|
if (resp.data.status == 403){
|
|
|
|
if (resp.data.status == 403){
|
|
|
@ -83,11 +83,13 @@ angular.module('applyPartnerApp', ['ngMessages']).controller('applyPartnerCtrl',
|
|
|
|
};
|
|
|
|
};
|
|
|
|
$scope.chooseArray = new Array(true, false, false, false, false);
|
|
|
|
$scope.chooseArray = new Array(true, false, false, false, false);
|
|
|
|
$scope.changeChoose = function (index) {
|
|
|
|
$scope.changeChoose = function (index) {
|
|
|
|
angular.forEach($scope.partner, function(key, value) {
|
|
|
|
$scope.repartner = {};
|
|
|
|
if(value.trim()==''){
|
|
|
|
angular.forEach($scope.partner, function(value, key) {
|
|
|
|
$scope.partner.remove(key);
|
|
|
|
if((value+'').trim()!=''){
|
|
|
|
|
|
|
|
$scope.repartner[key] = value;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
|
|
|
$scope.partner = $scope.repartner;
|
|
|
|
$scope.chooseArray = new Array(false, false, false, false, false);
|
|
|
|
$scope.chooseArray = new Array(false, false, false, false, false);
|
|
|
|
$scope.chooseArray[index] = true;
|
|
|
|
$scope.chooseArray[index] = true;
|
|
|
|
};
|
|
|
|
};
|
|
|
@ -134,8 +136,9 @@ angular.module('applyPartnerApp', ['ngMessages']).controller('applyPartnerCtrl',
|
|
|
|
}
|
|
|
|
}
|
|
|
|
};
|
|
|
|
};
|
|
|
|
$scope.sendVerificationCode = function () {
|
|
|
|
$scope.sendVerificationCode = function () {
|
|
|
|
|
|
|
|
$scope.checkUserName($scope.partner.contact_phone,$scope.partner.nation_code)
|
|
|
|
$scope.sendPhoneCodeTime();
|
|
|
|
$scope.sendPhoneCodeTime();
|
|
|
|
$http.post('/register/info/phone/'+ $scope.partner.contact_phone +'/verify?'+'nation_code=61').then(function (resp) {
|
|
|
|
$http.post('/register/info/phone/'+ $scope.partner.contact_phone +'/verify?nation_code='+$scope.partner.nation_code).then(function (resp) {
|
|
|
|
}, function (resp) {
|
|
|
|
}, function (resp) {
|
|
|
|
$scope.resError = resp.data.message;
|
|
|
|
$scope.resError = resp.data.message;
|
|
|
|
});
|
|
|
|
});
|
|
|
|