@@ -13,15 +13,15 @@ def _compute_destination_location_id(self):
1313 # Copy the Origin Location to the Destination Location
1414 # If it is an Internal move and the Location has is a vehicle/has a Plate
1515 type_is_internal = wiz .picking_type_id .code == "internal"
16- location_has_plate = bool (wiz .origin_location_id .l10n_pt_license_plate )
16+ location_has_plate = bool (wiz .origin_location_id .license_plate )
1717 if type_is_internal and location_has_plate :
1818 wiz .destination_location_id = wiz .origin_location_id
1919
2020 @api .depends ("origin_location_id" )
21- def _compute_l10n_pt_license_plate (self ):
21+ def _compute_license_plate (self ):
2222 for wiz in self :
2323 # Set the Default License Plate configured in the Location
24- wiz .l10n_pt_license_plate = wiz .origin_location_id .l10n_pt_license_plate
24+ wiz .license_plate = wiz .origin_location_id .license_plate
2525
2626 destination_location_id = fields .Many2one (
2727 # extend to add automatic calculation
@@ -30,15 +30,14 @@ def _compute_l10n_pt_license_plate(self):
3030 readonly = False ,
3131 )
3232
33- l10n_pt_license_plate = fields .Char (
34- string = "License Plate" ,
35- compute = "_compute_l10n_pt_license_plate" ,
33+ license_plate = fields .Char (
34+ compute = "_compute_license_plate" ,
3635 store = True ,
3736 readonly = False ,
3837 )
3938
4039 def _create_picking (self ):
4140 # Extend to set License Plate
4241 picking = super ()._create_picking ()
43- picking .write ({"l10n_pt_license_plate " : self .l10n_pt_license_plate })
42+ picking .write ({"license_plate " : self .license_plate })
4443 return picking
0 commit comments