Merge branch '2138-En-la-API-se-esta-usando-el-nombre-del-agente-para-filtrar-en-lugar-del-alias' into 'develop'
Agent filtering by alias See merge request artica/pandorafms!1627
This commit is contained in:
commit
d9a8e30229
|
@ -7080,10 +7080,11 @@ function otherParameter2Filter($other, $return_as_array = false) {
|
|||
|
||||
$idAgent = null;
|
||||
if (isset($other['data'][2]) && $other['data'][2] != '') {
|
||||
$idAgent = agents_get_agent_id($other['data'][2]);
|
||||
$idAgents = agents_get_agent_id_by_alias($other['data'][2]);
|
||||
|
||||
if (!empty($idAgent)) {
|
||||
$filter['id_agente'] = $idAgent;
|
||||
|
||||
$filter[] = "id_agente IN (" . explode(",", $idAgents) .")";
|
||||
}
|
||||
else {
|
||||
$filter['sql'] = "1=0";
|
||||
|
|
Loading…
Reference in New Issue