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

B 21170 INT 2 - Ensure USPostRegionsCitiesID populates in a scenarios #14467

Draft
wants to merge 27 commits into
base: integrationTesting
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
b7ae188
Limit UB weight allowance based on Studen Travel order type.
brooklyn-welsh Nov 26, 2024
65c29c9
Bump nanoid from 3.3.6 to 3.3.8
dependabot[bot] Dec 18, 2024
cb75def
Remove default 0 value
TevinAdams Dec 12, 2024
77343a9
Tests added
TevinAdams Dec 12, 2024
9d76cc6
Variable name change
TevinAdams Dec 12, 2024
b00830b
Merge branch 'main' into dependabot/npm_and_yarn/nanoid-3.3.8
deandreJones Dec 18, 2024
5465f7c
Merge branch 'main' into B-21686-M
TevinAdams Dec 18, 2024
df37b01
Merge branch 'main' into B-21686-M
TevinAdams Dec 18, 2024
103813c
Merge branch 'main' into B-21686-M
WeatherfordAaron Dec 18, 2024
3966fa2
Merge branch 'main' into dependabot/npm_and_yarn/nanoid-3.3.8
deandreJones Dec 18, 2024
e54fbca
Merge branch 'main' into B-21686-M
TevinAdams Dec 18, 2024
c8256e7
Merge branch 'main' into dependabot/npm_and_yarn/nanoid-3.3.8
deandreJones Dec 18, 2024
a724ba9
Merge pull request #14429 from transcom/B-21686-M
WeatherfordAaron Dec 18, 2024
21dad2a
Merge branch 'main' into dependabot/npm_and_yarn/nanoid-3.3.8
deandreJones Dec 18, 2024
1b5fd44
Merge branch 'main' into MAIN-B-21577-student-travel-ub-limit
brooklyn-welsh Dec 18, 2024
9b86e60
Edited comparison to be consistent with other ones in the file.
brooklyn-welsh Dec 12, 2024
61d160d
Merge pull request #14368 from transcom/dependabot/npm_and_yarn/nanoi…
deandreJones Dec 18, 2024
05641d0
migrate client proxies for http-proxy-middleware 2.0 -> 3.0
ajlusk Dec 18, 2024
2c8158f
Merge branch 'main' into MAIN-B-21577-student-travel-ub-limit
WeatherfordAaron Dec 18, 2024
68705df
Merge pull request #14435 from transcom/proxyMiddlewareFix
deandreJones Dec 18, 2024
fead5a4
Merge branch 'main' into MAIN-B-21577-student-travel-ub-limit
WeatherfordAaron Dec 19, 2024
d352c1c
Merge pull request #14396 from transcom/MAIN-B-21577-student-travel-u…
WeatherfordAaron Dec 19, 2024
917a5e9
Merge branch 'main' of github.com:transcom/mymove into B-21169
r-mettler Dec 20, 2024
c06db09
ensure prime sim and API populate usPostRegionsCitiesId
ajlusk Dec 23, 2024
6a54cc0
Merge remote-tracking branch 'origin/B-21169' into B-21170
ajlusk Dec 23, 2024
7ac99f8
fix proxy issue causing inability to logout locally
ajlusk Dec 24, 2024
31c40c0
Merge branch 'B-21170' into B-21170-Integration
ajlusk Dec 24, 2024
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
2 changes: 1 addition & 1 deletion migrations/app/migrations_manifest.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1054,6 +1054,6 @@
20241204155919_update_ordering_proc.up.sql
20241204210208_retroactive_update_of_ppm_max_and_estimated_incentives_prd.up.sql
20241210143143_redefine_mto_shipment_audit_table.up.sql
20241217163231_update_duty_locations_bad_zips.up.sql
20241216170325_update_nts_enum_name.up.sql
20241217163231_update_duty_locations_bad_zips.up.sql
20241217180136_add_AK_zips_to_zip3_distances.up.sql
2 changes: 1 addition & 1 deletion pkg/handlers/primeapi/mto_shipment.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ type DeleteMTOShipmentHandler struct {
services.ShipmentDeleter
}

