Closed warmwhisky closed 3 years ago
Hi,
You can create or retrieve any model using the regular Laravel methods:
$model = new MyModel($attributes);
// or
$model = MyModel::find(1);
// or
$model = MyModel::where(...)->first();
// etc.
Once you have an instance of your model class, then you can tag it as per the docs for this package.
$model->tag('cool', 'new');$model->tag(['Apple', 'Banana', 'Cherry']);
$model->save();
Please be sure you include all the relevant information in your issue so we can help you:
[
protected $connection = 'mysql3'; /**
use Searchable; use Taggable; ] a copy of your Models that use or extend this package (just the relevant parts!)
Hi,
I am not sure how I initialise the $model variable in your usage docs? What am I missing?
Thanks