Forms, Menu, DB
This commit is contained in:
parent
f4bff143a2
commit
42a9e2c8c7
4
README.md
Normal file
4
README.md
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
# TODO
|
||||||
|
|
||||||
|
- Type Creat Form localization
|
||||||
|
- Remove design phase databaase connection in Schema and Model
|
||||||
@ -10,4 +10,9 @@
|
|||||||
'history' => 'History',
|
'history' => 'History',
|
||||||
],
|
],
|
||||||
],
|
],
|
||||||
|
'menu' => [
|
||||||
|
'main' => 'GA Fleet',
|
||||||
|
'manufacturers' => 'Aircraft Manufacturers',
|
||||||
|
'types' => 'Aircraft Types',
|
||||||
|
],
|
||||||
];
|
];
|
||||||
@ -18,7 +18,9 @@ class AircraftManufacturer extends Model
|
|||||||
/**
|
/**
|
||||||
* @var string The database table used by the model.
|
* @var string The database table used by the model.
|
||||||
*/
|
*/
|
||||||
public $table = 'germanairlinesva_fleet_aircraft_manufacturers';
|
// public $table = 'germanairlinesva_fleet_aircraft_manufacturers';
|
||||||
|
public $table = 'aircraft_manufacturers';
|
||||||
|
protected $connection = 'germanairlinesva_fleet';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var array Validation rules
|
* @var array Validation rules
|
||||||
|
|||||||
@ -18,7 +18,9 @@ class AircraftType extends Model
|
|||||||
/**
|
/**
|
||||||
* @var string The database table used by the model.
|
* @var string The database table used by the model.
|
||||||
*/
|
*/
|
||||||
public $table = 'germanairlinesva_fleet_aircraft_types';
|
// public $table = 'germanairlinesva_fleet_aircraft_types';
|
||||||
|
public $table = 'aircraft_types';
|
||||||
|
protected $connection = 'germanairlinesva_fleet';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var array Validation rules
|
* @var array Validation rules
|
||||||
|
|||||||
@ -2,13 +2,16 @@ fields:
|
|||||||
name:
|
name:
|
||||||
label: 'germanairlinesva.fleet::lang.aircraft.manufacturers.name'
|
label: 'germanairlinesva.fleet::lang.aircraft.manufacturers.name'
|
||||||
span: auto
|
span: auto
|
||||||
|
required: 1
|
||||||
type: text
|
type: text
|
||||||
link:
|
link:
|
||||||
label: 'germanairlinesva.fleet::lang.aircraft.manufacturers.link'
|
label: 'germanairlinesva.fleet::lang.aircraft.manufacturers.link'
|
||||||
span: auto
|
span: auto
|
||||||
|
required: 1
|
||||||
type: text
|
type: text
|
||||||
history:
|
history:
|
||||||
label: 'germanairlinesva.fleet::lang.aircraft.manufacturers.history'
|
label: 'germanairlinesva.fleet::lang.aircraft.manufacturers.history'
|
||||||
size: ''
|
size: large
|
||||||
span: auto
|
span: auto
|
||||||
type: textarea
|
required: 1
|
||||||
|
type: richeditor
|
||||||
|
|||||||
@ -8,6 +8,9 @@ columns:
|
|||||||
typerating_id:
|
typerating_id:
|
||||||
label: typerating_id
|
label: typerating_id
|
||||||
type: number
|
type: number
|
||||||
|
only_charter:
|
||||||
|
label: only_charter
|
||||||
|
type: text
|
||||||
type:
|
type:
|
||||||
label: type
|
label: type
|
||||||
type: text
|
type: text
|
||||||
|
|||||||
@ -1,7 +1,141 @@
|
|||||||
|
tabs:
|
||||||
fields:
|
fields:
|
||||||
aircraft_manufacturer:
|
aircraft_manufacturer:
|
||||||
label: Relation
|
label: Manufacturer
|
||||||
nameFrom: name
|
nameFrom: name
|
||||||
descriptionFrom: description
|
descriptionFrom: description
|
||||||
span: auto
|
span: auto
|
||||||
|
required: 1
|
||||||
type: relation
|
type: relation
|
||||||
|
tab: Operational
|
||||||
|
typerating_id:
|
||||||
|
label: Typerating
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: number
|
||||||
|
tab: Operational
|
||||||
|
only_charter:
|
||||||
|
label: 'Charter Only'
|
||||||
|
options:
|
||||||
|
'No': 'no'
|
||||||
|
'Yes': 'yes'
|
||||||
|
showSearch: true
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: dropdown
|
||||||
|
tab: Operational
|
||||||
|
type:
|
||||||
|
label: Type
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: text
|
||||||
|
tab: Operational
|
||||||
|
simbrief_type:
|
||||||
|
label: 'SimBrief Type'
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: text
|
||||||
|
tab: Operational
|
||||||
|
dom:
|
||||||
|
label: DOM
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: number
|
||||||
|
tab: Weights
|
||||||
|
mpld:
|
||||||
|
label: 'Max Payload'
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: number
|
||||||
|
tab: Weights
|
||||||
|
mzfm:
|
||||||
|
label: 'Max ZFM'
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: number
|
||||||
|
tab: Weights
|
||||||
|
fuel_capacity:
|
||||||
|
label: 'Fuel Capacity'
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: number
|
||||||
|
tab: Weights
|
||||||
|
mtom:
|
||||||
|
label: 'Max TOM'
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: number
|
||||||
|
tab: Weights
|
||||||
|
mlam:
|
||||||
|
label: 'Max LAM'
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: number
|
||||||
|
tab: Weights
|
||||||
|
description:
|
||||||
|
label: Description
|
||||||
|
size: large
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: richeditor
|
||||||
|
tab: Informational
|
||||||
|
wingspan:
|
||||||
|
label: Wingspan
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: text
|
||||||
|
tab: Informational
|
||||||
|
length:
|
||||||
|
label: Length
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: text
|
||||||
|
tab: Informational
|
||||||
|
cruise_speed:
|
||||||
|
label: 'Cruise Speed'
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: text
|
||||||
|
tab: Informational
|
||||||
|
range:
|
||||||
|
label: Range
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: text
|
||||||
|
tab: Informational
|
||||||
|
engines:
|
||||||
|
label: Engines
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: text
|
||||||
|
tab: Informational
|
||||||
|
max_fl:
|
||||||
|
label: 'Max FL'
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: number
|
||||||
|
tab: Informational
|
||||||
|
capacity_flight_crew:
|
||||||
|
label: 'Flight Crew'
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: number
|
||||||
|
tab: Informational
|
||||||
|
capacity_cabin_crew:
|
||||||
|
label: 'Cabin Crew'
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: number
|
||||||
|
tab: Informational
|
||||||
|
capacity_passengers:
|
||||||
|
label: Passengers
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: number
|
||||||
|
tab: Informational
|
||||||
|
capacity_cargo:
|
||||||
|
label: Cargo
|
||||||
|
span: auto
|
||||||
|
required: 1
|
||||||
|
type: number
|
||||||
|
tab: Informational
|
||||||
|
|||||||
@ -1,7 +0,0 @@
|
|||||||
fields:
|
|
||||||
manufacturer:
|
|
||||||
label: Relation
|
|
||||||
nameFrom: name
|
|
||||||
descriptionFrom: description
|
|
||||||
span: auto
|
|
||||||
type: relation
|
|
||||||
14
plugin.yaml
14
plugin.yaml
@ -4,3 +4,17 @@ plugin:
|
|||||||
author: 'German Airlines VA'
|
author: 'German Airlines VA'
|
||||||
icon: oc-icon-plane
|
icon: oc-icon-plane
|
||||||
homepage: ''
|
homepage: ''
|
||||||
|
navigation:
|
||||||
|
main-menu-item:
|
||||||
|
label: 'germanairlinesva.fleet::lang.menu.main'
|
||||||
|
url: /
|
||||||
|
icon: icon-plane
|
||||||
|
sideMenu:
|
||||||
|
side-menu-item:
|
||||||
|
label: 'germanairlinesva.fleet::lang.menu.manufacturers'
|
||||||
|
url: /germanairlinesva/fleet/aircraftmanufacturers
|
||||||
|
icon: icon-wrench
|
||||||
|
side-menu-item2:
|
||||||
|
label: 'germanairlinesva.fleet::lang.menu.types'
|
||||||
|
url: germanairlinesva/fleet/aircrafttypes
|
||||||
|
icon: icon-paper-plane
|
||||||
|
|||||||
@ -8,8 +8,8 @@ class BuilderTableCreateGermanAirlinesVaAircraftManufacturers extends Migration
|
|||||||
{
|
{
|
||||||
public function up()
|
public function up()
|
||||||
{
|
{
|
||||||
Schema::connection('germanairlinesva_fleet')->create('ga_aircraft_manufacturers', function ($table) {
|
Schema::connection('germanairlinesva_fleet')->create('aircraft_manufacturers', function ($table) {
|
||||||
//Schema::create('ga_aircraft_manufacturers', function ($table) {
|
//Schema::create('germanairlinesva_fleet_aircraft_manufacturers', function ($table) {
|
||||||
$table->engine = 'InnoDB';
|
$table->engine = 'InnoDB';
|
||||||
$table->bigIncrements('id')->unsigned();
|
$table->bigIncrements('id')->unsigned();
|
||||||
$table->string('name');
|
$table->string('name');
|
||||||
@ -20,7 +20,7 @@ class BuilderTableCreateGermanAirlinesVaAircraftManufacturers extends Migration
|
|||||||
|
|
||||||
public function down()
|
public function down()
|
||||||
{
|
{
|
||||||
Schema::connection('germanairlinesva_fleet')->dropIfExists('ga_aircraft_manufacturers');
|
Schema::connection('germanairlinesva_fleet')->dropIfExists('aircraft_manufacturers');
|
||||||
//Schema::dropIfExists('ga_aircraft_manufacturers');
|
//Schema::dropIfExists('germanairlinesva_fleet_aircraft_manufacturers');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -8,12 +8,20 @@ class BuilderTableCreateGermanAirlinesVaAircraftTypes extends Migration
|
|||||||
{
|
{
|
||||||
public function up()
|
public function up()
|
||||||
{
|
{
|
||||||
Schema::connection('germanairlinesva_fleet')->create('ga_aircraft_types', function ($table) {
|
Schema::connection('germanairlinesva_fleet')->create('aircraft_types', function ($table) {
|
||||||
//Schema::create('ga_aircraft_types', function ($table) {
|
//Schema::create('germanairlinesva_fleet_aircraft_types', function ($table) {
|
||||||
$table->engine = 'InnoDB';
|
$table->engine = 'InnoDB';
|
||||||
$table->bigIncrements('id')->unsigned();
|
$table->bigIncrements('id')->unsigned();
|
||||||
$table->bigInteger('aircraft_manufacturer_id')->unsigned();
|
$table->bigInteger('aircraft_manufacturer_id')->unsigned();
|
||||||
|
$table
|
||||||
|
->foreign('aircraft_manufacturer_id')
|
||||||
|
->references('id')
|
||||||
|
->on('aircraft_manufacturers');
|
||||||
$table->bigInteger('typerating_id')->unsigned();
|
$table->bigInteger('typerating_id')->unsigned();
|
||||||
|
//$table
|
||||||
|
// ->foreign('typerating_manufacturer_id')
|
||||||
|
// ->references('id')
|
||||||
|
// ->on('typeratings');
|
||||||
$table->enum('only_charter', ['yes', 'no']);
|
$table->enum('only_charter', ['yes', 'no']);
|
||||||
$table->string('type');
|
$table->string('type');
|
||||||
$table->text('description');
|
$table->text('description');
|
||||||
@ -39,7 +47,7 @@ class BuilderTableCreateGermanAirlinesVaAircraftTypes extends Migration
|
|||||||
|
|
||||||
public function down()
|
public function down()
|
||||||
{
|
{
|
||||||
Schema::connection('germanairlinesva_fleet')->dropIfExists('ga_aircraft_types');
|
Schema::connection('germanairlinesva_fleet')->dropIfExists('aircraft_types');
|
||||||
//Schema::dropIfExists('ga_aircraft_types');
|
//Schema::dropIfExists('germanairlinesva_fleet_aircraft_types');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user