This commit is contained in:
Oliver Gorwits
2021-08-14 13:28:13 +01:00
parent f3478571a3
commit 2498d9766b
8 changed files with 26 additions and 10 deletions

View File

@@ -41,6 +41,8 @@ __PACKAGE__->add_columns(
{ data_type => "macaddr", is_nullable => 1 },
"serial",
{ data_type => "text", is_nullable => 1 },
"chassis_id",
{ data_type => "text", is_nullable => 1 },
"model",
{ data_type => "text", is_nullable => 1 },
"ps1_type",

View File

@@ -358,6 +358,8 @@ The following fields are inspected for a match:
=item serial
=item chassis_id
=item module serials (exact)
=item location
@@ -413,10 +415,11 @@ sub search_fuzzy {
->search(
{
-or => [
'me.contact' => { '-ilike' => $q },
'me.serial' => { '-ilike' => $q },
'me.location' => { '-ilike' => $q },
'me.name' => { '-ilike' => $q },
'me.contact' => { '-ilike' => $q },
'me.serial' => { '-ilike' => $q },
'me.chassis_id' => { '-ilike' => $q },
'me.location' => { '-ilike' => $q },
'me.name' => { '-ilike' => $q },
'me.description' => { '-ilike' => $q },
'me.ip' => { '-in' =>
$rs->search({ 'modules.serial' => $qc },