first commit
This commit is contained in:
commit
405df0a122
3083 changed files with 69203 additions and 0 deletions
88
dev/Models/InvoiceBillingAddress.php
Normal file
88
dev/Models/InvoiceBillingAddress.php
Normal file
|
|
@ -0,0 +1,88 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* Created by Reliese Model.
|
||||
*/
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Carbon\Carbon;
|
||||
use Illuminate\Database\Eloquent\Collection;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
/**
|
||||
* Class InvoiceBillingAddress
|
||||
*
|
||||
* @property int $id
|
||||
* @property int|null $salutation_id
|
||||
* @property string|null $title
|
||||
* @property string $name
|
||||
* @property string|null $address
|
||||
* @property string|null $address1
|
||||
* @property string|null $address2
|
||||
* @property string|null $postal_code
|
||||
* @property string|null $city
|
||||
* @property int|null $country_id
|
||||
* @property string|null $country_name
|
||||
* @property Carbon|null $created_at
|
||||
* @property Carbon|null $updated_at
|
||||
* @property Country|null $country
|
||||
* @property Salutation|null $salutation
|
||||
* @property Collection|Invoice[] $invoices
|
||||
* @package App\Models
|
||||
* @property-read int|null $invoices_count
|
||||
* @method static \Illuminate\Database\Eloquent\Builder|InvoiceBillingAddress newModelQuery()
|
||||
* @method static \Illuminate\Database\Eloquent\Builder|InvoiceBillingAddress newQuery()
|
||||
* @method static \Illuminate\Database\Eloquent\Builder|InvoiceBillingAddress query()
|
||||
* @method static \Illuminate\Database\Eloquent\Builder|InvoiceBillingAddress whereAddress($value)
|
||||
* @method static \Illuminate\Database\Eloquent\Builder|InvoiceBillingAddress whereAddress1($value)
|
||||
* @method static \Illuminate\Database\Eloquent\Builder|InvoiceBillingAddress whereAddress2($value)
|
||||
* @method static \Illuminate\Database\Eloquent\Builder|InvoiceBillingAddress whereCity($value)
|
||||
* @method static \Illuminate\Database\Eloquent\Builder|InvoiceBillingAddress whereCountryId($value)
|
||||
* @method static \Illuminate\Database\Eloquent\Builder|InvoiceBillingAddress whereCountryName($value)
|
||||
* @method static \Illuminate\Database\Eloquent\Builder|InvoiceBillingAddress whereCreatedAt($value)
|
||||
* @method static \Illuminate\Database\Eloquent\Builder|InvoiceBillingAddress whereId($value)
|
||||
* @method static \Illuminate\Database\Eloquent\Builder|InvoiceBillingAddress whereName($value)
|
||||
* @method static \Illuminate\Database\Eloquent\Builder|InvoiceBillingAddress wherePostalCode($value)
|
||||
* @method static \Illuminate\Database\Eloquent\Builder|InvoiceBillingAddress whereSalutationId($value)
|
||||
* @method static \Illuminate\Database\Eloquent\Builder|InvoiceBillingAddress whereTitle($value)
|
||||
* @method static \Illuminate\Database\Eloquent\Builder|InvoiceBillingAddress whereUpdatedAt($value)
|
||||
* @mixin \Eloquent
|
||||
*/
|
||||
class InvoiceBillingAddress extends Model
|
||||
{
|
||||
protected $table = 'invoice_billing_address';
|
||||
|
||||
protected $casts = [
|
||||
'salutation_id' => 'int',
|
||||
'country_id' => 'int'
|
||||
];
|
||||
|
||||
protected $fillable = [
|
||||
'salutation_id',
|
||||
'title',
|
||||
'name',
|
||||
'address',
|
||||
'address1',
|
||||
'address2',
|
||||
'postal_code',
|
||||
'city',
|
||||
'country_id',
|
||||
'country_name'
|
||||
];
|
||||
|
||||
public function country()
|
||||
{
|
||||
return $this->belongsTo(Country::class);
|
||||
}
|
||||
|
||||
public function salutation()
|
||||
{
|
||||
return $this->belongsTo(Salutation::class);
|
||||
}
|
||||
|
||||
public function invoices()
|
||||
{
|
||||
return $this->hasMany(Invoice::class, 'billing_address_id');
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue