Skip to content
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
1 change: 1 addition & 0 deletions openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20262,6 +20262,7 @@ components:
TotalChargesWithTaxes:
$ref: '#/components/schemas/NegotiatedRateCharges_TotalChargesWithTaxes'
description: 'Negotiated Rate Charges Container. For tiered rates and promotional discounts, if a particular shipment based on zone, origin, destination or even shipment size doesn''t qualify for the existing discount then no negotiated rates container will be returned. Published rates will be the applicable rate.'
nullable: true
xml:
name: NegotiatedRateCharges
NegotiatedRateCharges_ItemizedCharges:
Expand Down
1 change: 1 addition & 0 deletions openapi/Rating.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5012,6 +5012,7 @@ components:
even shipment size doesn't qualify for the existing discount then no negotiated
rates container will be returned. Published rates will be the applicable rate.
maximum: 1
nullable: true
NegotiatedRateCharges_ItemizedCharges:
type: object
required:
Expand Down
10 changes: 5 additions & 5 deletions src/Api/Model/RateResponseRatedShipment.php
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ public function isInitialized($property): bool
/**
* Negotiated Rate Charges Container. For tiered rates and promotional discounts, if a particular shipment based on zone, origin, destination or even shipment size doesn't qualify for the existing discount then no negotiated rates container will be returned. Published rates will be the applicable rate.
*
* @var RatedShipmentNegotiatedRateCharges
* @var RatedShipmentNegotiatedRateCharges|null
*/
protected $negotiatedRateCharges;
/**
Expand Down Expand Up @@ -529,20 +529,20 @@ public function setTotalChargesWithTaxes(RatedShipmentTotalChargesWithTaxes $tot
/**
* Negotiated Rate Charges Container. For tiered rates and promotional discounts, if a particular shipment based on zone, origin, destination or even shipment size doesn't qualify for the existing discount then no negotiated rates container will be returned. Published rates will be the applicable rate.
*
* @return RatedShipmentNegotiatedRateCharges
* @return RatedShipmentNegotiatedRateCharges|null
*/
public function getNegotiatedRateCharges(): RatedShipmentNegotiatedRateCharges
public function getNegotiatedRateCharges(): ?RatedShipmentNegotiatedRateCharges
{
return $this->negotiatedRateCharges;
}
/**
* Negotiated Rate Charges Container. For tiered rates and promotional discounts, if a particular shipment based on zone, origin, destination or even shipment size doesn't qualify for the existing discount then no negotiated rates container will be returned. Published rates will be the applicable rate.
*
* @param RatedShipmentNegotiatedRateCharges $negotiatedRateCharges
* @param RatedShipmentNegotiatedRateCharges|null $negotiatedRateCharges
*
* @return self
*/
public function setNegotiatedRateCharges(RatedShipmentNegotiatedRateCharges $negotiatedRateCharges): self
public function setNegotiatedRateCharges(?RatedShipmentNegotiatedRateCharges $negotiatedRateCharges): self
{
$this->initialized['negotiatedRateCharges'] = true;
$this->negotiatedRateCharges = $negotiatedRateCharges;
Expand Down
10 changes: 8 additions & 2 deletions src/Api/Normalizer/RateResponseRatedShipmentNormalizer.php
Original file line number Diff line number Diff line change
Expand Up @@ -116,10 +116,13 @@ public function denormalize(mixed $data, string $type, string $format = null, ar
$object->setTotalChargesWithTaxes($this->denormalizer->denormalize($data['TotalChargesWithTaxes'], \ShipStream\Ups\Api\Model\RatedShipmentTotalChargesWithTaxes::class, 'json', $context));
unset($data['TotalChargesWithTaxes']);
}
if (\array_key_exists('NegotiatedRateCharges', $data)) {
if (\array_key_exists('NegotiatedRateCharges', $data) && $data['NegotiatedRateCharges'] !== null) {
$object->setNegotiatedRateCharges($this->denormalizer->denormalize($data['NegotiatedRateCharges'], \ShipStream\Ups\Api\Model\RatedShipmentNegotiatedRateCharges::class, 'json', $context));
unset($data['NegotiatedRateCharges']);
}
elseif (\array_key_exists('NegotiatedRateCharges', $data) && $data['NegotiatedRateCharges'] === null) {
$object->setNegotiatedRateCharges(null);
}
if (\array_key_exists('RatedPackage', $data)) {
$values_4 = [];
foreach ($data['RatedPackage'] as $value_4) {
Expand Down Expand Up @@ -336,10 +339,13 @@ public function denormalize($data, $type, $format = null, array $context = [])
$object->setTotalChargesWithTaxes($this->denormalizer->denormalize($data['TotalChargesWithTaxes'], \ShipStream\Ups\Api\Model\RatedShipmentTotalChargesWithTaxes::class, 'json', $context));
unset($data['TotalChargesWithTaxes']);
}
if (\array_key_exists('NegotiatedRateCharges', $data)) {
if (\array_key_exists('NegotiatedRateCharges', $data) && $data['NegotiatedRateCharges'] !== null) {
$object->setNegotiatedRateCharges($this->denormalizer->denormalize($data['NegotiatedRateCharges'], \ShipStream\Ups\Api\Model\RatedShipmentNegotiatedRateCharges::class, 'json', $context));
unset($data['NegotiatedRateCharges']);
}
elseif (\array_key_exists('NegotiatedRateCharges', $data) && $data['NegotiatedRateCharges'] === null) {
$object->setNegotiatedRateCharges(null);
}
if (\array_key_exists('RatedPackage', $data)) {
$values_4 = [];
foreach ($data['RatedPackage'] as $value_4) {
Expand Down