diff options
| author | Vincent Schippefilt <vsc@odoo.com> | 2019-06-25 08:03:09 +0000 |
|---|---|---|
| committer | Vincent Schippefilt <vsc@odoo.com> | 2019-06-25 08:34:11 +0000 |
| commit | 793933a1287d08c174d7ba00ed4762d1807b4923 (patch) | |
| tree | 039957729b40772bbcc0a7bd8cf3fe6a63f6ac63 | |
| parent | fbd874368a30c1665ca1410046b60cf1dd8ce31d (diff) | |
[FIX] web: fix wrapping of many2one in list view
Before this fix, the many2one text in the list view was not wrapping.
After this fix, the text will wrap according to the available space
(managed automatically by the browser).
closes odoo/odoo#34345
Signed-off-by: VincentSchippefilt <VincentSchippefilt@users.noreply.github.com>
| -rw-r--r-- | addons/web/static/src/js/views/list/list_renderer.js | 1 | ||||
| -rw-r--r-- | addons/web/static/src/scss/list_view.scss | 8 |
2 files changed, 8 insertions, 1 deletions
diff --git a/addons/web/static/src/js/views/list/list_renderer.js b/addons/web/static/src/js/views/list/list_renderer.js index cbe99715fb5..76db6727285 100644 --- a/addons/web/static/src/js/views/list/list_renderer.js +++ b/addons/web/static/src/js/views/list/list_renderer.js @@ -29,6 +29,7 @@ var FIELD_CLASSES = { integer: 'o_list_number', monetary: 'o_list_number', text: 'o_list_text', + many2one: 'o_list_many2one', }; var ListRenderer = BasicRenderer.extend({ diff --git a/addons/web/static/src/scss/list_view.scss b/addons/web/static/src/scss/list_view.scss index c64c84ee548..d1f656fc1e0 100644 --- a/addons/web/static/src/scss/list_view.scss +++ b/addons/web/static/src/scss/list_view.scss @@ -30,6 +30,10 @@ &.o_list_text { white-space: pre-wrap; } + &.o_list_many2one { + white-space: pre-wrap; + + } } tfoot { @@ -173,7 +177,9 @@ .o_list_record_remove_header, .o_handle_cell { width: 32px; } - + &>tbody>tr>td.o_list_many2one { + white-space: nowrap; + } // checkboxes in editable lists should be clickable and activate the row .o_data_row:not(.o_selected_row) .o_data_cell { .custom-checkbox:not(.o_readonly_modifier) { |
