<?php

namespace Mehrab\OrderService\Http\Controllers;

use Illuminate\Http\Request;
use App\Http\Controllers\Controller;
use Mehrab\Common\Responses\AjaxResponses;
use Mehrab\OrderService\Http\Requests\OperatorsRequests\choose_team_leader_store_request;
use Mehrab\OrderService\Http\Requests\OperatorsRequests\failed_order_operator_request;
use Mehrab\OrderService\Http\Requests\TeamLeadersRequests\change_expert_store_request;
use Mehrab\OrderService\Http\Requests\TeamLeadersRequests\choose_expert_store_request;
use Mehrab\OrderService\Http\Requests\TeamLeadersRequests\failed_order_team_leader_request;
use Mehrab\OrderService\Models\CancelOrdersService;
use Mehrab\OrderService\Models\OrderService;
use Mehrab\OrderService\Repositories\CancelOrderServiceRepo;
use Mehrab\OrderService\Repositories\OrderServiceRepo;
use Mehrab\RolePermission\Models\Permission;
use Mehrab\Service\Repositories\QuestionRepo;
use Mehrab\Service\Repositories\ServiceRepo;
use Mehrab\User\Repositories\UserRepo;


class CancelOrderServiceController extends Controller
{
    private $CancelOrderServiceRepo;

    public function __construct(CancelOrderServiceRepo $cancelOrdersService)
    {
        $this->CancelOrderServiceRepo = $cancelOrdersService;
    }

    public function index(Request $request)
    {
        $this->authorize('index', CancelOrdersService::class);
        $cancelOrderServices = $this->CancelOrderServiceRepo->all_cancel_orders_service_with($request);
        return view('OrderService::Admin.CancelOrders.list_cancel_order_services', compact('cancelOrderServices'));
    }
}
