Jump to content

Disposable Basic - Sub Pages


KnightAviation

Recommended Posts

Hoping somebody can help here...

 

I've installed a few pages from DB pack which are all showing correctly but I'm struggling to get the next follow on pages which are returning "500" errors. In the "nav.blade" file i've placed the following which all show correctly:

 

DBasic.hubs      /dhubs

DBasic.stats     /dstats

 

Do I need to add the sub directories somewhere, and maybe do another step?

 

dhubs/EGSS (or any other ICAO) is showing as the link on the hubs page but returns to "500" error when clicking on the orange hub name in the hubs page. (airports/EGSS works fine by the way)

/dstats returns the "500" error when clicking on any of the airline names. 

 

Thanks in advance!

 

EDIT: Topic moved to correct forum. There is a dedicated forum for Disposable Addons. Please post support inquiries for Disposable Addons in this forum.

 

 

 

Link to comment
Share on other sites

6 hours ago, KnightAviation said:

Hoping somebody can help here...

 

I've installed a few pages from DB pack which are all showing correctly but I'm struggling to get the next follow on pages which are returning "500" errors. In the "nav.blade" file i've placed the following which all show correctly:

 

DBasic.hubs      /dhubs

DBasic.stats     /dstats

 

Do I need to add the sub directories somewhere, and maybe do another step?

 

dhubs/EGSS (or any other ICAO) is showing as the link on the hubs page but returns to "500" error when clicking on the orange hub name in the hubs page. (airports/EGSS works fine by the way)

/dstats returns the "500" error when clicking on any of the airline names. 

 

Thanks in advance!

 

EDIT: Topic moved to correct forum. There is a dedicated forum for Disposable Addons. Please post support inquiries for Disposable Addons in this forum.

 

 

 

 

Looks like you are missing a cache cleanup or the module is not installed properly or you have problems with dynamic links.

 

Either way, first try cleaning your application cache (admin > maintenance > application) as it is a part of the module installation, then for us to better understand what is going on, provide details about that "500 | Server Error".

 

Enable debugging to see it live as it happens or check you laravel logs when you see that generic page.

 

https://docs.phpvms.net/help

 

Good luck

  • Like 1
Link to comment
Share on other sites

Thanks for the quick reply!

 

I'd already run the clear cache so I think the module is installed ok - i'm certainly getting module admin link/page in the admin dashboard for editing all the aircraft specs etc.

 

The first line of the lavarel log from just after midnight states:

 

Quote

ERROR: Missing required parameter for [Route: DBasic.hub] [URI: dhubs/{icao}] [Missing parameter: icao].

 

I suspect this is more me not adding in a file / link properly than anything wrong with module(s) :D #NewbieErrors 

 

 

The following is what i've added to the nav.blade file:

<li class="nav-item">
          <a class="nav-link" href="{{ route('DBasic.ranks') }}">
            <i class="fab fa-avianex"></i>
            <p>{{ trans_choice('ranks', 2) }}</p>
          </a>
    </li>

    <li class="nav-item">
          <a class="nav-link" href="{{ route('DBasic.hubs') }}">
            <i class="fab fa-avianex"></i>
            <p>{{ trans_choice('hubs', 2) }}</p>
          </a>
    </li>

    <li class="nav-item">
          <a class="nav-link" href="{{ route('DBasic.stats') }}">
            <i class="fab fa-avianex"></i>
            <p>{{ trans_choice('stats', 2) }}</p>
          </a>
    </li>


Perhaps i've missed something here?

 

I've just clicked on all the links that are currently showing 500 Server Error and the "LAVAREL LOG" shows:

 

