Comments (15)
if i inject the modal instead of the repo i get a different error about not being to find query builder :: store
everything else is going smoothly with the template ;)
from laravel-boilerplate.
Hey bro,
Just go to your AppServiceProvider and you'll find out missing binding ;)
from laravel-boilerplate.
i added this, but i still get the same error:
$this->app->bind(
CourtCaseRepository::class,
EloquentCourtCaseRepository::class
);
from laravel-boilerplate.
Contracts\CourtCaseRepository.php :
namespace App\Repositories\Contracts;
use App\Models\CourtCase;
interface CourtCaseRepository
{
/**
* @return \Illuminate\Database\Query\Builder
*/
public function get();
/**
* @param $locale
* @param $route
*
* @return Meta
*/
public function find($locale, $route);
/**
* @param $input
*
* @return mixed
*/
public function store($input);
/**
* @param Meta $meta
* @param $input
*
* @return mixed
*/
public function update(CourtCase $courtCase, $input);
/**
* @param Meta $meta
*
* @return mixed
*/
public function destroy(CourtCase $courtCase);
/**
* @param \App\Models\Meta $meta
*
* @return mixed
*/
}
from laravel-boilerplate.
CaseController.php:
namespace App\Http\Controllers\Backend;
use App\Http\Controllers\Controller;
use App\Http\Requests\StoreUserRequest;
use App\Http\Requests\UpdateUserRequest;
use App\Models\User;
use App\Repositories\Contracts\RoleRepository;
use App\Repositories\Contracts\UserRepository;
use App\Models\CourtCase;
use App\Repositories\Contracts\CourtCaseRepository;
use App\Http\Requests\StoreCourtCaseRequest;
use Illuminate\Http\Request;
use Yajra\Datatables\Datatables;
use Yajra\Datatables\Engines\EloquentEngine;
use Yajra\Datatables\Html\Builder;
class CaseController extends Controller
{
protected $courtCase;
/**
* @var UserRepository
*/
protected $users;
/**
* @var RoleRepository
*/
protected $roles;
/**
* Datatables Html Builder.
*
* @var Builder
*/
protected $htmlBuilder;
/**
* Create a new controller instance.
*
* @param UserRepository $users
* @param \App\Repositories\Contracts\RoleRepository $roles
* @param Builder $htmlBuilder
*/
public function __construct(UserRepository $users, CourtCaseRepository $courtCase, RoleRepository $roles, Builder $htmlBuilder)
{
$this->users = $users;
$this->courtCase = $courtCase;
$this->roles = $roles;
$this->htmlBuilder = $htmlBuilder;
}
from laravel-boilerplate.
Are you sure you have import CourtCaseRepository in your AppServiceProvider ?
By the way dont use the old 2.4 release, just take master branch
from laravel-boilerplate.
the master branch is nice, but i can't add on learning vue at the moment =/ otherwise i would. (do you have a non vue version of master?)
from laravel-boilerplate.
i can also fork the git repo and show you my changes thus far
from laravel-boilerplate.
Okay for fork it will be simpler i guess ^^
But it should work if you have correct bindings
from laravel-boilerplate.
code is up at: https://github.com/mzummo/laravel-boilerplate/tree/dev github cant compare across the forks (that i know) ... i use beyond compare .... i know its going to be something super simple :P
from laravel-boilerplate.
This is i was thinking ;)
You just forgot to import CourtCaseRepository here (use statements) :
https://github.com/mzummo/laravel-boilerplate/blob/dev/app/Providers/AppServiceProvider.php
from laravel-boilerplate.
almost there!: Type error: Argument 1 passed to App\Http\Controllers\Backend\CaseController::__construct() must implement interface App\Repositories\Contracts\CourtCaseRepository, instance of App\Repositories\EloquentCourtCaseRepository given
from laravel-boilerplate.
updated github
from laravel-boilerplate.
Commented out your find method :
https://github.com/mzummo/laravel-boilerplate/blob/dev/app/Repositories/EloquentCourtCaseRepository.php
from laravel-boilerplate.
think i got it: class EloquentCourtCaseRepository extends BaseRepository implements CourtCaseRepository needed to add impliments ...
now to get it to write to the DB
from laravel-boilerplate.
Related Issues (20)
- Congrats To this Boilerplate and adr1enbe4udou1n [Not Issue]
- Removing Image Cache? HOT 1
- "npm run build" command causes a lot of prettier errors HOT 4
- Can not run php artisan db:seed HOT 1
- php artisan db:seed - error HOT 2
- Error page about HOT 1
- RoleForm.vue does not display feedback HOT 1
- RU translation misspell HOT 1
- User slugs are not unique HOT 2
- admin password reset HOT 1
- IE11 Backend Demo not working HOT 1
- phpunit error HOT 1
- Upgrade to 5.8? HOT 6
- Multiple authentication? HOT 7
- Upgrade to 6.0?
- server exception HOT 10
- Ways to images ? HOT 22
- [Vue warn]: Error in nextTick: "TypeError: Cannot convert undefined or null to object" HOT 1
- seocontroller and sitemap HOT 1
- Can you make the code without using the JSON data type? HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from laravel-boilerplate.