started work on OTP and disabled registration

This commit is contained in:
Kwesi Banson Jnr
2026-08-26 23:03:11 +00:00
parent 006a974044
commit ff66dbbabe
13 changed files with 938 additions and 3 deletions

View File

@@ -7,6 +7,7 @@ use Illuminate\Database\Eloquent\Model;
class OfficeLocation extends Model
{
protected $guarded = array('id');
protected $table = 'office_locations';
public function created_by_info(){
return $this->hasOne('App\Models\StaffMember', 'id', 'user_id');
@@ -15,4 +16,17 @@ class OfficeLocation extends Model
// return $this->hasOne('App\Models\StaffMember', 'id', 'country_manager_id');
return $this->hasOne('App\Models\StaffMember', 'id', 'country_manager_id');
}
public function manager()
{
return $this->belongsTo(StaffMember::class, 'country_manager_id');
}
public function documents()
{
return $this->hasMany(OfficeLocationDocument::class, 'office_location_id');
}
}

View File

@@ -0,0 +1,16 @@
<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
class OfficeLocationDocument extends Model
{
protected $table = 'office_location_documents';
protected $guarded = [];
public function location()
{
return $this->belongsTo(OfficeLocation::class, 'office_location_id');
}
}