add usercompany
This commit is contained in:
@@ -2,6 +2,30 @@
|
||||
|
||||
namespace App\Modules\UserCompany\Models;
|
||||
|
||||
use App\Models\User;
|
||||
use App\Modules\Bank\Models\Bank;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Relations\BelongsTo;
|
||||
|
||||
class UserCompany extends Model {}
|
||||
class UserCompany extends Model
|
||||
{
|
||||
/**
|
||||
* User
|
||||
*
|
||||
* @return BelongsTo<User, $this>
|
||||
*/
|
||||
public function user(): BelongsTo
|
||||
{
|
||||
return $this->belongsTo(User::class);
|
||||
}
|
||||
|
||||
/**
|
||||
* Bank
|
||||
*
|
||||
* @return BelongsTo<Bank, $this>
|
||||
*/
|
||||
public function bank(): BelongsTo
|
||||
{
|
||||
return $this->belongsTo(Bank::class);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user