bug fixes, AM change feature, refactoring

This commit is contained in:
Kwesi Banson Jnr
2025-11-23 14:40:32 +00:00
parent eabf61b7da
commit d5ac7391dd
41 changed files with 1559 additions and 125 deletions

View File

@@ -69,8 +69,8 @@ class NetworkOperatorsController extends Controller
public function getMnosJson(Request $request){
//$this->log_query();
$mno_arr = \DB::table('network_operators')
->join('staff_members AS staffam', 'staffam.id', '=', 'network_operators.account_manager_id')
->join('staff_members AS staffmodify', 'staffmodify.id', '=', 'network_operators.last_modified_by')
->join('auth_users AS staffam', 'staffam.id', '=', 'network_operators.account_manager_id')
->join('auth_users AS staffmodify', 'staffmodify.id', '=', 'network_operators.last_modified_by')
->select('network_operators.id', 'staffam.name AS accountManager', 'network_operators.name AS networkName', 'network_operators.country','network_operators.contract_validity', 'network_operators.connection_status', 'staffmodify.name AS modifiedBy')
->orderBy('network_operators.name', 'ASC')
->paginate(15);
@@ -78,8 +78,8 @@ class NetworkOperatorsController extends Controller
if($request->has('keyword')){
$keyword = $request->keyword;
$mno_arr = \DB::table('network_operators')
->join('staff_members AS staffam', 'staffam.id', '=', 'network_operators.account_manager_id')
->join('staff_members AS staffmodify', 'staffmodify.id', '=', 'network_operators.last_modified_by')
->join('auth_users AS staffam', 'staffam.id', '=', 'network_operators.account_manager_id')
->join('auth_users AS staffmodify', 'staffmodify.id', '=', 'network_operators.last_modified_by')
->select('network_operators.id', 'staffam.name AS accountManager', 'network_operators.name AS networkName', 'network_operators.country','network_operators.contract_validity', 'network_operators.connection_status', 'staffmodify.name AS modifiedBy')
->whereRaw("network_operators.name LIKE '%$keyword%' OR network_operators.connection_status LIKE '%$keyword%' OR network_operators.country LIKE '%$keyword%' OR staffam.name LIKE '%$keyword%' ")
->orderBy('network_operators.name', 'ASC')