// Handle handler that updates a mto shipment
// Handle handler that deletes a mto shipment
func (h DeleteMTOShipmentHandler) Handle(params mtoshipmentops.DeleteMTOShipmentParams) middleware.Responder {
return h.AuditableAppContextFromRequestWithErrors(params.HTTPRequest,
func(appCtx appcontext.AppContext) (middleware.Responder, error) {
Expand Down
9 changes: 8 additions & 1 deletion pkg/handlers/primeapi/payloads/model_to_payload.go
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,8 @@ func Address(address *models.Address) *primemessages.Address {
if address == nil {
return nil
}
return &primemessages.Address{

payloadAddress := &primemessages.Address{
ID: strfmt.UUID(address.ID.String()),
StreetAddress1: &address.StreetAddress1,
StreetAddress2: address.StreetAddress2,
Expand All @@ -301,6 +302,12 @@ func Address(address *models.Address) *primemessages.Address {
County: address.County,
ETag: etag.GenerateEtag(address.UpdatedAt),
}

if address.UsPostRegionCityID != nil {
payloadAddress.UsPostRegionCitiesID = strfmt.UUID(address.UsPostRegionCityID.String())
}

return payloadAddress
}

// StorageFacility payload
Expand Down
5 changes: 5 additions & 0 deletions pkg/handlers/primeapi/payloads/payload_to_model.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ func AddressModel(address *primemessages.Address) *models.Address {
ID: uuid.FromStringOrNil(address.ID.String()),
StreetAddress2: address.StreetAddress2,
StreetAddress3: address.StreetAddress3,
County: address.County,
}
if address.StreetAddress1 != nil {
modelAddress.StreetAddress1 = *address.StreetAddress1
Expand All @@ -56,6 +57,10 @@ func AddressModel(address *primemessages.Address) *models.Address {
if address.Country != nil {
modelAddress.Country = CountryModel(address.Country)
}
usPostRegionCitiesID := uuid.FromStringOrNil(address.UsPostRegionCitiesID.String())
if usPostRegionCitiesID != uuid.Nil {
modelAddress.UsPostRegionCityID = &usPostRegionCitiesID
}
return modelAddress
}

Expand Down
8 changes: 7 additions & 1 deletion pkg/handlers/primeapiv2/payloads/model_to_payload.go
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ func Address(address *models.Address) *primev2messages.Address {
if address == nil {
return nil
}
return &primev2messages.Address{
payloadAddress := &primev2messages.Address{
ID: strfmt.UUID(address.ID.String()),
StreetAddress1: &address.StreetAddress1,
StreetAddress2: address.StreetAddress2,
Expand All @@ -232,6 +232,12 @@ func Address(address *models.Address) *primev2messages.Address {
County: address.County,
ETag: etag.GenerateEtag(address.UpdatedAt),
}

if address.UsPostRegionCityID != nil {
payloadAddress.UsPostRegionCitiesID = strfmt.UUID(address.UsPostRegionCityID.String())
}

return payloadAddress
}

// StorageFacility payload
Expand Down
5 changes: 5 additions & 0 deletions pkg/handlers/primeapiv2/payloads/payload_to_model.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ func AddressModel(address *primev2messages.Address) *models.Address {
ID: uuid.FromStringOrNil(address.ID.String()),
StreetAddress2: address.StreetAddress2,
StreetAddress3: address.StreetAddress3,
County: address.County,
}
if address.StreetAddress1 != nil {
modelAddress.StreetAddress1 = *address.StreetAddress1
Expand All @@ -56,6 +57,10 @@ func AddressModel(address *primev2messages.Address) *models.Address {
if address.Country != nil {
modelAddress.Country = CountryModel(address.Country)
}
usPostRegionCitiesID := uuid.FromStringOrNil(address.UsPostRegionCitiesID.String())
if usPostRegionCitiesID != uuid.Nil {
modelAddress.UsPostRegionCityID = &usPostRegionCitiesID
}
return modelAddress
}

Expand Down
8 changes: 7 additions & 1 deletion pkg/handlers/primeapiv3/payloads/model_to_payload.go
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,7 @@ func Address(address *models.Address) *primev3messages.Address {
if address == nil {
return nil
}
return &primev3messages.Address{
payloadAddress := &primev3messages.Address{
ID: strfmt.UUID(address.ID.String()),
StreetAddress1: &address.StreetAddress1,
StreetAddress2: address.StreetAddress2,
Expand All @@ -259,6 +259,12 @@ func Address(address *models.Address) *primev3messages.Address {
ETag: etag.GenerateEtag(address.UpdatedAt),
County: address.County,
}

if address.UsPostRegionCityID != nil {
payloadAddress.UsPostRegionCitiesID = strfmt.UUID(address.UsPostRegionCityID.String())
}

return payloadAddress
}

// PPM Destination payload
Expand Down
5 changes: 5 additions & 0 deletions pkg/handlers/primeapiv3/payloads/payload_to_model.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ func AddressModel(address *primev3messages.Address) *models.Address {
ID: uuid.FromStringOrNil(address.ID.String()),
StreetAddress2: address.StreetAddress2,
StreetAddress3: address.StreetAddress3,
County: address.County,
}
if address.StreetAddress1 != nil {
modelAddress.StreetAddress1 = *address.StreetAddress1
Expand All @@ -57,6 +58,10 @@ func AddressModel(address *primev3messages.Address) *models.Address {
if address.Country != nil {
modelAddress.Country = CountryModel(address.Country)
}
usPostRegionCitiesID := uuid.FromStringOrNil(address.UsPostRegionCitiesID.String())
if usPostRegionCitiesID != uuid.Nil {
modelAddress.UsPostRegionCityID = &usPostRegionCitiesID
}
return modelAddress
}

Expand Down
Loading
Loading