diff --git a/system/controllers/customers.php b/system/controllers/customers.php index 01e40278..b8e9f38b 100644 --- a/system/controllers/customers.php +++ b/system/controllers/customers.php @@ -512,19 +512,11 @@ switch ($action) { break; default: - $search = _post('search'); run_hook('list_customers'); #HOOK - if ($search != '') { - $query = ORM::for_table('tbl_customers') - ->where_raw("(`username` LIKE '%$search%' OR `fullname` LIKE '%$search%' OR `phonenumber` LIKE '%$search%' OR `email` LIKE '%$search%')") - ->order_by_asc('username'); - $d = Paginator::findMany($query, ['search' => $search]); - } else { - $query = ORM::for_table('tbl_customers')->order_by_asc('username'); - $d = Paginator::findMany($query); - } - $ui->assign('search', htmlspecialchars($search)); + $query = ORM::for_table('tbl_customers')->order_by_asc('username'); + $d = $query->findMany(); + $ui->assign('xheader', ''); $ui->assign('d', $d); $ui->display('customers.tpl'); break; diff --git a/ui/ui/customers.tpl b/ui/ui/customers.tpl index d87ad173..4926ee92 100644 --- a/ui/ui/customers.tpl +++ b/ui/ui/customers.tpl @@ -1,31 +1,33 @@ {include file="sections/header.tpl"} +
{Lang::T('Username')} | {Lang::T('Account Type')} | {Lang::T('Full Name')} | {Lang::T('Balance')} | -+ | {Lang::T('Contact')} | {Lang::T('Package')} | {Lang::T('Service Type')} | {Lang::T('Created On')} | @@ -49,71 +51,62 @@
---|---|---|---|---|---|---|---|---|
{$ds['username']} | -{$ds['account_type']} | -{$ds['fullname']} | -{Lang::moneyFormat($ds['balance'])} | -- {if $ds['phonenumber']} - - {/if} - {if $ds['email']} - - {/if} - {if $ds['coordinates']} - - {/if} - | -- • - | -{$ds['service_type']} | -{Lang::dateTimeFormat($ds['created_at'])} | -- {Lang::T('View')} - {Lang::T('Edit')} - {Lang::T('Recharge')} - | -
{$ds['username']} | +{$ds['account_type']} | +{$ds['fullname']} | +{Lang::moneyFormat($ds['balance'])} | ++ {if $ds['phonenumber']} + + {/if} + {if $ds['email']} + + {/if} + {if $ds['coordinates']} + + {/if} + | ++ • + | +{$ds['service_type']} | +{Lang::dateTimeFormat($ds['created_at'])} | ++ {Lang::T('View')} + {Lang::T('Edit')} + {Lang::T('Recharge')} + | +