osb/app/Models/Supplier/Email.php

23 lines
446 B
PHP

<?php
namespace App\Models\Supplier;
use App\Interfaces\SupplierItem;
use App\Models\Product\Email as ProductEmail;
final class Email extends Type implements SupplierItem
{
protected $table = 'supplier_email';
/* INTERFACES */
public function getBillingIntervalAttribute(): int
{
return 4; // Yearly
}
public function types()
{
return $this->belongsToMany(ProductEmail::class,$this->table,'id','id','id',$this->table.'_id');
}
}