@extends('layouts.master') @section('title', 'Dashboard') @section('links') @endsection @section('content')

State Management

States


@foreach ($states as $state) @endforeach
Sno. Region Name State Name Action
{{++$i}}. {{$state->country}} {{$state->state_name}} {{ Form::open(array('url' => 'states/' . $state->state_id)) }} {{ Form::hidden('_method', 'DELETE') }} {{ Form::button('', ['type' => 'submit', 'class' => 'btn circle-delete del','onclick'=>"return confirm('Are you sure you want to delete this item?');"] ) }} {{ Form::close() }}
@if(!empty($editstates))

Update Country Master

{{ Form::model($editstates, array('action' => array('StateController@update', $editstates->state_id), 'method' => 'PUT')) }}
* {!! Form::select('country_id', [null => 'Select country'] + $countrys, $editstates->country_id ,['class'=>'form-control'],['class'=>'form-control','required'=>'required'])!!}
* {{ Form::text('state_name', null, array('class' => 'form-control onlytext','required'=>'required')) }}
{{ Form::submit('Update State!', array('class' => 'btn btn-primary')) }} {{ Form::close() }} @else

Add State Master

{{ Form::open(array('url' => 'states','action' => array('StateController@store'), 'method' => 'POST')) }}
*
* {{ Form::text('state_name', Input::old('state_name'), array('class' => 'form-control onlytext','required'=>'required','placeholder'=>('Enter State Name'))) }}
{{ Form::submit('Create State!', array('class' => 'btn btn-primary')) }} {{ Form::close() }} @endif
@endsection @section('scripts') @endsection