add file model
This commit is contained in:
parent
53037d26af
commit
acf701da70
10 changed files with 96 additions and 9 deletions
|
@ -13,7 +13,7 @@ class Container extends Model
|
|||
* @var array
|
||||
*/
|
||||
protected $fillable = [
|
||||
'cid'
|
||||
'cid', 'name'
|
||||
];
|
||||
|
||||
/**
|
||||
|
@ -22,4 +22,4 @@ class Container extends Model
|
|||
* @var array
|
||||
*/
|
||||
protected $hidden = [];
|
||||
}
|
||||
}
|
||||
|
|
|
@ -13,7 +13,7 @@ class Event extends Model
|
|||
* @var array
|
||||
*/
|
||||
protected $fillable = [
|
||||
'eid', 'name', 'short_name'
|
||||
'eid', 'name', 'slug', 'begin', 'end', 'pre_begin', 'post_end'
|
||||
];
|
||||
|
||||
/**
|
||||
|
@ -22,4 +22,4 @@ class Event extends Model
|
|||
* @var array
|
||||
*/
|
||||
protected $hidden = [];
|
||||
}
|
||||
}
|
||||
|
|
25
app/File.php
Normal file
25
app/File.php
Normal file
|
@ -0,0 +1,25 @@
|
|||
<?php
|
||||
|
||||
namespace App;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class File extends Model
|
||||
{
|
||||
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $fillable = [
|
||||
'hash', 'iid'
|
||||
];
|
||||
|
||||
/**
|
||||
* The attributes excluded from the model's JSON form.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $hidden = [];
|
||||
}
|
|
@ -3,17 +3,19 @@
|
|||
namespace App;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\SoftDeletes;
|
||||
|
||||
class Item extends Model
|
||||
{
|
||||
|
||||
use SoftDeletes;
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $fillable = [
|
||||
'iid', 'bezeichnung', 'wann', 'wo', 'eid', 'cid'
|
||||
'iid', 'item_uid', 'bezeichnung', 'wann', 'wo', 'eid', 'cid'
|
||||
];
|
||||
|
||||
/**
|
||||
|
@ -22,4 +24,4 @@ class Item extends Model
|
|||
* @var array
|
||||
*/
|
||||
protected $hidden = [];
|
||||
}
|
||||
}
|
||||
|
|
|
@ -4,6 +4,8 @@ namespace App\Providers;
|
|||
|
||||
use Illuminate\Support\ServiceProvider;
|
||||
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
class AppServiceProvider extends ServiceProvider
|
||||
{
|
||||
/**
|
||||
|
@ -15,4 +17,9 @@ class AppServiceProvider extends ServiceProvider
|
|||
{
|
||||
//
|
||||
}
|
||||
|
||||
public function boot()
|
||||
{
|
||||
Schema::defaultStringLength(191);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue