<?php

namespace App\Models\Orders;

use App\Models\ItemDb;
use App\Models\User;
use Illuminate\Database\Eloquent\Model;

class SalesBilling extends Model
{
    protected $table = 'sales_billing';
    protected $fillable = [
        'order_id',
        'order_item_id',
        'nmrfct',
        'nmrfct_print',
        'total_price_billing',
        'total_quantity_billing',
        'user_id',
        'sale_credit',
        'sale_credit_print',
        'user_nc',

    ];

    public function order()
    {
        return $this->belongsTo(SalesOrder::class);
    }
    public function orderItem()
    {
        return $this->hasMany(SalesOrderDetail::class);
    }
    public function user()
    {
        return $this->belongsTo(User::class);
    }
}
