Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/B-21935' into B-21935-int
Browse files Browse the repository at this point in the history
  • Loading branch information
deandreJones committed Feb 4, 2025
2 parents 53a4e95 + 567586b commit 606c321
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
7 changes: 5 additions & 2 deletions pkg/notifications/move_counseled.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import (
html "html/template"
text "text/template"

"github.com/dustin/go-humanize"
"github.com/gofrs/uuid"
"go.uber.org/zap"

Expand Down Expand Up @@ -97,13 +98,15 @@ func (m MoveCounseled) emails(appCtx appcontext.AppContext) ([]emailContent, err
weightRestriction = &weightRestrictionInt64
}

weightRestrictionFormatted := humanize.Comma(int64(*weightRestriction))

htmlBody, textBody, err := m.renderTemplates(appCtx, MoveCounseledEmailData{
OriginDutyLocation: originDutyLocationName,
DestinationLocation: destinationAddress,
Locator: move.Locator,
MyMoveLink: MyMoveLink,
ActualExpenseReimbursement: actualExpenseReimbursement,
WeightRestriction: weightRestriction,
WeightRestriction: weightRestrictionFormatted,
})

if err != nil {
Expand Down Expand Up @@ -142,7 +145,7 @@ type MoveCounseledEmailData struct {
Locator string
MyMoveLink string
ActualExpenseReimbursement bool
WeightRestriction *int64
WeightRestriction string
}

// RenderHTML renders the html for the email
Expand Down
4 changes: 2 additions & 2 deletions pkg/notifications/move_counseled_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -298,12 +298,12 @@ func (suite *NotificationSuite) TestMoveCounseledHTMLTemplateRenderWithWeightRes
Locator: "abc123",
MyMoveLink: MyMoveLink,
ActualExpenseReimbursement: true,
WeightRestriction: models.Int64Pointer(1500),
WeightRestriction: "1500",
}

expectedHTMLContent := `<p>*** DO NOT REPLY directly to this email ***</p>
<p>This is a confirmation that your counselor has approved move details for the assigned move code abc123 from origDutyLocation to destDutyLocation in the MilMove system.</p>
<p>Your move has been identified as going to an administratively restricted HHG weight location. Your weight restriction is 1500lbs. Be advised, you may be required to pay excess cost if you choose to move more than your weight restriction. </p>
<p>Your move has been identified as going to an administratively restricted HHG weight location. Your weight restriction is 1,500lbs. Be advised, you may be required to pay excess cost if you choose to move more than your weight restriction. </p>
<p>What this means to you:</br>
If you are doing a Personally Procured Move (PPM), you can start moving your personal property.</p>
<p><strong>Next steps for a PPM:</strong>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,7 @@ class MtoShipmentForm extends Component {
)} for this UB shipment. The weight of your UB is part of your authorized weight allowance`
: ` Your standard weight allowance is ${formatWeight(
orders.authorizedWeight,
)} total. If you are moving to an administratively restricted HHG weight location this amount may be less. `}
)} total. If you are moving to an administratively restricted HHG weight location this amount may be less`}
. You’ll be billed for any excess weight you move.
</Alert>
<Form className={formStyles.form}>
Expand Down
5 changes: 1 addition & 4 deletions src/pages/MyMove/MovingInfo.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -86,10 +86,7 @@ export class MovingInfo extends Component {
icon="weight-hanging"
headline={`Your standard weight allowance is ${formatWeight(entitlementWeight)} for this move.`}
>
<p>
If you are moving to an administratively restricted HHG weight location this amount may be less. You
will have to pay for any excess weight above this amount.
</p>
<p>If you are moving to an administratively restricted HHG weight location this amount may be less.</p>
<p>
You will have to pay for any excess weight above this allowance, so work hard to make sure you stay
within your weight limit.
Expand Down

0 comments on commit 606c321

Please sign in to comment.