|
|
|
@ -437,6 +437,21 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
|
|
|
|
|
$scope.partner.legal_representative_phone_p = $scope.partner.contact_phone_p;
|
|
|
|
|
$scope.partner.legal_representative_email = $scope.partner.contact_email;
|
|
|
|
|
$scope.partner.legal_representative_job = $scope.partner.contact_job;
|
|
|
|
|
$scope.partner.legal_representative_wechatid = $scope.partner.contact_wechatid;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$scope.partner.marketingSameAsContact = false;
|
|
|
|
|
$scope.checkMarketingSameAsContact = function (){
|
|
|
|
|
$scope.partner.marketingSameAsContact = !($scope.partner.marketingSameAsContact);
|
|
|
|
|
if($scope.partner.marketingSameAsContact) {
|
|
|
|
|
$scope.partner.marketing_person = $scope.partner.contact_person;
|
|
|
|
|
$scope.partner.marketing_phone_a = $scope.partner.contact_phone_a;
|
|
|
|
|
$scope.partner.marketing_phone_c = $scope.partner.contact_phone_c;
|
|
|
|
|
$scope.partner.marketing_phone_p = $scope.partner.contact_phone_p;
|
|
|
|
|
$scope.partner.marketing_email = $scope.partner.contact_email;
|
|
|
|
|
$scope.partner.marketing_job = $scope.partner.contact_job;
|
|
|
|
|
$scope.partner.marketing_wechatid = $scope.partner.contact_wechatid;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -630,7 +645,7 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
|
|
|
|
|
$scope.partner.company_phone = '+' + $scope.partner.company_phone_c + ($scope.partner.company_phone_a || '') + $scope.partner.company_phone_p;
|
|
|
|
|
$scope.partner.contact_phone = '+' + $scope.partner.contact_phone_c + ($scope.partner.contact_phone_a || '') + $scope.partner.contact_phone_p;
|
|
|
|
|
$scope.partner.legal_representative_phone = '+' + $scope.partner.legal_representative_phone_c + ( $scope.partner.legal_representative_phone_a || '') + $scope.partner.legal_representative_phone_p;
|
|
|
|
|
|
|
|
|
|
$scope.partner.marketing_phone = '+' + $scope.partner.marketing_phone_c + ( $scope.partner.marketing_phone_a || '') + $scope.partner.marketing_phone_p;
|
|
|
|
|
if ($scope.partner.company_phone.indexOf(' ') != -1) {
|
|
|
|
|
alert('Company Phone can not contain space character');
|
|
|
|
|
return;
|
|
|
|
@ -643,6 +658,10 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
|
|
|
|
|
alert('Representative phone can not contain space character');
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
if ($scope.partner.marketing_phone.indexOf(' ') != -1) {
|
|
|
|
|
alert('Marketing phone can not contain space character');
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
if ($scope.partner.contact_email.indexOf(' ') != -1) {
|
|
|
|
|
alert('Contact email Phone can not contain space character');
|
|
|
|
|
return;
|
|
|
|
@ -651,6 +670,10 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
|
|
|
|
|
alert('Representative email Phone can not contain space character');
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
if ($scope.partner.marketing_email.indexOf(' ') != -1) {
|
|
|
|
|
alert('Marketing email Phone can not contain space character');
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
if ($scope.partner.suburb.indexOf(' ') != -1) {
|
|
|
|
|
alert('suburb can not contain two and more continuous space characters');
|
|
|
|
|
return;
|
|
|
|
@ -1290,6 +1313,14 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
|
|
|
|
|
$scope.partner.legal_representative_phone = $scope.partner.representativeInfo.phone;
|
|
|
|
|
$scope.partner.legal_representative_email = $scope.partner.representativeInfo.email;
|
|
|
|
|
$scope.partner.legal_representative_job = $scope.partner.representativeInfo.job_title;
|
|
|
|
|
|
|
|
|
|
$scope.partner.marketing_person = $scope.partner.representativeInfo.marketing_person;
|
|
|
|
|
$scope.partner.marketing_phone = $scope.partner.representativeInfo.marketing_phone;
|
|
|
|
|
$scope.partner.marketing_email = $scope.partner.representativeInfo.marketing_email;
|
|
|
|
|
$scope.partner.marketing_job = $scope.partner.representativeInfo.marketing_job_title;
|
|
|
|
|
|
|
|
|
|
$scope.partner.legal_representative_wechatid = $scope.partner.representativeInfo.wechatid;
|
|
|
|
|
$scope.partner.marketing_wechatid = $scope.partner.representativeInfo.marketing_wechatid;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function hasRole() {
|
|
|
|
@ -1401,6 +1432,19 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
|
|
|
|
|
$scope.partner.legal_representative_phone = $scope.partner.contact_phone;
|
|
|
|
|
$scope.partner.legal_representative_email = $scope.partner.contact_email;
|
|
|
|
|
$scope.partner.legal_representative_job = $scope.partner.contact_job;
|
|
|
|
|
$scope.partner.legal_representative_wechatid = $scope.partner.contact_wechatid;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$scope.partner.marketingSameAsContact = false;
|
|
|
|
|
$scope.checkMarketingSameAsContact = function (){
|
|
|
|
|
$scope.partner.marketingSameAsContact = !($scope.partner.marketingSameAsContact);
|
|
|
|
|
if($scope.partner.marketingSameAsContact) {
|
|
|
|
|
$scope.partner.marketing_person = $scope.partner.contact_person;
|
|
|
|
|
$scope.partner.marketing_phone = $scope.partner.contact_phone;
|
|
|
|
|
$scope.partner.marketing_email = $scope.partner.contact_email;
|
|
|
|
|
$scope.partner.marketing_job = $scope.partner.contact_job;
|
|
|
|
|
$scope.partner.marketing_wechatid = $scope.partner.contact_wechatid;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -3107,6 +3151,22 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
|
|
|
|
|
$scope.partner.legal_representative_phone_p = $scope.partner.contact_phone_p;
|
|
|
|
|
$scope.partner.legal_representative_email = $scope.partner.contact_email;
|
|
|
|
|
$scope.partner.legal_representative_job = $scope.partner.contact_job;
|
|
|
|
|
$scope.partner.legal_representative_wechatid = $scope.partner.contact_wechatid;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$scope.partner.marketingSameAsContact = false;
|
|
|
|
|
$scope.checkMarketingSameAsContact = function (){
|
|
|
|
|
$scope.partner.marketingSameAsContact = !($scope.partner.marketingSameAsContact);
|
|
|
|
|
if($scope.partner.marketingSameAsContact) {
|
|
|
|
|
$scope.partner.marketing_person = $scope.partner.contact_person;
|
|
|
|
|
$scope.partner.marketing_phone_a = $scope.partner.contact_phone_a;
|
|
|
|
|
$scope.partner.marketing_phone_c = $scope.partner.contact_phone_c;
|
|
|
|
|
$scope.partner.marketing_phone_p = $scope.partner.contact_phone_p;
|
|
|
|
|
$scope.partner.marketing_email = $scope.partner.contact_email;
|
|
|
|
|
$scope.partner.marketing_job = $scope.partner.contact_job;
|
|
|
|
|
$scope.partner.marketing_wechatid = $scope.partner.contact_wechatid;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -3165,6 +3225,7 @@ define(['angular', 'decimal', 'static/commons/commons', 'uiBootstrap', 'uiRouter
|
|
|
|
|
$scope.partner.company_phone = '+' + $scope.partner.company_phone_c + ($scope.partner.company_phone_a || '') + $scope.partner.company_phone_p;
|
|
|
|
|
$scope.partner.contact_phone = '+' + $scope.partner.contact_phone_c + ($scope.partner.contact_phone_a || '') + $scope.partner.contact_phone_p;
|
|
|
|
|
$scope.partner.legal_representative_phone = '+' + $scope.partner.legal_representative_phone_c + ( $scope.partner.legal_representative_phone_a || '') + $scope.partner.legal_representative_phone_p;
|
|
|
|
|
$scope.partner.marketing_phone = '+' + $scope.partner.marketing_phone_c + ( $scope.partner.marketing_phone_a || '') + $scope.partner.marketing_phone_p;
|
|
|
|
|
|
|
|
|
|
if ($scope.partner.company_phone.indexOf(' ') != -1) {
|
|
|
|
|
alert('Company Phone can not contain space character');
|
|
|
|
|