%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /home/silvzytp/crm-ind-code/routes/
Upload File :
Create Path :
Current File : /home/silvzytp/crm-ind-code/routes/web.php

<?php

use App\Http\Controllers\Backend\ReportController;
use Illuminate\Support\Facades\Auth;
use Illuminate\Support\Facades\Route;
use App\Http\Controllers\CallingController;
use App\Http\Controllers\CommentController;
use App\Http\Controllers\Auth\AuthController;
use App\Http\Controllers\Backend\AdminController;
use App\Http\Controllers\Backend\AgentController;
use App\Http\Controllers\Backend\ExportController;
use App\Http\Controllers\Backend\CompareController;
use App\Http\Controllers\Backend\SettingController;
use App\Http\Controllers\Backend\SupportController;
use App\Http\Controllers\Backend\Super\RoleController;
use App\Http\Controllers\Backend\CallingStatusController;
use App\Http\Controllers\Backend\Super\ProfileController;
use App\Http\Controllers\Backend\Super\DashboardController;
use App\Http\Controllers\Backend\CallingSubStatusController;
use App\Http\Controllers\Backend\Module\FreshCall\ChannelController;
use App\Http\Controllers\Backend\Module\FreshCall\EmirateController;
use App\Http\Controllers\Backend\Module\FreshCall\CampaignController;
use App\Http\Controllers\Backend\Module\FreshCall\CategoryController;
use App\Http\Controllers\Backend\Module\FreshCall\LeadTypeController;
use App\Http\Controllers\Backend\Module\FreshCall\LocationController;
use App\Http\Controllers\Backend\Module\FreshCall\FreshLeadController;
use App\Http\Controllers\Backend\Module\FreshCall\SubLocationController;
use App\Http\Controllers\Backend\ManagerController as ManagerControllerName;
use App\Http\Controllers\Backend\Module\FreshCall\MarketingSourceController;

Auth::routes([
    'register'         => false, // 404 disabled
    'password.reset'   => false, // 404 disabled
    'password.update'  => false, // 404 disabled
    'password.request' => false, // 404 disabled
    'password.email'   => false, // 404 disabled
    'password.confirm' => false,  // 404 disabled
    'logout'           => false  // 404 disabled
]);

//------------------------ Logout -----------------------//
Route::get('logout', [AuthController::class, 'logout'])->name('logout');
Route::get('forgot-password', [AuthController::class, 'forgotShowForm'])->name('forgot-password');
Route::post('forgot-email', [AuthController::class, 'forgotEmail'])->name('forgot-email');
Route::get('forgot-password/{id}/{email}', [AuthController::class, 'forgotPassword'])->name('forgot.email.password');
Route::post('forgot-password', [AuthController::class, 'resetPassword'])->name('forgot.password');

//----------------  Route List ------------//
Route::get('route-list', function(){
    $routes = Route::getRoutes();
    return view('layouts.route', compact('routes'));
});

