@section('body_class', 'loyalty-subtotal') @extends('layouts.app') @section('content') @if(!$loyalty_subtotal->id) {!! Form::model($loyalty_subtotal, [ 'method' => 'POST', 'route' => ['loyalties.store', 'membership=' . $_GET['membership']], 'role' => 'form'])!!} @else {!! Form::model($loyalty_subtotal, [ 'method' => 'PUT', 'route' => ['loyalties.update', $loyalty_subtotal->id, 'membership=' . $_GET['membership']], 'role' => 'form'])!!} @endif

Edit Membership Rule

@if (count($errors) > 0)
Whoops! There were some problems with your input.

    @foreach ($errors->all() as $error)
  • {{ $error }}
  • @endforeach
@endif @if ($message = Session::get('fail'))
Whoops! There were some problems with your input.

{{ $message }}
@endif
{!! Form::label('lblName', 'Name'); !!} {!! Form::text('name', null, ['class' => 'form-control', 'placeholder' => 'Loyalty Name']); !!} @if ($errors->has('name'))

Loyalty Name is required

@endif
Rule 1
{!! Form::label('lblLevel1', 'Price greater than'); !!} {!! Form::text('level1', $loyalty_subtotal->level1, ['class' => 'form-control', 'placeholder' => 'Price Amount']); !!} @if ($errors->has('level1'))

Price must be numeric

@endif
{!! Form::label('lblPoint1', 'Point Earned'); !!} {!! Form::text('point1', $loyalty_subtotal->point1, ['class' => 'form-control', 'placeholder' => 'Point earned']); !!} @if ($errors->has('point1'))

Point Earned must be numeric

@endif
@if($loyalty_subtotal->id)
@if ($loyalty_subtotal->rule->status) {!! Form::checkbox('status', 1, TRUE); !!} @else {!! Form::checkbox('status', 1); !!} @endif {!! Form::label('lblStatus', 'Enabled', array('class' => 'status')); !!}
@endif
Rule 2
{!! Form::label('lblLevel2', 'Price greater than'); !!} {!! Form::text('level2', $loyalty_subtotal->level2, ['class' => 'form-control', 'placeholder' => 'Price Amount']); !!} @if ($errors->has('level2'))

Price must be numeric

@endif
{!! Form::label('lblPoint2', 'Point Earned'); !!} {!! Form::text('point2', $loyalty_subtotal->point2, ['class' => 'form-control', 'placeholder' => 'Point earned']); !!} @if ($errors->has('point2'))

Point Earned must be numeric

@endif
Rule 3
{!! Form::label('lblLevel3', 'Price greater than'); !!} {!! Form::text('level3', $loyalty_subtotal->level3, ['class' => 'form-control', 'placeholder' => 'Price Amount']); !!} @if ($errors->has('level3'))

Price must be numeric

@endif
{!! Form::label('lblPoint3', 'Point Earned'); !!} {!! Form::text('point3', $loyalty_subtotal->point3, ['class' => 'form-control', 'placeholder' => 'Point earned']); !!} @if ($errors->has('point3'))

Point Earned must be numeric

@endif
{!! link_to_route('memberships.show', 'Back to Membership', $_GET['membership'], ['class' => 'btn btn-info pull-right']) !!} {!! Form::submit('Submit', ['class' => 'btn btn-info btn-fill pull-right'])!!}
{!! Form::close() !!}
@endsection