@extends('layouts.app') @section('content')

Manage Formula

{{ !empty($formula) ? 'Update Formula' : 'Create Formula'}}

@include('layouts.flash.alert') @if(isset($formula)) {{ Form::model($formula, ['route' => ['formulas.update', $formula->id], 'method' => 'patch']) }} @else {{ Form::open(['route' => 'formulas.store']) }} @endif
{{ Form::label('project_id', 'Project') }}* {{ Form::select('project_id', $projects, @$formula->project_id, [ 'class' => "form-control select2-input", 'id' => "project_id", 'data-live-search'=>'true', ]) }} @if($errors->has('project_id')) {{ $errors->first('project_id') }} @endif
{{ Form::label('keyword', 'Keyword') }}* {{ Form::text('keyword', @$formula->keyword, [ 'class' => "form-control", 'id' => "keyword", ]) }} @if($errors->has('keyword')) {{ $errors->first('keyword') }} @endif
{{ Form::label('description', 'Description') }}* {{ Form::text('description', @$formula->description, [ 'class' => "form-control", 'id' => "description", ]) }} @if($errors->has('description')) {{ $errors->first('description') }} @endif
{{ Form::label('formula', 'Formula') }}* {{ Form::text('formula', @$formula->formula, [ 'class' => "form-control", 'id' => "formula", ]) }} @if($errors->has('formula')) {{ $errors->first('formula') }} @endif
{{ Form::label('value', 'Value') }}* {{ Form::text('value', @$formula->value, [ 'class' => "form-control", 'id' => "value", ]) }} @if($errors->has('value')) {{ $errors->first('value') }} @endif
{{ Form::submit('Submit', [ 'class' => "btn btn-primary btn-flat" ]) }}
{{ Form::close() }}
@endsection