Skip to content

Commit

Permalink
make a use of those links we've created
Browse files Browse the repository at this point in the history
* override index layouts
* add specific field renderer in overrides
  • Loading branch information
alex7r committed Sep 10, 2018
1 parent 11b339b commit 859adde
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 0 deletions.
3 changes: 3 additions & 0 deletions admin/tmpl/idea/create.blade.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
@extends('crud.create')

@include('fields')
3 changes: 3 additions & 0 deletions admin/tmpl/idea/edit.blade.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
@extends('crud.edit')

@include('fields')
16 changes: 16 additions & 0 deletions admin/tmpl/idea/fields.blade.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
@php
/** @var \Joomplace\X\Model $item */
@endphp

@section('field.project_id')
@php
$field = 'project_id';
@endphp
<label>@lang($item->getLabelFor($field))</label>
<select name="{{$field}}">
<option disabled="disabled" value="">@lang('COM_ROADMAP_IDEA_SELECT_THE_PROJECT')</option>
@foreach(\Joomplace\Component\Roadmap\Admin\Model\Project::all() as $project)
<option value="{{$project->id}}" {{$project->id==$item->$field?'selected':''}}>{{$project->title}}</option>
@endforeach
</select>
@endsection

0 comments on commit 859adde

Please sign in to comment.