config/app/Http/Controllers/OrderController.php
/**
     * Display a listing of the resource.
     *
     * @return \Illuminate\Http\Response
     */
Display a listing of the resource.
@return \Illuminate\Http\Response
Display a listing of the resource . @return \ Illuminate \ Http \ Response
public function index()
    {
        $products = Product::where('product_status',1)->orderBy('product_name','ASC')->get();
        $orders = Order::all();
        return view('admin.orders.index',compact('products','orders'));
    }
public function index ( ) { $ products = Product :: where ( 'product_status' , 1 ) -> orderBy ( 'product_name' , 'ASC' ) -> get ( ) ; $ orders = Order :: all ( ) ; return view ( 'admin.orders.index' , compact ( 'products' , 'orders' ) ) ; }
Display a listing of the resource.
Display a listing of the resource .