diff options
| author | Zog | 2017-12-21 15:47:29 +0100 |
|---|---|---|
| committer | Alban Peignier | 2017-12-21 21:58:56 +0100 |
| commit | be8afa7aa3fd1c8922a4e02e16cdfef698b3df26 (patch) | |
| tree | 390a90c9b243050259dd9e6ffe2e28e3943176e9 /app/views/referentials | |
| parent | 09f335237d39e9cce1d4051355d16f2781806cbd (diff) | |
| download | chouette-core-be8afa7aa3fd1c8922a4e02e16cdfef698b3df26.tar.bz2 | |
Refs #5361 @1H; Make company optional in Lines form
And handle the case when it is nil in the views
Diffstat (limited to 'app/views/referentials')
| -rw-r--r-- | app/views/referentials/show.html.slim | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/views/referentials/show.html.slim b/app/views/referentials/show.html.slim index 9852fb0a3..96755359c 100644 --- a/app/views/referentials/show.html.slim +++ b/app/views/referentials/show.html.slim @@ -68,7 +68,7 @@ ), \ TableBuilderHelper::Column.new( \ key: 'companies.name', \ - attribute: Proc.new { |n| n.try(:company).try(:name) } \ + attribute: Proc.new { |n| n&.company&.name || "-" } \ ) \ ], links: [:show], |
