fix: fix Location column for All Logs subgrid when viewing Asset
This commit is contained in:
parent
03dacd9957
commit
a26f16a67e
1 changed files with 5 additions and 1 deletions
|
|
@ -103,6 +103,7 @@ class AssetMasterView(WuttaFarmMasterView):
|
|||
|
||||
row_labels = {
|
||||
"message": "Log Name",
|
||||
"locations": "Location",
|
||||
}
|
||||
|
||||
row_grid_columns = [
|
||||
|
|
@ -112,7 +113,7 @@ class AssetMasterView(WuttaFarmMasterView):
|
|||
"message",
|
||||
"log_type",
|
||||
"assets",
|
||||
"location",
|
||||
"locations",
|
||||
"quantity",
|
||||
"is_group_assignment",
|
||||
]
|
||||
|
|
@ -446,6 +447,9 @@ class AssetMasterView(WuttaFarmMasterView):
|
|||
# assets
|
||||
g.set_renderer("assets", self.render_assets_for_grid)
|
||||
|
||||
# locations
|
||||
g.set_renderer("locations", self.render_assets_for_grid)
|
||||
|
||||
def render_assets_for_grid(self, log, field, value):
|
||||
assets = getattr(log, field)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue