prepaeres to some code for the tests
This commit is contained in:
@ -2,6 +2,7 @@
|
||||
|
||||
namespace Database\Seeds;
|
||||
|
||||
use App\Models\Common\Company;
|
||||
use App\Models\Model;
|
||||
use App\Models\Banking\Account;
|
||||
use Setting;
|
||||
@ -25,7 +26,7 @@ class Accounts extends Seeder
|
||||
|
||||
private function create()
|
||||
{
|
||||
$company_id = $this->command->argument('company');
|
||||
$company_id = Company::first()->id;
|
||||
|
||||
$rows = [
|
||||
[
|
||||
|
@ -2,6 +2,7 @@
|
||||
|
||||
namespace Database\Seeds;
|
||||
|
||||
use App\Models\Common\Company;
|
||||
use App\Models\Model;
|
||||
use App\Models\Expense\BillStatus;
|
||||
|
||||
@ -25,7 +26,7 @@ class BillStatuses extends Seeder
|
||||
|
||||
private function create()
|
||||
{
|
||||
$company_id = $this->command->argument('company');
|
||||
$company_id = Company::first()->id;
|
||||
|
||||
$rows = [
|
||||
[
|
||||
|
@ -2,6 +2,7 @@
|
||||
|
||||
namespace Database\Seeds;
|
||||
|
||||
use App\Models\Common\Company;
|
||||
use App\Models\Model;
|
||||
use App\Models\Setting\Category;
|
||||
|
||||
@ -25,7 +26,7 @@ class Categories extends Seeder
|
||||
|
||||
private function create()
|
||||
{
|
||||
$company_id = $this->command->argument('company');
|
||||
$company_id = Company::first()->id;
|
||||
|
||||
$rows = [
|
||||
[
|
||||
|
@ -2,6 +2,7 @@
|
||||
|
||||
namespace Database\Seeds;
|
||||
|
||||
use App\Models\Common\Company;
|
||||
use App\Models\Model;
|
||||
use App\Models\Setting\Currency;
|
||||
|
||||
@ -25,7 +26,7 @@ class Currencies extends Seeder
|
||||
|
||||
private function create()
|
||||
{
|
||||
$company_id = $this->command->argument('company');
|
||||
$company_id = Company::first()->id;
|
||||
|
||||
$rows = [
|
||||
[
|
||||
|
@ -11,6 +11,7 @@ class DatabaseSeeder extends Seeder
|
||||
*/
|
||||
public function run()
|
||||
{
|
||||
|
||||
$this->call(\Database\Seeds\TestCompany::class);
|
||||
$this->call(CompanySeeder::class);
|
||||
}
|
||||
}
|
||||
|
@ -2,6 +2,7 @@
|
||||
|
||||
namespace Database\Seeds;
|
||||
|
||||
use App\Models\Common\Company;
|
||||
use App\Models\Model;
|
||||
use App\Models\Income\InvoiceStatus;
|
||||
|
||||
@ -25,7 +26,7 @@ class InvoiceStatuses extends Seeder
|
||||
|
||||
private function create()
|
||||
{
|
||||
$company_id = $this->command->argument('company');
|
||||
$company_id = Company::first()->id;
|
||||
|
||||
$rows = [
|
||||
[
|
||||
|
@ -2,6 +2,7 @@
|
||||
|
||||
namespace Database\Seeds;
|
||||
|
||||
use App\Models\Common\Company;
|
||||
use App\Models\Model;
|
||||
use Artisan;
|
||||
|
||||
@ -25,7 +26,7 @@ class Modules extends Seeder
|
||||
|
||||
private function create()
|
||||
{
|
||||
$company_id = $this->command->argument('company');
|
||||
$company_id = Company::first()->id;
|
||||
|
||||
Artisan::call('module:install', ['alias' => 'offlinepayment', 'company_id' => $company_id]);
|
||||
Artisan::call('module:install', ['alias' => 'paypalstandard', 'company_id' => $company_id]);
|
||||
|
@ -10,7 +10,11 @@ use Illuminate\Database\Seeder;
|
||||
|
||||
class Roles extends Seeder
|
||||
{
|
||||
/**
|
||||
public function __construct()
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
* Run the database seeds.
|
||||
*
|
||||
* @return void
|
||||
|
@ -2,6 +2,7 @@
|
||||
|
||||
namespace Database\Seeds;
|
||||
|
||||
use App\Models\Common\Company;
|
||||
use App\Models\Model;
|
||||
use Illuminate\Database\Seeder;
|
||||
use Setting;
|
||||
@ -24,7 +25,7 @@ class Settings extends Seeder
|
||||
|
||||
private function create()
|
||||
{
|
||||
$company_id = $this->command->argument('company');
|
||||
$company_id = Company::first()->id;
|
||||
|
||||
Setting::set([
|
||||
'general.date_format' => 'd M Y',
|
||||
|
@ -2,6 +2,7 @@
|
||||
|
||||
namespace Database\Seeds;
|
||||
|
||||
use App\Models\Common\Company;
|
||||
use App\Models\Model;
|
||||
use App\Models\Setting\Tax;
|
||||
|
||||
@ -25,7 +26,7 @@ class Taxes extends Seeder
|
||||
|
||||
private function create()
|
||||
{
|
||||
$company_id = $this->command->argument('company');
|
||||
$company_id = Company::first()->id;
|
||||
|
||||
$rows = [
|
||||
[
|
||||
|
Reference in New Issue
Block a user