[2022-02-24 07:47:03] production.ERROR: Call to undefined relationship [airline] on model [App\Models\Aircraft]. {"userId":1,"exception":"[object] (Illuminate\\Database\\Eloquent\\RelationNotFoundException(code: 0): Call to undefined relationship [airline] on model [App\\Models\\Aircraft]. at /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Database/Eloquent/RelationNotFoundException.php:34)
[stacktrace]
#0 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Builder.php(669): Illuminate\\Database\\Eloquent\\RelationNotFoundException::make(Object(App\\Models\\Aircraft), 'airline')
#1 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Relation.php(99): Illuminate\\Database\\Eloquent\\Builder->Illuminate\\Database\\Eloquent\\{closure}()
#2 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Builder.php(671): Illuminate\\Database\\Eloquent\\Relations\\Relation::noConstraints(Object(Closure))
#3 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Builder.php(639): Illuminate\\Database\\Eloquent\\Builder->getRelation('airline')
#4 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Builder.php(619): Illuminate\\Database\\Eloquent\\Builder->eagerLoadRelation(Array, 'airline', Object(Closure))
#5 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Builder.php(587): Illuminate\\Database\\Eloquent\\Builder->eagerLoadRelations(Array)
#6 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Relation.php(188): Illuminate\\Database\\Eloquent\\Builder->get(Array)
#7 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Relations/Relation.php(153): Illuminate\\Database\\Eloquent\\Relations\\Relation->get()
#8 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Builder.php(650): Illuminate\\Database\\Eloquent\\Relations\\Relation->getEager()
#9 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Builder.php(619): Illuminate\\Database\\Eloquent\\Builder->eagerLoadRelation(Array, 'aircraft', Object(Closure))
#10 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Builder.php(587): Illuminate\\Database\\Eloquent\\Builder->eagerLoadRelations(Array)
#11 /var/www/vhosts/knightair.co.uk/httpdocs/modules/DisposableBasic/Http/Controllers/DB_AirlineController.php(85): Illuminate\\Database\\Eloquent\\Builder->get()
#12 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/Controller.php(54): Modules\\DisposableBasic\\Http\\Controllers\\DB_AirlineController->show('KTF')
#13 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/ControllerDispatcher.php(45): Illuminate\\Routing\\Controller->callAction('show', Array)
#14 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/Route.php(254): Illuminate\\Routing\\ControllerDispatcher->dispatch(Object(Illuminate\\Routing\\Route), Object(Modules\\DisposableBasic\\Http\\Controllers\\DB_AirlineController), 'show')
#15 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/Route.php(197): Illuminate\\Routing\\Route->runController()
#16 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/Router.php(695): Illuminate\\Routing\\Route->run()
#17 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(128): Illuminate\\Routing\\Router->Illuminate\\Routing\\{closure}(Object(Illuminate\\Http\\Request))
#18 /var/www/vhosts/knightair.co.uk/httpdocs/app/Http/Middleware/SetActiveTheme.php(40): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request))
#19 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(167): App\\Http\\Middleware\\SetActiveTheme->handle(Object(Illuminate\\Http\\Request), Object(Closure))
#20 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/Middleware/SubstituteBindings.php(50): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request))
#21 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(167): Illuminate\\Routing\\Middleware\\SubstituteBindings->handle(Object(Illuminate\\Http\\Request), Object(Closure))
#22 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Auth/Middleware/Authenticate.php(44): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request))
#23 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(167): Illuminate\\Auth\\Middleware\\Authenticate->handle(Object(Illuminate\\Http\\Request), Object(Closure))
#24 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/View/Middleware/ShareErrorsFromSession.php(49): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request))
#25 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(167): Illuminate\\View\\Middleware\\ShareErrorsFromSession->handle(Object(Illuminate\\Http\\Request), Object(Closure))
#26 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Session/Middleware/StartSession.php(121): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request))
#27 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Session/Middleware/StartSession.php(64): Illuminate\\Session\\Middleware\\StartSession->handleStatefulRequest(Object(Illuminate\\Http\\Request), Object(Illuminate\\Session\\Store), Object(Closure))
#28 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(167): Illuminate\\Session\\Middleware\\StartSession->handle(Object(Illuminate\\Http\\Request), Object(Closure))
#29 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Cookie/Middleware/AddQueuedCookiesToResponse.php(37): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request))
#30 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(167): Illuminate\\Cookie\\Middleware\\AddQueuedCookiesToResponse->handle(Object(Illuminate\\Http\\Request), Object(Closure))
#31 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Cookie/Middleware/EncryptCookies.php(67): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request))
#32 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(167): Illuminate\\Cookie\\Middleware\\EncryptCookies->handle(Object(Illuminate\\Http\\Request), Object(Closure))
#33 /var/www/vhosts/knightair.co.uk/httpdocs/app/Http/Middleware/InstalledCheck.php(29): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request))
#34 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(167): App\\Http\\Middleware\\InstalledCheck->handle(Object(Illuminate\\Http\\Request), Object(Closure))
#35 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(103): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request))
#36 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/Router.php(697): Illuminate\\Pipeline\\Pipeline->then(Object(Closure))
#37 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/Router.php(672): Illuminate\\Routing\\Router->runRouteWithinStack(Object(Illuminate\\Routing\\Route), Object(Illuminate\\Http\\Request))
#38 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/Router.php(636): Illuminate\\Routing\\Router->runRoute(Object(Illuminate\\Http\\Request), Object(Illuminate\\Routing\\Route))
#39 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Routing/Router.php(625): Illuminate\\Routing\\Router->dispatchToRoute(Object(Illuminate\\Http\\Request))
#40 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php(166): Illuminate\\Routing\\Router->dispatch(Object(Illuminate\\Http\\Request))
#41 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(128): Illuminate\\Foundation\\Http\\Kernel->Illuminate\\Foundation\\Http\\{closure}(Object(Illuminate\\Http\\Request))
#42 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/barryvdh/laravel-debugbar/src/Middleware/InjectDebugbar.php(60): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request))
#43 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(167): Barryvdh\\Debugbar\\Middleware\\InjectDebugbar->handle(Object(Illuminate\\Http\\Request), Object(Closure))
#44 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php(21): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request))
#45 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/ConvertEmptyStringsToNull.php(31): Illuminate\\Foundation\\Http\\Middleware\\TransformsRequest->handle(Object(Illuminate\\Http\\Request), Object(Closure))
#46 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(167): Illuminate\\Foundation\\Http\\Middleware\\ConvertEmptyStringsToNull->handle(Object(Illuminate\\Http\\Request), Object(Closure))
#47 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TransformsRequest.php(21): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request))
#48 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/TrimStrings.php(40): Illuminate\\Foundation\\Http\\Middleware\\TransformsRequest->handle(Object(Illuminate\\Http\\Request), Object(Closure))
#49 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(167): Illuminate\\Foundation\\Http\\Middleware\\TrimStrings->handle(Object(Illuminate\\Http\\Request), Object(Closure))
#50 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Foundation/Http/Middleware/PreventRequestsDuringMaintenance.php(86): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request))
#51 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(167): Illuminate\\Foundation\\Http\\Middleware\\PreventRequestsDuringMaintenance->handle(Object(Illuminate\\Http\\Request), Object(Closure))
#52 /var/www/vhosts/knightair.co.uk/httpdocs/app/Http/Middleware/TrustProxies.php(38): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request))
#53 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(167): App\\Http\\Middleware\\TrustProxies->handle(Object(Illuminate\\Http\\Request), Object(Closure))
#54 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Pipeline/Pipeline.php(103): Illuminate\\Pipeline\\Pipeline->Illuminate\\Pipeline\\{closure}(Object(Illuminate\\Http\\Request))
#55 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php(141): Illuminate\\Pipeline\\Pipeline->then(Object(Closure))
#56 /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Foundation/Http/Kernel.php(110): Illuminate\\Foundation\\Http\\Kernel->sendRequestThroughRouter(Object(Illuminate\\Http\\Request))
#57 /var/www/vhosts/knightair.co.uk/httpdocs/public/index.php(59): Illuminate\\Foundation\\Http\\Kernel->handle(Object(Illuminate\\Http\\Request))
#58 {main}
"} 

 

 

 

Edited by KnightAviation
Link to comment
Share on other sites

2 hours ago, KnightAviation said:

I've just clicked on all the links that are currently showing 500 Server Error and the "LAVAREL LOG" shows:

 

[2022-02-24 07:47:03] production.ERROR: Call to undefined relationship [airline] on model [App\Models\Aircraft]. {"userId":1,"exception":"[object] (Illuminate\\Database\\Eloquent\\RelationNotFoundException(code: 0): Call to undefined relationship [airline] on model [App\\Models\\Aircraft]. at /var/www/vhosts/knightair.co.uk/httpdocs/vendor/laravel/framework/src/Illuminate/Database/Eloquent/RelationNotFoundException.php:34)

 

Looks like the main links you added to your menu/navbar is ok but you are missing a crucial component, your phpVMS v7 is out of date (or not updated properly, missing some critical improvements). That relationship error is a clear sign this, in other words you are using a Disposable addon which requires a more recent (preferably latest dev build of) phpVMS v7.

 

Latest version of the module has this info in its readme,

 

Compatible with any latest development (dev) build of phpVMS v7 released after 10.FEB.22

 

Anyway, that "Aircraft <> Airline" relationship was added to phpVMS v7 around the first week of November, 02.NOV.21 to be precise. So if you want to stick with an older v7 release you should also find a compatible release of my addons with that version and stick with it too.

 

I kindly suggest you to update your core phpVMS v7 or do not use my addons as I can not support older versions :(

 

Best wishes and good luck on the update process.

Link to comment
Share on other sites

I'm using your pack from 30th Nov:

 

Quote

# Disposable Basic Pack v3

phpVMS v7 module for Basic VA features

Compatible with any latest development (dev) build of phpVMS v7 released after **30.NOV.21**.  
Module blades are designed for themes using **Bootstrap v5.x** and FontAwesome v5.x (not v6) icons.

 

I suspect that we're using a VMS install from prior to that. I'll update phpVMS first and then see what happens. Thanks for your help! :) 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...