Jump to content

[ADD-ON] JumpSeat Travel & Aircraft Transfer Module


Recommended Posts

JumpSeat Travel & Aircraft Transfer Module


*** IMPORTANT NOTE ***

 

*** Please check the latest docs for this addon either from it's GitHub Repository or from the file you downloaded ***

 

*** It is either in /docs folder or in the root of the file you downloaded and is called README.MD ***


 

Edited by DisposableHero
  • Like 1
Link to comment
Share on other sites

  • 3 weeks later...
  • 2 weeks later...
Posted (edited)

No unless you edit the module on your own and add aircraft to the process (which in my opinion will be really un-realistic) ... This is a module for pilots to change their locations, not a tool for va admins/managers to let their aircraft jump from a to b without flights.

 

For listing your aircraft locations, there are some solutions ... There is a widget i developed (and available here for free) which gives you the counts of aircrafts at airports. If you want to give your pilots some clues you can use it (though it does not provide types or registrations, just gives an airport and a count of total aircrafts parked there). Or you can develop your own module for your fleet locations or find a module for listing until phpvms default core offers some solutions (if it offers of course).

 

Safe flights

Edited by FatihKoz
Link to comment
Share on other sites

  • DisposableHero changed the title to [ADD-ON] JumpSeat Travel Module

 

Quote

the frontend is a widget which can be placed anywhere you wish. 


As written in instructions (above), the module has no link or a button. It uses a widget, which can be placed anywhere you wish. (my suggestion is using dashboard/index for this, but you are free to choose your location)

 

