-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit f0e33c5
Showing
300 changed files
with
27,887 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
root = true | ||
|
||
[*] | ||
charset = utf-8 | ||
end_of_line = lf | ||
insert_final_newline = true | ||
indent_style = space | ||
indent_size = 4 | ||
trim_trailing_whitespace = true | ||
|
||
[*.md] | ||
trim_trailing_whitespace = false | ||
|
||
[*.{yml,yaml}] | ||
indent_size = 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
APP_NAME=Laravel | ||
APP_ENV=local | ||
APP_KEY= | ||
APP_DEBUG=true | ||
APP_URL=http://localhost | ||
|
||
LOG_CHANNEL=stack | ||
|
||
DB_CONNECTION=mysql | ||
DB_HOST=127.0.0.1 | ||
DB_PORT=3306 | ||
DB_DATABASE=laravel | ||
DB_USERNAME=root | ||
DB_PASSWORD= | ||
|
||
BROADCAST_DRIVER=log | ||
CACHE_DRIVER=file | ||
QUEUE_CONNECTION=sync | ||
SESSION_DRIVER=file | ||
SESSION_LIFETIME=120 | ||
|
||
REDIS_HOST=127.0.0.1 | ||
REDIS_PASSWORD=null | ||
REDIS_PORT=6379 | ||
|
||
MAIL_DRIVER=smtp | ||
MAIL_HOST=smtp.mailtrap.io | ||
MAIL_PORT=2525 | ||
MAIL_USERNAME=null | ||
MAIL_PASSWORD=null | ||
MAIL_ENCRYPTION=null | ||
|
||
AWS_ACCESS_KEY_ID= | ||
AWS_SECRET_ACCESS_KEY= | ||
AWS_DEFAULT_REGION=us-east-1 | ||
AWS_BUCKET= | ||
|
||
PUSHER_APP_ID= | ||
PUSHER_APP_KEY= | ||
PUSHER_APP_SECRET= | ||
PUSHER_APP_CLUSTER=mt1 | ||
|
||
MIX_PUSHER_APP_KEY="${PUSHER_APP_KEY}" | ||
MIX_PUSHER_APP_CLUSTER="${PUSHER_APP_CLUSTER}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
* text=auto | ||
*.css linguist-vendored | ||
*.scss linguist-vendored | ||
*.js linguist-vendored | ||
CHANGELOG.md export-ignore |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
/node_modules | ||
/public/hot | ||
/public/storage | ||
/storage/*.key | ||
/vendor | ||
.env | ||
.env.backup | ||
.phpunit.result.cache | ||
Homestead.json | ||
Homestead.yaml | ||
npm-debug.log | ||
yarn-error.log |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
<?php | ||
|
||
namespace App; | ||
|
||
use App\Traits\Auditable; | ||
use Illuminate\Database\Eloquent\Model; | ||
use Illuminate\Database\Eloquent\SoftDeletes; | ||
|
||
class AccountType extends Model | ||
{ | ||
use SoftDeletes, Auditable; | ||
|
||
public $table = 'account_types'; | ||
|
||
protected $dates = [ | ||
'created_at', | ||
'updated_at', | ||
'deleted_at', | ||
]; | ||
|
||
protected $fillable = [ | ||
'title', | ||
'created_at', | ||
'updated_at', | ||
'deleted_at', | ||
]; | ||
|
||
public function bankAccounts() | ||
{ | ||
return $this->hasMany(BankAccount::class, 'account_type_id', 'id'); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
<?php | ||
|
||
namespace App; | ||
|
||
use Illuminate\Database\Eloquent\Model; | ||
|
||
class AuditLog extends Model | ||
{ | ||
protected $fillable = [ | ||
'description', | ||
'subject_id', | ||
'subject_type', | ||
'user_id', | ||
'properties', | ||
'host', | ||
]; | ||
|
||
protected $casts = [ | ||
'properties' => 'collection', | ||
]; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
<?php | ||
|
||
namespace App; | ||
|
||
use App\Traits\Auditable; | ||
use Carbon\Carbon; | ||
use Illuminate\Database\Eloquent\Model; | ||
use Illuminate\Database\Eloquent\SoftDeletes; | ||
|
||
class BankAccount extends Model | ||
{ | ||
use SoftDeletes, Auditable; | ||
|
||
public $table = 'bank_accounts'; | ||
|
||
protected $dates = [ | ||
'updated_at', | ||
'created_at', | ||
'deleted_at', | ||
'account_opening_date', | ||
]; | ||
|
||
protected $fillable = [ | ||
'balance', | ||
'bank_name', | ||
'created_at', | ||
'updated_at', | ||
'deleted_at', | ||
'branch_name', | ||
'account_title', | ||
'account_number', | ||
'account_type_id', | ||
'account_opening_date', | ||
]; | ||
|
||
public function projects() | ||
{ | ||
return $this->hasMany(Project::class, 'bank_account_id', 'id'); | ||
} | ||
|
||
public function account_type() | ||
{ | ||
return $this->belongsTo(AccountType::class, 'account_type_id'); | ||
} | ||
|
||
public function users() | ||
{ | ||
return $this->belongsToMany(User::class); | ||
} | ||
|
||
public function getAccountOpeningDateAttribute($value) | ||
{ | ||
return $value ? Carbon::parse($value)->format(config('panel.date_format')) : null; | ||
} | ||
|
||
public function setAccountOpeningDateAttribute($value) | ||
{ | ||
$this->attributes['account_opening_date'] = $value ? Carbon::createFromFormat(config('panel.date_format'), $value)->format('Y-m-d') : null; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
<?php | ||
|
||
namespace App\Console; | ||
|
||
use Illuminate\Console\Scheduling\Schedule; | ||
use Illuminate\Foundation\Console\Kernel as ConsoleKernel; | ||
|
||
class Kernel extends ConsoleKernel | ||
{ | ||
/** | ||
* The Artisan commands provided by your application. | ||
* | ||
* @var array | ||
*/ | ||
protected $commands = [ | ||
// | ||
]; | ||
|
||
/** | ||
* Define the application's command schedule. | ||
* | ||
* @param \Illuminate\Console\Scheduling\Schedule $schedule | ||
* @return void | ||
*/ | ||
protected function schedule(Schedule $schedule) | ||
{ | ||
// $schedule->command('inspire') | ||
// ->hourly(); | ||
} | ||
|
||
/** | ||
* Register the commands for the application. | ||
* | ||
* @return void | ||
*/ | ||
protected function commands() | ||
{ | ||
$this->load(__DIR__.'/Commands'); | ||
|
||
require base_path('routes/console.php'); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
<?php | ||
|
||
namespace App\Exceptions; | ||
|
||
use Exception; | ||
use Illuminate\Foundation\Exceptions\Handler as ExceptionHandler; | ||
|
||
class Handler extends ExceptionHandler | ||
{ | ||
/** | ||
* A list of the exception types that are not reported. | ||
* | ||
* @var array | ||
*/ | ||
protected $dontReport = [ | ||
// | ||
]; | ||
|
||
/** | ||
* A list of the inputs that are never flashed for validation exceptions. | ||
* | ||
* @var array | ||
*/ | ||
protected $dontFlash = [ | ||
'password', | ||
'password_confirmation', | ||
]; | ||
|
||
/** | ||
* Report or log an exception. | ||
* | ||
* @param \Exception $exception | ||
* @return void | ||
*/ | ||
public function report(Exception $exception) | ||
{ | ||
parent::report($exception); | ||
} | ||
|
||
/** | ||
* Render an exception into an HTTP response. | ||
* | ||
* @param \Illuminate\Http\Request $request | ||
* @param \Exception $exception | ||
* @return \Illuminate\Http\Response | ||
*/ | ||
public function render($request, Exception $exception) | ||
{ | ||
return parent::render($request, $exception); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
<?php | ||
|
||
namespace App; | ||
|
||
use Carbon\Carbon; | ||
use Illuminate\Database\Eloquent\Model; | ||
use Illuminate\Database\Eloquent\SoftDeletes; | ||
|
||
class Expense extends Model | ||
{ | ||
use SoftDeletes; | ||
|
||
public $table = 'expenses'; | ||
|
||
protected $dates = [ | ||
'entry_date', | ||
'created_at', | ||
'updated_at', | ||
'deleted_at', | ||
]; | ||
|
||
protected $fillable = [ | ||
'amount', | ||
'entry_date', | ||
'created_at', | ||
'updated_at', | ||
'deleted_at', | ||
'description', | ||
'expense_category_id', | ||
]; | ||
|
||
public function expense_category() | ||
{ | ||
return $this->belongsTo(ExpenseCategory::class, 'expense_category_id'); | ||
} | ||
|
||
public function getEntryDateAttribute($value) | ||
{ | ||
return $value ? Carbon::parse($value)->format(config('panel.date_format')) : null; | ||
} | ||
|
||
public function setEntryDateAttribute($value) | ||
{ | ||
$this->attributes['entry_date'] = $value ? Carbon::createFromFormat(config('panel.date_format'), $value)->format('Y-m-d') : null; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
<?php | ||
|
||
namespace App; | ||
|
||
use Illuminate\Database\Eloquent\Model; | ||
use Illuminate\Database\Eloquent\SoftDeletes; | ||
|
||
class ExpenseCategory extends Model | ||
{ | ||
use SoftDeletes; | ||
|
||
public $table = 'expense_categories'; | ||
|
||
protected $dates = [ | ||
'created_at', | ||
'updated_at', | ||
'deleted_at', | ||
]; | ||
|
||
protected $fillable = [ | ||
'name', | ||
'created_at', | ||
'updated_at', | ||
'deleted_at', | ||
]; | ||
|
||
public function expenses() | ||
{ | ||
return $this->hasMany(Expense::class, 'expense_category_id', 'id'); | ||
} | ||
} |
Oops, something went wrong.