Improvement the list advanced Search
This commit is contained in:
@@ -15,6 +15,7 @@ $action = isset( $_GET["action"] ) ? $_GET["action"] : (isset( $_POST["action"]
|
|||||||
$type = isset( $_GET["type"] ) ? $_GET["type"] : (isset( $_POST["type"] ) ? $_POST["type"] : "extjs");
|
$type = isset( $_GET["type"] ) ? $_GET["type"] : (isset( $_POST["type"] ) ? $_POST["type"] : "extjs");
|
||||||
$dateFrom = isset( $_POST["dateFrom"] ) ? substr( $_POST["dateFrom"], 0, 10 ) : "";
|
$dateFrom = isset( $_POST["dateFrom"] ) ? substr( $_POST["dateFrom"], 0, 10 ) : "";
|
||||||
$dateTo = isset( $_POST["dateTo"] ) ? substr( $_POST["dateTo"], 0, 10 ) : "";
|
$dateTo = isset( $_POST["dateTo"] ) ? substr( $_POST["dateTo"], 0, 10 ) : "";
|
||||||
|
$first = isset( $_POST["first"] ) ? true :false;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
$userUid = (isset($_SESSION["USER_LOGGED"]) && $_SESSION["USER_LOGGED"] != "")? $_SESSION["USER_LOGGED"] : null;
|
$userUid = (isset($_SESSION["USER_LOGGED"]) && $_SESSION["USER_LOGGED"] != "")? $_SESSION["USER_LOGGED"] : null;
|
||||||
@@ -24,6 +25,13 @@ try {
|
|||||||
switch ($action) {
|
switch ($action) {
|
||||||
case "search":
|
case "search":
|
||||||
case "to_reassign":
|
case "to_reassign":
|
||||||
|
if ($first) {
|
||||||
|
$result['totalCount'] = 0;
|
||||||
|
$result['data'] = array();
|
||||||
|
$result = G::json_encode($result);
|
||||||
|
echo $result;
|
||||||
|
return ;
|
||||||
|
}
|
||||||
$user = ($user == "CURRENT_USER")? $userUid : $user;
|
$user = ($user == "CURRENT_USER")? $userUid : $user;
|
||||||
$userUid = $user;
|
$userUid = $user;
|
||||||
break;
|
break;
|
||||||
|
|||||||
@@ -1951,7 +1951,14 @@ var gridForm = new Ext.FormPanel({
|
|||||||
storeCases.setBaseParam("action", action);
|
storeCases.setBaseParam("action", action);
|
||||||
storeCases.setBaseParam("start", 0);
|
storeCases.setBaseParam("start", 0);
|
||||||
storeCases.setBaseParam("limit", pageSize);
|
storeCases.setBaseParam("limit", pageSize);
|
||||||
storeCases.load();
|
|
||||||
|
if (action != 'search') {
|
||||||
|
storeCases.load();
|
||||||
|
} else {
|
||||||
|
storeCases.load( {params: { first: true}} );
|
||||||
|
PMExt.notify_time_out = 5;
|
||||||
|
PMExt.notify(_('ID_ADVANCEDSEARCH'), _('ID_ENTER_SEARCH_CRITERIA'));
|
||||||
|
}
|
||||||
//newPopUp.add(reassignGrid);
|
//newPopUp.add(reassignGrid);
|
||||||
newPopUp.add(gridForm);
|
newPopUp.add(gridForm);
|
||||||
newPopUp.addButton(btnExecReassignSelected);
|
newPopUp.addButton(btnExecReassignSelected);
|
||||||
|
|||||||
Reference in New Issue
Block a user