<?php
namespace App\Models;
class GoodsReceipt extends BaseModel {
    protected function casts(): array { return ['grn_date' => 'date']; }
    public function supplier() { return $this->belongsTo(Supplier::class); }
    public function purchaseOrder() { return $this->belongsTo(PurchaseOrder::class); }
    public function warehouse() { return $this->belongsTo(Warehouse::class); }
    public function lines() { return $this->hasMany(GoodsReceiptLine::class); }
}
