@@ -34,8 +34,8 @@ |
||
| 34 | 34 | |
| 35 | 35 | public function title() |
| 36 | 36 | { |
| 37 | - return ($this->husband ? $this->husband->fullname() : '?'). |
|
| 38 | - ' + '. |
|
| 37 | + return ($this->husband ? $this->husband->fullname() : '?') . |
|
| 38 | + ' + ' . |
|
| 39 | 39 | ($this->wife ? $this->wife->fullname() : '?'); |
| 40 | 40 | } |
| 41 | 41 | |
@@ -25,10 +25,10 @@ |
||
| 25 | 25 | } |
| 26 | 26 | public function type() |
| 27 | 27 | { |
| 28 | - return $this->hasMany(Type::class,'id','type_id'); |
|
| 28 | + return $this->hasMany(Type::class, 'id', 'type_id'); |
|
| 29 | 29 | } |
| 30 | 30 | public function addr() |
| 31 | 31 | { |
| 32 | - return $this->hasMany(Addr::class,'id','addr_id'); |
|
| 32 | + return $this->hasMany(Addr::class, 'id', 'addr_id'); |
|
| 33 | 33 | } |
| 34 | 34 | } |
@@ -50,6 +50,6 @@ |
||
| 50 | 50 | } |
| 51 | 51 | public function place() |
| 52 | 52 | { |
| 53 | - return $this->hasMany(Place::class,'id','places_id'); |
|
| 53 | + return $this->hasMany(Place::class, 'id', 'places_id'); |
|
| 54 | 54 | } |
| 55 | 55 | } |
@@ -8,7 +8,7 @@ |
||
| 8 | 8 | class Type extends Model |
| 9 | 9 | { |
| 10 | 10 | use HasFactory; |
| 11 | - protected $fillable = ['name', 'description','is_active']; |
|
| 11 | + protected $fillable = ['name', 'description', 'is_active']; |
|
| 12 | 12 | |
| 13 | 13 | |
| 14 | 14 | } |
@@ -10,7 +10,7 @@ |
||
| 10 | 10 | /** |
| 11 | 11 | * @var array |
| 12 | 12 | */ |
| 13 | - protected $fillable = ['name', 'description','company_id','current_tenant']; |
|
| 13 | + protected $fillable = ['name', 'description', 'company_id', 'current_tenant']; |
|
| 14 | 14 | |
| 15 | 15 | protected $connection = 'landlord'; |
| 16 | 16 | public function company() |
@@ -16,7 +16,7 @@ |
||
| 16 | 16 | protected static function boot() { |
| 17 | 17 | parent::boot(); |
| 18 | 18 | |
| 19 | - static::creating(function ($category) { |
|
| 19 | + static::creating(function($category) { |
|
| 20 | 20 | $category->slug = Str::slug($category->name); |
| 21 | 21 | }); |
| 22 | 22 | } |
@@ -11,7 +11,7 @@ |
||
| 11 | 11 | |
| 12 | 12 | protected $connection = 'landlord'; |
| 13 | 13 | |
| 14 | - protected $fillable = ['name','status','current_tenant']; |
|
| 14 | + protected $fillable = ['name', 'status', 'current_tenant']; |
|
| 15 | 15 | public function trees() |
| 16 | 16 | { |
| 17 | 17 | return $this->hasMany(App\Model\Tree::class); |
@@ -16,20 +16,20 @@ |
||
| 16 | 16 | protected static function boot() { |
| 17 | 17 | parent::boot(); |
| 18 | 18 | |
| 19 | - static::creating(function ($topic) { |
|
| 19 | + static::creating(function($topic) { |
|
| 20 | 20 | $topic->slug = Str::slug($topic->title); |
| 21 | 21 | }); |
| 22 | 22 | } |
| 23 | 23 | |
| 24 | - public function category(){ |
|
| 24 | + public function category() { |
|
| 25 | 25 | return $this->belongsTo(ForumCategory::class, 'category_id'); |
| 26 | 26 | } |
| 27 | 27 | |
| 28 | - public function author(){ |
|
| 28 | + public function author() { |
|
| 29 | 29 | return $this->belongsTo(User::class, 'created_by'); |
| 30 | 30 | } |
| 31 | 31 | |
| 32 | - public function posts(){ |
|
| 32 | + public function posts() { |
|
| 33 | 33 | return $this->hasMany(ForumPost::class, 'topic_id')->with('author'); |
| 34 | 34 | } |
| 35 | 35 | } |
@@ -40,12 +40,12 @@ |
||
| 40 | 40 | */ |
| 41 | 41 | public function toMail($notifiable) |
| 42 | 42 | { |
| 43 | - $param =[ |
|
| 43 | + $param = [ |
|
| 44 | 44 | 'id' => $notifiable->getKey(), |
| 45 | 45 | 'hash' => sha1($notifiable->getEmailForVerification()) |
| 46 | 46 | ]; |
| 47 | 47 | |
| 48 | - $url = env('FRONTEND_URL') .'/verify-email?'; |
|
| 48 | + $url = env('FRONTEND_URL') . '/verify-email?'; |
|
| 49 | 49 | |
| 50 | 50 | foreach ($param as $key => $params) { |
| 51 | 51 | $url .= "{$key}={$params}&"; |