Permalink
Browse files

added views column to field type

  • Loading branch information...
philmareu committed Jul 30, 2018
1 parent 0eeefc3 commit 7d9a520feba932a672f331048ad9dcc76285153c
@@ -11,6 +11,7 @@ class LaramanagerFieldType extends Model
'title',
'slug',
'class',
'views',
'active'
];
@@ -13,90 +13,103 @@ class FieldTypesSeeder extends Seeder
'title' => 'Text',
'slug' => 'text',
'class' => 'PhilMareu\Laramanager\FieldTypes\TextFieldType',
'views' => 'laramanager::field_types',
'active' => 1
],
[
'id' => 2,
'title' => 'Email',
'slug' => 'email',
'class' => 'PhilMareu\Laramanager\FieldTypes\EmailFieldType',
'views' => 'laramanager::field_types',
'active' => 1
],
[
'id' => 3,
'title' => 'Slug',
'slug' => 'slug',
'class' => 'PhilMareu\Laramanager\FieldTypes\SlugFieldType',
'views' => 'laramanager::field_types',
'active' => 1
],
[
'id' => 4,
'title' => 'Password',
'slug' => 'password',
'class' => 'PhilMareu\Laramanager\FieldTypes\PasswordFieldType',
'views' => 'laramanager::field_types',
'active' => 1
],
[
'id' => 5,
'title' => 'Image',
'slug' => 'image',
'class' => 'PhilMareu\Laramanager\FieldTypes\ImageFieldType',
'views' => 'laramanager::field_types',
'active' => 1
],
[
'id' => 6,
'title' => 'Images',
'slug' => 'images',
'class' => 'PhilMareu\Laramanager\FieldTypes\ImagesFieldType',
'views' => 'laramanager::field_types',
'active' => 1
],
[
'id' => 7,
'title' => 'Checkbox',
'slug' => 'checkbox',
'class' => 'PhilMareu\Laramanager\FieldTypes\CheckboxFieldType',
'views' => 'laramanager::field_types',
'active' => 1
],
[
'id' => 8,
'title' => 'Textarea',
'slug' => 'textarea',
'class' => 'PhilMareu\Laramanager\FieldTypes\TextareaFieldType',
'views' => 'laramanager::field_types',
'active' => 1
],
[
'id' => 9,
'title' => 'CKEditor',
'slug' => 'ckeditor',
'class' => 'PhilMareu\Laramanager\FieldTypes\CKEditorFieldType',
'views' => 'laramanager::field_types',
'active' => 1
],
[
'id' => 10,
'title' => 'Select',
'slug' => 'select',
'class' => 'PhilMareu\Laramanager\FieldTypes\SelectFieldType',
'views' => 'laramanager::field_types',
'active' => 1
],
[
'id' => 11,
'title' => 'Date',
'slug' => 'date',
'class' => 'PhilMareu\Laramanager\FieldTypes\DateFieldType',
'views' => 'laramanager::field_types',
'active' => 1
],
[
'id' => 12,
'title' => 'Relational',
'slug' => 'relational',
'class' => 'PhilMareu\Laramanager\FieldTypes\RelationalFieldType',
'views' => 'laramanager::field_types',
'active' => 1
],
[
'id' => 13,
'title' => 'Markdown',
'slug' => 'markdown',
'class' => 'PhilMareu\Laramanager\FieldTypes\MarkdownFieldType',
'views' => 'laramanager::field_types',
'active' => 1
]
];
@@ -18,6 +18,7 @@ public function up()
$table->string('title');
$table->string('slug');
$table->string('class');
$table->string('views');
$table->boolean('active');
$table->timestamps();
});
@@ -17,6 +17,7 @@
@include('laramanager::partials.elements.form.text', ['field' => ['name' => 'title', 'id' => 'title']])
@include('laramanager::partials.elements.form.slug', ['field' => ['name' => 'slug', 'id' => 'slug', 'target' => 'title']])
@include('laramanager::partials.elements.form.text', ['field' => ['name' => 'class']])
@include('laramanager::partials.elements.form.text', ['field' => ['name' => 'views']])
@include('laramanager::partials.elements.form.checkbox', ['field' => ['name' => 'active', 'checked' => true]])
@include('laramanager::partials.elements.buttons.submit')
@@ -19,6 +19,7 @@
@include('laramanager::partials.elements.form.text', ['field' => ['name' => 'title', 'id' => 'title', 'value' => $fieldType->title]])
@include('laramanager::partials.elements.form.slug', ['field' => ['name' => 'slug', 'id' => 'slug', 'target' => 'title', 'value' => $fieldType->slug]])
@include('laramanager::partials.elements.form.text', ['field' => ['name' => 'class', 'value' => $fieldType->class]])
@include('laramanager::partials.elements.form.text', ['field' => ['name' => 'views', 'value' => $fieldType->views]])
@include('laramanager::partials.elements.form.checkbox', ['field' => ['name' => 'active', 'checked' => $fieldType->active]])
@include('laramanager::partials.elements.buttons.submit', ['submitText' => 'Update'])
@@ -16,6 +16,7 @@
<td>Title</td>
<td>Slug</td>
<td>Class</td>
<td>Views</td>
<td>Active</td>
<td>&nbsp;</td>
@endsection
@@ -26,6 +27,7 @@
<td>{{ $fieldType->title }}</td>
<td>{{ $fieldType->slug }}</td>
<td>{{ $fieldType->class }}</td>
<td>{{ $fieldType->views }}</td>
<td>{{ $fieldType->active }}</td>
<td width="50">

0 comments on commit 7d9a520

Please sign in to comment.