Merge remote-tracking branch 'origin/cc_master' into afiqhamzah/feat/overall-report

This commit is contained in:
Afiq Hamzah
2023-12-03 11:23:18 +08:00
6 changed files with 172 additions and 40 deletions
+2
View File
@@ -37,6 +37,8 @@ class HomeController extends Controller
return redirect()->route('akaun.home');
elseif($auth_user->roles == 'kpo')
return redirect()->route('kpo.home');
elseif($auth_user->roles == 'callcenter')
return redirect()->route('callcenter.home');
else
return redirect()->route('home');
}
@@ -0,0 +1,45 @@
<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Auth;
use Illuminate\Support\Facades\Session;
use Illuminate\Support\Facades\Http;
use Carbon\Carbon;
class PelangganArccController extends Controller{
public function AdminPelangganArcc()
{
$api_url = config('api_url');
$auth_user = Auth::user();
}
public function DetailsPelangganArcc()
{
$api_url = config('api_url');
$auth_user = Auth::user();
}
public function AdminPelanggan()
{
$api_url = config('api.url');
$auth_user = Auth::user();
return view('pelanggan.pelanggan',compact('api_url','auth_user'));
}
public function DetailsPelanggan($id)
{
$api_url = config('api.url');
$auth_user = Auth::user();
$customer_info = Http::get(config('api.url') . '/admin/Customers/'. $id)->json();
return view('pelanggan.detailspelanggan',compact('api_url','auth_user','customer_info'));
}
}