IDEMPIERE-569 Ticket #1001758: Improve shipping configuration to support external services
* Inactive 'Package' window record * Inactive 'Package' menu record * Fix NullPointerException when freight charges is not provided during create package process
This commit is contained in:
parent
2f7e416dc1
commit
1d50a92f1d
|
@ -0,0 +1,15 @@
|
|||
SET SQLBLANKLINES ON
|
||||
SET DEFINE OFF
|
||||
|
||||
-- Sep 30, 2013 6:48:37 PM SGT
|
||||
-- IDEMPIERE-569 Ticket #1001758: Improve shipping configuration to support external services
|
||||
UPDATE AD_Menu SET IsActive='N',Updated=TO_DATE('2013-09-30 18:48:37','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Menu_ID=444
|
||||
;
|
||||
|
||||
-- Sep 30, 2013 6:48:42 PM SGT
|
||||
-- IDEMPIERE-569 Ticket #1001758: Improve shipping configuration to support external services
|
||||
UPDATE AD_Window SET IsActive='N',Updated=TO_DATE('2013-09-30 18:48:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Window_ID=319
|
||||
;
|
||||
|
||||
SELECT register_migration_script('201309301851_IDEMPIERE-569.sql') FROM dual
|
||||
;
|
|
@ -0,0 +1,12 @@
|
|||
-- Sep 30, 2013 6:48:37 PM SGT
|
||||
-- IDEMPIERE-569 Ticket #1001758: Improve shipping configuration to support external services
|
||||
UPDATE AD_Menu SET IsActive='N',Updated=TO_TIMESTAMP('2013-09-30 18:48:37','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Menu_ID=444
|
||||
;
|
||||
|
||||
-- Sep 30, 2013 6:48:42 PM SGT
|
||||
-- IDEMPIERE-569 Ticket #1001758: Improve shipping configuration to support external services
|
||||
UPDATE AD_Window SET IsActive='N',Updated=TO_TIMESTAMP('2013-09-30 18:48:42','YYYY-MM-DD HH24:MI:SS'),UpdatedBy=100 WHERE AD_Window_ID=319
|
||||
;
|
||||
|
||||
SELECT register_migration_script('201309301851_IDEMPIERE-569.sql') FROM dual
|
||||
;
|
|
@ -200,19 +200,22 @@ public class MPackage extends X_M_Package
|
|||
setIsSaturdayDelivery(shipper.isSaturdayDelivery());
|
||||
setTrackingInfo(shipper.getTrackingURL());
|
||||
|
||||
String shipperAccount = null;
|
||||
String dutiesShipperAccount = null;
|
||||
if (shipment.getFreightCharges().equals(MInOut.FREIGHTCHARGES_Prepaid) || shipment.getFreightCharges().equals(MInOut.FREIGHTCHARGES_PrepaidAndBill))
|
||||
if (shipment.getFreightCharges() != null)
|
||||
{
|
||||
shipperAccount = ShippingUtil.getSenderShipperAccount(shipper.getM_Shipper_ID(), shipper.getAD_Org_ID());
|
||||
dutiesShipperAccount = ShippingUtil.getSenderDutiesShipperAccount(shipper.getM_Shipper_ID(), shipper.getAD_Org_ID());
|
||||
String shipperAccount = null;
|
||||
String dutiesShipperAccount = null;
|
||||
if (shipment.getFreightCharges().equals(MInOut.FREIGHTCHARGES_Prepaid) || shipment.getFreightCharges().equals(MInOut.FREIGHTCHARGES_PrepaidAndBill))
|
||||
{
|
||||
shipperAccount = ShippingUtil.getSenderShipperAccount(shipper.getM_Shipper_ID(), shipper.getAD_Org_ID());
|
||||
dutiesShipperAccount = ShippingUtil.getSenderDutiesShipperAccount(shipper.getM_Shipper_ID(), shipper.getAD_Org_ID());
|
||||
}
|
||||
else
|
||||
shipperAccount = shipment.getShipperAccount();
|
||||
if (shipperAccount != null)
|
||||
setShipperAccount(shipperAccount);
|
||||
if (dutiesShipperAccount != null)
|
||||
setDutiesShipperAccount(dutiesShipperAccount);
|
||||
}
|
||||
else
|
||||
shipperAccount = shipment.getShipperAccount();
|
||||
if (shipperAccount != null)
|
||||
setShipperAccount(shipperAccount);
|
||||
if (dutiesShipperAccount != null)
|
||||
setDutiesShipperAccount(dutiesShipperAccount);
|
||||
} // MPackage
|
||||
|
||||
protected boolean beforeSave(boolean newRecord)
|
||||
|
|
Loading…
Reference in New Issue