How can I help you anymore I do not know. Sorry but I can not edit files on your server or choose a widget location for you :(

 

If you are new to v7 and laravel theme logic, please check the docs ( docs.phpvms.net ), they will give you the basic idea where to find files etc.

  • Thanks 2
Link to comment
Share on other sites

The truth is that I am lost. I don't understand this from widgets.
In the Module manager, the View Fronted Module button doesn't get me anywhere.
I don't know where I have to put the widget
@ widget ('Modules \ JumpSeat \ Widgets \ JumpSeat', ['price' => 'auto', 'base' => 0.20])
I don't control this. I have a lot to read

 

Link to comment
Share on other sites

We may have a language barrier here, I think i clearly wrote that the module has no links or pages or etc, the frontend is a widget ... So clicking `View Frontend` button of course will not get you anywhere :( And clicking Admin button will give you nothing too (except some text and info).

 

As i wrote in module description and in the reply just above your post, selecting a location and adding the widget there is up to you ... ( I still do suggest using dashboard ) 

 

But again, if you really do not know where the dashboard is or how to edit views/pages in phpvms v7, you really need to read more :) 

  • Thanks 1
Link to comment
Share on other sites

Hi,

 

Coming from a non skilled person in this stuff all I had to do was edit the page I wanted the jumpseat to be in and add the line that calls the widget.  (As per the read me)  It was a trial an error to get the correct line but was easy enough.

 

In my case I added it to the dashboard, so it went into the index.blade.php file located in the dashboard section of the theme I was using.

 

But I keep telling people don't bother adding it to the default theme it will just get overwritten on an update.

 

Regards


Dough

Link to comment
Share on other sites

On 4/4/2021 at 12:34 AM, jftejeiro said:

I perfectly understood what he told me. I understood it before and now.
What happens is that I don't know how to do what you tell me, that's why I say I have to read more. Thank you very much for your time.

 

 

I got you message, thought I would reply on here so others can see.

 

1. Make sure you upload the module to the right place.   It should go into the phpvms/modules/ folders so it looks like image 1 

 

2. Go into your admin page for modules and you should see a line at the bottom asking if you want to activate the module.  Once activated it joins the list above, just like image 2 

 

3. Before leaving admin go to the maintenance and clear the cache in fact press all 3.      Like image 3

 

4. Now if you follow the instruction you just need to call it to one of you pages as described in the instructions.  Mine is in the dashboard of the disposable theme.  So it in in index.blade.php inside the dashboard folder.  I have mine set to auto but you can see the entry in the last image.  

image.pngimage.png

image.png

image.png

Edited by Dougjuk
  • Thanks 1
Link to comment
Share on other sites

1 hour ago, Dougjuk said:

 

 

I got you message, thought I would reply on here so others can see.

 

1. Make sure you upload the module to the right place.   It should go into the phpvms/modules/ folders so it looks like image 1 

 

2. Go into your admin page for modules and you should see a line at the bottom asking if you want to activate the module.  Once activated it joins the list above, just like image 2 

 

3. Before leaving admin go to the maintenance and clear the cache in fact press all 3.      Like image 3

 

4. Now if you follow the instruction you just need to call it to one of you pages as described in the instructions.  Mine is in the dashboard of the disposable theme.  So it in in index.blade.php inside the dashboard folder.  I have mine set to auto but you can see the entry in the last image.  

image.pngimage.png

image.png

image.png

 

 

Thank you very much, you are very kind.
I was going crazy because I thought I was doing it right but it wasn't going well.

In order not to make mistakes, what I did was copy the example line that the program brings, so as not to make an error when writing the code.

The problem that if you put the code like this:
@ widget ('Modules \ JumpSeat \ Widgets \ JumpSeat', ['price' => 'auto']) the widget is not working.

But if you put the code like this:
@widget ('Modules \ JumpSeat \ Widgets \ JumpSeat', ['price' => 'auto'])
the widget does work.
For those of us who don't know about code, we can go crazy, we don't know anymore.

The small difference between it working and not working is in the blank "  " after the @
Putting "@widget" is not the same as putting "@ widget", that makes a difference.
Thanks a lot. A picture is worth a thousand words.
Greetings

 

 

Captura6.JPG

Edited by jftejeiro
  • Like 1
Link to comment
Share on other sites

On 4/5/2021 at 1:42 PM, jftejeiro said:

 

 

Thank you very much, you are very kind.
I was going crazy because I thought I was doing it right but it wasn't going well.

In order not to make mistakes, what I did was copy the example line that the program brings, so as not to make an error when writing the code.

The problem that if you put the code like this:
@ widget ('Modules \ JumpSeat \ Widgets \ JumpSeat', ['price' => 'auto']) the widget is not working.

But if you put the code like this:
@widget ('Modules \ JumpSeat \ Widgets \ JumpSeat', ['price' => 'auto'])
the widget does work.
For those of us who don't know about code, we can go crazy, we don't know anymore.

The small difference between it working and not working is in the blank "  " after the @
Putting "@widget" is not the same as putting "@ widget", that makes a difference.
Thanks a lot. A picture is worth a thousand words.
Greetings

 

 

Captura6.JPG

 

Just wondering, when did you downloaded the module ?

 

The screen you posted is from an admin.blade.php which changed before i released the final 1.2.0 (with language file support and corrected escape for `@widget` calls ...

 

Not a big issue but you may want to download it again, either from here or from Github. The core JumpSeat is ok but you may be missing language translations etc.

Link to comment
Share on other sites

12 hours ago, jftejeiro said:

How the language files are changed in the template and widgets

 

Admin -> settings ... Select your language 

 

If you are asking to create new language files (translations) you need to edit the files under resources\langs folder. For modules it may be different but most probably under modules\ModuleName\Resources\lang (as an example modules\JumpSeat\Resources\lang )

 

There you will see the provided langauges in folders, like en / es / fr / de with ISO country codes. Just copy one of them (en for example) and give it a new name like (it for Italian) , edit the files under newly created/coppied folder by translating every single line.

 

After saving that new file and selecting that language from admin/settings you will see your translations applied.

 

 

Link to comment
Share on other sites

This is the language file of JumpSeat Travel

 

return [
  // Widget Body
  'jstitle'    => 'JumpSeat Travel',
  'jsdropdown' => 'Please select your destination',
  'jsbutton'   => 'Travel',
  'iconfree'   => 'Free Travel',
  'iconfixed'  => 'Fixed Ticket Price:',
  'iconauto'   => 'Automatic Ticket Price Calculation',
  // Success Response Messages
  'successfree'  => 'JumpSeat travel completed, you are at :location now.',
  'successfixed' => 'JumpSeat travel completed, you are at :location now. Ticket price was :price',
  'successauto'  => 'JumpSeat travel completed, you are at :location now. Calculated ticket price was :price for :distance nm',
  // Error Response Messages
  'errordest'    => 'JumpSeat travel not possible without a valid destination!',
  'errorfunds'   => 'JumpSeat travel not possible, not enough funds! You need at least :price',
];

 

do not touch the left part, it is the definition ;) edit only the right side like

 

'jsdropdown' => 'Seleziona la tua destinazione',

 

Do NOT translate in text definitions like :price or :location , they are being populated by the code

 

`Sei alla :location adesso`,

 

Will result Sei alla LIRF adesso

 

Hope this helps to understand the logic behind it.

  • Thanks 1
Link to comment
Share on other sites

😂😂

Well, in my Admin panel there is no option to change the language.
I have the version installed
version 7.0.0 dev

general
Units
acars
airports
bids
flights
simbrief
pyreps
pilots
notifications.
In none of these sections is there anything related to changing the language

Link to comment
Share on other sites

3 hours ago, jftejeiro said:

😂😂

Well, in my Admin panel there is no option to change the language.

 

edit your config.php , add two lines to app section as below

 

'locale' => env('APP_LOCALE', 'it'),
'fallback_locale' => 'en',

 

it will look like something like this when finished

 

// Overrides config/app.php
'app' => [
    'name' => 'Your VA Name',
    'url'  => 'http://Your VA URL',
    'locale' => env('APP_LOCALE', 'it'),
    'fallback_locale' => 'en',

    // When live, 'env' should be 'prod'
    'env'   => 'prod',

 

the locale setting defines the main language to be used by phpvms, fallback is the safety part ... If "it" / Italian translation is not found "en" English will be used ;)

 

It may be defined during install, i am not sure ... But you are right, language selection is not in the admin / settings.

  • Like 1
Link to comment
Share on other sites

  • 4 weeks later...
On 9/17/2021 at 4:41 PM, DominZo said:

Hello, what I have to edit to have jumpseat above Weather at in dashboard. I tried to edit index.blade.php in defult/dashboard but I have some error

 

 

What was/is the error ? ( blade file you mentioned is correct for dashboard )

 

Link to comment
Share on other sites

8 hours ago, DominZo said:

It's 505 Error and I edit dasboard like this 

 

What I see from that image is your placing of the widget is terribly wrong. I am not sure that it will work inside a bootstrap nav, specially under a nav-tabs class 'cause the widget itself renders a full card with lots of data. Anyway, beside from the placing, I still need to see what the error details are. Error 500, Error 505 etc alone does not help at all :( You should provide some tracing info from your logs.

 

https://docs.phpvms.net/help#information-required

 

https://docs.phpvms.net/help#logs

 

At the moment, I only "assume" that it is an error about routes not being loaded thus widget is generating a Server 500 error.

 

https://github.com/FatihKoz/JumpSeat#installation-steps

 

"After enabling/disabling or updating modules application cache cleaning process may be necessary (check admin/maintenance)."

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...
 Share

×
×
  • Create New...