@extends('layouts.master')

@section('navigation')
    @if(Auth::user()->role==1)
        @include('local.managers.admins._navigation')
    @elseif(Auth::user()->role==2)
        @include('local.managers.sCoords._navigation')
    @elseif(Auth::user()->role==3)
        @include('local.managers.pCoords._navigation')
    @endif
@stop

@section('main')
    <div class="row">
        <div class="col-md-12">
            <p>Click on the values you want to change. Invalid values will be rejected automatically. To save your changes, click the 'Save' button at the bottom of the page.</p>
            <table class="table table-striped table-condensed editable-table">
                <thead><tr class="center-text">
                    <th class="col-md-4">Learning Objectives</th>
                    <th class="col-md-6">Transformative Actions</th>
                    <th class="col-md-2">Expected Metric</th>

                </thead>
                <tbody>
                @foreach ($objectives as $objective)
                    <tr data-id="{{ $objective->id }}">
                        <td contenteditable="true" class="name col-md-4" >{{ $objective->text }}</td>
                        {{-- TODO: Use correct data --}}
                        <td contenteditable="true" data-type="textarea" class="definition col-md-6" >{{ 'TODO' }}</td>
                        <td contenteditable="true" class="expected-outcome col-md-1" >{{ $outcome->expected_outcome }}</td>
                    </tr>
                @endforeach
                </tbody>
            </table>
        </div>
    </div>

@stop

@section('included-js')
    @include('global._datatables_js')
@stop

@section('javascript')

    // ------------------------------------------------------------------------
    // Page Load
    // ------------------------------------------------------------------------

    // ------------------------------------------------------------------------
    // Events
    // ------------------------------------------------------------------------



    // ------------------------------------------------------------------------
    // Functions
    // ------------------------------------------------------------------------

@stop