33 lines
1.3 KiB
PHP
33 lines
1.3 KiB
PHP
<?php
|
|
|
|
namespace App\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
class MarketplaceSellerForm extends Model
|
|
{
|
|
use HasFactory;
|
|
|
|
protected $fillable = ['users_id','name','city','country','postal_code','contact_number','email','declaration'];
|
|
|
|
public function users(){
|
|
return $this->belongsTo(User::class);
|
|
}
|
|
|
|
public function aif(){
|
|
// return $this->hasMany(MarketplaceAlternativeInvestmentFundSeller::class,'seller_forms_id')->where('listing_status', '!=','Hide')->where('status','Approved');
|
|
return $this->hasMany(MarketplaceAlternativeInvestmentFundSeller::class,'seller_forms_id')->where('status','Approved');
|
|
// return $this->hasMany(MarketplaceAlternativeInvestmentFundSeller::class,'seller_forms_id');
|
|
}
|
|
|
|
public function fre(){
|
|
// return $this->hasMany(MarketplaceFractionalRealEstateSeller::class,'seller_forms_id')->where('listing_status', '!=','Hide')->where('status','Approved');
|
|
return $this->hasMany(MarketplaceFractionalRealEstateSeller::class,'seller_forms_id')->where('status','Approved');
|
|
}
|
|
|
|
public function op(){
|
|
return $this->hasMany(MarketplaceOtherProductsSeller::class,'seller_forms_id')->where('listing_status', '!=','Hide');
|
|
}
|
|
}
|