Add Stargas supplier dashboard with performance analytics
This commit is contained in:
27
src/app/Models/CustomerInvoiceLine.php
Normal file
27
src/app/Models/CustomerInvoiceLine.php
Normal file
@@ -0,0 +1,27 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class CustomerInvoiceLine extends Model
|
||||
{
|
||||
protected $table = 'SL_SALESINVOICETRAN';
|
||||
public $timestamps = false;
|
||||
|
||||
protected $casts = [
|
||||
'QTYTOINVOICE' => 'decimal:2',
|
||||
'SELLINGPRICE' => 'decimal:2',
|
||||
'COSTPRICE' => 'decimal:2',
|
||||
];
|
||||
|
||||
public function invoice()
|
||||
{
|
||||
return $this->belongsTo(CustomerInvoice::class, 'REFNO', 'REFNO');
|
||||
}
|
||||
|
||||
public function product()
|
||||
{
|
||||
return $this->belongsTo(Product::class, 'STOCKCODE', 'STOCKCODE');
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user