ldc-crm/app/Models/CustomerAnswer.php
Alexis Gousseau 303834bbca
Crm V4
- Make all tests pass Client (V4),CRMV2,CRMV4
- Simplify client submodule path
- Move App_url to .env.testing
2023-10-06 16:37:29 +02:00

49 lines
1.2 KiB
PHP

<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Relations\Pivot;
/**
* @property integer $answer_id Foreign key Answer.
* @property integer $customer_id Foreign key Customer.
* @property-read \Illuminate\Support\Carbon $created_at Created date.
*
* @property-read \App\Models\Customer $customer Customer BelongsTo relation.
* @property-read \App\Models\Answer $answer Answer BelongsTo relation.
*/
class CustomerAnswer extends Pivot
{
/**
* Inhibit update_at column as we only have
* created_at.
*
* @return null
*/
public function getUpdatedAtColumn()
{
return null;
}
// * RELATIONS
/**
* Customer belongsTo relation.
*
* @return \Illuminate\Database\Eloquent\Relations\BelongsTo
*/
public function customer(): \Illuminate\Database\Eloquent\Relations\BelongsTo
{
return $this->belongsTo(Customer::class);
}
/**
* Customer belongsTo relation.
*
* @return \Illuminate\Database\Eloquent\Relations\BelongsTo
*/
public function answer(): \Illuminate\Database\Eloquent\Relations\BelongsTo
{
return $this->belongsTo(Answer::class);
}
}