2018-10-15 14:40:34 +02:00
|
|
|
<?php
|
2019-05-11 05:32:07 +02:00
|
|
|
/**
|
2020-09-06 11:38:10 +02:00
|
|
|
* Invoice Ninja (https://invoiceninja.com).
|
2019-05-11 05:32:07 +02:00
|
|
|
*
|
|
|
|
* @link https://github.com/invoiceninja/invoiceninja source repository
|
|
|
|
*
|
2024-04-12 06:15:41 +02:00
|
|
|
* @copyright Copyright (c) 2024. Invoice Ninja LLC (https://invoiceninja.com)
|
2019-05-11 05:32:07 +02:00
|
|
|
*
|
2021-06-16 08:58:16 +02:00
|
|
|
* @license https://www.elastic.co/licensing/elastic-license
|
2019-05-11 05:32:07 +02:00
|
|
|
*/
|
2018-10-15 14:40:34 +02:00
|
|
|
|
2018-10-16 13:42:43 +02:00
|
|
|
namespace App\DataMapper;
|
2018-10-15 14:40:34 +02:00
|
|
|
|
|
|
|
class InvoiceItem
|
|
|
|
{
|
2019-10-29 12:44:54 +01:00
|
|
|
public $quantity = 0;
|
2018-10-15 14:40:34 +02:00
|
|
|
|
2019-10-29 12:44:54 +01:00
|
|
|
public $cost = 0;
|
2018-10-15 14:40:34 +02:00
|
|
|
|
2019-10-29 12:44:54 +01:00
|
|
|
public $product_key = '';
|
2018-10-15 14:40:34 +02:00
|
|
|
|
2021-07-07 13:39:49 +02:00
|
|
|
public $product_cost = 0;
|
|
|
|
|
2019-10-29 12:44:54 +01:00
|
|
|
public $notes = '';
|
2018-10-15 14:40:34 +02:00
|
|
|
|
2019-10-29 12:44:54 +01:00
|
|
|
public $discount = 0;
|
2018-10-15 14:40:34 +02:00
|
|
|
|
2019-10-29 12:44:54 +01:00
|
|
|
public $is_amount_discount = false;
|
2018-10-15 14:40:34 +02:00
|
|
|
|
2019-10-29 12:44:54 +01:00
|
|
|
public $tax_name1 = '';
|
2018-10-15 14:40:34 +02:00
|
|
|
|
2019-10-29 12:44:54 +01:00
|
|
|
public $tax_rate1 = 0;
|
2018-10-15 14:40:34 +02:00
|
|
|
|
2019-10-29 12:44:54 +01:00
|
|
|
public $tax_name2 = '';
|
2018-10-15 14:40:34 +02:00
|
|
|
|
2019-10-29 12:44:54 +01:00
|
|
|
public $tax_rate2 = 0;
|
2018-10-15 14:40:34 +02:00
|
|
|
|
2019-10-29 12:44:54 +01:00
|
|
|
public $tax_name3 = '';
|
2018-10-15 14:40:34 +02:00
|
|
|
|
2019-10-29 12:44:54 +01:00
|
|
|
public $tax_rate3 = 0;
|
2018-10-15 14:40:34 +02:00
|
|
|
|
2019-11-10 13:06:30 +01:00
|
|
|
public $sort_id = '0';
|
2019-09-03 05:39:35 +02:00
|
|
|
|
2019-10-29 12:44:54 +01:00
|
|
|
public $line_total = 0;
|
2019-09-03 05:39:35 +02:00
|
|
|
|
2021-09-15 01:02:25 +02:00
|
|
|
public $gross_line_total = 0;
|
2024-01-14 05:05:00 +01:00
|
|
|
|
2022-11-10 11:57:55 +01:00
|
|
|
public $tax_amount = 0;
|
2021-09-15 01:02:25 +02:00
|
|
|
|
2019-10-29 12:44:54 +01:00
|
|
|
public $date = '';
|
2019-09-03 05:39:35 +02:00
|
|
|
|
2019-10-29 12:44:54 +01:00
|
|
|
public $custom_value1 = '';
|
2019-09-03 05:39:35 +02:00
|
|
|
|
2019-10-29 12:44:54 +01:00
|
|
|
public $custom_value2 = '';
|
2019-09-03 05:39:35 +02:00
|
|
|
|
2019-10-29 12:44:54 +01:00
|
|
|
public $custom_value3 = '';
|
2018-10-15 14:40:34 +02:00
|
|
|
|
2019-10-29 12:44:54 +01:00
|
|
|
public $custom_value4 = '';
|
|
|
|
|
2021-03-31 12:41:17 +02:00
|
|
|
public $type_id = '1'; //1 = product, 2 = service, 3 unpaid gateway fee, 4 paid gateway fee, 5 late fee, 6 expense
|
2019-10-29 12:44:54 +01:00
|
|
|
|
2023-03-24 08:02:34 +01:00
|
|
|
public $tax_id = '';
|
|
|
|
|
2023-08-16 07:38:08 +02:00
|
|
|
public $task_id = '';
|
|
|
|
|
|
|
|
public $expense_id = '';
|
2024-06-14 09:09:44 +02:00
|
|
|
|
2024-04-03 07:03:52 +02:00
|
|
|
public $unit_code = 'C62';
|
2024-06-14 09:09:44 +02:00
|
|
|
|
2019-10-29 12:44:54 +01:00
|
|
|
public static $casts = [
|
2023-08-16 07:38:08 +02:00
|
|
|
'task_id' => 'string',
|
|
|
|
'expense_id' => 'string',
|
2023-03-24 08:02:34 +01:00
|
|
|
'tax_id' => 'string',
|
2020-03-10 07:45:24 +01:00
|
|
|
'type_id' => 'string',
|
2019-10-29 12:44:54 +01:00
|
|
|
'quantity' => 'float',
|
|
|
|
'cost' => 'float',
|
2021-07-07 13:39:49 +02:00
|
|
|
'product_cost' => 'float',
|
2019-10-29 12:44:54 +01:00
|
|
|
'product_key' => 'string',
|
|
|
|
'notes' => 'string',
|
|
|
|
'discount' => 'float',
|
|
|
|
'is_amount_discount' => 'bool',
|
|
|
|
'tax_name1' => 'string',
|
|
|
|
'tax_name2' => 'string',
|
|
|
|
'tax_name3' => 'string',
|
|
|
|
'tax_rate1' => 'float',
|
|
|
|
'tax_rate2' => 'float',
|
|
|
|
'tax_rate3' => 'float',
|
2019-11-10 13:06:30 +01:00
|
|
|
'sort_id' => 'string',
|
2019-10-29 12:44:54 +01:00
|
|
|
'line_total' => 'float',
|
2021-09-15 01:02:25 +02:00
|
|
|
'gross_line_total' => 'float',
|
2022-11-10 11:57:55 +01:00
|
|
|
'tax_amount' => 'float',
|
2019-10-29 12:44:54 +01:00
|
|
|
'date' => 'string',
|
|
|
|
'custom_value1' => 'string',
|
|
|
|
'custom_value2' => 'string',
|
|
|
|
'custom_value3' => 'string',
|
|
|
|
'custom_value4' => 'string',
|
2024-04-03 07:03:52 +02:00
|
|
|
'unit_code' => 'string',
|
2019-10-29 12:44:54 +01:00
|
|
|
];
|
2018-10-15 14:40:34 +02:00
|
|
|
}
|