Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EP-2525 - Hide unnecessary fields #1120

Merged
merged 8 commits into from
Dec 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/app/branded/step-1/branded-checkout-step-1.tpl.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
ng-if="!$ctrl.loadingProductConfig && !$ctrl.errorLoadingProductConfig"
use-v3="$ctrl.useV3"
>

</product-config-form>
<div ng-if="$ctrl.errorLoadingProductConfig" class="alert alert-danger" role="alert">
<p translate='LOADING_ERROR' translate-values="{loadData: '$ctrl.loadData()'}" translate-compile></p>
Expand All @@ -30,7 +29,8 @@ <h3 class="panel-name" translate>{{'YOUR_INFORMATION'}}</h3>
on-submit="$ctrl.onContactInfoSubmit(success)"
donor-details="$ctrl.donorDetails"
radio-station-api-url="$ctrl.radioStationApiUrl"
radio-station-radius="$ctrl.radioStationRadius">
radio-station-radius="$ctrl.radioStationRadius"
use-v3="$ctrl.useV3">
</contact-info>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ <h4 class="panel-title border-bottom-small mt0 pt-" translate>
</div><!-- // panel -->
</div>
</div>
<div class="panel panel-default give-modal-panel">
<div ng-if="$ctrl.useV3 !== 'true'" class="panel panel-default give-modal-panel">
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One concern I realize I have with this is our datadog tests. These rely on the special instructions in order to work. We'll need to make sure that our tests are pointing at a v2 branded checkout.

<h4 class="panel-title border-bottom-small mt" translate>
{{'OPTIONAL'}}
</h4>
Expand Down
3 changes: 2 additions & 1 deletion src/common/components/contactInfo/contactInfo.component.js
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,7 @@ export default angular
donorDetails: '=?',
onSubmit: '&',
radioStationApiUrl: '<',
radioStationRadius: '<'
radioStationRadius: '<',
useV3: '<'
}
})
13 changes: 6 additions & 7 deletions src/common/components/contactInfo/contactInfo.tpl.html
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@

<form novalidate ng-keyup="$event.key === 'Enter' && $ctrl.submitDetails()" name="$ctrl.detailsForm">
<div class="mb">
<h4 class="panel-title border-bottom-small visible" translate>{{'YOUR_INFORMATION'}}</h4>
<h4 ng-if="$ctrl.useV3 !== 'true'" class="panel-title border-bottom-small visible" translate>{{'YOUR_INFORMATION'}}</h4>
wrandall22 marked this conversation as resolved.
Show resolved Hide resolved
<div class="row">
<div class="col-sm-4">
<div class="form-group is-required" ng-class="{'has-error': ($ctrl.detailsForm.nameGivenName | showErrors)}">
Expand All @@ -65,7 +65,7 @@ <h4 class="panel-title border-bottom-small visible" translate>{{'YOUR_INFORMAT
</div>
</div>
</div>
<div class="col-sm-2">
<div ng-if="$ctrl.useV3 !== 'true'" class="col-sm-2">
<div class="form-group" ng-class="{'has-error': ($ctrl.detailsForm.nameMiddleInitial | showErrors)}">
<label>
<span translate>{{'MIDDLE_ABBREV'}}</span>
Expand Down Expand Up @@ -99,7 +99,7 @@ <h4 class="panel-title border-bottom-small visible" translate>{{'YOUR_INFORMAT
</div>
</div>
</div>
<div class="col-sm-2">
<div ng-if="$ctrl.useV3 !== 'true'" class="col-sm-2">
<div class="form-group">
<label>
<span translate>{{'SUFFIX'}}</span>
Expand All @@ -121,7 +121,7 @@ <h4 class="panel-title border-bottom-small visible" translate>{{'YOUR_INFORMAT

</div>

<div class="row" ng-if="$ctrl.donorDetails['donor-type'] === 'Household'">
<div class="row" ng-if="$ctrl.donorDetails['donor-type'] === 'Household' && $ctrl.useV3 !== 'true'">
wrandall22 marked this conversation as resolved.
Show resolved Hide resolved
<div class="col-sm-4">
<div class="form-group" ng-class="{'has-error': ($ctrl.detailsForm.spouseGivenName | showErrors)}">
<label>
Expand Down Expand Up @@ -218,8 +218,7 @@ <h4 class="panel-title border-bottom-small visible" translate>{{'MAILING_ADDRE
address="$ctrl.donorDetails.mailingAddress"
parent-form="$ctrl.detailsForm"
on-address-changed="$ctrl.loadRadioStations()"
address-disabled="$ctrl.donorDetails.staff"
>
address-disabled="$ctrl.donorDetails.staff">
</address-form>
</div>

Expand All @@ -239,7 +238,7 @@ <h4 class="panel-title border-bottom-small visible" translate>{{'CONTACT_INFO'
</div>
</div>
</div>
<div class="col-sm-6">
<div ng-if="$ctrl.useV3 !== 'true'" class="col-sm-6">
<div class="form-group" ng-class="{'has-error': ($ctrl.detailsForm.phoneNumber | showErrors)}">
<label>
<span translate>{{'PHONE'}}</span>
Expand Down