Replace importer with AJAX powered; better error handling #443 (#447)

* Replace importer with AJAX powered; better error handling #443

* Formatting

* Fix command line importer
This commit is contained in:
Nabeel S
2019-12-02 09:57:35 -05:00
committed by GitHub
parent 50dc79bc8d
commit 68eff40753
31 changed files with 544 additions and 354 deletions

View File

@@ -6,8 +6,10 @@ namespace App\Contracts;
* @property mixed $id
* @property bool $skip_mutator
*
* @method static Model find(int $airline_id)
* @method static create(array $attrs)
* @method static Model find(int $id)
* @method static Model where(array $array)
* @method static Model firstOrCreate(array $where, array $array)
* @method static Model updateOrCreate(array $array, array $attrs)
* @method static truncate()
*/

View File

@@ -6,6 +6,7 @@ use App\Contracts\Model;
use App\Models\Enums\AircraftStatus;
use App\Models\Traits\ExpensableTrait;
use App\Models\Traits\FilesTrait;
use Carbon\Carbon;
/**
* @property int id

View File

@@ -25,6 +25,7 @@ use App\Models\Subfleet;
use App\Models\User;
use App\Repositories\SettingRepository;
use App\Services\ModuleService;
use Barryvdh\LaravelIdeHelper\IdeHelperServiceProvider;
use Illuminate\Support\Facades\Schema;
use Illuminate\Support\Facades\View;
use Illuminate\Support\ServiceProvider;
@@ -66,13 +67,11 @@ class AppServiceProvider extends ServiceProvider
*/
public function register(): void
{
// Only dev environment stuff
if ($this->app->environment() === 'dev') {
// Only load the IDE helper if it's included. This lets use distribute the
// package without any dev dependencies
// Only load the IDE helper if it's included and enabled
if (config('app.debug_toolbar') === true) {
/* @noinspection NestedPositiveIfStatementsInspection */
if (class_exists(\Barryvdh\LaravelIdeHelper\IdeHelperServiceProvider::class)) {
$this->app->register(\Barryvdh\LaravelIdeHelper\IdeHelperServiceProvider::class);
if (class_exists(IdeHelperServiceProvider::class)) {
$this->app->register(IdeHelperServiceProvider::class);
}
}
}