diff --git a/app/Models/RequestMaterial.php b/app/Models/RequestMaterial.php index 4686317..df32ec2 100644 --- a/app/Models/RequestMaterial.php +++ b/app/Models/RequestMaterial.php @@ -11,23 +11,29 @@ class RequestMaterial extends Model const CREATED_AT = 'created_at'; const UPDATED_AT = 'updated_at'; + protected $casts = [ + 'id' => 'integer', + 'price' => 'float', + 'qty' => 'float', + ]; + protected $fillable = [ - 'description', - 'required_date', - 'qty', - 'uom', - 'qty_received', - 'fom_date', - 'pr_date', - 'po_date', - 'received_date', - 'delivery_date', - 'status', + 'description', + 'required_date', + 'qty', + 'uom', + 'qty_received', + 'fom_date', + 'pr_date', + 'po_date', + 'received_date', + 'delivery_date', + 'status', 'proyek_id', - 'created_at', - 'created_by', - 'updated_at', - 'updated_by', + 'created_at', + 'created_by', + 'updated_at', + 'updated_by', 'price' ]; }