credit fixes

This commit is contained in:
Kyle Spearrin 2019-02-20 20:37:27 -05:00
parent fb3afbdc76
commit 041cf1268d
3 changed files with 16 additions and 8 deletions

View File

@ -15,17 +15,20 @@
</div>
-->
</div>
<div class="row">
<div class="form-group col-4">
<label for="creditAmount">{{'amount' | i18n}}</label>
<div class="input-group mb-3">
<div class="input-group-prepend"><span class="input-group-text">$USD</span></div>
<input id="creditAmount" class="form-control" type="text" name="CreditAmount" [(ngModel)]="creditAmount"
(blur)="formatAmount()" required>
<div class="form-group">
<div class="row">
<div class="col-4">
<label for="creditAmount">{{'amount' | i18n}}</label>
<div class="input-group">
<div class="input-group-prepend"><span class="input-group-text">$USD</span></div>
<input id="creditAmount" class="form-control" type="text" name="CreditAmount" [(ngModel)]="creditAmount"
(blur)="formatAmount()" required>
</div>
</div>
</div>
<small class="form-text text-muted">{{'creditDelayed' | i18n}}</small>
</div>
<button type="submit" class="btn btn-primary btn-submit" [disabled]="form.loading">
<button type="submit" class="btn btn-primary btn-submit" [disabled]="form.loading || ppLoading">
<i class="fa fa-spinner fa-spin" title="{{'loading' | i18n}}"></i>
<span>{{'submit' | i18n}}</span>
</button>

View File

@ -37,6 +37,7 @@ export class AddCreditComponent implements OnInit {
ppButtonFormAction = WebConstants.paypal.buttonActionProduction;
ppButtonBusinessId = WebConstants.paypal.businessIdProduction;
ppButtonCustomField: string;
ppLoading = false;
subject: string;
formPromise: Promise<any>;
@ -71,6 +72,7 @@ export class AddCreditComponent implements OnInit {
if (this.method === PaymentMethodType.PayPal) {
this.ppButtonFormRef.nativeElement.submit();
this.ppLoading = true;
return;
}
try {

View File

@ -1506,6 +1506,9 @@
"message": "Amount",
"description": "Dollar amount, or quantity."
},
"creditDelayed": {
"message": "Added credit will appear on your account after the payment has been fully processed. Some payment methods are delayed and can take longer to process than others."
},
"makeSureEnoughCredit": {
"message": "Please make sure that your account has enough credit available for this purchase. If your account does not have enough credit available, your default payment method on file will be used for the difference. You can add credit to your account from the Billing page."
},