@section('page_title') OSAA - Music Large Ensemble Report Administration @stop @section('page_sub_title') OSAA Music Large Ensemble Contest Report Forms @stop @section('scripts') @parent @stop @section('jquery_init') // Success bar $('.success_bar').animate({ 'top' : 32, 'background-color' : 'rgba(176, 255, 190, 1.0)'}, 1600, 'easeOutQuad', function () { $(this).delay(6000).fadeOut(4000); $(this).hover(function () { $(this).stop(true).css('opacity', '1.0'); }, function () { $(this).fadeOut(4000); }) }); /* Positioned elements * * Elements that contain the attribute data-position="true" will be positioned * using JQuery's UI positioning utility. Other expected attributes define the * element's position: * data-position-my * data-position-at * data-position-of */ $('[data-position="true"]').each(function() { var element = $(this); var my = element.attr('data-position-my'); var at = element.attr('data-position-at'); var of = element.attr('data-position-of'); var options = $.parseJSON('{ "my" : "' + my + '", "at": "' + at + '", "of": "' + of + '"}'); element.position(options); }); // Required field marker $('[data-required]').after('*'); // Name fields (do not allow any special characters) $('[data-name-field]').bind('input', function() { $(this).val($(this).val().replace(/[^A-Za-z \-'\.,]/gi, '')); }); // Table row highlighter function colorRows () { $('table').each(function () { var i = 0; $('tbody tr:visible', $(this)).each(function () { if (i % 2 == 1) { $(this).addClass('odd'); } else { $(this).removeClass('odd'); } i = i + 1; }); }); } colorRows(); // Help button $('.help_button') .button({'icons':{'primary':'ui-icon-help'}}) .css({'font-size':'9pt', 'margin-right':'10px'}) .click(function(event) { event.preventDefault(); var topic = 'admin'; $('
') .appendTo('body') .dialog( { draggable : true, resizable : true, height : 725, minHeight : 400, width : 615, minWidth : 330, modal : false, title : 'Help', open : function () { var dialog_object = $(this); dialog_object.html("
"); var jqxhr = $.ajax( { type : 'GET', url : '{{ url('forms/music/help') }}?topic=' + topic, dataType : 'html' }) .done(function (returned_data) { dialog_object.html(returned_data); }) .fail(function (jqXHR, status, error) { var response = jqXHR.responseText; var errorData = $.parseJSON(response); console.log(errorData); alert ("There was an error looking up help information.\n\nThis page will be reloaded."); location.reload(); }) .complete(function () { }); }, close : function () { var dialog_object = $(this); $(dialog_object).remove(); } }); }); // Create button $('.create_button') .button({'icons':{'primary':'ui-icon-plusthick'}}) .css({'font-size':'9pt'}); // Report button $('.report_button') .button({'icons':{'primary':'ui-icon-script'}}) .css({'font-size':'9pt','margin-right':'10px'}); // Gray out incomplete forms $('tr[data-submitted="false"] td') .css({'background-color' : '#ffefef'}); $('tr.odd[data-submitted="false"] td') .css({'background-color' : '#eedfdf'}); $('table tbody tr') .hover(function () { $(this).addClass('hover'); }, function () { $(this).removeClass('hover'); }) .click(function() { $('*').css({'cursor':'wait'}); window.location.href = "{{ url('/forms/music/large-ensemble') }}/" + $(this).attr('data-form-id'); }); // Get filters on page load var pref = {INC : {{ ($info['filters']->INC) ? 'true' : 'false' }}, BND : {{ ($info['filters']->BND) ? 'true' : 'false' }}, CHO : {{ ($info['filters']->CHO) ? 'true' : 'false' }}, ORC : {{ ($info['filters']->ORC) ? 'true' : 'false' }}}; function filterPreferences() { if (pref.CHO) { $('tbody tr[data-activity="CHO"][data-submitted="true"]').show(); if (pref.INC) { $('tbody tr[data-activity="CHO"][data-submitted="false"]').show(); } else { $('tbody tr[data-activity="CHO"][data-submitted="false"]').hide(); } } else { $('tbody tr[data-activity="CHO"]').hide(); } if (pref.BND) { $('tbody tr[data-activity="BND"][data-submitted="true"]').show(); if (pref.INC) { $('tbody tr[data-activity="BND"][data-submitted="false"]').show(); } else { $('tbody tr[data-activity="BND"][data-submitted="false"]').hide(); } } else { $('tbody tr[data-activity="BND"]').hide(); } if (pref.ORC) { $('tbody tr[data-activity="ORC"][data-submitted="true"]').show(); if (pref.INC) { $('tbody tr[data-activity="ORC"][data-submitted="false"]').show(); } else { $('tbody tr[data-activity="ORC"][data-submitted="false"]').hide(); } } else { $('tbody tr[data-activity="ORC"]').hide(); } colorRows(); } filterPreferences(); $('input[type="checkbox"][data-preference]') .change(function() { var box = $(this); var pref_var = box.attr('data-preference'); pref[pref_var] = box.is(':checked'); filterPreferences(); // Save this user's view preferences var jqxhr = $.ajax( { type : 'POST', url : '{{ url('account/set-osaa-preference') }}', data : { 'preference' : 'large_ensemble_admin_filters', 'settings' : pref}, dataType : 'html' }) .done(function (data) { console.log('Preferences were successfully saved.'); }) .fail(function (jqXHR, status, error) { var response = jqXHR.responseText; var errorData = $.parseJSON(response); console.log(errorData); }); }); @stop @section('page_functions') {{-- Help --}} Summary Report New Form @stop @section('main_content') {{-- Success Bar --}} @if (Session::has('success'))
{{ Session::get('success') }}
@endif Filters: CHO) checked="checked" @endif/> BND) checked="checked" @endif/> ORC) checked="checked" @endif/> INC) checked="checked" @endif/>

@foreach ($info['forms'] as $form) @endforeach
Date Activity Name Location League Organizer Submitted Updated Created
{{ date('n/j/Y', strtotime($form->date)) }}
{{ $form->id }}
{{ Helpers::getActivityName($form->activity) }} {{ $form->event_name }} {{ $form->location->name }} {{ (!is_null($form->league)) ? $form->league->name : '- -' }} {{ $form->data->organizer->name }} {{ (!is_null($form->submitted_at)) ? date('n/j/Y g:i a', strtotime($form->submitted_at)) : '- -' }} {{ (!is_null($form->updated_at)) ? date('n/j/Y g:i a', strtotime($form->updated_at)) : '- -' }} {{ (!is_null($form->created_at)) ? date('n/j/Y g:i a', strtotime($form->created_at)) : '- -' }}

@stop