private void FixupVendor(Vendor previousValue)
        {
            if (previousValue != null
                && previousValue.PurchaseOrderHeaders.Contains(this))
            {
                previousValue.PurchaseOrderHeaders.Remove(this);
            }

            if (Vendor != null)
            {
                if (!Vendor.PurchaseOrderHeaders.Contains(this))
                {
                    Vendor.PurchaseOrderHeaders.Add(this);
                }
                if (VendorID != Vendor.VendorID)
                {
                    VendorID = Vendor.VendorID;
                }
            }
        }
        private void FixupVendor(Vendor previousValue)
        {
            if (previousValue != null
                && previousValue.VendorAddresses.Contains(this))
            {
                previousValue.VendorAddresses.Remove(this);
            }

            if (Vendor != null)
            {
                if (!Vendor.VendorAddresses.Contains(this))
                {
                    Vendor.VendorAddresses.Add(this);
                }
                if (VendorID != Vendor.VendorID)
                {
                    VendorID = Vendor.VendorID;
                }
            }
        }