From 3fe791bfe32bb808ed8554f5dec711552ca0d1d8 Mon Sep 17 00:00:00 2001 From: Yann Papouin Date: Wed, 2 Dec 2020 23:36:47 +0100 Subject: [PATCH] [14.0][FIX] base_location: Update name when changing city's state or country --- base_location/models/res_city_zip.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/base_location/models/res_city_zip.py b/base_location/models/res_city_zip.py index 18395991e..a113160d3 100644 --- a/base_location/models/res_city_zip.py +++ b/base_location/models/res_city_zip.py @@ -35,7 +35,7 @@ class ResCityZip(models.Model): ) ] - @api.depends("name", "city_id") + @api.depends("name", "city_id", "city_id.state_id", "city_id.country_id") def _compute_new_display_name(self): for rec in self: name = [rec.name, rec.city_id.name]