In workflow/engine/templates/cases/casesListExtJs.php:122, change from:
Code: Select all$oHeadPublisher->assign( 'enableEnterprise', $enableEnterprise ); //sending the page size
/*----------------------------------********---------------------------------*/
To:
Code: Select all$oHeadPublisher->assign( 'enableEnterprise', $enableEnterprise ); //sending the page size
//added by ABB to display last search in cases list search box:
$searchText = isset($_SESSION['last_cases_search']) ? $_SESSION['last_cases_search'] : '';
$oHeadPublisher->assign( 'lastSearchText', $searchText );
//end ABB edit
/*----------------------------------********---------------------------------*/
In workflow/engine/methods/cases/proxCasesList.php:31, change from:
Code: Select all$search = isset($_REQUEST["search"]) ? $_REQUEST["search"] : "";
$action = isset($_GET["action"]) ? $_GET["action"] : (isset($_REQUEST["action"]) ? $_REQUEST["action"] : "todo");
To:
Code: Select all$search = isset($_REQUEST["search"]) ? $_REQUEST["search"] : "";
//added by ABB to save last search text as a session variable:
if (trim($search) != '') {
$_SESSION['last_cases_search'] = $search;
}
$action = isset($_GET["action"]) ? $_GET["action"] : (isset($_REQUEST["action"]) ? $_REQUEST["action"] : "todo");
In workflow/engine/templates/cases/casesList.js:1233, change from:
Code: Select all var textSearch = new Ext.form.TextField ({
allowBlank: true,
ctCls:'pm_search_text_field',
width: 140,
emptyText: _('ID_EMPTY_SEARCH'),
To:
Code: Select all var textSearch = new Ext.form.TextField ({
allowBlank: true,
ctCls:'pm_search_text_field',
width: 140,
value: (typeof lastSearchText === 'undefined' ? '' : lastSearchText), //added by ABB
emptyText: _('ID_EMPTY_SEARCH'),
Then in ProcessMaker go to
Admin > Clear Cache and mark all the options and click on "Clear".
Then, in your web browser, press CTRL+F5 in Windows or F5 in Linux to clear the browser's cache.
Now the last text searched in the "Search" box will be automatically entered in the field when the user goes to
Home and clicks on one of the case lists. The user only has to click on the search icon next to the "Search" field to do the same search as before.