//----------------------- Super Admin ---------------------//
Route::name('super.')->middleware('auth','is_super_admin','permission')->group(function(){

    //--------------------- Dashboard -------------------//
    Route::get('/',[DashboardController::class, 'dashboard'])->name('dashboard');

    //--------------------- Cold Calling Dashboard ------------------//
    Route::get('cold-calling-portal',[DashboardController::class, 'coldCallingDashboard'])->name('cold-calling.dashboard');
    Route::post('cold-calling-portal/filter',[DashboardController::class, 'filter'])->name('cold-calling-portal.dashboard.filter');
    // Dashboard Datatable
    Route::get('cold-calling-portal/{param}',[DashboardController::class, 'dashboardBoxData'])->name('dashboard.box-data');


    //---------------------- Fresh Leads Dashboard --------------------//
    Route::get('fresh-leads-portal',[DashboardController::class, 'freshLeadDashboard'])->name('fresh-lead.dashboard');
    Route::post('fresh-leads-portal/filter',[DashboardController::class, 'freshLeadDashboardFilter'])->name('fresh-lead.filter.dashboard');

    //--------------------- Activity Log ----------------//
    Route::get('activities', [DashboardController::class, 'activityLogs'])->name('activities.index');

    //---------------------- Profile ---------------------//
    Route::get('profile',[ProfileController::class, 'profile'])->name('profile.index');
    Route::post('profile/update',[ProfileController::class, 'profileUpdate'])->name('profile.update');

    //--------------------- Password --------------------//
    Route::get('password', [ProfileController::class, 'password'])->name('password.index');
    Route::post('password/update', [ProfileController::class, 'passwordUpdate'])->name('password.update');

    //---------------------- System --------------------//
    Route::prefix('system')->group(function(){
        //---------------------- Role ---------------------//
        Route::resource('roles', RoleController::class)->only(['index','edit','update']);
        Route::post('roles/destroy/{id}', [RoleController::class, 'destroy'])->name('roles.destroy');

        //---------------------- Admin Manage -----------------------//
        Route::resource('admins', AdminController::class)->except('show','destroy');
        Route::post('admins/destroy', [AdminController::class, 'destroy'])->name('admins.destroy');
        Route::post('admins/get-data',[AdminController::class, 'getData'])->name('admins.get-data');
        Route::post('admins/status',[AdminController::class, 'status'])->name('admins.status');
        Route::get('admins/{id}', [AdminController::class, 'show'])->name('admins.show');
        Route::post('admins/bulk/deletable',[AdminController::class, 'bulkDestroy'])
            ->name('admins.bulk-destroy');

        //---------------------- Manager Manage -------------------//
        Route::resource('managers', ManagerControllerName::class)->except('show','destroy');
        Route::post('managers/destroy', [ManagerControllerName::class, 'destroy'])->name('managers.destroy');
        Route::post('managers/get-data',[ManagerControllerName::class, 'getData'])->name('managers.get-data');
        Route::post('managers/status',[ManagerControllerName::class, 'status'])->name('managers.status');
        Route::get('managers/{id}', [ManagerControllerName::class, 'show'])->name('managers.show');
        Route::post('managers/bulk/deletable',[ManagerControllerName::class, 'bulkDestroy'])
            ->name('managers.bulk-destroy');

        //---------------------- Agent Manage -----------------------//
        Route::resource('agents', AgentController::class)->except('show','destroy');
        Route::post('agents/destroy', [AgentController::class, 'destroy'])->name('agents.destroy');
        Route::post('agents/get-data',[AgentController::class, 'getData'])->name('agents.get-data');
        Route::post('agents/status',[AgentController::class, 'status'])->name('agents.status');
        Route::get('agents/{id}', [AgentController::class, 'show'])->name('agents.show');
        Route::post('agents/bulk/deletable',[AgentController::class, 'bulkDestroy'])
            ->name('agents.bulk-destroy');
    });

    //---------------------- Calling Status --------------------//
    Route::resource('status', CallingStatusController::class)->except('show','destroy');
    Route::post('status/{id}', [CallingStatusController::class, 'destroy'])->name('status.destroy');

    //---------------------- Calling Sub-Status --------------------//
    Route::resource('sub-status', CallingSubStatusController::class)->except('show','destroy');
    Route::post('sub-status/{id}', [CallingSubStatusController::class, 'destroy'])->name('sub-status.destroy');

    //---------------------- Calling --------------------//
    Route::resource('callings', CallingController::class)->except('show','destroy');
    Route::post('callings/get-data', [CallingController::class, 'getData'])->name('callings.get-data');
    Route::post('callings/destroy', [CallingController::class, 'destroy'])->name('callings.destroy');
    Route::post('callings/import', [CallingController::class, 'import'])->name('callings.import');
    Route::post('callings/bulk-operation', [CallingController::class, 'bulkOperation'])->name('callings.bulk-operation');
    Route::post('callings/select-status', [CallingController::class, 'selectStatus'])->name('callings.status.get-data');
    Route::post('callings/status-selected', [CallingController::class, 'statusSelected'])->name('callings.status.selected');
    Route::get('callings/lead-pool', [CallingController::class, 'callingReject'])
        ->name('callings.reject');
    Route::post('callings/read-pool/get-data', [CallingController::class, 'readPoolGetData'])
        ->name('callings.reject.get-data');
    Route::post('callings/read-pool/operation', [CallingController::class, 'readPoolOperation'])
        ->name('callings.read-pool.operation');
    Route::post('callings/time', [CallingController::class, 'callingTime'])
        ->name('callings.time');
    //---------------------- Reject Calling -------------------//
    Route::get('callings/transfer', [CallingController::class, 'callingTransfer'])->name('callings.transfer');
    Route::post('callings/transfer/get-data', [CallingController::class, 'callingTransferGetData'])->name('callings.transfer.get-data');
        // Export Route
        Route::post('callings/export', [ExportController::class, 'export'])->name('callings.export');

    //--------------------- Compare -------------------//
    Route::get('compare', [CompareController::class, 'index'])->name('compare.index');
    Route::post('compare/get-data', [CompareController::class, 'getData'])->name('compare.get-data');
    Route::get('compare/filter', [CompareController::class, 'filter'])->name('compare.filter');
    //-------------------- File Compare -----------------//
    Route::get('file/compare', [CompareController::class, 'fileCompareForm'])->name('file.compare.index');
    Route::get('file/compare/pie-chart', [CompareController::class, 'fileCompareFilter'])->name('file.compare.filter');
    

    //--------------------- Support -------------------//
    Route::post('supoort/message', [SupportController::class, 'support'])->name('support.message');


    //Fresh Lead
    //--------------------- Campaign ------------------//
    Route::resource('campaigns', CampaignController::class)->name('show','destroy');
    Route::post('campaigns/destroy', [CampaignController::class, 'destroy'])->name('campaigns.destroy');


    //-------------------- Category -------------------//
    Route::resource('categories', CategoryController::class)->except('show','destroy');
    Route::post('categories/destroy', [CategoryController::class,'destroy'])
        ->name('categories.destroy');

    //-------------------- Channel -------------------//
    Route::resource('channels', ChannelController::class)->except('show','destroy');
    Route::post('channels/destroy', [ChannelController::class,'destroy'])
        ->name('channels.destroy');

    //-------------------- Marketing Source -------------------//
    Route::resource('marketing-sources', MarketingSourceController::class)->except('show','destroy');
    Route::post('marketing-sources/destroy', [MarketingSourceController::class,'destroy'])
            ->name('marketing-sources.destroy');

    //-------------------- Emirate -------------------//
    Route::resource('emirates', EmirateController::class)->except('show','destroy');
    Route::post('emirates/destroy', [EmirateController::class,'destroy'])
        ->name('emirates.destroy');

    //-------------------- Location -------------------//
    Route::resource('locations', LocationController::class)->except('show','destroy');
    Route::post('locations/destroy', [LocationController::class,'destroy'])
        ->name('locations.destroy');
    Route::post('locations/sub-location/get', [LocationController::class,'subLocationGet'])
        ->name('locations.sub-location.get');

    //-------------------- Sub-Location -------------------//
    Route::resource('sub-locations', SubLocationController::class)->except('show','destroy');
    Route::post('sub-locations/destroy', [SubLocationController::class,'destroy'])
        ->name('sub-locations.destroy');

    //-------------------- Lead Type -------------------//
    Route::resource('lead-types', LeadTypeController::class)->except('show','destroy');
    Route::post('lead-types/destroy', [LeadTypeController::class,'destroy'])
        ->name('lead-types.destroy');

    //--------------------- Fresh Lead -----------------//
    Route::resource('fresh-lead', FreshLeadController::class)->except('destroy');
    Route::post('fresh-lead/bulk-operation', [FreshLeadController::class,'bulkOperation'])
        ->name('fresh-lead.bulk-operation');
    Route::post('fresh-lead/destroy', [FreshLeadController::class,'destroy'])
        ->name('fresh-lead.destroy');
    Route::post('fresh-lead/sub-status/selected', [FreshLeadController::class,'subStatusSelected'])
        ->name('fresh-lead.sub-status.selected');
    Route::post('fresh-lead/sub-location/selected', [FreshLeadController::class,'subLocationSelected'])
        ->name('fresh-lead.sub-location.selected');
    Route::get('fresh-lead/lead/pool', [FreshLeadController::class,'leadPool'])
        ->name('fresh-lead.lead-pool');

    //--------------------- Comment -----------------//
    Route::post('comments/store', [CommentController::class, 'commentStore'])
        ->name('comments.store');
    Route::post('comments/get', [CommentController::class, 'commentGet'])
        ->name('comments.get');

    //--------------------- Recycle and Lead Pool Count ---------------------//
    Route::post('recycle-lead-pool/count', [FreshLeadController::class, 'sidebarLeadPoolCount'])
        ->name('recycle.lead-pool.count');

    //----------------------- Settings ----------------------//
    Route::get('settings', [SettingController::class, 'settingForm'])
        ->name('settings.index');
    Route::post('settings/update-or-store', [SettingController::class, 'updateOrStore'])
        ->name('settings.update-or-store');
        
    //---------------------- Notification ---------------------//
    Route::get('notification/read-all',function(){
        Auth::user()->unreadNotifications->markAsRead();
        $notifications = Auth::user()->unreadNotifications;
        foreach ($notifications as $notification) {
            $notification->delete();
        }
        return back();
    })->name('notification.read-all');
    
    
    // Report Route
    Route::get('report', [ReportController::class, 'report'])->name('report.index');
    Route::get('report/filter', [ReportController::class, 'report_filter'])->name('report.filter');
    Route::post('report/export', [ReportController::class, 'report_export'])->name('report.export');

});





Zerion Mini Shell 1.0