Remove taxes from demo data set

This commit is contained in:
= 2021-04-18 09:04:40 +10:00
parent d47a0e1392
commit 6eaff79544
2 changed files with 61 additions and 60 deletions

View File

@ -388,20 +388,20 @@ class DemoMode extends Command
$invoice->line_items = $this->buildLineItems(rand(1, 10)); $invoice->line_items = $this->buildLineItems(rand(1, 10));
$invoice->uses_inclusive_taxes = false; $invoice->uses_inclusive_taxes = false;
if (rand(0, 1)) { // if (rand(0, 1)) {
$invoice->tax_name1 = 'GST'; // $invoice->tax_name1 = 'GST';
$invoice->tax_rate1 = 10.00; // $invoice->tax_rate1 = 10.00;
} // }
if (rand(0, 1)) { // if (rand(0, 1)) {
$invoice->tax_name2 = 'VAT'; // $invoice->tax_name2 = 'VAT';
$invoice->tax_rate2 = 17.50; // $invoice->tax_rate2 = 17.50;
} // }
if (rand(0, 1)) { // if (rand(0, 1)) {
$invoice->tax_name3 = 'CA Sales Tax'; // $invoice->tax_name3 = 'CA Sales Tax';
$invoice->tax_rate3 = 5; // $invoice->tax_rate3 = 5;
} // }
// $invoice->custom_value1 = $faker->date; // $invoice->custom_value1 = $faker->date;
// $invoice->custom_value2 = rand(0, 1) ? 'yes' : 'no'; // $invoice->custom_value2 = rand(0, 1) ? 'yes' : 'no';
@ -455,20 +455,20 @@ class DemoMode extends Command
$invoice->line_items = $this->buildLineItems(rand(1, 10)); $invoice->line_items = $this->buildLineItems(rand(1, 10));
$invoice->uses_inclusive_taxes = false; $invoice->uses_inclusive_taxes = false;
if (rand(0, 1)) { // if (rand(0, 1)) {
$invoice->tax_name1 = 'GST'; // $invoice->tax_name1 = 'GST';
$invoice->tax_rate1 = 10.00; // $invoice->tax_rate1 = 10.00;
} // }
if (rand(0, 1)) { // if (rand(0, 1)) {
$invoice->tax_name2 = 'VAT'; // $invoice->tax_name2 = 'VAT';
$invoice->tax_rate2 = 17.50; // $invoice->tax_rate2 = 17.50;
} // }
if (rand(0, 1)) { // if (rand(0, 1)) {
$invoice->tax_name3 = 'CA Sales Tax'; // $invoice->tax_name3 = 'CA Sales Tax';
$invoice->tax_rate3 = 5; // $invoice->tax_rate3 = 5;
} // }
// $invoice->custom_value1 = $faker->date; // $invoice->custom_value1 = $faker->date;
// $invoice->custom_value2 = rand(0, 1) ? 'yes' : 'no'; // $invoice->custom_value2 = rand(0, 1) ? 'yes' : 'no';
@ -504,20 +504,20 @@ class DemoMode extends Command
$credit->line_items = $this->buildLineItems(rand(1, 10)); $credit->line_items = $this->buildLineItems(rand(1, 10));
$credit->uses_inclusive_taxes = false; $credit->uses_inclusive_taxes = false;
if (rand(0, 1)) { // if (rand(0, 1)) {
$credit->tax_name1 = 'GST'; // $credit->tax_name1 = 'GST';
$credit->tax_rate1 = 10.00; // $credit->tax_rate1 = 10.00;
} // }
if (rand(0, 1)) { // if (rand(0, 1)) {
$credit->tax_name2 = 'VAT'; // $credit->tax_name2 = 'VAT';
$credit->tax_rate2 = 17.50; // $credit->tax_rate2 = 17.50;
} // }
if (rand(0, 1)) { // if (rand(0, 1)) {
$credit->tax_name3 = 'CA Sales Tax'; // $credit->tax_name3 = 'CA Sales Tax';
$credit->tax_rate3 = 5; // $credit->tax_rate3 = 5;
} // }
$credit->save(); $credit->save();
@ -559,20 +559,20 @@ class DemoMode extends Command
$quote->line_items = $this->buildLineItems(rand(1, 10)); $quote->line_items = $this->buildLineItems(rand(1, 10));
$quote->uses_inclusive_taxes = false; $quote->uses_inclusive_taxes = false;
if (rand(0, 1)) { // if (rand(0, 1)) {
$quote->tax_name1 = 'GST'; // $quote->tax_name1 = 'GST';
$quote->tax_rate1 = 10.00; // $quote->tax_rate1 = 10.00;
} // }
if (rand(0, 1)) { // if (rand(0, 1)) {
$quote->tax_name2 = 'VAT'; // $quote->tax_name2 = 'VAT';
$quote->tax_rate2 = 17.50; // $quote->tax_rate2 = 17.50;
} // }
if (rand(0, 1)) { // if (rand(0, 1)) {
$quote->tax_name3 = 'CA Sales Tax'; // $quote->tax_name3 = 'CA Sales Tax';
$quote->tax_rate3 = 5; // $quote->tax_rate3 = 5;
} // }
$quote->save(); $quote->save();
@ -600,20 +600,20 @@ class DemoMode extends Command
$item->quantity = 1; $item->quantity = 1;
//$item->cost = 10; //$item->cost = 10;
if (rand(0, 1)) { // if (rand(0, 1)) {
$item->tax_name1 = 'GST'; // $item->tax_name1 = 'GST';
$item->tax_rate1 = 10.00; // $item->tax_rate1 = 10.00;
} // }
if (rand(0, 1)) { // if (rand(0, 1)) {
$item->tax_name1 = 'VAT'; // $item->tax_name1 = 'VAT';
$item->tax_rate1 = 17.50; // $item->tax_rate1 = 17.50;
} // }
if (rand(0, 1)) { // if (rand(0, 1)) {
$item->tax_name1 = 'Sales Tax'; // $item->tax_name1 = 'Sales Tax';
$item->tax_rate1 = 5; // $item->tax_rate1 = 5;
} // }
$product = Product::all()->random(); $product = Product::all()->random();

View File

@ -22,6 +22,7 @@ class TaskStatusFactory
$task_status->company_id = $company_id; $task_status->company_id = $company_id;
$task_status->name = ''; $task_status->name = '';
$task_status->color = '#fff'; $task_status->color = '#fff';
$task_status->status_order = 9999;
return $task_status; return $task_status;
} }