/**
  * Store a new resource
  * @param InventoryRequest $request - do some validation before this store(..) function is called
  * @return \Illuminate\Http\RedirectResponse|\Illuminate\Routing\Redirector
  */
 public function store(InventoryRequest $request)
 {
     // if guest or cannot inventory.create, redirect -> home
     if (Entrust::can('inventory.create') == false) {
         return redirect()->route('home');
     }
     if (isset($request->btn_Cancel)) {
         return Redirect::route('inventory.index');
     }
     $this->transaction(function ($this) use($request, &$inventory) {
         /*
          *  retrieve all the request form field values
          *  and pass them into create to mass update the new Inventory object
          *  Can replace Request::all() in the call to create, because we added validation.
          */
         $inventory = $this->inventoryRepository->create($request->all());
     });
     // to see our $inventory, we could Dump and Die here
     //dd(__METHOD__.'('.__LINE__.')',compact('request','inventory'));
     $tote = $this->getRequest('Tote');
     Session::flash('status', Lang::get('internal.created', ['class' => Inventory::TABLE_NAME]));
     Session::flash('warning', Lang::get('internal.errors.noParent') . ' ' . Lang::get('labels.titles.Move_Tote'));
     return view('pages.inventory.edit', compact('inventory', 'tote'));
 }