public function delete(TagRequest $request, $type)
    {
        try {
            $ids = hashids_decode($request->input('ids'));

            if ($type == 'purge') {
                $this->repository->purge($ids);
            } else {
                $this->repository->delete($ids);
            }

            return $this->response->message(trans('messages.success.deleted', ['Module' => trans('news::tag.name')]))
                ->status("success")
                ->code(202)
                ->url(guard_url('news/tag'))
                ->redirect();

        } catch (Exception $e) {

            return $this->response->message($e->getMessage())
                ->status("error")
                ->code(400)
                ->url(guard_url('/news/tag'))
                ->redirect();
        }

    }
public function delete(TagRequest $request, $type)
    {
        try {
            $ids = hashids_decode($request->input('ids'));

            if ($type == 'purge') {
                $this->repository->purge($ids);
            } else {
                $this->repository->delete($ids);
            }

            return $this->response->message(trans('messages.success.deleted', ['Module' => trans('news::tag.name')]))
                ->status("success")
                ->code(202)
                ->url(guard_url('news/tag'))
                ->redirect();

        } catch (Exception $e) {

            return $this->response->message($e->getMessage())
                ->status("error")
                ->code(400)
                ->url(guard_url('/news/tag'))
                ->redirect();
        }

    }
public function delete ( TagRequest $ request , $ type ) { try { $ ids = hashids_decode ( $ request -> input ( 'ids' ) ) ; if ( $ type == 'purge' ) { $ this -> repository -> purge ( $ ids ) ; } else { $ this -> repository -> delete ( $ ids ) ; } return $ this -> response -> message ( trans ( 'messages.success.deleted' , [ 'Module' => trans ( 'news::tag.name' ) ] ) ) -> status ( "success" ) -> code ( 202 ) -> url ( guard_url ( 'news/tag' ) ) -> redirect ( ) ; } catch ( Exception $ e ) { return $ this -> response -> message ( $ e -> getMessage ( ) ) -> status ( "error" ) -> code ( 400 ) -> url ( guard_url ( '/news/tag' ) ) -> redirect ( ) ; } }
Remove multiple tag.

@param Model   $tag

@return Response
Remove multiple tag .