Skip to content
Snippets Groups Projects
Commit 740b6819 authored by Philippe Grand's avatar Philippe Grand
Browse files

add phone pro search within member list

parent cd801fe1
No related branches found
No related tags found
No related merge requests found
...@@ -49,6 +49,7 @@ $search_zip=GETPOST("search_zip"); ...@@ -49,6 +49,7 @@ $search_zip=GETPOST("search_zip");
$search_town=GETPOST("search_town"); $search_town=GETPOST("search_town");
$search_state=GETPOST("search_state"); $search_state=GETPOST("search_state");
$search_country=GETPOST("search_country"); $search_country=GETPOST("search_country");
$search_phone=GETPOST("search_phone");
$type=GETPOST("type"); $type=GETPOST("type");
$search_email=GETPOST("search_email"); $search_email=GETPOST("search_email");
$search_categ = GETPOST("search_categ",'int'); $search_categ = GETPOST("search_categ",'int');
...@@ -104,6 +105,7 @@ $arrayfields=array( ...@@ -104,6 +105,7 @@ $arrayfields=array(
'd.address'=>array('label'=>$langs->trans("Address"), 'checked'=>0), 'd.address'=>array('label'=>$langs->trans("Address"), 'checked'=>0),
'd.zip'=>array('label'=>$langs->trans("Zip"), 'checked'=>0), 'd.zip'=>array('label'=>$langs->trans("Zip"), 'checked'=>0),
'd.town'=>array('label'=>$langs->trans("Town"), 'checked'=>0), 'd.town'=>array('label'=>$langs->trans("Town"), 'checked'=>0),
'd.phone'=>array('label'=>$langs->trans("Phone"), 'checked'=>0),
'state.nom'=>array('label'=>$langs->trans("State"), 'checked'=>0), 'state.nom'=>array('label'=>$langs->trans("State"), 'checked'=>0),
'country.code_iso'=>array('label'=>$langs->trans("Country"), 'checked'=>0), 'country.code_iso'=>array('label'=>$langs->trans("Country"), 'checked'=>0),
/*'d.note_public'=>array('label'=>$langs->trans("NotePublic"), 'checked'=>0), /*'d.note_public'=>array('label'=>$langs->trans("NotePublic"), 'checked'=>0),
...@@ -151,6 +153,7 @@ if (GETPOST("button_removefilter_x") || GETPOST("button_removefilter.x") || GETP ...@@ -151,6 +153,7 @@ if (GETPOST("button_removefilter_x") || GETPOST("button_removefilter.x") || GETP
$search_town=""; $search_town="";
$search_state=""; $search_state="";
$search_country=''; $search_country='';
$search_phone='';
$search_morphy=""; $search_morphy="";
$search_categ=""; $search_categ="";
$catid=""; $catid="";
...@@ -290,6 +293,7 @@ if ($resql) ...@@ -290,6 +293,7 @@ if ($resql)
if ($search_zip != '') $param.= "&search_zip=".urlencode($search_zip); if ($search_zip != '') $param.= "&search_zip=".urlencode($search_zip);
if ($search_state != '') $param.= "&search_state=".urlencode($search_state); if ($search_state != '') $param.= "&search_state=".urlencode($search_state);
if ($search_country != '') $param.= "&search_country=".urlencode($search_country); if ($search_country != '') $param.= "&search_country=".urlencode($search_country);
if ($search_phone != '') $param.= "&search_phone=".urlencode($search_phone);
if ($filter) $param.="&filter=".urlencode($filter); if ($filter) $param.="&filter=".urlencode($filter);
if ($type > 0) $param.="&type=".urlencode($type); if ($type > 0) $param.="&type=".urlencode($type);
if ($optioncss != '') $param.='&optioncss='.urlencode($optioncss); if ($optioncss != '') $param.='&optioncss='.urlencode($optioncss);
...@@ -361,6 +365,7 @@ if ($resql) ...@@ -361,6 +365,7 @@ if ($resql)
if (! empty($arrayfields['d.town']['checked'])) print_liste_field_titre($arrayfields['d.town']['label'],$_SERVER["PHP_SELF"],'d.town','',$param,'',$sortfield,$sortorder); if (! empty($arrayfields['d.town']['checked'])) print_liste_field_titre($arrayfields['d.town']['label'],$_SERVER["PHP_SELF"],'d.town','',$param,'',$sortfield,$sortorder);
if (! empty($arrayfields['state.nom']['checked'])) print_liste_field_titre($langs->trans("StateShort"),$_SERVER["PHP_SELF"],"state.nom","",$param,'',$sortfield,$sortorder); if (! empty($arrayfields['state.nom']['checked'])) print_liste_field_titre($langs->trans("StateShort"),$_SERVER["PHP_SELF"],"state.nom","",$param,'',$sortfield,$sortorder);
if (! empty($arrayfields['country.code_iso']['checked'])) print_liste_field_titre($langs->trans("Country"),$_SERVER["PHP_SELF"],"country.code_iso","",$param,'align="center"',$sortfield,$sortorder); if (! empty($arrayfields['country.code_iso']['checked'])) print_liste_field_titre($langs->trans("Country"),$_SERVER["PHP_SELF"],"country.code_iso","",$param,'align="center"',$sortfield,$sortorder);
if (! empty($arrayfields['d.phone']['checked'])) print_liste_field_titre($arrayfields['d.phone']['label'],$_SERVER["PHP_SELF"],'d.phone','',$param,'',$sortfield,$sortorder);
if (! empty($arrayfields['d.email']['checked'])) print_liste_field_titre($arrayfields['d.email']['label'],$_SERVER["PHP_SELF"],'d.email','',$param,'',$sortfield,$sortorder); if (! empty($arrayfields['d.email']['checked'])) print_liste_field_titre($arrayfields['d.email']['label'],$_SERVER["PHP_SELF"],'d.email','',$param,'',$sortfield,$sortorder);
if (! empty($arrayfields['d.datefin']['checked'])) print_liste_field_titre($arrayfields['d.datefin']['label'],$_SERVER["PHP_SELF"],'d.datefin','',$param,'align="center"',$sortfield,$sortorder); if (! empty($arrayfields['d.datefin']['checked'])) print_liste_field_titre($arrayfields['d.datefin']['label'],$_SERVER["PHP_SELF"],'d.datefin','',$param,'align="center"',$sortfield,$sortorder);
// Extra fields // Extra fields
...@@ -470,6 +475,12 @@ if ($resql) ...@@ -470,6 +475,12 @@ if ($resql)
print $form->select_country($search_country,'search_country','',0,'maxwidth100'); print $form->select_country($search_country,'search_country','',0,'maxwidth100');
print '</td>'; print '</td>';
} }
// Phone pro
if (! empty($arrayfields['d.phone']['checked']))
{
print '<td class="liste_titre" align="left">';
print '<input class="flat" type="text" name="search_phone" value="'.$search_phone.'" size="5"></td>';
}
// Email // Email
if (! empty($arrayfields['d.email']['checked'])) if (! empty($arrayfields['d.email']['checked']))
{ {
...@@ -656,6 +667,14 @@ if ($resql) ...@@ -656,6 +667,14 @@ if ($resql)
print '</td>'; print '</td>';
if (! $i) $totalarray['nbfield']++; if (! $i) $totalarray['nbfield']++;
} }
// Phone pro
if (! empty($arrayfields['d.phone']['checked']))
{
print '<td class="nocellnopadd">';
print $obj->phone;
print '</td>';
if (! $i) $totalarray['nbfield']++;
}
// EMail // EMail
if (! empty($arrayfields['d.email']['checked'])) if (! empty($arrayfields['d.email']['checked']))
{ {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment