Skip to content

Commit

Permalink
Display Premium on Checkout
Browse files Browse the repository at this point in the history
  • Loading branch information
reldredge71 committed Aug 17, 2021
1 parent 7b712c8 commit abcd22a
Show file tree
Hide file tree
Showing 5 changed files with 28 additions and 4 deletions.
4 changes: 3 additions & 1 deletion src/app/branded/branded-checkout.tpl.html
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,9 @@
<branded-checkout-step-2
ng-if="$ctrl.checkoutStep === 'review'"
next="$ctrl.next()"
previous="$ctrl.previous()">
previous="$ctrl.previous()"
premium-name="$ctrl.premiumName"
item-config="$ctrl.itemConfig">
</branded-checkout-step-2>
<thank-you-summary
ng-if="$ctrl.checkoutStep === 'thankYou'"
Expand Down
4 changes: 3 additions & 1 deletion src/app/branded/step-2/branded-checkout-step-2.component.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ export default angular
templateUrl: template,
bindings: {
previous: '&',
next: '&'
next: '&',
premiumName: '<',
itemConfig: '<'
}
})
4 changes: 3 additions & 1 deletion src/app/branded/step-2/branded-checkout-step-2.tpl.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@ <h3 class="panel-name" translate>{{'REVIEW'}}</h3>
<div class="alert alert-danger" role="alert" ng-if="$ctrl.errorLoadingCart" translate="RETRY_LOAD" translate-value-retryLoadFunction="{{$ctrl.loadCart()}}"></div>
<checkout-step-3
cart-data="$ctrl.cartData"
change-step="$ctrl.changeStep(newStep)">
change-step="$ctrl.changeStep(newStep)"
premium-name="$ctrl.premiumName"
branded-checkout-item="$ctrl.itemConfig">
</checkout-step-3>
</div>
</div>
4 changes: 3 additions & 1 deletion src/app/checkout/step-3/step-3.component.js
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,8 @@ export default angular
onSubmitBtnChangeState: '&',
onSubmitted: '&',
onSubmittingOrder: '&',
submittingOrder: '<'
submittingOrder: '<',
premiumName: '<',
brandedCheckoutItem: '<'
}
})
16 changes: 16 additions & 0 deletions src/app/checkout/step-3/step-3.tpl.html
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,22 @@
</div>
</div>

<div class="mb" ng-if="!!$ctrl.brandedCheckoutItem['premium-code']">
<div class="panel panel-default">
<div class="panel-heading">
<translate>{{'PREMIUM'}}</translate>
<button id="changePremiumButton" class="btn btn-default btn-panel-head pull-right" ng-click="$ctrl.changeStep({newStep: 'premium'})" translate>{{'CHANGE'}}</button>
</div>
<div class="panel-body">
<div class="row">
<div class="col-md-12">
{{$ctrl.premiumName}}
</div>
</div>
</div>
</div>
</div>

<div class="mb">
<div class="panel panel-default">
<div class="panel-heading">
Expand Down

0 comments on commit abcd22a

Please sign in to comment.