Odoo Mindscape. Understand Odoo faster. Explore modules, fields, dependencies and version differences in one place instead of digging through the source code.

Module: Sendcloud Shipping

Entity: sendcloud.parcel

Compute Method: _compute_shipment_id

View 18.0
Inputs Method Outputs
  • shipment
- for parcel in self:
-             shipment_data = safe_eval(parcel.shipment or "{}")
-             shipment_code = shipment_data.get("id")
-             domain = parcel._get_shipment_domain_by_code(shipment_code)
-             parcel.shipment_id = self.env["delivery.carrier"].search(domain, limit=1)
  • shipment_id

Back to entity