v2 first commit

This commit is contained in:
denisdulici
2019-11-16 10:21:14 +03:00
parent 5b23e9c2c4
commit 6d50fa8442
3075 changed files with 3451681 additions and 65594 deletions

View File

@@ -208,7 +208,7 @@ return [
|
| Responses can be returned in multiple formats by registering different
| response formatters. You can also customize an existing response
| formatter.
| formatter with a number of options to configure its output.
|
*/
@@ -220,4 +220,14 @@ return [
],
'formatsOptions' => [
'json' => [
'pretty_print' => env('API_JSON_FORMAT_PRETTY_PRINT_ENABLED', false),
'indent_style' => env('API_JSON_FORMAT_INDENT_STYLE', 'space'),
'indent_size' => env('API_JSON_FORMAT_INDENT_SIZE', 2),
],
],
];

View File

@@ -38,7 +38,7 @@ return [
|
*/
'debug' => env('APP_DEBUG', true),
'debug' => env('APP_DEBUG', false),
/*
|--------------------------------------------------------------------------
@@ -53,6 +53,8 @@ return [
'url' => env('APP_URL', 'http://localhost'),
'asset_url' => env('ASSET_URL', null),
/*
|--------------------------------------------------------------------------
| Application Timezone
@@ -92,6 +94,18 @@ return [
'fallback_locale' => 'en-GB',
/*
|--------------------------------------------------------------------------
| Faker Locale
|--------------------------------------------------------------------------
|
| This locale will be used by the Faker PHP library when generating fake
| data for your database seeds. For example, this will be used to get
| localized telephone numbers, street address information and more.
|
*/
'faker_locale' => 'en_GB',
/*
|--------------------------------------------------------------------------
| Encryption Key
@@ -107,23 +121,6 @@ return [
'cipher' => env('APP_CIPHER', 'AES-256-CBC'),
/*
|--------------------------------------------------------------------------
| Logging Configuration
|--------------------------------------------------------------------------
|
| Here you may configure the log settings for your application. Out of
| the box, Laravel uses the Monolog PHP logging library. This gives
| you a variety of powerful log handlers / formatters to utilize.
|
| Available Settings: "single", "daily", "syslog", "errorlog"
|
*/
'log' => env('APP_LOG', 'single'),
'log_level' => env('APP_LOG_LEVEL', 'debug'),
/*
|--------------------------------------------------------------------------
| Autoloaded Service Providers
@@ -171,41 +168,16 @@ return [
/*
* Application Service Providers...
*/
App\Providers\AppServiceProvider::class,
App\Providers\AuthServiceProvider::class,
// App\Providers\BroadcastServiceProvider::class,
App\Providers\EventServiceProvider::class,
App\Providers\FormServiceProvider::class,
App\Providers\ObserverServiceProvider::class,
App\Providers\RouteServiceProvider::class,
App\Providers\ValidationServiceProvider::class,
App\Providers\ViewComposerServiceProvider::class,
/*
* Vendor Service Providers...
*/
Akaunting\Language\Provider::class,
Akaunting\Money\Provider::class,
Akaunting\Setting\Provider::class,
Akaunting\SignedUrl\Provider::class,
Akaunting\Version\Provider::class,
Barryvdh\DomPDF\ServiceProvider::class,
Bkwld\Cloner\ServiceProvider::class,
Collective\Html\HtmlServiceProvider::class,
ConsoleTVs\Charts\ChartsServiceProvider::class,
Dingo\Api\Provider\LaravelServiceProvider::class,
EloquentFilter\ServiceProvider::class,
Fideloper\Proxy\TrustedProxyServiceProvider::class,
Intervention\Image\ImageServiceProvider::class,
Jenssegers\Date\DateServiceProvider::class,
Kyslik\ColumnSortable\ColumnSortableServiceProvider::class,
Laracasts\Flash\FlashServiceProvider::class,
Laratrust\LaratrustServiceProvider::class,
Maatwebsite\Excel\ExcelServiceProvider::class,
Nwidart\Menus\MenusServiceProvider::class,
Nwidart\Modules\LaravelModulesServiceProvider::class,
Sofa\Eloquence\ServiceProvider::class,
Plank\Mediable\MediableServiceProvider::class,
App\Providers\App::class,
App\Providers\Auth::class,
App\Providers\Blade::class,
// App\Providers\Broadcast::class,
App\Providers\Event::class,
App\Providers\Form::class,
App\Providers\Observer::class,
App\Providers\Route::class,
App\Providers\Validation::class,
App\Providers\ViewComposer::class,
],
@@ -223,6 +195,7 @@ return [
'aliases' => [
'App' => Illuminate\Support\Facades\App::class,
'Arr' => Illuminate\Support\Arr::class,
'Artisan' => Illuminate\Support\Facades\Artisan::class,
'Auth' => Illuminate\Support\Facades\Auth::class,
'Blade' => Illuminate\Support\Facades\Blade::class,
@@ -241,7 +214,6 @@ return [
'Lang' => Illuminate\Support\Facades\Lang::class,
'Log' => Illuminate\Support\Facades\Log::class,
'Mail' => Illuminate\Support\Facades\Mail::class,
'MediaUploader' => Plank\Mediable\MediaUploaderFacade::class,
'Notification' => Illuminate\Support\Facades\Notification::class,
'Password' => Illuminate\Support\Facades\Password::class,
'Queue' => Illuminate\Support\Facades\Queue::class,
@@ -253,29 +225,10 @@ return [
'Schema' => Illuminate\Support\Facades\Schema::class,
'Session' => Illuminate\Support\Facades\Session::class,
'Storage' => Illuminate\Support\Facades\Storage::class,
'Str' => Illuminate\Support\Str::class,
'URL' => Illuminate\Support\Facades\URL::class,
'Validator' => Illuminate\Support\Facades\Validator::class,
'View' => Illuminate\Support\Facades\View::class,
/*
* Vendor Aliases...
*/
//'Api' => Dingo\Api\Facade\API,
'Charts' => ConsoleTVs\Charts\Facades\Charts::class,
'Debugbar' => Barryvdh\Debugbar\Facade::class,
'Date' => Jenssegers\Date\Date::class,
'Excel' => Maatwebsite\Excel\Facades\Excel::class,
'Form' => Collective\Html\FormFacade::class,
'Html' => Collective\Html\HtmlFacade::class,
'Image' => Intervention\Image\Facades\Image::class,
'Language' => Akaunting\Language\Facade::class,
'Laratrust' => Laratrust\LaratrustFacade::class,
'Menu' => Nwidart\Menus\Facades\Menu::class,
'Module' => Nwidart\Modules\Facades\Module::class,
'PDF' => Barryvdh\DomPDF\Facade::class,
'Setting' => Akaunting\Setting\Facade::class,
'SignedUrl' => Akaunting\SignedUrl\Facade::class,
'Version' => Akaunting\Version\Facade::class,
],

View File

@@ -44,6 +44,7 @@ return [
'api' => [
'driver' => 'token',
'provider' => 'users',
'hash' => false,
],
],

View File

@@ -36,7 +36,8 @@ return [
'secret' => env('PUSHER_APP_SECRET'),
'app_id' => env('PUSHER_APP_ID'),
'options' => [
//
'cluster' => env('PUSHER_APP_CLUSTER'),
'useTLS' => true,
],
],

View File

@@ -1,5 +1,7 @@
<?php
use Illuminate\Support\Str;
return [
/*
@@ -11,7 +13,8 @@ return [
| using this caching library. This connection is used when another is
| not explicitly specified when executing a given caching function.
|
| Supported: "apc", "array", "database", "file", "memcached", "redis"
| Supported: "apc", "array", "database", "file",
| "memcached", "redis", "dynamodb"
|
*/
@@ -57,7 +60,7 @@ return [
env('MEMCACHED_PASSWORD'),
],
'options' => [
// Memcached::OPT_CONNECT_TIMEOUT => 2000,
// Memcached::OPT_CONNECT_TIMEOUT => 2000,
],
'servers' => [
[
@@ -70,7 +73,16 @@ return [
'redis' => [
'driver' => 'redis',
'connection' => 'default',
'connection' => 'cache',
],
'dynamodb' => [
'driver' => 'dynamodb',
'key' => env('AWS_ACCESS_KEY_ID'),
'secret' => env('AWS_SECRET_ACCESS_KEY'),
'region' => env('AWS_DEFAULT_REGION', 'us-east-1'),
'table' => env('DYNAMODB_CACHE_TABLE', 'cache'),
'endpoint' => env('DYNAMODB_ENDPOINT'),
],
],
@@ -86,6 +98,6 @@ return [
|
*/
'prefix' => 'laravel',
'prefix' => env('CACHE_PREFIX', Str::slug(env('APP_NAME', 'laravel'), '_') . '_cache'),
];

View File

@@ -1,173 +1,15 @@
<?php
return [
/*
|--------------------------------------------------------------------------
| Default settings for charts.
| Default library used in charts.
|--------------------------------------------------------------------------
|
| This value is used as the default chart library used when creating
| any chart in the command line. Feel free to modify it or set it up
| while creating the chart to ignore this value.
|
*/
'default' => [
'type' => 'line', // The default chart type.
'library' => 'material', // The default chart library.
'element_label' => '', // The default chart element label.
'empty_dataset_label' => 'No Data Set',
'empty_dataset_value' => 0,
'title' => '', // Default chart title.
'height' => 400, // 0 Means it will take 100% of the division height.
'width' => 0, // 0 Means it will take 100% of the division width.
'responsive' => false, // Not recommended since all libraries have diferent sizes.
'background_color' => 'inherit', // The chart division background color.
'colors' => [], // Default chart colors if using no template is set.
'one_color' => false, // Only use the first color in all values.
'template' => 'material', // The default chart color template.
'legend' => true, // Whether to enable the chart legend (where applicable).
'x_axis_title' => false, // The title of the x-axis
'y_axis_title' => null, // The title of the y-axis (When set to null will use element_label value).
'loader' => [
'active' => false, // Determines the if loader is active by default.
'duration' => 500, // In milliseconds.
'color' => '#6da252', // Determines the default loader color.
],
],
/*
|--------------------------------------------------------------------------
| All the color templates available for the charts.
|--------------------------------------------------------------------------
*/
'templates' => [
'material' => [
'#2196F3', '#F44336', '#FFC107',
],
'red-material' => [
'#B71C1C', '#F44336', '#E57373',
],
'indigo-material' => [
'#1A237E', '#3F51B5', '#7986CB',
],
'blue-material' => [
'#0D47A1', '#2196F3', '#64B5F6',
],
'teal-material' => [
'#004D40', '#009688', '#4DB6AC',
],
'green-material' => [
'#1B5E20', '#4CAF50', '#81C784',
],
'yellow-material' => [
'#F57F17', '#FFEB3B', '#FFF176',
],
'orange-material' => [
'#E65100', '#FF9800', '#FFB74D',
],
],
/*
|--------------------------------------------------------------------------
| Assets required by the libraries.
|--------------------------------------------------------------------------
*/
'assets' => [
'global' => [
'scripts' => [
//'https://cdnjs.cloudflare.com/ajax/libs/jquery/3.1.1/jquery.min.js',
],
],
'canvas-gauges' => [
'scripts' => [
//'https://cdn.rawgit.com/Mikhus/canvas-gauges/gh-pages/download/2.1.2/all/gauge.min.js',
],
],
'chartist' => [
'scripts' => [
//'https://cdnjs.cloudflare.com/ajax/libs/chartist/0.10.1/chartist.min.js',
],
'styles' => [
//'https://cdnjs.cloudflare.com/ajax/libs/chartist/0.10.1/chartist.min.css',
],
],
'chartjs' => [
'scripts' => [
app()->runningInConsole() ? '' : asset('public/js/chartjs/Chart.min.js'),
],
],
'fusioncharts' => [
'scripts' => [
//'https://static.fusioncharts.com/code/latest/fusioncharts.js',
//'https://static.fusioncharts.com/code/latest/themes/fusioncharts.theme.fint.js',
],
],
'google' => [
'scripts' => [
//'https://www.google.com/jsapi',
//'https://www.gstatic.com/charts/loader.js',
//"google.charts.load('current', {'packages':['corechart', 'gauge', 'geochart', 'bar', 'line']})",
],
],
'highcharts' => [
'styles' => [
// The following CSS is not added due to color compatibility errors.
// 'https://cdnjs.cloudflare.com/ajax/libs/highcharts/5.0.7/css/highcharts.css',
],
'scripts' => [
//'https://cdnjs.cloudflare.com/ajax/libs/highcharts/5.0.7/highcharts.js',
//'https://cdnjs.cloudflare.com/ajax/libs/highcharts/5.0.7/js/modules/offline-exporting.js',
//'https://cdnjs.cloudflare.com/ajax/libs/highmaps/5.0.7/js/modules/map.js',
//'https://cdnjs.cloudflare.com/ajax/libs/highmaps/5.0.7/js/modules/data.js',
//'https://code.highcharts.com/mapdata/custom/world.js',
],
],
'justgage' => [
'scripts' => [
//'https://cdnjs.cloudflare.com/ajax/libs/raphael/2.2.6/raphael.min.js',
//'https://cdnjs.cloudflare.com/ajax/libs/justgage/1.2.2/justgage.min.js',
],
],
'morris' => [
'styles' => [
//'https://cdnjs.cloudflare.com/ajax/libs/morris.js/0.5.1/morris.css',
],
'scripts' => [
//'https://cdnjs.cloudflare.com/ajax/libs/raphael/2.2.6/raphael.min.js',
//'https://cdnjs.cloudflare.com/ajax/libs/morris.js/0.5.1/morris.min.js',
],
],
'plottablejs' => [
'scripts' => [
//'https://cdnjs.cloudflare.com/ajax/libs/d3/3.5.5/d3.min.js',
//'https://cdnjs.cloudflare.com/ajax/libs/plottable.js/2.8.0/plottable.min.js',
],
'styles' => [
//'https://cdnjs.cloudflare.com/ajax/libs/plottable.js/2.2.0/plottable.css',
],
],
'progressbarjs' => [
'scripts' => [
//'https://cdnjs.cloudflare.com/ajax/libs/progressbar.js/1.0.1/progressbar.min.js',
],
],
'c3' => [
'scripts' => [
//'https://cdnjs.cloudflare.com/ajax/libs/d3/3.5.5/d3.min.js',
//'https://cdnjs.cloudflare.com/ajax/libs/c3/0.4.11/c3.min.js',
],
'styles' => [
//'https://cdnjs.cloudflare.com/ajax/libs/c3/0.4.11/c3.min.css',
],
],
],
'default_library' => 'Chartjs',
];

View File

@@ -7,28 +7,33 @@ return [
*/
'columns' => [
'alpha' => [
'rows' => ['name', 'customer_name', 'vendor_name', 'display_name', 'company_name', 'domain', 'email', 'description', 'code', 'type', 'status', 'vendor', 'account', 'bill_status_code', 'invoice_status_code'],
'class' => 'fa fa-sort-alpha',
'rows' => ['name', 'contact_name', 'customer_name', 'vendor_name', 'display_name', 'company_name', 'domain', 'email', 'description', 'code', 'type', 'status', 'vendor', 'account', 'bill_status_code', 'invoice_status_code'],
'class' => 'fas fa-sort-alpha',
],
'amount' => [
'rows' => ['amount', 'price', 'sale_price', 'purchase_price', 'total_price', 'current_balance', 'total_price', 'opening_balance'],
'class' => 'fa fa-sort-amount'
'class' => 'fas fa-sort-amount',
],
'numeric' => [
'rows' => ['created_at', 'updated_at', 'paid_at', 'invoiced_at', 'billed_at', 'due_at', 'id', 'quantity', 'rate', 'number', 'invoice_number', 'bill_number'],
'class' => 'fa fa-sort-numeric'
'class' => 'fas fa-sort-numeric',
],
],
/*
whether icons should be enabled
*/
'enable_icons' => true,
/*
defines icon set to use when sorted data is none above (alpha nor amount nor numeric)
*/
'default_icon_set' => 'fa fa-long-arrow-down sort-icon',
'default_icon_set' => 'fas fa-arrow-down sort-icon',
/*
icon that shows when generating sortable link while column is not sorted
*/
'sortable_icon' => 'fa fa-long-arrow-down sort-icon',
'sortable_icon' => 'fas fa-arrow-down sort-icon',
/*
generated icon is clickable non-clickable (default)
@@ -44,12 +49,12 @@ return [
/*
suffix class that is appended when ascending order is applied
*/
'asc_suffix' => '-asc',
'asc_suffix' => '-down',
/*
suffix class that is appended when descending order is applied
*/
'desc_suffix' => '-desc',
'desc_suffix' => '-up',
/*
default anchor class, if value is null none is added
@@ -85,5 +90,17 @@ return [
/*
default order for non-sorted columns
*/
'default_direction_unsorted' => 'asc'
'default_direction_unsorted' => 'asc',
/*
use the first defined sortable column (Model::$sortable) as default
also applies if sorting parameters are invalid for example: 'sort' => 'name', 'direction' => ''
*/
'default_first_column' => false,
/*
join type: join vs leftJoin (default leftJoin)
for more information see https://github.com/Kyslik/column-sortable/issues/59
*/
'join_type' => 'leftJoin',
];

View File

@@ -1,5 +1,7 @@
<?php
use Illuminate\Support\Str;
return [
/*
@@ -35,12 +37,15 @@ return [
'sqlite' => [
'driver' => 'sqlite',
'url' => env('DATABASE_URL'),
'database' => env('DB_DATABASE', database_path('database.sqlite')),
'prefix' => env('DB_PREFIX', 'ak_'),
'foreign_key_constraints' => env('DB_FOREIGN_KEYS', true),
],
'mysql' => [
'driver' => 'mysql',
'url' => env('DATABASE_URL'),
'host' => env('DB_HOST', '127.0.0.1'),
'port' => env('DB_PORT', '3306'),
'database' => env('DB_DATABASE', 'forge'),
@@ -50,6 +55,7 @@ return [
'charset' => 'utf8mb4',
'collation' => 'utf8mb4_unicode_ci',
'prefix' => env('DB_PREFIX', 'ak_'),
'prefix_indexes' => true,
'strict' => true,
'engine' => null,
'modes' => [
@@ -60,10 +66,14 @@ return [
'ERROR_FOR_DIVISION_BY_ZERO',
'NO_ENGINE_SUBSTITUTION',
],
'options' => extension_loaded('pdo_mysql') ? array_filter([
PDO::MYSQL_ATTR_SSL_CA => env('MYSQL_ATTR_SSL_CA'),
]) : [],
],
'pgsql' => [
'driver' => 'pgsql',
'url' => env('DATABASE_URL'),
'host' => env('DB_HOST', '127.0.0.1'),
'port' => env('DB_PORT', '5432'),
'database' => env('DB_DATABASE', 'forge'),
@@ -71,10 +81,24 @@ return [
'password' => env('DB_PASSWORD', ''),
'charset' => 'utf8',
'prefix' => env('DB_PREFIX', 'ak_'),
'prefix_indexes' => true,
'schema' => 'public',
'sslmode' => 'prefer',
],
'sqlsrv' => [
'driver' => 'sqlsrv',
'url' => env('DATABASE_URL'),
'host' => env('DB_HOST', 'localhost'),
'port' => env('DB_PORT', '1433'),
'database' => env('DB_DATABASE', 'forge'),
'username' => env('DB_USERNAME', 'forge'),
'password' => env('DB_PASSWORD', ''),
'charset' => 'utf8',
'prefix' => env('DB_PREFIX', 'ak_'),
'prefix_indexes' => true,
],
],
/*
@@ -96,20 +120,34 @@ return [
|--------------------------------------------------------------------------
|
| Redis is an open source, fast, and advanced key-value store that also
| provides a richer set of commands than a typical key-value systems
| provides a richer body of commands than a typical key-value system
| such as APC or Memcached. Laravel makes it easy to dig right in.
|
*/
'redis' => [
'client' => 'predis',
'client' => env('REDIS_CLIENT', 'phpredis'),
'options' => [
'cluster' => env('REDIS_CLUSTER', 'redis'),
'prefix' => env('REDIS_PREFIX', Str::slug(env('APP_NAME', 'laravel'), '_') . '_database_'),
],
'default' => [
'url' => env('REDIS_URL'),
'host' => env('REDIS_HOST', '127.0.0.1'),
'password' => env('REDIS_PASSWORD', null),
'port' => env('REDIS_PORT', 6379),
'database' => 0,
'database' => env('REDIS_DB', 0),
],
'cache' => [
'url' => env('REDIS_URL'),
'host' => env('REDIS_HOST', '127.0.0.1'),
'password' => env('REDIS_PASSWORD', null),
'port' => env('REDIS_PORT', 6379),
'database' => env('REDIS_CACHE_DB', 1),
],
],

View File

@@ -10,9 +10,14 @@ return [
| Debugbar is enabled by default, when debug is set to true in app.php.
| You can override the value by setting enable to true or false instead of null.
|
| You can provide an array of URI's that must be ignored (eg. 'api/*')
|
*/
'enabled' => true,
'enabled' => env('APP_DEBUG', false),
'except' => [
'telescope*'
],
/*
|--------------------------------------------------------------------------
@@ -58,9 +63,22 @@ return [
| The Debugbar can capture Ajax requests and display them. If you don't want this (ie. because of errors),
| you can use this option to disable sending the data through the headers.
|
| Optionally, you can also send ServerTiming headers on ajax requests for the Chrome DevTools.
*/
'capture_ajax' => true,
'add_ajax_timing' => false,
/*
|--------------------------------------------------------------------------
| Custom Error Handler for Deprecated warnings
|--------------------------------------------------------------------------
|
| When enabled, the Debugbar shows deprecated warnings for Symfony components
| in the Messages tab.
|
*/
'error_handler' => false,
/*
|--------------------------------------------------------------------------
@@ -92,17 +110,19 @@ return [
'db' => true, // Show database (PDO) queries and bindings
'views' => true, // Views with their data
'route' => true, // Current route information
'laravel' => false, // Laravel version and environment
'events' => false, // All events fired
'default_request' => false, // Regular or special Symfony request logger
'symfony_request' => true, // Only one can be enabled..
'mail' => true, // Catch mail messages
'logs' => false, // Add the latest log messages
'files' => false, // Show the included files
'config' => false, // Display config settings
'auth' => false, // Display Laravel authentication status
'gate' => false, // Display Laravel Gate checks
'session' => true, // Display session data
'symfony_request' => true, // Only one can be enabled..
'mail' => false, // Catch mail messages
'laravel' => false, // Laravel version and environment
'events' => false, // All events fired
'default_request' => false, // Regular or special Symfony request logger
'logs' => false, // Add the latest log messages
'files' => false, // Show the included files
'config' => false, // Display config settings
'cache' => false, // Display cache events
'models' => false, // Display models
],
/*
@@ -116,15 +136,15 @@ return [
'options' => [
'auth' => [
'show_name' => false, // Also show the users name/email in the debugbar
'show_name' => true, // Also show the users name/email in the debugbar
],
'db' => [
'with_params' => true, // Render SQL with the parameters substituted
'timeline' => false, // Add the queries to the timeline
'backtrace' => false, // EXPERIMENTAL: Use a backtrace to find the origin of the query in your files.
'explain' => [ // EXPERIMENTAL: Show EXPLAIN output on queries
'backtrace' => true, // Use a backtrace to find the origin of the query in your files.
'timeline' => true, // Add the queries to the timeline
'explain' => [ // Show EXPLAIN output on queries
'enabled' => false,
'types' => ['SELECT'], // ['SELECT', 'INSERT', 'UPDATE', 'DELETE']; for MySQL 5.6.3+
'types' => ['SELECT'], // // workaround ['SELECT'] only. https://github.com/barryvdh/laravel-debugbar/issues/888 ['SELECT', 'INSERT', 'UPDATE', 'DELETE']; for MySQL 5.6.3+
],
'hints' => true, // Show hints for common mistakes
],
@@ -140,6 +160,9 @@ return [
'logs' => [
'file' => null
],
'cache' => [
'values' => true // collect cache values
],
],
/*
@@ -167,4 +190,13 @@ return [
*/
'route_prefix' => '_debugbar',
/*
|--------------------------------------------------------------------------
| DebugBar route domain
|--------------------------------------------------------------------------
|
| By default DebugBar route served from the same domain that request served.
| To override default domain, specify it as a non-empty value.
*/
'route_domain' => null,
];

View File

@@ -1,27 +0,0 @@
<?php
return array(
/*
|----------------------------------------------------------------------
| Auto backup mode
|----------------------------------------------------------------------
|
| This value is used when you save your file content. If value is true,
| the original file will be backed up before save.
*/
'autoBackup' => false,
/*
|----------------------------------------------------------------------
| Backup location
|----------------------------------------------------------------------
|
| This value is used when you backup your file. This value is the sub
| path from root folder of project application.
*/
'backupPath' => base_path('storage/dotenv-editor/backups/')
);

View File

@@ -1,16 +0,0 @@
<?php
return [
/*
|--------------------------------------------------------------------------
| Eloquent Filter Settings
|--------------------------------------------------------------------------
|
| This is the namespace all you Eloquent Model Filters will reside
|
*/
'namespace' => 'App\\Filters\\',
];

View File

@@ -1,704 +1,185 @@
<?php
return array(
use Maatwebsite\Excel\Excel;
'cache' => [
return [
'exports' => [
/*
|--------------------------------------------------------------------------
| Enable/Disable cell caching
|--------------------------------------------------------------------------
*/
'enable' => true,
/*
|--------------------------------------------------------------------------
| Caching driver
| Chunk size
|--------------------------------------------------------------------------
|
| Set the caching driver
|
| Available methods:
| memory|gzip|serialized|igbinary|discISAM|apc|memcache|temp|wincache|sqlite|sqlite3
| When using FromQuery, the query is automatically chunked.
| Here you can specify how big the chunk should be.
|
*/
'driver' => 'memory',
/*
|--------------------------------------------------------------------------
| Cache settings
|--------------------------------------------------------------------------
*/
'settings' => [
'memoryCacheSize' => '32MB',
'cacheTime' => 600
],
/*
|--------------------------------------------------------------------------
| Memcache settings
|--------------------------------------------------------------------------
*/
'memcache' => [
'host' => 'localhost',
'port' => 11211,
],
/*
|--------------------------------------------------------------------------
| Cache dir (for discISAM)
|--------------------------------------------------------------------------
*/
'dir' => storage_path('cache')
],
'properties' => [
'creator' => 'Akaunting',
'lastModifiedBy' => 'Akaunting',
'title' => 'Spreadsheet',
'description' => 'Default spreadsheet export',
'subject' => 'Spreadsheet export',
'keywords' => 'akaunting, excel, export',
'category' => 'Excel',
'manager' => 'Akaunting',
'company' => 'Akaunting',
],
/*
|--------------------------------------------------------------------------
| Sheets settings
|--------------------------------------------------------------------------
*/
'sheets' => [
/*
|--------------------------------------------------------------------------
| Default page setup
|--------------------------------------------------------------------------
*/
'pageSetup' => [
'orientation' => 'portrait',
'paperSize' => '9',
'scale' => '100',
'fitToPage' => false,
'fitToHeight' => true,
'fitToWidth' => true,
'columnsToRepeatAtLeft' => ['', ''],
'rowsToRepeatAtTop' => [0, 0],
'horizontalCentered' => false,
'verticalCentered' => false,
'printArea' => null,
'firstPageNumber' => null,
],
],
/*
|--------------------------------------------------------------------------
| Creator
|--------------------------------------------------------------------------
|
| The default creator of a new Excel file
|
*/
'creator' => 'Akaunting',
'csv' => [
/*
|--------------------------------------------------------------------------
| Delimiter
|--------------------------------------------------------------------------
|
| The default delimiter which will be used to read out a CSV file
|
*/
'delimiter' => ',',
/*
|--------------------------------------------------------------------------
| Enclosure
|--------------------------------------------------------------------------
*/
'enclosure' => '"',
/*
|--------------------------------------------------------------------------
| Line endings
|--------------------------------------------------------------------------
*/
'line_ending' => "\r\n",
/*
|--------------------------------------------------------------------------
| setUseBom
|--------------------------------------------------------------------------
*/
'use_bom' => false
],
'export' => [
/*
|--------------------------------------------------------------------------
| Autosize columns
|--------------------------------------------------------------------------
|
| Disable/enable column autosize or set the autosizing for
| an array of columns ( array('A', 'B') )
|
*/
'autosize' => true,
/*
|--------------------------------------------------------------------------
| Autosize method
|--------------------------------------------------------------------------
|
| --> PHPExcel_Shared_Font::AUTOSIZE_METHOD_APPROX
| The default is based on an estimate, which does its calculation based
| on the number of characters in the cell value (applying any calculation
| and format mask, and allowing for wordwrap and rotation) and with an
| "arbitrary" adjustment based on the font (Arial, Calibri or Verdana,
| defaulting to Calibri if any other font is used) and a proportional
| adjustment for the font size.
|
| --> PHPExcel_Shared_Font::AUTOSIZE_METHOD_EXACT
| The second method is more accurate, based on actual style formatting as
| well (bold, italic, etc), and is calculated by generating a gd2 imagettf
| bounding box and using its dimensions to determine the size; but this
| method is significantly slower, and its accuracy is still dependent on
| having the appropriate fonts installed.
|
*/
'autosize-method' => PHPExcel_Shared_Font::AUTOSIZE_METHOD_APPROX,
/*
|--------------------------------------------------------------------------
| Auto generate table heading
|--------------------------------------------------------------------------
|
| If set to true, the array indices (or model attribute names)
| will automatically be used as first row (table heading)
|
*/
'generate_heading_by_indices' => true,
/*
|--------------------------------------------------------------------------
| Auto set alignment on merged cells
|--------------------------------------------------------------------------
*/
'merged_cell_alignment' => 'left',
'chunk_size' => 1000,
/*
|--------------------------------------------------------------------------
| Pre-calculate formulas during export
|--------------------------------------------------------------------------
*/
'calculate' => false,
'pre_calculate_formulas' => false,
/*
|--------------------------------------------------------------------------
| Include Charts during export
| CSV Settings
|--------------------------------------------------------------------------
|
| Configure e.g. delimiter, enclosure and line ending for CSV exports.
|
*/
'includeCharts' => false,
/*
|--------------------------------------------------------------------------
| Default sheet settings
|--------------------------------------------------------------------------
*/
'sheets' => [
/*
|--------------------------------------------------------------------------
| Default page margin
|--------------------------------------------------------------------------
|
| 1) When set to false, default margins will be used
| 2) It's possible to enter a single margin which will
| be used for all margins.
| 3) Alternatively you can pass an array with 4 margins
| Default order: array(top, right, bottom, left)
|
*/
'page_margin' => false,
/*
|--------------------------------------------------------------------------
| Value in source array that stands for blank cell
|--------------------------------------------------------------------------
*/
'nullValue' => null,
/*
|--------------------------------------------------------------------------
| Insert array starting from this cell address as the top left coordinate
|--------------------------------------------------------------------------
*/
'startCell' => 'A1',
/*
|--------------------------------------------------------------------------
| Apply strict comparison when testing for null values in the array
|--------------------------------------------------------------------------
*/
'strictNullComparison' => false
'csv' => [
'delimiter' => ',',
'enclosure' => '"',
'line_ending' => PHP_EOL,
'use_bom' => false,
'include_separator_line' => false,
'excel_compatibility' => false,
],
/*
|--------------------------------------------------------------------------
| Store settings
|--------------------------------------------------------------------------
*/
'store' => [
/*
|--------------------------------------------------------------------------
| Path
|--------------------------------------------------------------------------
|
| The path we want to save excel file to
|
*/
'path' => storage_path('app/exports'),
/*
|--------------------------------------------------------------------------
| Return info
|--------------------------------------------------------------------------
|
| Whether we want to return information about the stored file or not
|
*/
'returnInfo' => false
],
/*
|--------------------------------------------------------------------------
| PDF Settings
|--------------------------------------------------------------------------
*/
'pdf' => [
/*
|--------------------------------------------------------------------------
| PDF Drivers
|--------------------------------------------------------------------------
| Supported: DomPDF, tcPDF, mPDF
*/
'driver' => 'DomPDF',
/*
|--------------------------------------------------------------------------
| PDF Driver settings
|--------------------------------------------------------------------------
*/
'drivers' => [
/*
|--------------------------------------------------------------------------
| DomPDF settings
|--------------------------------------------------------------------------
*/
'DomPDF' => [
'path' => base_path('vendor/dompdf/dompdf/')
],
/*
|--------------------------------------------------------------------------
| tcPDF settings
|--------------------------------------------------------------------------
*/
'tcPDF' => [
'path' => base_path('vendor/tecnick.com/tcpdf/')
],
/*
|--------------------------------------------------------------------------
| mPDF settings
|--------------------------------------------------------------------------
*/
'mPDF' => [
'path' => base_path('vendor/mpdf/mpdf/')
],
]
]
],
'filters' => [
/*
|--------------------------------------------------------------------------
| Register read filters
|--------------------------------------------------------------------------
*/
'imports' => [
'registered' => [
'chunk' => 'Maatwebsite\Excel\Filters\ChunkReadFilter'
'read_only' => true,
'heading_row' => [
/*
|--------------------------------------------------------------------------
| Heading Row Formatter
|--------------------------------------------------------------------------
|
| Configure the heading row formatter.
| Available options: none|slug|custom
|
*/
'formatter' => 'slug',
],
/*
|--------------------------------------------------------------------------
| Enable certain filters for every file read
| CSV Settings
|--------------------------------------------------------------------------
|
| Configure e.g. delimiter, enclosure and line ending for CSV imports.
|
*/
'enabled' => []
'csv' => [
'delimiter' => ',',
'enclosure' => '"',
'escape_character' => '\\',
'contiguous' => false,
'input_encoding' => 'UTF-8',
],
],
'import' => [
/*
|--------------------------------------------------------------------------
| Extension detector
|--------------------------------------------------------------------------
|
| Configure here which writer type should be used when
| the package needs to guess the correct type
| based on the extension alone.
|
*/
'extension_detector' => [
'xlsx' => Excel::XLSX,
'xlsm' => Excel::XLSX,
'xltx' => Excel::XLSX,
'xltm' => Excel::XLSX,
'xls' => Excel::XLS,
'xlt' => Excel::XLS,
'ods' => Excel::ODS,
'ots' => Excel::ODS,
'slk' => Excel::SLK,
'xml' => Excel::XML,
'gnumeric' => Excel::GNUMERIC,
'htm' => Excel::HTML,
'html' => Excel::HTML,
'csv' => Excel::CSV,
'tsv' => Excel::TSV,
/*
|--------------------------------------------------------------------------
| Has heading
| PDF Extension
|--------------------------------------------------------------------------
|
| The sheet has a heading (first) row which we can use as attribute names
|
| Options: true|false|slugged|slugged_with_count|ascii|numeric|hashed|trans|original
| Configure here which Pdf driver should be used by default.
| Available options: Excel::MPDF | Excel::TCPDF | Excel::DOMPDF
|
*/
'heading' => 'slugged',
/*
|--------------------------------------------------------------------------
| First Row with data or heading of data
|--------------------------------------------------------------------------
|
| If the heading row is not the first row, or the data doesn't start
| on the first row, here you can change the start row.
|
*/
'startRow' => 1,
/*
|--------------------------------------------------------------------------
| Cell name word separator
|--------------------------------------------------------------------------
|
| The default separator which is used for the cell names
| Note: only applies to 'heading' settings 'true' && 'slugged'
|
*/
'separator' => '_',
/*
|--------------------------------------------------------------------------
| Slug whitelisting
|--------------------------------------------------------------------------
|
| Here you can whitelist certain characters in the slug.
| E.g. user.last_name will not remove . and _
| Note: only applies to 'heading' settings 'true' && 'slugged'
|
*/
'slug_whitelist' => '._',
/*
|--------------------------------------------------------------------------
| Include Charts during import
|--------------------------------------------------------------------------
*/
'includeCharts' => false,
/*
|--------------------------------------------------------------------------
| Sheet heading conversion
|--------------------------------------------------------------------------
|
| Convert headings to ASCII
| Note: only applies to 'heading' settings 'true' && 'slugged'
|
*/
'to_ascii' => true,
/*
|--------------------------------------------------------------------------
| Import encoding
|--------------------------------------------------------------------------
*/
'encoding' => [
'input' => 'UTF-8',
'output' => 'UTF-8'
],
/*
|--------------------------------------------------------------------------
| Calculate
|--------------------------------------------------------------------------
|
| By default cells with formulas will be calculated.
|
*/
'calculate' => true,
/*
|--------------------------------------------------------------------------
| Ignore empty cells
|--------------------------------------------------------------------------
|
| By default empty cells are not ignored
|
*/
'ignoreEmpty' => true,
/*
|--------------------------------------------------------------------------
| Force sheet collection
|--------------------------------------------------------------------------
|
| For a sheet collection even when there is only 1 sheets.
| When set to false and only 1 sheet found, the parsed file will return
| a row collection instead of a sheet collection.
| When set to true, it will return a sheet collection instead.
|
*/
'force_sheets_collection' => true,
/*
|--------------------------------------------------------------------------
| Date format
|--------------------------------------------------------------------------
|
| The format dates will be parsed to
|
*/
'dates' => [
/*
|--------------------------------------------------------------------------
| Enable/disable date formatting
|--------------------------------------------------------------------------
*/
'enabled' => true,
/*
|--------------------------------------------------------------------------
| Default date format
|--------------------------------------------------------------------------
|
| If set to false, a carbon object will return
|
*/
'format' => false,
/*
|--------------------------------------------------------------------------
| Date columns
|--------------------------------------------------------------------------
*/
'columns' => []
],
/*
|--------------------------------------------------------------------------
| Import sheets by config
|--------------------------------------------------------------------------
*/
'sheets' => [
/*
|--------------------------------------------------------------------------
| Example sheet
|--------------------------------------------------------------------------
|
| Example sheet "test" will grab the firstname at cell A2
|
*/
'test' => [
'firstname' => 'A2'
]
]
'pdf' => Excel::DOMPDF,
],
'views' => [
'value_binder' => [
/*
|--------------------------------------------------------------------------
| Styles
| Default Value Binder
|--------------------------------------------------------------------------
|
| The default styles which will be used when parsing a view
| PhpSpreadsheet offers a way to hook into the process of a value being
| written to a cell. In there some assumptions are made on how the
| value should be formatted. If you want to change those defaults,
| you can implement your own default value binder.
|
*/
'default' => Maatwebsite\Excel\DefaultValueBinder::class,
],
'styles' => [
'transactions' => [
/*
|--------------------------------------------------------------------------
| Table headings
|--------------------------------------------------------------------------
*/
'th' => [
'font' => [
'bold' => true,
'size' => 12,
]
],
/*
|--------------------------------------------------------------------------
| Transaction Handler
|--------------------------------------------------------------------------
|
| By default the import is wrapped in a transaction. This is useful
| for when an import may fail and you want to retry it. With the
| transactions, the previous import gets rolled-back.
|
| You can disable the transaction handler by setting this to null.
| Or you can choose a custom made transaction handler here.
|
| Supported handlers: null|db
|
*/
'handler' => 'db',
],
/*
|--------------------------------------------------------------------------
| Strong tags
|--------------------------------------------------------------------------
*/
'strong' => [
'font' => [
'bold' => true,
'size' => 12,
]
],
'temporary_files' => [
/*
|--------------------------------------------------------------------------
| Bold tags
|--------------------------------------------------------------------------
*/
'b' => [
'font' => [
'bold' => true,
'size' => 12,
]
],
/*
|--------------------------------------------------------------------------
| Local Temporary Path
|--------------------------------------------------------------------------
|
| When exporting and importing files, we use a temporary file, before
| storing reading or downloading. Here you can customize that path.
|
*/
'local_path' => storage_path('app/temp'),
/*
|--------------------------------------------------------------------------
| Italic tags
|--------------------------------------------------------------------------
*/
'i' => [
'font' => [
'italic' => true,
'size' => 12,
]
],
/*
|--------------------------------------------------------------------------
| Remote Temporary Disk
|--------------------------------------------------------------------------
|
| When dealing with a multi server setup with queues in which you
| cannot rely on having a shared local temporary path, you might
| want to store the temporary file on a shared disk. During the
| queue executing, we'll retrieve the temporary file from that
| location instead. When left to null, it will always use
| the local path. This setting only has effect when using
| in conjunction with queued imports and exports.
|
*/
'remote_disk' => null,
/*
|--------------------------------------------------------------------------
| Heading 1
|--------------------------------------------------------------------------
*/
'h1' => [
'font' => [
'bold' => true,
'size' => 24,
]
],
/*
|--------------------------------------------------------------------------
| Heading 2
|--------------------------------------------------------------------------
*/
'h2' => [
'font' => [
'bold' => true,
'size' => 18,
]
],
/*
|--------------------------------------------------------------------------
| Heading 3
|--------------------------------------------------------------------------
*/
'h3' => [
'font' => [
'bold' => true,
'size' => 13.5,
]
],
/*
|--------------------------------------------------------------------------
| Heading 4
|--------------------------------------------------------------------------
*/
'h4' => [
'font' => [
'bold' => true,
'size' => 12,
]
],
/*
|--------------------------------------------------------------------------
| Heading 5
|--------------------------------------------------------------------------
*/
'h5' => [
'font' => [
'bold' => true,
'size' => 10,
]
],
/*
|--------------------------------------------------------------------------
| Heading 6
|--------------------------------------------------------------------------
*/
'h6' => [
'font' => [
'bold' => true,
'size' => 7.5,
]
],
/*
|--------------------------------------------------------------------------
| Hyperlinks
|--------------------------------------------------------------------------
*/
'a' => [
'font' => [
'underline' => true,
'color' => ['argb' => 'FF0000FF'],
]
],
/*
|--------------------------------------------------------------------------
| Horizontal rules
|--------------------------------------------------------------------------
*/
'hr' => [
'borders' => [
'bottom' => [
'style' => 'thin',
'color' => ['FF000000']
],
]
]
]
]
);
],
];

View File

@@ -13,7 +13,7 @@ return [
|
*/
'default' => 'uploads',
'default' => env('FILESYSTEM_DRIVER', 'uploads'),
/*
|--------------------------------------------------------------------------
@@ -26,7 +26,24 @@ return [
|
*/
'cloud' => 's3',
'cloud' => env('FILESYSTEM_CLOUD', 's3'),
/*
|--------------------------------------------------------------------------
| Allowed file mimes
|--------------------------------------------------------------------------
*/
'mimes' => env('FILESYSTEM_MIMES', 'pdf,jpeg,jpg,png'),
/*
|--------------------------------------------------------------------------
| Allowed file max size, in MB
|--------------------------------------------------------------------------
*/
'max_size' => env('FILESYSTEM_MAX_SIZE', '2'),
/*
|--------------------------------------------------------------------------
@@ -37,7 +54,7 @@ return [
| may even configure multiple disks of the same driver. Defaults have
| been setup for each driver as an example of the required options.
|
| Supported Drivers: "local", "ftp", "s3", "rackspace"
| Supported Drivers: "local", "ftp", "sftp", "s3"
|
*/
@@ -64,10 +81,11 @@ return [
's3' => [
'driver' => 's3',
'key' => env('AWS_KEY'),
'secret' => env('AWS_SECRET'),
'region' => env('AWS_REGION'),
'key' => env('AWS_ACCESS_KEY_ID'),
'secret' => env('AWS_SECRET_ACCESS_KEY'),
'region' => env('AWS_DEFAULT_REGION'),
'bucket' => env('AWS_BUCKET'),
'url' => app()->runningInConsole() ? '' : url('/'),
],
],

401
config/firewall.php Normal file
View File

@@ -0,0 +1,401 @@
<?php
return [
'enabled' => env('FIREWALL_ENABLED', false),
'whitelist' => [env('FIREWALL_WHITELIST', '')],
'models' => [
'user' => '\App\Models\Auth\User',
],
'responses' => [
'block' => [
'view' => env('FIREWALL_BLOCK_VIEW', null),
'redirect' => env('FIREWALL_BLOCK_REDIRECT', null),
'abort' => env('FIREWALL_BLOCK_ABORT', false),
'code' => env('FIREWALL_BLOCK_CODE', 403),
],
],
'notifications' => [
'mail' => [
'enabled' => env('FIREWALL_EMAIL_ENABLED', false),
'name' => env('FIREWALL_EMAIL_NAME', 'Akaunting Firewall'),
'from' => env('FIREWALL_EMAIL_FROM', 'firewall@mydomain.com'),
'to' => [env('FIREWALL_EMAIL_TO', 'admin@mydomain.com')],
],
'slack' => [
'enabled' => env('FIREWALL_SLACK_ENABLED', false),
'from' => env('FIREWALL_SLACK_FROM', 'Akaunting Firewall'),
'to' => env('FIREWALL_SLACK_TO', '#my-channel'),
'emoji' => env('FIREWALL_SLACK_EMOJI', ':fire:'),
],
],
'all_middleware' => [
'firewall.ip',
'firewall.agent',
'firewall.bot',
'firewall.geo',
'firewall.lfi',
'firewall.php',
'firewall.referrer',
'firewall.rfi',
'firewall.session',
'firewall.sqli',
'firewall.swear',
'firewall.xss',
//'App\Http\Middleware\YourCustomRule',
],
'middleware' => [
'ip' => [
'methods' => ['all'],
'routes' => [
'only' => [], // i.e. 'contact'
'except' => [], // i.e. 'admin/*'
],
],
'agent' => [
'methods' => ['all'],
'routes' => [
'only' => [], // i.e. 'contact'
'except' => [], // i.e. 'admin/*'
],
// https://github.com/jenssegers/agent
'browsers' => [
'allow' => [], // i.e. 'Chrome', 'Firefox'
'block' => [], // i.e. 'IE'
],
'platforms' => [
'allow' => [], // i.e. 'Ubuntu', 'Windows'
'block' => [], // i.e. 'OS X'
],
'devices' => [
'allow' => [], // i.e. 'Desktop', 'Mobile'
'block' => [], // i.e. 'Tablet'
],
'properties' => [
'allow' => [], // i.e. 'Gecko', 'Version/5.1.7'
'block' => [], // i.e. 'AppleWebKit'
],
'auto_block' => [
'attempts' => 5,
'frequency' => 1 * 60, // 1 minute
'period' => 30 * 60, // 30 minutes
],
],
'bot' => [
'methods' => ['all'],
'routes' => [
'only' => [], // i.e. 'contact'
'except' => [], // i.e. 'admin/*'
],
// https://github.com/JayBizzle/Crawler-Detect/blob/master/raw/Crawlers.txt
'crawlers' => [
'allow' => [], // i.e. 'GoogleSites', 'GuzzleHttp'
'block' => [], // i.e. 'Holmes'
],
'auto_block' => [
'attempts' => 5,
'frequency' => 1 * 60, // 1 minute
'period' => 30 * 60, // 30 minutes
],
],
'geo' => [
'methods' => ['all'],
'routes' => [
'only' => [], // i.e. 'contact'
'except' => [], // i.e. 'admin/*'
],
'continents' => [
'allow' => [], // i.e. 'Africa'
'block' => [], // i.e. 'Europe'
],
'regions' => [
'allow' => [], // i.e. 'California'
'block' => [], // i.e. 'Nevada'
],
'countries' => [
'allow' => [], // i.e. 'Albania'
'block' => [], // i.e. 'Madagascar'
],
'cities' => [
'allow' => [], // i.e. 'Istanbul'
'block' => [], // i.e. 'London'
],
// ipapi, extremeiplookup, ipstack, ipdata, ipinfo
'service' => 'ipapi',
'auto_block' => [
'attempts' => 3,
'frequency' => 5 * 60, // 5 minutes
'period' => 30 * 60, // 30 minutes
],
],
'lfi' => [
'methods' => ['get', 'delete'],
'routes' => [
'only' => [], // i.e. 'contact'
'except' => [], // i.e. 'admin/*'
],
'inputs' => [
'only' => [], // i.e. 'first_name'
'except' => [], // i.e. 'password'
],
'patterns' => [
'#\.\/#is',
],
'auto_block' => [
'attempts' => 3,
'frequency' => 5 * 60, // 5 minutes
'period' => 30 * 60, // 30 minutes
],
],
'login' => [
'enabled' => true,
'auto_block' => [
'attempts' => 5,
'frequency' => 1 * 60, // 1 minute
'period' => 30 * 60, // 30 minutes
],
],
'php' => [
'methods' => ['get', 'post', 'delete'],
'routes' => [
'only' => [], // i.e. 'contact'
'except' => [], // i.e. 'admin/*'
],
'inputs' => [
'only' => [], // i.e. 'first_name'
'except' => [], // i.e. 'password'
],
'patterns' => [
'bzip2://',
'expect://',
'glob://',
'phar://',
'php://',
'ogg://',
'rar://',
'ssh2://',
'zip://',
'zlib://',
],
'auto_block' => [
'attempts' => 3,
'frequency' => 5 * 60, // 5 minutes
'period' => 30 * 60, // 30 minutes
],
],
'referrer' => [
'methods' => ['all'],
'routes' => [
'only' => [], // i.e. 'contact'
'except' => [], // i.e. 'admin/*'
],
'blocked' => [],
'auto_block' => [
'attempts' => 3,
'frequency' => 5 * 60, // 5 minutes
'period' => 30 * 60, // 30 minutes
],
],
'rfi' => [
'methods' => ['get', 'post', 'delete'],
'routes' => [
'only' => [], // i.e. 'contact'
'except' => [], // i.e. 'admin/*'
],
'inputs' => [
'only' => [], // i.e. 'first_name'
'except' => [], // i.e. 'password'
],
'patterns' => [
'#(http|ftp){1,1}(s){0,1}://.*#i',
],
'exceptions' => [],
'auto_block' => [
'attempts' => 3,
'frequency' => 5 * 60, // 5 minutes
'period' => 30 * 60, // 30 minutes
],
],
'session' => [
'methods' => ['get', 'post', 'delete'],
'routes' => [
'only' => [], // i.e. 'contact'
'except' => [], // i.e. 'admin/*'
],
'inputs' => [
'only' => [], // i.e. 'first_name'
'except' => [], // i.e. 'password'
],
'patterns' => [
'@[\|:]O:\d{1,}:"[\w_][\w\d_]{0,}":\d{1,}:{@i',
'@[\|:]a:\d{1,}:{@i',
],
'auto_block' => [
'attempts' => 3,
'frequency' => 5 * 60, // 5 minutes
'period' => 30 * 60, // 30 minutes
],
],
'sqli' => [
'methods' => ['get', 'delete'],
'routes' => [
'only' => [], // i.e. 'contact'
'except' => [], // i.e. 'admin/*'
],
'inputs' => [
'only' => [], // i.e. 'first_name'
'except' => [], // i.e. 'password'
],
'patterns' => [
'#[\d\W](union select|union join|union distinct)[\d\W]#is',
'#[\d\W](union|union select|insert|from|where|concat|into|cast|truncate|select|delete|having)[\d\W]#is',
],
'auto_block' => [
'attempts' => 3,
'frequency' => 5 * 60, // 5 minutes
'period' => 30 * 60, // 30 minutes
],
],
'swear' => [
'methods' => ['post', 'put', 'patch'],
'routes' => [
'only' => [], // i.e. 'contact'
'except' => [], // i.e. 'admin/*'
],
'inputs' => [
'only' => [], // i.e. 'first_name'
'except' => [], // i.e. 'password'
],
'words' => [],
'auto_block' => [
'attempts' => 3,
'frequency' => 5 * 60, // 5 minutes
'period' => 30 * 60, // 30 minutes
],
],
'url' => [
'methods' => ['all'],
'inspections' => [], // i.e. 'admin'
'auto_block' => [
'attempts' => 5,
'frequency' => 1 * 60, // 1 minute
'period' => 30 * 60, // 30 minutes
],
],
'whitelist' => [
'methods' => ['all'],
'routes' => [
'only' => [], // i.e. 'contact'
'except' => [], // i.e. 'admin/*'
],
],
'xss' => [
'methods' => ['post', 'put', 'patch'],
'routes' => [
'only' => [], // i.e. 'contact'
'except' => [], // i.e. 'admin/*'
],
'inputs' => [
'only' => [], // i.e. 'first_name'
'except' => [], // i.e. 'password'
],
'patterns' => [
// Evil starting attributes
'#(<[^>]+[\x00-\x20\"\'\/])(form|formaction|on\w*|style|xmlns|xlink:href)[^>]*>?#iUu',
// javascript:, livescript:, vbscript:, mocha: protocols
'!((java|live|vb)script|mocha|feed|data):(\w)*!iUu',
'#-moz-binding[\x00-\x20]*:#u',
// Unneeded tags
'#</*(applet|meta|xml|blink|link|style|script|embed|object|iframe|frame|frameset|ilayer|layer|bgsound|title|base)[^>]*>?#i'
],
'auto_block' => [
'attempts' => 3,
'frequency' => 5 * 60, // 5 minutes
'period' => 30 * 60, // 30 minutes
],
],
],
];

52
config/hashing.php Normal file
View File

@@ -0,0 +1,52 @@
<?php
return [
/*
|--------------------------------------------------------------------------
| Default Hash Driver
|--------------------------------------------------------------------------
|
| This option controls the default hash driver that will be used to hash
| passwords for your application. By default, the bcrypt algorithm is
| used; however, you remain free to modify this option if you wish.
|
| Supported: "bcrypt", "argon", "argon2id"
|
*/
'driver' => 'bcrypt',
/*
|--------------------------------------------------------------------------
| Bcrypt Options
|--------------------------------------------------------------------------
|
| Here you may specify the configuration options that should be used when
| passwords are hashed using the Bcrypt algorithm. This will allow you
| to control the amount of time it takes to hash the given password.
|
*/
'bcrypt' => [
'rounds' => env('BCRYPT_ROUNDS', 10),
],
/*
|--------------------------------------------------------------------------
| Argon Options
|--------------------------------------------------------------------------
|
| Here you may specify the configuration options that should be used when
| passwords are hashed using the Argon algorithm. These will allow you
| to control the amount of time it takes to hash the given password.
|
*/
'argon' => [
'memory' => 1024,
'threads' => 2,
'time' => 2,
],
];

View File

@@ -20,6 +20,53 @@ return [
*/
'use_morph_map' => true,
/*
|--------------------------------------------------------------------------
| Which permissions and role checker to use.
|--------------------------------------------------------------------------
|
| Defines if you want to use the roles and permissions checker.
| Available:
| - default: Check for the roles and permissions using the method that Laratrust
has always used.
| - query: Check for the roles and permissions using direct queries to the database.
| This method doesn't support cache yet.
|
*/
'checker' => 'default',
/*
|--------------------------------------------------------------------------
| Cache
|--------------------------------------------------------------------------
|
| Manage Laratrust's cache configurations. It uses the driver defined in the
| config/cache.php file.
|
*/
'cache' => [
/*
|--------------------------------------------------------------------------
| Use cache in the package
|--------------------------------------------------------------------------
|
| Defines if Laratrust will use Laravel's Cache to cache the roles and permissions.
| NOTE: Currently the database check does not use cache.
|
*/
'enabled' => true,
/*
|--------------------------------------------------------------------------
| Time to store in cache Laratrust's roles and permissions.
|--------------------------------------------------------------------------
|
| Determines the time in SECONDS to store Laratrust's roles and permissions in the cache.
|
*/
'expiration_time' => 3600,
],
/*
|--------------------------------------------------------------------------
| Use teams feature in the package
@@ -31,6 +78,19 @@ return [
*/
'use_teams' => false,
/*
|--------------------------------------------------------------------------
| Strict check for roles/permissions inside teams
|--------------------------------------------------------------------------
|
| Determines if a strict check should be done when checking if a role or permission
| is attached inside a team.
| If it's false, when checking a role/permission without specifying the team,
| it will check only if the user has attached that role/permission ignoring the team.
|
*/
'teams_strict_check' => false,
/*
|--------------------------------------------------------------------------
| Laratrust User Models
@@ -152,21 +212,46 @@ return [
| Laratrust Middleware
|--------------------------------------------------------------------------
|
| This configuration helps to customize the Laratrust middlewares behavior.
| This configuration helps to customize the Laratrust middleware behavior.
|
*/
'middleware' => [
/**
* Define if the laratrust middleware are registered automatically in the service provider
*/
'register' => false,
/**
* Method to be called in the middleware return case.
* Available: abort|redirect
*/
'handling' => 'redirect',
'handling' => 'abort',
/**
* Parameter passed to the middleware_handling method
* Handlers for the unauthorized method in the middlewares.
* The name of the handler must be the same as the handling.
*/
'params' => 'auth/login',
'handlers' => [
/**
* Aborts the execution with a 403 code.
*/
'abort' => [
'code' => 403
],
/**
* Redirects the user to the given url.
* If you want to flash a key to the session,
* you can do it by setting the key and the content of the message
* If the message content is empty it won't be added to the redirection.
*/
'redirect' => [
'url' => 'auth/login',
'message' => [
'key' => 'error',
'content' => ''
]
]
]
],
/*

View File

@@ -0,0 +1,22 @@
<?php
return [
//'default_namespace' => 'App\Widgets',
'use_jquery_for_ajax_calls' => false,
/*
* Set Ajax widget middleware
*/
'route_middleware' => ['web'],
/*
* Relative path from the base directory to a regular widget stub.
*/
'widget_stub' => 'vendor/arrilot/laravel-widgets/src/Console/stubs/widget.stub',
/*
* Relative path from the base directory to a plain widget stub.
*/
'widget_plain_stub' => 'vendor/arrilot/laravel-widgets/src/Console/stubs/widget_plain.stub',
];

101
config/logging.php Normal file
View File

@@ -0,0 +1,101 @@
<?php
use Monolog\Handler\NullHandler;
use Monolog\Handler\StreamHandler;
use Monolog\Handler\SyslogUdpHandler;
return [
/*
|--------------------------------------------------------------------------
| Default Log Channel
|--------------------------------------------------------------------------
|
| This option defines the default log channel that gets used when writing
| messages to the logs. The name specified in this option should match
| one of the channels defined in the "channels" configuration array.
|
*/
'default' => env('LOG_CHANNEL', 'stack'),
/*
|--------------------------------------------------------------------------
| Log Channels
|--------------------------------------------------------------------------
|
| Here you may configure the log channels for your application. Out of
| the box, Laravel uses the Monolog PHP logging library. This gives
| you a variety of powerful log handlers / formatters to utilize.
|
| Available Drivers: "single", "daily", "slack", "syslog",
| "errorlog", "monolog",
| "custom", "stack"
|
*/
'channels' => [
'stack' => [
'driver' => 'stack',
'channels' => ['daily'],
'ignore_exceptions' => false,
],
'single' => [
'driver' => 'single',
'path' => storage_path('logs/laravel.log'),
'level' => 'debug',
],
'daily' => [
'driver' => 'daily',
'path' => storage_path('logs/laravel.log'),
'level' => 'debug',
'days' => 14,
],
'slack' => [
'driver' => 'slack',
'url' => env('LOG_SLACK_WEBHOOK_URL'),
'username' => 'Laravel Log',
'emoji' => ':boom:',
'level' => 'critical',
],
'papertrail' => [
'driver' => 'monolog',
'level' => 'debug',
'handler' => SyslogUdpHandler::class,
'handler_with' => [
'host' => env('PAPERTRAIL_URL'),
'port' => env('PAPERTRAIL_PORT'),
],
],
'stderr' => [
'driver' => 'monolog',
'handler' => StreamHandler::class,
'formatter' => env('LOG_STDERR_FORMATTER'),
'with' => [
'stream' => 'php://stderr',
],
],
'syslog' => [
'driver' => 'syslog',
'level' => 'debug',
],
'errorlog' => [
'driver' => 'errorlog',
'level' => 'debug',
],
'null' => [
'driver' => 'monolog',
'handler' => NullHandler::class,
],
],
];

View File

@@ -11,12 +11,12 @@ return [
| sending of e-mail. You may specify which one you're using throughout
| your application here. By default, Laravel is setup for SMTP mail.
|
| Supported: "smtp", "sendmail", "mailgun", "mandrill", "ses",
| "sparkpost", "log", "array"
| Supported: "smtp", "sendmail", "mailgun", "ses",
| "postmark", "log", "array"
|
*/
'driver' => env('MAIL_DRIVER', 'mail'),
'driver' => env('MAIL_DRIVER', 'smtp'),
/*
|--------------------------------------------------------------------------
@@ -29,7 +29,7 @@ return [
|
*/
'host' => env('MAIL_HOST', 'localhost'),
'host' => env('MAIL_HOST', 'smtp.mailgun.org'),
/*
|--------------------------------------------------------------------------
@@ -120,4 +120,17 @@ return [
],
],
/*
|--------------------------------------------------------------------------
| Log Channel
|--------------------------------------------------------------------------
|
| If you are using the "log" driver, you may specify the logging channel
| if you prefer to keep mail messages separate from other log entries
| for simpler reading. Otherwise, the default channel will be used.
|
*/
'log_channel' => env('MAIL_LOG_CHANNEL'),
];

107
config/maintenancemode.php Normal file
View File

@@ -0,0 +1,107 @@
<?php
return [
/**
* The view to show to users when maintenance mode is currently enabled
*
* @var string
*/
'view' => 'maintenancemode::app-down',
/**
* Include CSS styles with the optional notification view
*
* @var boolean
*/
'notification-styles' => true,
/**
* Configuration values for injecting variables into the views
*
* Variables available:
* [prefix]Enabled - If maintenance mode is currently enabled
* [prefix]Timestamp - The timestamp of when maintenance mode was enabled
* [prefix]Message - The message passed in with the command, if applicable
*
* @var array
*/
'inject' => [
/**
* Make variables accessible in all views
*
* If set to false, only the maintenance page will have access to these variables
*
* @var boolean
*/
'global' => true,
/**
* Prefix the variables to prevent name collisions
*
* @var string
*/
'prefix' => 'MaintenanceMode',
],
/**
* The path to the language file to use
*
* @var string
*/
'language-path' => 'maintenance',
/**
* An array of IP address that will never see the maintenance page
*
* To be used in conjunction with the IPWhitelist exemption class
*
* @var array
*/
'exempt-ips' => [env('MAINTENANCE_EXEMPT_IPS')],
/**
* Use proxies to get the user's IP address
*
* See: http://symfony.com/doc/current/components/http_foundation/trusting_proxies.html
*
* @var boolean
*/
'exempt-ips-proxy' => false,
/**
* An array of environments that will never show the maintenance page
*
* To be used in conjunction with the EnvironmentWhitelist exemption class
*
* @var array
*/
'exempt-environments' => [env('MAINTENANCE_EXEMPT_ENVIRONMENTS', 'local')],
/**
* A list of exemption classes to execute
*
* Each of these classes should extend
* \MisterPhilip\MaintenanceMode\Exemptions\MaintenanceModeExemption
* and contain an "isExempt" method that returns a boolean value on
* if the user should or should not see the maintenance page.
*
* To create your own, simply add it to the list below. For more information and examples, see:
* https://github.com/MisterPhilip/maintenance-mode/blob/master/examples/exemptions
*
* @var array
*/
'exemptions' => [
/*
* IPWhitelist exempts users with the IPs matched in the "exempt-ips" config
*/
MisterPhilip\MaintenanceMode\Exemptions\IPWhitelist::class,
/*
* EnvironmentWhitelist exempts installations with environments matched in the "exempt-environments" config
*/
MisterPhilip\MaintenanceMode\Exemptions\EnvironmentWhitelist::class,
],
];

27
config/menu.php Normal file
View File

@@ -0,0 +1,27 @@
<?php
return [
'styles' => [
// Boostrap 3
'bs3-navbar' => \Akaunting\Menu\Presenters\Bootstrap3\Navbar::class,
'bs3-navbar-right' => \Akaunting\Menu\Presenters\Bootstrap3\NavbarRight::class,
'bs3-nav-pills' => \Akaunting\Menu\Presenters\Bootstrap3\NavPills::class,
'bs3-nav-tab' => \Akaunting\Menu\Presenters\Bootstrap3\NavTab::class,
'bs3-sidebar' => \Akaunting\Menu\Presenters\Bootstrap3\Sidebar::class,
'bs3-navmenu' => \Akaunting\Menu\Presenters\Bootstrap3\Nav::class,
// Zurb
'zurb' => \Akaunting\Menu\Presenters\Foundation\Zurb::class,
// Admin
'adminlte' => \Akaunting\Menu\Presenters\Admin\Adminlte::class,
'argon' => \Akaunting\Menu\Presenters\Admin\Argon::class,
'metronic-horizontal' => \Akaunting\Menu\Presenters\Admin\MetronicHorizontal::class,
],
'ordering' => true,
];

View File

@@ -1,18 +0,0 @@
<?php
return [
'styles' => [
'navbar' => \Nwidart\Menus\Presenters\Bootstrap\NavbarPresenter::class,
'navbar-right' => \Nwidart\Menus\Presenters\Bootstrap\NavbarRightPresenter::class,
'nav-pills' => \Nwidart\Menus\Presenters\Bootstrap\NavPillsPresenter::class,
'nav-tab' => \Nwidart\Menus\Presenters\Bootstrap\NavTabPresenter::class,
'sidebar' => \Nwidart\Menus\Presenters\Bootstrap\SidebarMenuPresenter::class,
'navmenu' => \Nwidart\Menus\Presenters\Bootstrap\NavMenuPresenter::class,
'adminlte' => \Nwidart\Menus\Presenters\Admin\AdminltePresenter::class,
'zurbmenu' => \Nwidart\Menus\Presenters\Foundation\ZurbMenuPresenter::class,
],
'ordering' => true,
];

View File

@@ -1,6 +1,7 @@
<?php
return [
/*
|--------------------------------------------------------------------------
| Module Namespace
@@ -23,20 +24,23 @@ return [
'enabled' => true,
'path' => base_path() . '/app/Console/Stubs/Modules',
'files' => [
'start' => 'start.php',
'routes' => 'Http/routes.php',
'routes/admin' => 'Routes/admin.php',
'routes/portal' => 'Routes/portal.php',
'lang/general' => 'Resources/lang/en-GB/general.php',
'views/index' => 'Resources/views/index.blade.php',
'views/master' => 'Resources/views/layouts/master.blade.php',
'scaffold/config' => 'Config/config.php',
'composer' => 'composer.json',
'assets/js/app' => 'Resources/assets/js/app.js',
'assets/sass/app' => 'Resources/assets/sass/app.scss',
'webpack' => 'webpack.mix.js',
'package' => 'package.json',
],
'replacements' => [
'start' => ['LOWER_NAME'],
'routes' => ['LOWER_NAME', 'STUDLY_NAME', 'MODULE_NAMESPACE'],
'json' => ['LOWER_NAME', 'STUDLY_NAME', 'MODULE_NAMESPACE'],
'views/index' => ['LOWER_NAME'],
'views/master' => ['STUDLY_NAME'],
'scaffold/config' => ['STUDLY_NAME'],
'routes/admin' => ['ALIAS', 'STUDLY_NAME'],
'routes/portal' => ['ALIAS', 'STUDLY_NAME'],
'webpack' => ['ALIAS'],
'json' => ['ALIAS', 'STUDLY_NAME', 'MODULE_NAMESPACE'],
'lang/general' => ['ALIAS', 'STUDLY_NAME'],
'views/index' => ['ALIAS', 'STUDLY_NAME'],
'composer' => [
'LOWER_NAME',
'STUDLY_NAME',
@@ -46,14 +50,16 @@ return [
'MODULE_NAMESPACE',
],
],
'gitkeep' => false,
],
'paths' => [
/*
|--------------------------------------------------------------------------
| Modules path
|--------------------------------------------------------------------------
|
| This path used for save the generated module. This path also will added
| This path used for save the generated module. This path also will be added
| automatically to list of scanned folders.
|
*/
@@ -67,7 +73,7 @@ return [
| Here you may update the modules assets path.
|
*/
'assets' => public_path('public/modules'),
'assets' => public_path('modules'),
/*
|--------------------------------------------------------------------------
@@ -84,29 +90,34 @@ return [
|--------------------------------------------------------------------------
| Generator path
|--------------------------------------------------------------------------
|
| Here you may update the modules generator path.
|
| Customise the paths where the folders will be generated.
| Set the generate key to false to not generate that folder
*/
'generator' => [
'assets' => 'Assets',
'config' => 'Config',
'command' => 'Console',
'event' => 'Events',
'listener' => 'Listeners',
'migration' => 'Database/Migrations',
'model' => 'Models',
'repository' => 'Repositories',
'seeder' => 'Database/Seeders',
'controller' => 'Http/Controllers',
'filter' => 'Http/Middleware',
'request' => 'Http/Requests',
'provider' => 'Providers',
'lang' => 'Resources/lang',
'views' => 'Resources/views',
'test' => 'Tests',
'jobs' => 'Jobs',
'emails' => 'Mail',
'config' => ['path' => 'Config', 'generate' => false],
'command' => ['path' => 'Console', 'generate' => true],
'migration' => ['path' => 'Database/Migrations', 'generate' => true],
'seeder' => ['path' => 'Database/Seeders', 'generate' => true],
'factory' => ['path' => 'Database/factories', 'generate' => false],
'model' => ['path' => 'Models', 'generate' => true],
'controller' => ['path' => 'Http/Controllers', 'generate' => true],
'middleware' => ['path' => 'Http/Middleware', 'generate' => false],
'request' => ['path' => 'Http/Requests', 'generate' => true],
'provider' => ['path' => 'Providers', 'generate' => true],
'resource' => ['path' => 'Http/Resources', 'generate' => false],
'asset' => ['path' => 'Resources/assets', 'generate' => false],
'lang' => ['path' => 'Resources/lang/en-GB', 'generate' => true],
'views' => ['path' => 'Resources/views', 'generate' => true],
'test' => ['path' => 'Tests', 'generate' => false],
'repository' => ['path' => 'Repositories', 'generate' => false],
'event' => ['path' => 'Events', 'generate' => false],
'listener' => ['path' => 'Listeners', 'generate' => true],
'policy' => ['path' => 'Policies', 'generate' => false],
'rule' => ['path' => 'Rules', 'generate' => false],
'job' => ['path' => 'Jobs', 'generate' => true],
'email' => ['path' => 'Emails', 'generate' => false],
'notification' => ['path' => 'Notifications', 'generate' => false],
'route' => ['path' => 'Routes', 'generate' => true],
],
],
@@ -152,18 +163,25 @@ return [
*/
'cache' => [
'enabled' => true,
'key' => 'modules',
'key' => 'module',
'lifetime' => 60,
],
/*
|--------------------------------------------------------------------------
| Choose what laravel-modules will register as custom namespaces.
| Setting one to false will require to register that part
| Choose what module will register as custom namespaces.
| Setting one to false will require you to register that part
| in your own Service Provider class.
|--------------------------------------------------------------------------
*/
'register' => [
'translations' => true,
/**
* load files on boot or register method
*
* @example boot|register
*/
'files' => 'register',
],
];

View File

@@ -4,18 +4,16 @@ return [
/*
|--------------------------------------------------------------------------
| Default Queue Driver
| Default Queue Connection Name
|--------------------------------------------------------------------------
|
| Laravel's queue API supports an assortment of back-ends via a single
| API, giving you convenient access to each back-end using the same
| syntax for each one. Here you may set the default queue driver.
|
| Supported: "sync", "database", "beanstalkd", "sqs", "redis", "null"
| syntax for every one. Here you may define a default connection.
|
*/
'default' => env('QUEUE_DRIVER', 'database'),
'default' => env('QUEUE_CONNECTION', 'sync'),
/*
|--------------------------------------------------------------------------
@@ -26,6 +24,8 @@ return [
| is used by your application. A default configuration has been added
| for each back-end shipped with Laravel. You are free to add more.
|
| Drivers: "sync", "database", "beanstalkd", "sqs", "redis", "null"
|
*/
'connections' => [
@@ -38,7 +38,6 @@ return [
'driver' => 'database',
'table' => 'jobs',
'queue' => 'default',
'delay' => 2,
'retry_after' => 90,
],
@@ -47,22 +46,24 @@ return [
'host' => 'localhost',
'queue' => 'default',
'retry_after' => 90,
'block_for' => 0,
],
'sqs' => [
'driver' => 'sqs',
'key' => 'your-public-key',
'secret' => 'your-secret-key',
'prefix' => 'https://sqs.us-east-1.amazonaws.com/your-account-id',
'queue' => 'your-queue-name',
'region' => 'us-east-1',
'key' => env('AWS_ACCESS_KEY_ID'),
'secret' => env('AWS_SECRET_ACCESS_KEY'),
'prefix' => env('SQS_PREFIX', 'https://sqs.us-east-1.amazonaws.com/your-account-id'),
'queue' => env('SQS_QUEUE', 'your-queue-name'),
'region' => env('AWS_DEFAULT_REGION', 'us-east-1'),
],
'redis' => [
'driver' => 'redis',
'connection' => 'default',
'queue' => 'default',
'queue' => env('REDIS_QUEUE', 'default'),
'retry_after' => 90,
'block_for' => null,
],
],
@@ -79,6 +80,7 @@ return [
*/
'failed' => [
'driver' => env('QUEUE_FAILED_DRIVER', 'database'),
'database' => env('DB_CONNECTION', 'mysql'),
'table' => 'failed_jobs',
],

209
config/search-string.php Normal file
View File

@@ -0,0 +1,209 @@
<?php
return [
/*
|--------------------------------------------------------------------------
| Invalid search string handling
|--------------------------------------------------------------------------
|
| - all-results: (Default) Silently fail with a query containing everything.
| - no-results: Silently fail with a query containing nothing.
| - exceptions: Throw an `InvalidSearchStringException`.
|
*/
'fail' => 'no-results',
/*
|--------------------------------------------------------------------------
| Default options
|--------------------------------------------------------------------------
|
| When options are missing from your models, this array will be used
| to fill the gaps. You can also define a set of options specific
| to a model, using its class name as a key, e.g. 'App\User'.
|
*/
'default' => [
'keywords' => [
'order_by' => 'sort',
'select' => 'fields',
'limit' => 'limit',
'offset' => 'page',
],
'columns' => [
'created_at' => 'date',
],
],
App\Models\Auth\Permission::class => [
'columns' => [
'name' => ['searchable' => true],
'display_name' => ['searchable' => true],
'description' => ['searchable' => true],
],
],
App\Models\Auth\Role::class => [
'columns' => [
'name' => ['searchable' => true],
'display_name' => ['searchable' => true],
'description' => ['searchable' => true],
],
],
App\Models\Auth\User::class => [
'columns' => [
'name' => ['searchable' => true],
'email' => ['searchable' => true],
'enabled' => ['boolean' => true],
'last_logged_in_at' => ['date' => true],
],
],
App\Models\Banking\Account::class => [
'columns' => [
'name' => ['searchable' => true],
'number' => ['searchable' => true],
'bank_name' => ['searchable' => true],
'bank_address' => ['searchable' => true],
'currency_code',
'enabled' => ['boolean' => true],
],
],
App\Models\Banking\Reconciliation::class => [
'columns' => [
'account_id',
'closing_balance',
'reconciled' => ['boolean' => true],
'started_at' => ['date' => true],
'ended_at' => ['date' => true],
],
],
App\Models\Banking\Transaction::class => [
'columns' => [
'type',
'account_id',
'paid_at' => ['date' => true],
'amount',
'currency_code',
'document_id',
'contact_id',
'description' => ['searchable' => true],
'payment_method',
'reference',
'category_id',
'parent_id',
],
],
App\Models\Common\Company::class => [
'columns' => [
'domain' => ['searchable' => true],
'enabled' => ['boolean' => true],
],
],
App\Models\Common\Item::class => [
'columns' => [
'name' => ['searchable' => true],
'description' => ['searchable' => true],
'enabled' => ['boolean' => true],
'category_id' => ['key' => 'category_id'],
'sale_price',
'purchase_price',
],
],
App\Models\Common\Contact::class => [
'columns' => [
'type',
'name' => ['searchable' => true],
'email' => ['searchable' => true],
'tax_number' => ['searchable' => true],
'phone' => ['searchable' => true],
'address' => ['searchable' => true],
'website' => ['searchable' => true],
'currency_code',
'reference',
'user_id',
'enabled' => ['boolean' => true],
],
],
App\Models\Expense\Bill::class => [
'columns' => [
'bill_number' => ['searchable' => true],
'order_number' => ['searchable' => true],
'bill_status_code',
'billed_at' => ['date' => true],
'due_at' => ['date' => true],
'amount',
'currency_code',
'contact_id',
'contact_name' => ['searchable' => true],
'contact_email' => ['searchable' => true],
'contact_tax_number',
'contact_phone' => ['searchable' => true],
'contact_address' => ['searchable' => true],
'category_id',
'parent_id',
],
],
App\Models\Income\Invoice::class => [
'columns' => [
'invoice_number' => ['searchable' => true],
'order_number' => ['searchable' => true],
'invoice_status_code',
'invoiced_at' => ['date' => true],
'due_at' => ['date' => true],
'amount',
'currency_code',
'contact_id',
'contact_name' => ['searchable' => true],
'contact_email' => ['searchable' => true],
'contact_tax_number',
'contact_phone' => ['searchable' => true],
'contact_address' => ['searchable' => true],
'category_id',
'parent_id',
],
],
App\Models\Setting\Category::class => [
'columns' => [
'name' => ['searchable' => true],
'enabled' => ['boolean' => true],
'type',
],
],
App\Models\Setting\Currency::class => [
'columns' => [
'name' => ['searchable' => true],
'code' => ['searchable' => true],
'rate' => ['searchable' => true],
'enabled' => ['boolean' => true],
'precision',
'symbol',
'symbol_first' => ['boolean' => true],
'decimal_mark',
'thousands_separator',
],
],
App\Models\Setting\Tax::class => [
'columns' => [
'name' => ['searchable' => true],
'type',
'rate',
'enabled' => ['boolean' => true],
],
],
];

View File

@@ -8,31 +8,26 @@ return [
|--------------------------------------------------------------------------
|
| This file is for storing the credentials for third party services such
| as Stripe, Mailgun, SparkPost and others. This file provides a sane
| default location for this type of information, allowing packages
| to have a conventional place to find your various credentials.
| as Mailgun, Postmark, AWS and more. This file provides the de facto
| location for this type of information, allowing packages to have
| a conventional file to locate the various service credentials.
|
*/
'mailgun' => [
'domain' => env('MAILGUN_DOMAIN'),
'secret' => env('MAILGUN_SECRET'),
'endpoint' => env('MAILGUN_ENDPOINT', 'api.mailgun.net'),
],
'postmark' => [
'token' => env('POSTMARK_TOKEN'),
],
'ses' => [
'key' => env('SES_KEY'),
'secret' => env('SES_SECRET'),
'region' => 'us-east-1',
'key' => env('AWS_ACCESS_KEY_ID'),
'secret' => env('AWS_SECRET_ACCESS_KEY'),
'region' => env('AWS_DEFAULT_REGION', 'us-east-1'),
],
'sparkpost' => [
'secret' => env('SPARKPOST_SECRET'),
],
'stripe' => [
'model' => App\User::class,
'key' => env('STRIPE_KEY'),
'secret' => env('STRIPE_SECRET'),
],
];
];

View File

@@ -1,5 +1,7 @@
<?php
use Illuminate\Support\Str;
return [
/*
@@ -12,7 +14,7 @@ return [
| you may specify any of the other wonderful drivers provided here.
|
| Supported: "file", "cookie", "database", "apc",
| "memcached", "redis", "array"
| "memcached", "redis", "dynamodb", "array"
|
*/
@@ -29,7 +31,7 @@ return [
|
*/
'lifetime' => 30,
'lifetime' => env('SESSION_LIFETIME', 120),
'expire_on_close' => false,
@@ -70,7 +72,7 @@ return [
|
*/
'connection' => null,
'connection' => env('SESSION_CONNECTION', null),
/*
|--------------------------------------------------------------------------
@@ -90,13 +92,13 @@ return [
| Session Cache Store
|--------------------------------------------------------------------------
|
| When using the "apc" or "memcached" session drivers, you may specify a
| cache store that should be used for these sessions. This value must
| correspond with one of the application's configured cache stores.
| When using the "apc", "memcached", or "dynamodb" session drivers you may
| list a cache store that should be used for these sessions. This value
| must match with one of the application's configured cache "stores".
|
*/
'store' => null,
'store' => env('SESSION_STORE', null),
/*
|--------------------------------------------------------------------------
@@ -122,7 +124,10 @@ return [
|
*/
'cookie' => 'laravel_session',
'cookie' => env(
'SESSION_COOKIE',
Str::slug(env('APP_NAME', 'laravel'), '_') . '_session'
),
/*
|--------------------------------------------------------------------------
@@ -176,4 +181,19 @@ return [
'http_only' => true,
];
/*
|--------------------------------------------------------------------------
| Same-Site Cookies
|--------------------------------------------------------------------------
|
| This option determines how your cookies behave when cross-site requests
| take place, and can be used to mitigate CSRF attacks. By default, we
| do not enable this as other CSRF protection services are in place.
|
| Supported: "lax", "strict"
|
*/
'same_site' => null,
];

View File

@@ -12,6 +12,22 @@ return [
*/
'auto_save' => false,
/*
|--------------------------------------------------------------------------
| Cache
|--------------------------------------------------------------------------
|
| Options for caching. Set whether to enable cache, its key, time to live
| in seconds and whether to auto clear after save.
|
*/
'cache' => [
'enabled' => true,
'key' => 'setting',
'ttl' => 21600,
'auto_clear' => true,
],
/*
|--------------------------------------------------------------------------
| Setting driver
@@ -49,7 +65,7 @@ return [
|
*/
'json' => [
'path' => storage_path().'/settings.json',
'path' => storage_path() . '/settings.json',
],
/*
@@ -81,6 +97,6 @@ return [
|
*/
'required_extra_columns' => [
'company_id'
'company_id',
],
];

View File

@@ -4,21 +4,21 @@ return [
'name' => 'Akaunting',
'code' => 'Reconciliation',
'code' => 'Argon',
'major' => '1',
'major' => '2',
'minor' => '3',
'minor' => '0',
'patch' => '17',
'patch' => '0',
'build' => '',
'status' => 'Stable',
'date' => '10-April-2019',
'date' => '16-Nov-2019',
'time' => '21:45',
'time' => '10:00',
'zone' => 'GMT +3',

View File

@@ -28,6 +28,9 @@ return [
|
*/
'compiled' => realpath(storage_path('framework/views')),
'compiled' => env(
'VIEW_COMPILED_PATH',
realpath(storage_path('framework/views'))
),
];