<?php

namespace App\Http\Controllers;

use App\StoreItem;
use Illuminate\Contracts\Foundation\Application;
use Illuminate\Contracts\View\Factory;
use Illuminate\Http\Response;
use Illuminate\View\View;

class StoreItemController extends Controller
{
    /**
     * Display a listing of the resource.
     *
     * @return Application|Factory|Response|View
     */
    public function index()
    {
        $storeItems=StoreItem::query()->with('store')
            ->whereHas('store',function($query){
                $query->where('is_fast_stored','快速入库');
            })
            ->orderBy('id','DESC')->paginate(50);
        return view('store.fast.storeItem',['storeItems'=>$storeItems]);
    }
}
