From b74d0fabbd2042b866f3a5f06fc24509755babcd Mon Sep 17 00:00:00 2001 From: Steve Blamey Date: Fri, 14 Jul 2017 14:16:43 +0100 Subject: [PATCH] Fix scrolling of selector targets [again] --- assets/js/lib/functions.js | 2 ++ .../common/templates/elements/selector_list_targets.tpl | 8 +++++--- .../erp/order/sales_order/resources/css/sales_order.less | 7 ++++++- 3 files changed, 13 insertions(+), 4 deletions(-) diff --git a/assets/js/lib/functions.js b/assets/js/lib/functions.js index fe894b51..aaa9c3d8 100755 --- a/assets/js/lib/functions.js +++ b/assets/js/lib/functions.js @@ -144,6 +144,8 @@ function check_if_table_needs_scroll_bar() { } } + // Scroll selected targets in modules/common/templates/elements/selected_targets.tpl + $('#targets').height($('#view_page').height() - $('#selected-items-header').height() - 5); } function refresh_current_page (url) { diff --git a/modules/common/templates/elements/selector_list_targets.tpl b/modules/common/templates/elements/selector_list_targets.tpl index 616802ee..64fecb5a 100755 --- a/modules/common/templates/elements/selector_list_targets.tpl +++ b/modules/common/templates/elements/selector_list_targets.tpl @@ -62,7 +62,8 @@ {include file='elements/cancelForm.tpl' cancel_action='cancel'}
- {view_section heading="Selected Items"} +
+ {view_section heading="Selected Items"}
@@ -88,12 +89,13 @@
- {/view_section} + {/view_section} {view_section dont_prettify="true" heading="Selected $title [Remove All]"} +
-
+
{include file="elements/selected_targets.tpl"}
diff --git a/modules/public_pages/erp/order/sales_order/resources/css/sales_order.less b/modules/public_pages/erp/order/sales_order/resources/css/sales_order.less index c4e63c30..add5a950 100755 --- a/modules/public_pages/erp/order/sales_order/resources/css/sales_order.less +++ b/modules/public_pages/erp/order/sales_order/resources/css/sales_order.less @@ -80,4 +80,9 @@ select.tax_rate { #SOrder_status.cancelled { background-color: yellow; border-radius: 5px; -} \ No newline at end of file +} + +/* soproductselectors > select_targets */ +#selected-items-header { + display:inline-block; width:100%; +}