From 4dde30f9f9e45ad334e3efd072f13778dec319db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=84=E7=84=B1?= Date: Mon, 8 Jan 2024 16:28:49 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9sf=E8=A1=A8=E6=A0=BC=E6=A0=B7?= =?UTF-8?q?=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../static/src/scss/custom_style.scss | 18 ++++++++++++------ sf_sale/static/js/setTableWidth.js | 5 +++-- sf_tool_management/static/src/change.scss | 6 +----- 3 files changed, 16 insertions(+), 13 deletions(-) diff --git a/jikimo_frontend/static/src/scss/custom_style.scss b/jikimo_frontend/static/src/scss/custom_style.scss index eddf019b..2b1c6cfc 100644 --- a/jikimo_frontend/static/src/scss/custom_style.scss +++ b/jikimo_frontend/static/src/scss/custom_style.scss @@ -132,11 +132,11 @@ td.o_required_modifier { //font-weight: bold; } -//.text-truncate { -// overflow: unset !important; -// text-overflow: unset !important; -// white-space: nowrap!important; -//} +.text-truncate { + overflow: unset !important; + text-overflow: unset !important; + //white-space: nowrap!important; +} .o_list_renderer .o_list_table tbody > tr > td:not(.o_list_record_selector):not(.o_handle_cell):not(.o_list_button):not(.o_list_record_remove) { white-space: nowrap !important; @@ -425,7 +425,13 @@ div:has(.o_required_modifier) > label::before { .o_list_renderer .o_list_table thead .o_list_number_th { text-align:left; } - +.o_list_renderer .o_list_table tbody > tr > td:not(.o_list_record_selector).o_list_number { + text-align: left; +} .o_list_renderer .flex-row-reverse { flex-direction: unset!important; +} + +.o_list_renderer .flex-row-reverse > .text-end { + text-align: left!important; } \ No newline at end of file diff --git a/sf_sale/static/js/setTableWidth.js b/sf_sale/static/js/setTableWidth.js index 7cae3950..6e494214 100644 --- a/sf_sale/static/js/setTableWidth.js +++ b/sf_sale/static/js/setTableWidth.js @@ -11,15 +11,16 @@ function setTableWidth() { const tbody_tr = dom.find('tbody').children('tr') dom.find('thead').children('tr').children().each(function () { $('#widthTest').text($(this).text()) - const width = $('#widthTest').width() + const width = $('#widthTest').width() + 10 const i = $(this).index() - console.log(111) tbody_tr.each(function () { if($(this).children().length > 2) { $(this).children().eq(i).css('min-width', width + 'px') } }) }) + const resizeEvent = new Event('resize'); + window.dispatchEvent(resizeEvent); } $(function () { diff --git a/sf_tool_management/static/src/change.scss b/sf_tool_management/static/src/change.scss index a4e64f97..4c857c8c 100644 --- a/sf_tool_management/static/src/change.scss +++ b/sf_tool_management/static/src/change.scss @@ -11,11 +11,7 @@ } .o_form_view .o_field_widget .o_list_renderer { - width: calc(100% - 64px) !important; + width: 100%!important; margin:0 auto; overflow: auto; } - -.o_list_renderer .o_list_table tbody > tr > td:not(.o_list_record_selector).o_list_number { - text-align: left; -} \ No newline at end of file