mirror of
https://github.com/salesagility/SuiteCRM.git
synced 2025-02-21 12:46:09 +00:00
buildSelectedObjectsSpan(): moving hardcoded template into smarty template.
This commit is contained in:
parent
6b27a556e3
commit
b9d990f7fc
2 changed files with 13 additions and 1 deletions
include/ListView
|
@ -406,7 +406,15 @@ class ListViewDisplay {
|
|||
global $app_strings;
|
||||
|
||||
$displayStyle = $total > 0 ? "" : "display: none;";
|
||||
$selectedObjectSpan = "<span style='$displayStyle' id='selectedRecordsTop'>{$app_strings['LBL_LISTVIEW_SELECTED_OBJECTS']}<input style='border: 0px; background: transparent; font-size: inherit; color: inherit' type='text' id='selectCountTop' readonly name='selectCount[]' value='{$total}' /></span>";
|
||||
$template = new Sugar_Smarty();
|
||||
|
||||
$displayStyle = $total > 0 ? "" : "display: none;";
|
||||
$selectedObjectSpan = "";
|
||||
|
||||
$template->assign('DISPLAY_STYLE', $displayStyle);
|
||||
$template->assign('APP', $app_strings);
|
||||
$template->assign('TOTAL_ITEMS_SELECTED', $total);
|
||||
$selectedObjectSpan = $template->fetch('include/ListView/ListViewSelectObjects.tpl');
|
||||
|
||||
return $selectedObjectSpan;
|
||||
}
|
||||
|
|
4
include/ListView/ListViewSelectObjects.tpl
Normal file
4
include/ListView/ListViewSelectObjects.tpl
Normal file
|
@ -0,0 +1,4 @@
|
|||
<span style='{$DISPLAY_STYLE}' id='selectedRecordsTop'>
|
||||
{$APP.LBL_LISTVIEW_SELECTED_OBJECTS}
|
||||
<input style='border: 0px; background: transparent; font-size: inherit; color: inherit' type='text' id='selectCountTop' type='text' id='selectCountTop' readonly name='selectCount[]' value='{$TOTAL_ITEMS_SELECTED}' />
|
||||
</span>
|
Loading…
Reference in a new issue