fix editing orders

This commit is contained in:
Ludovic CANDELLIER
2022-11-19 23:43:12 +01:00
parent caee665758
commit 73763bb146
19 changed files with 314 additions and 174 deletions

View File

@@ -3,12 +3,19 @@
namespace App\Models\Shop;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;
use Venturecraft\Revisionable\RevisionableTrait;
class Order extends Model
{
use RevisionableTrait, SoftDeletes;
protected $guarded = ['id'];
protected $table = 'shop_orders';
protected $revisionCreationsEnabled = false;
protected $keepRevisionOf = ['customer_address_id', 'delivery_id', 'payment_type', 'status'];
public function customer()
{
return $this->belongsTo(Customer::class);