master
yuan 7 years ago
parent 4f28d86abd
commit d8bf233bd3

@ -296,6 +296,7 @@ public class SimpleClientApplyServiceImpl implements SimpleClientApplyService {
sysClient.put("merchant_id", availableMerchant.getMerchantId());
sysClient.put("sub_merchant_id",tempSubMerchantId);
sysClient.put("common_sub_merchant_id",1);
sysClient.put("skip_clearing",1);
sysClient.put("credential_code", RandomStringUtils.random(32, true, true));
clientMapper.save(sysClient);
@ -334,6 +335,7 @@ public class SimpleClientApplyServiceImpl implements SimpleClientApplyService {
JSONObject clientConfig = new JSONObject();
clientConfig.put("client_id",clientId);
clientConfig.put("skip_clearing",1);
clientConfig.put("client_moniker",clientMoniker);
clientConfig.put("clean_days",apply.getIntValue("clean_days"));
clientConfig.put("common_sub_merchant_id",1);

@ -232,14 +232,23 @@
<i class="fa fa-dot-circle-o" ng-if="!mail_confirm"></i>
</div>
<div class="start_text" style="cursor: default">
<p><a class="text-primary" ng-if="sendMailCount == 0">
<span ng-class="{'text-gray':mail_confirm,'text-primary':!mail_confirm}">&nbsp;Verify your email address <em>{{currentUser.client.contact_email}}</em></span>
<i role="button" class="fa fa-paper-plane-o" ng-if="!mail_confirm" ng-click="checkEmail()"></i>
</a>
<a class="text-primary" ng-if="sendMailCount > 0">
<span ng-class="{'text-gray':mail_confirm,'text-primary':!mail_confirm}">&nbsp;Send to <em>{{currentUser.client.contact_email}}</em></span>
<i role="button" class="fa fa-paper-plane-o" ng-if="!mail_confirm" ng-click="checkEmail()"></i>
<p ng-if="!mail_confirm"><a class="text-primary" ng-if="sendMailCount == 0">
<span ng-class="{'text-gray':mail_confirm,'text-primary':!mail_confirm}">&nbsp;Verify your email address <em class="text-info">{{currentUser.client.contact_email}}</em></span>
<i role="button" class="fa fa-paper-plane-o"
ng-click="checkEmail()"></i>
</a>
<a class="text-primary" ng-if="sendMailCount > 0">
<span ng-class="{'text-gray':mail_confirm,'text-primary':!mail_confirm}">&nbsp;Send to <em class="text-info">{{currentUser.client.contact_email}}</em></span>
<i role="button" class="fa fa-paper-plane-o"
ng-click="checkEmail()"></i>
</a>
</p>
<p ng-if="mail_confirm">
<a class="text-primary">
<span ng-class="{'text-gray':mail_confirm,'text-primary':!mail_confirm}">&nbsp;Your email address <em class="text-info">{{currentUser.client.contact_email}}</em> has been verified</span>
<i class="fa fa-paper-plane-o"></i>
</a>
</p>
</div>
@ -252,7 +261,7 @@
</div>
<div class="start_text">
<p ng-if="!commitPartnerInfo">&nbsp;
<a href="" ui-sref="basic.payment_info_edit" ng-class="{'text-gray':commitPartnerInfo,'text-primary':!commitPartnerInfo}">
<a href="" ui-sref="basic" ng-class="{'text-gray':commitPartnerInfo,'text-primary':!commitPartnerInfo}">
Complete your company information
</a>
</p>

@ -15,10 +15,6 @@ define(['angular', 'decimal', 'uiRouter', 'ngBootSwitch', 'ngFileUpload'], funct
return $http.get('/client/partner_info');
}]
}
}).state('basic.payment_info_edit', {
url: '/payment/edit',
templateUrl: '/static/payment/partner/templates/client_partner_edit.html',
controller: 'clientPaymentInfoEditCtrl'
}).state('basic.payment_info', {
url: '/payment',
templateUrl: '/static/payment/partner/templates/client_payment_info.html',
@ -59,46 +55,11 @@ define(['angular', 'decimal', 'uiRouter', 'ngBootSwitch', 'ngFileUpload'], funct
controller: 'clientDeviceCtrl'
})
}]);
app.controller('clientPartnerDetailCtrl', ['$scope', '$http', 'partner','industryMap','businessStructuresMap', function ($scope, $http, partner,industryMap,businessStructuresMap) {
app.controller('clientPartnerDetailCtrl', ['$scope', '$http', 'partner','industryMap','businessStructuresMap','commonDialog','Upload','$state', function ($scope, $http, partner,industryMap,businessStructuresMap,commonDialog,Upload,$state) {
$scope.business_structures = businessStructuresMap.configs();
$scope.industries = industryMap.configs();
$scope.partner = partner.data;
//修改邮箱
$scope.updateEmail = function () {
$http.put('/client/partner_info/compliance_audit').then(
);
};
$scope.commitToCompliance = function () {
$http.get('/client/partner_info/compliance/files').then(function (resp) {
$scope.complianceFiles = resp.data;
if($scope.complianceFiles.client_id_file == null||$scope.complianceFiles.client_bank_file == null || $scope.complianceFiles.client_company_file == null){
alert("请前去完善合规资料,再进行提交");
return;
}
if($scope.partner.business_structure == null ||$scope.partner.logo_url == null || $scope.partner.description == null || (($scope.partner.store_photo == null || $scope.partner.company_photo == null) && $scope.currentUser.client.company_website == null)){
alert("请前去完善商户资料,再进行提交");
return;
}
if(($scope.partner.business_structure == "Company" && $scope.partner.acn == null) || ($scope.partner.business_structure != "Company" && $scope.partner.abn == null)){
alert("请前去完善商户资料,再进行提交");
return;
}
if(!$scope.partner.mail_confirm){
alert("请验证邮箱后,再进行提交");
return;
}
$http.post('/client/partner_info/compliance_audit').then(
);
});
}
}]);
app.controller('clientPaymentInfoEditCtrl', ['$scope', '$http','industryMap', 'commonDialog','$state','Upload',function ($scope, $http,industryMap,commonDialog,$state,Upload) {
/* $scope.loadClient = function () {
$http.get('/client/partner_info').then(function (resp) {
$scope.partner = resp.data;
})
};*/
$scope.partner.partner_type = $scope.partner.website ? 'website' : 'photo';
$scope.uploadLogo = function (file) {
if (file != null) {
@ -199,6 +160,36 @@ define(['angular', 'decimal', 'uiRouter', 'ngBootSwitch', 'ngFileUpload'], funct
commonDialog.alert({title: 'Error', content: resp.data.message, type: 'error'})
});
};
//修改邮箱
$scope.updateEmail = function () {
$http.put('/client/partner_info/compliance_audit').then(
);
};
$scope.commitToCompliance = function () {
$http.get('/client/partner_info/compliance/files').then(function (resp) {
$scope.complianceFiles = resp.data;
if($scope.complianceFiles.client_id_file == null||$scope.complianceFiles.client_bank_file == null || $scope.complianceFiles.client_company_file == null){
commonDialog.alert({title: 'Message', content: '请前去完善合规资料,再进行提交!', type: 'info'});
return;
}
if($scope.partner.business_structure == null ||$scope.partner.logo_url == null || $scope.partner.description == null || (($scope.partner.store_photo == null || $scope.partner.company_photo == null) && $scope.currentUser.client.company_website == null)){
commonDialog.alert({title: 'Message', content: '请前去完善商户资料,再进行提交!', type: 'info'});
return;
}
if(($scope.partner.business_structure == "Company" && $scope.partner.acn == null) || ($scope.partner.business_structure != "Company" && $scope.partner.abn == null)){
commonDialog.alert({title: 'Message', content: '请前去完善商户资料,再进行提交!', type: 'info'});
return;
}
if(!$scope.partner.mail_confirm){
commonDialog.alert({title: 'Message', content: '请验证邮箱后,再进行提交!', type: 'info'});
return;
}
$http.post('/client/partner_info/compliance_audit').then(
commonDialog.alert({title: 'Success', content: '已提交至合规,请耐心等待审核!', type: 'info'})
);
});
}
}]);
app.controller('clientComplianceFilesCtrl', ['$scope', '$http', '$rootScope', 'commonDialog', '$state', 'Upload', 'file', function ($scope, $http, $rootScope, commonDialog, $state, Upload, file) {

@ -23,7 +23,7 @@
<span ng-if="partner.approve_result==3">(自助申请)待审核(材料已提交)</span>
</b>
</h3>
<div class="btn-group pull-right" role="group" aria-label="...">
<div class="btn-group pull-right" role="group" aria-label="..." ng-show="partner.approve_result == 2">
<button type="button" class="btn btn-danger" ng-click="commitToCompliance()">Commit to Compliance
</button>
</div>
@ -43,110 +43,370 @@
<a ui-sref=".clearing_config">Clearing Config</a>
</li>
<li ui-sref-active="active">
<li ui-sref-active="active" ng-show="partner.source==4">
<a ui-sref=".compliance_files">Compliance files</a>
</li>
</ul>
<div class="tab-content" ui-view>
<div ng-if="(partner.source == 4 && partner.approve_result !=2) || partner.source != 4">
<div class="panel panel-default">
<div class="panel-heading">
Partner Basic Information
</div>
<div class="panel-body">
<div class="form-horizontal">
<div class="form-group">
<label class="control-label col-sm-2">Partner Code</label>
<div class="panel panel-default">
<div class="panel-heading">
Partner Basic Information
</div>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.client_moniker"></p>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Company Name</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.company_name"></p>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Short Name</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.short_name"></p>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Business Name</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.business_name"></p>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Business Structure</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.business_structure|business_structure"></p>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">*Logo</label>
<div class="col-sm-10">
<img class="col-sm-3 col-xs-5" ng-src="{{partner.logo_url}}">
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">ABN</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.abn"></p>
</div>
</div>
<div class="form-group" ng-if="partner.acn">
<label class="control-label col-sm-2">ACN</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.acn"></p>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Industry</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.industry|partner_industry"></p>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Sector</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.sector"></p>
</div>
</div>
<div class="form-group" ng-if="partner.company_photo">
<label class="control-label col-sm-2">Shop Photo</label>
<div class="col-sm-3 col-xs-5"><em>1:</em>&nbsp;
<div>
<a class="thumbnail" target="_blank" ng-href="{{partner.company_photo}}">
<img ng-src="{{partner.company_photo}}" style="max-height: 100px">
</a>
</div>
</div>
<div class="col-sm-3 col-xs-5" ng-if="partner.store_photo"><em>2:</em>&nbsp;
<div>
<a class="thumbnail" target="_blank" ng-href="{{partner.store_photo}}" >
<img ng-src="{{partner.store_photo}}" style="max-height: 100px">
</a>
</div>
</div>
</div>
<div class="form-group" ng-if="partner.company_website">
<label class="control-label col-sm-2">Website</label>
<div class="col-sm-10">
<a class="form-control-static" target="_blank" ng-bind="partner.company_website"
href="https://{{partner.company_website}}" ></a>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Service Phone</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.company_phone||'-'"></p>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Description</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.description"></p>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Remark</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.remark"></p>
</div>
</div>
</div>
</div>
</div>
<!--end 商户基本资料-->
<div class="panel panel-default">
<div class="panel-heading">Partner Contact Information</div>
<div class="panel-body">
<div class="form-horizontal">
<div class="form-group">
<label class="control-label col-sm-2">Contact Person</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.contact_person"></p>
</div>
</div>
<div class="form-group col-sm-6">
<label class="control-label col-sm-4">Phone</label>
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.contact_phone"></p>
</div>
</div>
<div class="form-group col-sm-6">
<label class="control-label col-sm-4">E-mail</label>
<div class="col-sm-8">
<p class="form-control-static" ng-show="!ctrl.editEmail">
<span ng-if="!ctrl.editEmail" ng-bind="partner.contact_email"></span>
<a role="button" ng-click="ctrl.editEmail=true" ng-show="!ctrl.editEmail"><i class="fa fa-edit"></i></a>
</p>
<div class="input-group col-sm-8" ng-if="ctrl.editEmail">
<input type="text" class="form-control" ng-model="partner.contact_email"
title="partner contact_email">
<div class="input-group-btn">
<button class="btn btn-success" ng-click="updateEmail(1);ctrl.editEmail=false">
<i class="fa fa-check"></i>
</button>
</div>
<div class="input-group-btn">
<button class="btn btn-danger" ng-click="ctrl.editEmail=false">
<i class="fa fa-remove"></i>
</button>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<!--end 商户联系资料-->
<div class="panel panel-default">
<div class="panel-heading">Address Information</div>
<div class="panel-body">
<div class="form-horizontal">
<div class="form-group col-sm-6">
<label class="control-label col-sm-4">Address</label>
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.address"></p>
</div>
</div>
<div class="form-group col-sm-6">
<label class="control-label col-sm-4">Suburb</label>
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.suburb"></p>
</div>
</div>
<div class="form-group col-sm-6">
<label class="control-label col-sm-4">PostCode</label>
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.postcode"></p>
</div>
</div>
<div class="form-group col-sm-6">
<label class="control-label col-sm-4">State</label>
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.state"></p>
</div>
</div>
<div class="form-group col-sm-6">
<label class="control-label col-sm-4">Counrty</label>
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.country"></p>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="panel panel-default" ng-if="partner.source == 4 && partner.approve_result ==2">
<div class="panel-heading">Partner Basic Information</div>
<div class="panel-body">
<div class="form-horizontal">
<form class="form-horizontal" novalidate name="partnerForm">
<div class="form-group">
<label class="control-label col-sm-2">Partner Code</label>
<div class="col-sm-10">
<label class="control-label col-sm-2">* Partner Code</label>
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.client_moniker"></p>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Company Name</label>
<div class="col-sm-10">
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.company_name"></p>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Short Name</label>
<div class="col-sm-10">
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.short_name"></p>
</div>
</div>
<div class="form-group">
<div class="form-group"
ng-class="{'has-error':partnerForm.business_name.$invalid && partnerForm.business_name.$dirty}">
<label class="control-label col-sm-2">Business Name</label>
<div class="col-sm-10">
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.business_name"></p>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Business Structure</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.business_structure|business_structure"></p>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Logo</label>
<div class="col-sm-10">
<img class="col-sm-3 col-xs-5" ng-src="{{partner.logo_url}}">
<div class="form-group"
ng-class="{'has-error':partnerForm.business_structure.$invalid && partnerForm.business_structure.$dirty}">
<label class="control-label col-sm-2" for="business-structure-input">Business Structure</label>
<div class="col-sm-8">
<select class="form-control" name="business_structure" ng-model="partner.business_structure"
id="business-structure-input" required
ng-options="structure.value as structure.label for structure in business_structures">
<option value="">Please Choose</option>
</select>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">ABN</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.abn"></p>
<div class="form-group" ng-if="!partner.parent_client_id || ('00110'|withRole)">
<label class="control-label col-sm-2">*Logo</label>
<div class="col-sm-8">
<div class="form-control-static">
<button class="btn btn-success" type="button" ngf-select="uploadLogo($file)"
accept="image/*" ngf-max-size="1MB">
<i class="fa fa-upload"></i> Upload Logo
</button>
</div>
<uib-progressbar value="logoProgress.value" ng-if="logoProgress"></uib-progressbar>
<img ng-src="{{partner.logo_url}}" ng-if="partner.logo_url" style="height: 100px;">
</div>
</div>
<div class="form-group" ng-if="partner.acn">
<label class="control-label col-sm-2">ACN</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.acn"></p>
<div class="form-group"
ng-class="{'has-error':partnerForm.abn.$invalid && partnerForm.abn.$dirty}" ng-if="partner.business_structure != 'Company'">
<label class="control-label col-sm-2" for="abn-input">ABN</label>
<div class="col-sm-8">
<input class="form-control" ng-model="partner.abn" type="text" name="abn"
id="abn-input"
maxlength="20" required>
<div ng-messages="partnerForm.abn.$error" ng-if="partnerForm.abn.$dirty">
<p class="small text-danger" ng-message="required">Less Than 20
Characters(including symbols and spaces)</p>
</div>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Industry</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.industry|partner_industry"></p>
<div class="form-group"
ng-class="{'has-error':partnerForm.acn.$invalid && partnerForm.acn.$dirty}" ng-if="partner.business_structure == 'Company'">
<label class="control-label col-sm-2" for="acn-input">ACN</label>
<div class="col-sm-8">
<input class="form-control" ng-model="partner.acn" type="text" name="acn"
id="acn-input" maxlength="20" required>
<div ng-messages="partnerForm.acn.$error" ng-if="partnerForm.acn.$dirty">
<p class="small text-danger" ng-message="required">Less Than 20
Characters(including symbols and spaces)</p>
</div>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Sector</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.sector"></p>
<div class="form-group" ng-if="!partner.parent_client_id || ('00110'|withRole)"
ng-class="{'has-error':partnerForm.partner_type.$invalid && partnerForm.partner_type.$dirty}">
<label class="control-label col-sm-2" for="partner-type-select">* Photo/Website</label>
<div class="col-sm-8">
<select class="form-control" ng-model="partner.partner_type"
id="partner-type-select" required
name="partner_type">
<option value="">Please Choose</option>
<option value="photo">Photo</option>
<option value="companyWebsite">Website</option>
</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 company website</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>
</div>
</div>
</div>
<div class="form-group" ng-if="partner.company_photo">
<label class="control-label col-sm-2">Shop Photo</label>
<div class="col-sm-3 col-xs-5"><em>1:</em>&nbsp;
<div>
<a class="thumbnail" target="_blank" ng-href="{{partner.company_photo}}">
<img ng-src="{{partner.company_photo}}" style="max-height: 100px">
</a>
<div class="form-group"
ng-if="partner.partner_type == 'photo'">
<label class="control-label col-sm-2">* Shop Photo</label>
<div class="col-sm-5">
<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-5">
</div>
<div class="col-sm-3 col-xs-5" ng-if="partner.store_photo"><em>2:</em>&nbsp;
<div>
<a class="thumbnail" target="_blank" ng-href="{{partner.store_photo}}" >
<img ng-src="{{partner.store_photo}}" style="max-height: 100px">
</a>
<div class="col-sm-5">
<div class="form-control-static"><em>2:</em>&nbsp;
<button class="btn btn-primary" type="button"
ngf-select="uploadStorePhoto($file)" accept="image/*"
ngf-max-size="2MB">
<i class="fa fa-upload"></i> Upload Shop Photo2
</button>
</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 col-sm-5">
</div>
</div>
<div class="form-group" ng-if="partner.company_website">
<label class="control-label col-sm-2">Website</label>
<div class="col-sm-10">
<a class="form-control-static" target="_blank" ng-bind="partner.company_website"
href="https://{{partner.company_website}}" ></a>
<div class="form-group"
ng-if="partner.partner_type == 'companyWebsite' && (!partner.parent_client_id || ('00110'|withRole))"
ng-class="{'has-error':partnerForm.company_website.$invalid && partnerForm.company_website.$dirty}">
<label class="control-label col-sm-2" for="company_website-input">* Website</label>
<div class="col-sm-8">
<input type="text" name="company_website" class="form-control"
ng-model="partner.company_website"
id="company_website-input" required maxlength="200">
<div ng-messages="partnerForm.company_website.$error"
ng-if="partnerForm.company_website.$dirty">
<p class="small text-danger" ng-message="required">Required Field</p>
<p class="small text-danger" ng-message="required">Less Than 200
Characters(including symbols and spaces)</p>
</div>
</div>
</div>
<div class="form-group">
@ -156,113 +416,30 @@
<p class="form-control-static" ng-bind="partner.company_phone||'-'"></p>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Description</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.description"></p>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Remark</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.remark"></p>
</div>
</div>
</div>
</div>
</div>
<!--end 商户基本资料-->
<div class="panel panel-default">
<div class="panel-heading">Partner Contact Information</div>
<div class="panel-body">
<div class="form-horizontal">
<div class="form-group">
<label class="control-label col-sm-2">Contact Person</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.contact_person"></p>
</div>
</div>
<div class="form-group col-sm-6">
<label class="control-label col-sm-4">Phone</label>
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.contact_phone"></p>
</div>
</div>
<div class="form-group col-sm-6">
<label class="control-label col-sm-4">E-mail</label>
<div class="form-group"
ng-class="{'has-error':partnerForm.description.$invalid && partnerForm.description.$dirty}">
<label class="control-label col-sm-2" for="desc-input">Description</label>
<div class="col-sm-8">
<p class="form-control-static" ng-show="!ctrl.editEmail">
<span ng-if="!ctrl.editEmail" ng-bind="partner.contact_email"></span>
<a role="button" ng-click="ctrl.editEmail=true" ng-show="!ctrl.editEmail"><i class="fa fa-edit"></i></a>
</p>
<div class="input-group col-sm-8" ng-if="ctrl.editEmail">
<input type="text" class="form-control" ng-model="partner.contact_email"
title="partner contact_email">
<div class="input-group-btn">
<button class="btn btn-success" ng-click="updateEmail(1);ctrl.editEmail=false">
<i class="fa fa-check"></i>
</button>
</div>
<div class="input-group-btn">
<button class="btn btn-danger" ng-click="ctrl.editEmail=false">
<i class="fa fa-remove"></i>
</button>
</div>
<textarea class="form-control" ng-model="partner.description"
name="description" id="desc-input" maxlength="200" required
placeholder="Tell me about your company and the main products you sell"></textarea>
<div ng-messages="partnerForm.description.$error"
ng-if="partnerForm.description.$dirty">
<p class="small text-danger" ng-message="maxlength">Less Than 200
Characters(including symbols and spaces)</p>
</div>
</div>
</div>
</div>
</div>
</div>
<!--end 商户联系资料-->
<div class="panel panel-default">
<div class="panel-heading">Address Information</div>
<div class="panel-body">
<div class="form-horizontal">
<div class="form-group col-sm-6">
<label class="control-label col-sm-4">Address</label>
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.address"></p>
</div>
</div>
<div class="form-group col-sm-6">
<label class="control-label col-sm-4">Suburb</label>
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.suburb"></p>
</div>
</div>
<div class="form-group col-sm-6">
<label class="control-label col-sm-4">PostCode</label>
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.postcode"></p>
</div>
</div>
<div class="form-group col-sm-6">
<label class="control-label col-sm-4">State</label>
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.state"></p>
</div>
</div>
<div class="form-group col-sm-6">
<label class="control-label col-sm-4">Counrty</label>
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.country"></p>
</div>
<div class="btn-group margin-bottom margin-top">
<button class="btn btn-success" type="button" ng-click="updatePartner(partnerForm)">Save
</button>
<a class="btn btn-danger" role="button" ui-sref="^" ui-sref-opts="{reload:true}">Back</a>
</div>
</div>
</form>
</div>
</div>
<!--end 商户基本资料-->
</div>
</div>

@ -1,176 +0,0 @@
<div class="panel panel-default">
<div class="panel-heading">Partner Basic Information</div>
<div class="panel-body">
<form class="form-horizontal" novalidate name="partnerForm">
<div class="form-group">
<label class="control-label col-sm-2">* Partner Code</label>
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.client_moniker"></p>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Company Name</label>
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.company_name"></p>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Short Name</label>
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.short_name"></p>
</div>
</div>
<div class="form-group"
ng-class="{'has-error':partnerForm.business_name.$invalid && partnerForm.business_name.$dirty}">
<label class="control-label col-sm-2">Business Name</label>
<div class="col-sm-8">
<p class="form-control-static" ng-bind="partner.business_name"></p>
</div>
</div>
<div class="form-group"
ng-class="{'has-error':partnerForm.business_structure.$invalid && partnerForm.business_structure.$dirty}">
<label class="control-label col-sm-2" for="business-structure-input">Business Structure</label>
<div class="col-sm-8">
<select class="form-control" name="business_structure" ng-model="partner.business_structure"
id="business-structure-input" required
ng-options="structure.value as structure.label for structure in business_structures">
<option value="">Please Choose</option>
</select>
</div>
</div>
<div class="form-group" ng-if="!partner.parent_client_id || ('00110'|withRole)">
<label class="control-label col-sm-2">Logo</label>
<div class="col-sm-8">
<div class="form-control-static">
<button class="btn btn-success" type="button" ngf-select="uploadLogo($file)"
accept="image/*" ngf-max-size="1MB">
<i class="fa fa-upload"></i> Upload Logo
</button>
</div>
<uib-progressbar value="logoProgress.value" ng-if="logoProgress"></uib-progressbar>
<img ng-src="{{partner.logo_url}}" ng-if="partner.logo_url" style="height: 100px;">
</div>
</div>
<div class="form-group"
ng-class="{'has-error':partnerForm.abn.$invalid && partnerForm.abn.$dirty}" ng-if="partner.business_structure != 'Company'">
<label class="control-label col-sm-2" for="abn-input">ABN</label>
<div class="col-sm-8">
<input class="form-control" ng-model="partner.abn" type="text" name="abn"
id="abn-input"
maxlength="20" required>
<div ng-messages="partnerForm.abn.$error" ng-if="partnerForm.abn.$dirty">
<p class="small text-danger" ng-message="required">Less Than 20
Characters(including symbols and spaces)</p>
</div>
</div>
</div>
<div class="form-group"
ng-class="{'has-error':partnerForm.acn.$invalid && partnerForm.acn.$dirty}" ng-if="partner.business_structure == 'Company'">
<label class="control-label col-sm-2" for="acn-input">ACN</label>
<div class="col-sm-8">
<input class="form-control" ng-model="partner.acn" type="text" name="acn"
id="acn-input" maxlength="20" required>
<div ng-messages="partnerForm.acn.$error" ng-if="partnerForm.acn.$dirty">
<p class="small text-danger" ng-message="required">Less Than 20
Characters(including symbols and spaces)</p>
</div>
</div>
</div>
<div class="form-group" ng-if="!partner.parent_client_id || ('00110'|withRole)"
ng-class="{'has-error':partnerForm.partner_type.$invalid && partnerForm.partner_type.$dirty}">
<label class="control-label col-sm-2" for="partner-type-select">* Photo/Website</label>
<div class="col-sm-8">
<select class="form-control" ng-model="partner.partner_type"
id="partner-type-select" required
name="partner_type">
<option value="">Please Choose</option>
<option value="photo">Photo</option>
<option value="companyWebsite">Website</option>
</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 company website</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>
</div>
</div>
</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-5">
<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-5">
</div>
<div class="col-sm-5">
<div class="form-control-static"><em>2:</em>&nbsp;
<button class="btn btn-primary" type="button"
ngf-select="uploadStorePhoto($file)" accept="image/*"
ngf-max-size="2MB">
<i class="fa fa-upload"></i> Upload Shop Photo2
</button>
</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 col-sm-5">
</div>
</div>
<div class="form-group"
ng-if="partner.partner_type == 'companyWebsite' && (!partner.parent_client_id || ('00110'|withRole))"
ng-class="{'has-error':partnerForm.company_website.$invalid && partnerForm.company_website.$dirty}">
<label class="control-label col-sm-2" for="company_website-input">* Website</label>
<div class="col-sm-8">
<input type="text" name="company_website" class="form-control"
ng-model="partner.company_website"
id="company_website-input" required maxlength="200">
<div ng-messages="partnerForm.company_website.$error"
ng-if="partnerForm.company_website.$dirty">
<p class="small text-danger" ng-message="required">Required Field</p>
<p class="small text-danger" ng-message="required">Less Than 200
Characters(including symbols and spaces)</p>
</div>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">Service Phone</label>
<div class="col-sm-10">
<p class="form-control-static" ng-bind="partner.company_phone||'-'"></p>
</div>
</div>
<div class="form-group"
ng-class="{'has-error':partnerForm.description.$invalid && partnerForm.description.$dirty}">
<label class="control-label col-sm-2" for="desc-input">Description</label>
<div class="col-sm-8">
<textarea class="form-control" ng-model="partner.description"
name="description" id="desc-input" maxlength="200" required
placeholder="Tell me about your company and the main products you sell"></textarea>
<div ng-messages="partnerForm.description.$error"
ng-if="partnerForm.description.$dirty">
<p class="small text-danger" ng-message="maxlength">Less Than 200
Characters(including symbols and spaces)</p>
</div>
</div>
</div>
</form>
</div>
</div>
<!--end 商户基本资料-->
<div class="btn-group margin-bottom margin-top">
<button class="btn btn-success" type="button" ng-click="updatePartner(partnerForm)">Save
</button>
<a class="btn btn-danger" role="button" ui-sref="^" ui-sref-opts="{reload:true}">Back</a>
</div>
Loading…
Cancel
Save