@section('page_title') OSAA - OWWMP BIA @stop @section('page_sub_title') OWWMP BIA Administration @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); }) }); // Placeholder functionality $('[data-placeholder]').focus(function() { var input = $(this); if (input.val() == input.attr('data-placeholder')) { input.val(''); input.removeClass('placeholder'); } }).blur(function() { var input = $(this); if (input.val() == '' || input.val() == input.attr('data-placeholder')) { input.addClass('placeholder'); input.val(input.attr('data-placeholder')); } }).blur(); $('[data-placeholder]').parents('form').submit(function() { $(this).find('[data-placeholder]').each(function() { var input = $(this); if (input.val() == input.attr('data-placeholder')) { input.val(''); } }) }); // 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(); // Process received button $('.process_received') .button({'icons':{'primary':'ui-icon-clipboard'}}) .css({'font-size':'9pt'}) .click(function(event) { $('
') .appendTo('body') .dialog( { draggable : false, resizable : false, modal : true, height : 400, width : 500, title : 'Payments & Reports', open : function () { var dialog_object = $(this); dialog_object.html("
"); var jqxhr = $.ajax( { type : 'GET', url : '{{ url('forms/bia/admin/process-received') }}', 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 the processing form.\n\nThis page will be reloaded."); location.reload(); }) .complete(function () { $('.school_summary') .button({'icons':{'secondary':'ui-icon-calculator'}}) .css({'font-size':'9pt'}) .click(function() { window.open('{{ url('/forms/bia/admin/process-received/school-summary') }}'); }); $('.details_summary') .button({'icons':{'secondary':'ui-icon-document'}}) .css({'font-size':'9pt'}) .click(function() { window.open('{{ url('/forms/bia/admin/process-received/details-summary') }}'); }); $('input[type="text"][data-datepicker="true"]') .datepicker({dateFormat:'yy-mm-dd'}) .on('change', function () { var value = $(this).val(); if (value != '') { $('.next_button').button('enable'); } else { $('.next_button').button('disable'); } }); $('.next_button') .button({'icons':{'secondary':'ui-icon-arrowthick-1-e'}}) .css({'font-size' : '9pt', 'float' : 'right'}) .click(function () { var cutoff_date = $('input[type="text"][data-datepicker="true"]').val(); dialog_object.html("
Processing
" + cutoff_date + "
"); var jqxhr = $.ajax( { type : 'GET', url : '{{ url('forms/bia/admin/process-received') }}', data : {'cutoff_date' : cutoff_date}, 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 the processing form.\n\nThis page will be reloaded."); location.reload(); }) .complete(function () { var cutoff_date = $('input[name="cutoff_date"]').val(); $('.assessor_summary') .button({'icons':{'secondary':'ui-icon-calculator'}}) .css({'font-size':'9pt'}) .click(function() { window.open('{{ url('/forms/bia/admin/process-received/assessor-summary') }}?cutoff_date=' + cutoff_date); }); $('.mark_done') .button({'icons':{'secondary':'ui-icon-mail-open'}}) .css({'font-size':'9pt'}) .click(function() { var result = confirm('Are you sure you want to mark these received forms as paid? This will change the filtered form\'s status to DONE and archive these reports which cannot be processed again for payment.'); if (result) { window.location= '{{ url('/forms/bia/admin/process-received/mark-done') }}?cutoff_date=' + cutoff_date; } }); }); }); $('.next_button').button('disable'); }); }, close : function () { var dialog_object = $(this); $(dialog_object).remove(); } }); }); // Help button /* $('.help_button') .button({'icons':{'primary':'ui-icon-help'}}) .css({'font-size':'9pt', 'margin-right':'10px'}) .click(function(event) { event.preventDefault(); $('
') .appendTo('body') .dialog( { draggable : true, resizable : true, height : 725, minHeight : 400, width : 615, minWidth : 330, modal : false, title : 'Administration Help', open : function () { var dialog_object = $(this); dialog_object.html("
"); var jqxhr = $.ajax( { type : 'GET', url : '{{ url('forms/bia/help') }}', 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(); } }); });*/ // Print form button $('.bia_print') .css({'width' : '16px', 'height' : '16px', 'margin-right' : '5px'}) .button({ icons : { primary : 'ui-icon-print'}, text : false}) .click(function () { var button = $(this); var row = button.parents('tr'); var record = row.attr('data-record'); window.open('{{ url('/forms/bia') }}/' + record + '/print'); }); // Edit form button $('.bia_edit') .css({'width' : '16px', 'height' : '16px'}) .button({ icons : { primary : 'ui-icon-pencil'}, text : false}) .click(function() { var button = $(this); var row = button.parents('tr'); var original_background_color = row.css('background-color'); var record = row.attr('data-record'); var status = row.attr('data-status'); row.css({'background-color':'yellow'}); if (status == 'WORK' || status == 'INSF' || {{ (Auth::user()->isOsaaUser()) ? 1 : 0 }}) { window.location = "{{ url('/forms/bia') }}/" + record + "/edit?admin=true"; } else { $('
') .appendTo('body') .dialog( { draggable : true, resizable : false, modal : true, height : 200, width : 400, title : 'Unable to Edit', buttons: [ { text : "Ok", 'class' : "float_right", 'data-autofocus' : "true", icons : { primary : 'ui-icon-check'}, click : function() { // Close the dialog box $(this).dialog("close"); } } ], open : function () { var dialog_object = $(this); dialog_object.html('
You cannot edit this record.'); $('.ui-dialog-buttonpane').css('padding', '0 0.5em').css('font-size', '9pt'); $('.ui-dialog-buttonpane .ui-dialog-buttonset').css('width', '100%'); $('[data-autofocus="true"]').focus(); }, close : function () { var dialog_object = $(this); row.css({'background-color':original_background_color}); $(dialog_object).remove(); } }); } }); // Delete form button $('.bia_delete') .css({'width' : '16px', 'height' : '16px', 'margin-left' : '5px'}) .button({ icons : { primary : 'ui-icon-trash'}, text : false}) .click(function() { var button = $(this); var row = button.parents('tr'); var original_background_color = row.css('background-color'); var record = row.attr('data-record'); var status = row.attr('data-status'); row.css({'background-color':'yellow'}); if (status == 'WORK' || status == 'INSF' || {{ (Auth::user()->isOsaaUser()) ? 1 : 0 }}) { $('
') .appendTo('body') .dialog( { draggable : true, resizable : false, modal : true, height : 250, width : 400, title : 'Confirm Deletion', buttons: [ { text : "Delete", 'class' : "float_left", icons : { primary : 'ui-icon-check'}, click : function() { var data = { record : record }; $('
').addClass('ui-widget-overlay ui-front') .appendTo('body'); $('
').appendTo('body') .css('width', '225px') .css('height', '170px') .css('text-align', 'center') .css('padding', '0.5em') .position({my : "center center", at : "center center", of : window}) .addClass('ui-dialog ui-widget ui-widget-content ui-corner-all ui-front ui-dialog-buttons') .html('
Working...

Please wait, this may take a while to process.
'); // Submit the change var jqxhr = $.ajax( { type : 'POST', url : '{{ url('/forms/bia/delete-form') }}', data : data, dataType : 'html' }) .done(function (data) { console.log('Deletion was successful.'); // Reload of refresh is specified location.reload(); }) .fail(function (jqXHR, status, error) { var response = jqXHR.responseText; var errorData = $.parseJSON(response); console.log(errorData); alert ("There was an error deleting the record.\n\nThis page will be reloaded."); location.reload(); }); } }, { text : "Cancel", 'class' : "float_right", 'data-autofocus' : "true", icons : { primary : 'ui-icon-cancel'}, click : function() { // Close the dialog box $(this).dialog("close"); } } ], open : function () { var dialog_object = $(this); dialog_object.html('
Are you sure you want to delete this form with ID = ' + record + '?

Warning
If you delete this form, it will no longer exist.
'); $('.ui-dialog-buttonpane').css('padding', '0 0.5em').css('font-size', '9pt'); $('.ui-dialog-buttonpane .ui-dialog-buttonset').css('width', '100%'); $('[data-autofocus="true"]').focus(); }, close : function () { var dialog_object = $(this); row.css({'background-color':original_background_color}); $(dialog_object).remove(); } }); } else { $('
') .appendTo('body') .dialog( { draggable : true, resizable : false, modal : true, height : 200, width : 400, title : 'Unable to Delete', buttons: [ { text : "Ok", 'class' : "float_right", 'data-autofocus' : "true", icons : { primary : 'ui-icon-check'}, click : function() { // Close the dialog box $(this).dialog("close"); } } ], open : function () { var dialog_object = $(this); dialog_object.html('
You cannot delete this record.'); $('.ui-dialog-buttonpane').css('padding', '0 0.5em').css('font-size', '9pt'); $('.ui-dialog-buttonpane .ui-dialog-buttonset').css('width', '100%'); $('[data-autofocus="true"]').focus(); }, close : function () { var dialog_object = $(this); row.css({'background-color':original_background_color}); $(dialog_object).remove(); } }); } }); // Un-Delete/Restore form button $('.bia_undelete') .css({'width' : '16px', 'height' : '16px', 'margin-left' : '5px'}) .button({ icons : { primary : 'ui-icon-arrowreturnthick-1-e'}, text : false}) .click(function() { var button = $(this); var row = button.parents('tr'); var original_background_color = row.css('background-color'); var record = row.attr('data-record'); var status = row.attr('data-status'); row.css({'background-color':'yellow'}); if (status == 'DEL') { $('
') .appendTo('body') .dialog( { draggable : true, resizable : false, modal : true, height : 250, width : 400, title : 'Confirm Restoration', buttons: [ { text : "Restore", 'class' : "float_left", icons : { primary : 'ui-icon-check'}, click : function() { var data = { record : record }; $('
').addClass('ui-widget-overlay ui-front') .appendTo('body'); $('
').appendTo('body') .css('width', '225px') .css('height', '170px') .css('text-align', 'center') .css('padding', '0.5em') .position({my : "center center", at : "center center", of : window}) .addClass('ui-dialog ui-widget ui-widget-content ui-corner-all ui-front ui-dialog-buttons') .html('
Working...

Please wait, this may take a while to process.
'); // Submit the change var jqxhr = $.ajax( { type : 'POST', url : '{{ url('/forms/bia/restore-form') }}', data : data, dataType : 'html' }) .done(function (data) { console.log('Restoration was successful.'); // Reload location.reload(); }) .fail(function (jqXHR, status, error) { var response = jqXHR.responseText; var errorData = $.parseJSON(response); console.log(errorData); alert ("There was an error restoring the record.\n\nThis page will be reloaded."); location.reload(); }); } }, { text : "Cancel", 'class' : "float_right", 'data-autofocus' : "true", icons : { primary : 'ui-icon-cancel'}, click : function() { // Close the dialog box $(this).dialog("close"); } } ], open : function () { var dialog_object = $(this); dialog_object.html('
Are you sure you want to restore this form with ID = ' + record + '?'); $('.ui-dialog-buttonpane').css('padding', '0 0.5em').css('font-size', '9pt'); $('.ui-dialog-buttonpane .ui-dialog-buttonset').css('width', '100%'); $('[data-autofocus="true"]').focus(); }, close : function () { var dialog_object = $(this); row.css({'background-color':original_background_color}); $(dialog_object).remove(); } }); } else { $('
') .appendTo('body') .dialog( { draggable : true, resizable : false, modal : true, height : 200, width : 400, title : 'Unable to Restore', buttons: [ { text : "Ok", 'class' : "float_right", 'data-autofocus' : "true", icons : { primary : 'ui-icon-check'}, click : function() { // Close the dialog box $(this).dialog("close"); } } ], open : function () { var dialog_object = $(this); dialog_object.html('
You cannot restore this record because it has not been deleted.'); $('.ui-dialog-buttonpane').css('padding', '0 0.5em').css('font-size', '9pt'); $('.ui-dialog-buttonpane .ui-dialog-buttonset').css('width', '100%'); $('[data-autofocus="true"]').focus(); }, close : function () { var dialog_object = $(this); row.css({'background-color':original_background_color}); $(dialog_object).remove(); } }); } }); // Update form button $('.bia_update') .css({'width' : '16px', 'height' : '16px', 'margin-left' : '5px'}) .button({ icons : { primary : 'ui-icon-arrowrefresh-1-s'}, text : false}) .click(function() { var button = $(this); var row = button.parents('tr'); var original_background_color = row.css('background-color'); var record = row.attr('data-record'); var status = row.attr('data-status'); row.css({'background-color':'yellow'}); if (status == 'PEND' || status == 'INSF') { $('
') .appendTo('body') .dialog( { draggable : true, resizable : false, modal : true, height : 550, width : 500, title : 'Change Form Status', buttons: [ { text : "Received", 'class' : "float_left", icons : { primary : 'ui-icon-check'}, click : function() { var data = { record : record, status : 'RECD'}; $('
').addClass('ui-widget-overlay ui-front') .appendTo('body'); $('
').appendTo('body') .css('width', '225px') .css('height', '170px') .css('text-align', 'center') .css('padding', '0.5em') .position({my : "center center", at : "center center", of : window}) .addClass('ui-dialog ui-widget ui-widget-content ui-corner-all ui-front ui-dialog-buttons') .html('
Working...

Please wait, this may take a while to process.
'); // Submit the change var jqxhr = $.ajax( { type : 'POST', url : '{{ url('/forms/bia/update-form') }}', data : data, dataType : 'html' }) .done(function (data) { console.log('Update was successful.'); // Reload location.reload(); }) .fail(function (jqXHR, status, error) { var response = jqXHR.responseText; var errorData = $.parseJSON(response); console.log(errorData); alert ("There was an error updating the record.\n\nThis page will be reloaded."); location.reload(); }); } }, { text : "Insufficient", 'class' : "float_left", 'style' : "margin-left: 97px;", icons : { primary : 'ui-icon-circle-minus'}, click : function() { var data = { 'record' : record, 'status' : 'INSF', 'note' : $('[name="note"]').val().replace('\n','
')}; $('
').addClass('ui-widget-overlay ui-front') .appendTo('body'); $('
').appendTo('body') .css('width', '225px') .css('height', '170px') .css('text-align', 'center') .css('padding', '0.5em') .position({my : "center center", at : "center center", of : window}) .addClass('ui-dialog ui-widget ui-widget-content ui-corner-all ui-front ui-dialog-buttons') .html('
Working...

Please wait, this may take a while to process.
'); // Submit the change var jqxhr = $.ajax( { type : 'POST', url : '{{ url('/forms/bia/update-form') }}', data : data, dataType : 'html' }) .done(function (data) { console.log('Update was successful.'); // Reload location.reload(); }) .fail(function (jqXHR, status, error) { var response = jqXHR.responseText; var errorData = $.parseJSON(response); console.log(errorData); alert ("There was an error updating the record.\n\nThis page will be reloaded."); location.reload(); }); } }, { text : "Cancel", 'class' : "float_right", 'data-autofocus' : "true", icons : { primary : 'ui-icon-cancel'}, click : function() { // Close the dialog box $(this).dialog("close"); } } ], open : function () { var dialog_object = $(this); dialog_object.html('
Use this window to update this form\'s status.

Received
  • All of the paperwork is in order
  • No further information is needed from the assessor
  • The next phase is processing payment for this form


Insufficient
  • The form needs additional information or this form in incomplete
  • The assessor will be able to edit the form and resubmit
  • Once resubmitted, the from\'s status will change from INSF to PEND
  • Please provide a specific note below that will be sent to the assessor



After the form\'s status is changed, an e-mail will be sent to the assessor to this effect.'); $('.ui-dialog-buttonpane').css('padding', '0 0.5em').css('font-size', '9pt'); $('.ui-dialog-buttonpane .ui-dialog-buttonset').css('width', '100%'); $('[data-autofocus="true"]').focus(); }, close : function () { var dialog_object = $(this); row.css({'background-color':original_background_color}); $(dialog_object).remove(); } }); } else { $('
') .appendTo('body') .dialog( { draggable : true, resizable : false, modal : true, height : 200, width : 400, title : 'Unable to Update', buttons: [ { text : "Ok", 'class' : "float_right", 'data-autofocus' : "true", icons : { primary : 'ui-icon-check'}, click : function() { // Close the dialog box $(this).dialog("close"); } } ], open : function () { var dialog_object = $(this); dialog_object.html('
You cannot update this record because it has not been submitted.'); $('.ui-dialog-buttonpane').css('padding', '0 0.5em').css('font-size', '9pt'); $('.ui-dialog-buttonpane .ui-dialog-buttonset').css('width', '100%'); $('[data-autofocus="true"]').focus(); }, close : function () { var dialog_object = $(this); row.css({'background-color':original_background_color}); $(dialog_object).remove(); } }); } }); // Pay form button $('.bia_pay') .css({'width' : '16px', 'height' : '16px', 'margin-left' : '5px'}) .button({ icons : { primary : 'ui-icon-check'}, text : false}) .click(function() { var button = $(this); var row = button.parents('tr'); var original_background_color = row.css('background-color'); var record = row.attr('data-record'); var status = row.attr('data-status'); row.css({'background-color':'yellow'}); if (status == 'RECD') { $('
') .appendTo('body') .dialog( { draggable : true, resizable : false, modal : true, height : 550, width : 500, title : 'Mark Payment', buttons: [ { text : "Received", 'class' : "float_left", icons : { primary : 'ui-icon-check'}, click : function() { var data = { record : record, status : 'RECD'}; $('
').addClass('ui-widget-overlay ui-front') .appendTo('body'); $('
').appendTo('body') .css('width', '225px') .css('height', '170px') .css('text-align', 'center') .css('padding', '0.5em') .position({my : "center center", at : "center center", of : window}) .addClass('ui-dialog ui-widget ui-widget-content ui-corner-all ui-front ui-dialog-buttons') .html('
Working...

Please wait, this may take a while to process.
'); // Submit the change var jqxhr = $.ajax( { type : 'POST', url : '{{ url('/forms/bia/update-form') }}', data : data, dataType : 'html' }) .done(function (data) { console.log('Update was successful.'); // Reload location.reload(); }) .fail(function (jqXHR, status, error) { var response = jqXHR.responseText; var errorData = $.parseJSON(response); console.log(errorData); alert ("There was an error updating the record.\n\nThis page will be reloaded."); location.reload(); }); } }, { text : "Insufficient", 'class' : "float_left", 'style' : "margin-left: 97px;", icons : { primary : 'ui-icon-circle-minus'}, click : function() { var data = { 'record' : record, 'status' : 'INSF', 'note' : $('[name="note"]').val().replace('\n','
')}; $('
').addClass('ui-widget-overlay ui-front') .appendTo('body'); $('
').appendTo('body') .css('width', '225px') .css('height', '170px') .css('text-align', 'center') .css('padding', '0.5em') .position({my : "center center", at : "center center", of : window}) .addClass('ui-dialog ui-widget ui-widget-content ui-corner-all ui-front ui-dialog-buttons') .html('
Working...

Please wait, this may take a while to process.
'); // Submit the change var jqxhr = $.ajax( { type : 'POST', url : '{{ url('/forms/bia/update-form') }}', data : data, dataType : 'html' }) .done(function (data) { console.log('Update was successful.'); // Reload location.reload(); }) .fail(function (jqXHR, status, error) { var response = jqXHR.responseText; var errorData = $.parseJSON(response); console.log(errorData); alert ("There was an error updating the record.\n\nThis page will be reloaded."); location.reload(); }); } }, { text : "Cancel", 'class' : "float_right", 'data-autofocus' : "true", icons : { primary : 'ui-icon-cancel'}, click : function() { // Close the dialog box $(this).dialog("close"); } } ], open : function () { var dialog_object = $(this); dialog_object.html('
Use this window to update this form\'s status.

Received
  • All of the paperwork is in order
  • No further information is needed from the assessor
  • The next phase is processing payment for this form


Insufficient
  • The form needs additional information or this form in incomplete
  • The assessor will be able to edit the form and resubmit
  • Once resubmitted, the from\'s status will change from INSF to PEND
  • Please provide a specific note below that will be sent to the assessor



After the form\'s status is changed, an e-mail will be sent to the assessor to this effect.'); $('.ui-dialog-buttonpane').css('padding', '0 0.5em').css('font-size', '9pt'); $('.ui-dialog-buttonpane .ui-dialog-buttonset').css('width', '100%'); $('[data-autofocus="true"]').focus(); }, close : function () { var dialog_object = $(this); row.css({'background-color':original_background_color}); $(dialog_object).remove(); } }); } else { $('
') .appendTo('body') .dialog( { draggable : true, resizable : false, modal : true, height : 200, width : 400, title : 'Unable to Mark Payment', buttons: [ { text : "Ok", 'class' : "float_right", 'data-autofocus' : "true", icons : { primary : 'ui-icon-check'}, click : function() { // Close the dialog box $(this).dialog("close"); } } ], open : function () { var dialog_object = $(this); dialog_object.html('
You cannot mark this record for a payment because this record because it has not been marked as received.'); $('.ui-dialog-buttonpane').css('padding', '0 0.5em').css('font-size', '9pt'); $('.ui-dialog-buttonpane .ui-dialog-buttonset').css('width', '100%'); $('[data-autofocus="true"]').focus(); }, close : function () { var dialog_object = $(this); row.css({'background-color':original_background_color}); $(dialog_object).remove(); } }); } }); // Gray out deleted forms $('tr[data-status="DEL"]') .css({'color' : '#aaaaaa'}); /* * Make the table sortable */ // Up and down sorting arrows var down_arrow = '{{ asset('/images/icons/bullet_arrow_up.png') }}'; var up_arrow = '{{ asset('/images/icons/bullet_arrow_down.png') }}'; // Bind a click event to table headers that are sortable $('thead').on('click', 'th[data-sortable="true"]', function() { // Remove any sorting images $('th[data-sortable="true"] img').remove(); // Get the table and the set of rows var table = $(this).parents('table').eq(0); var rows = table.find('tr:gt(0)').toArray().sort(comparer($(this).index())); // Figure out sorting directions this.asc = !this.asc; var arrow = down_arrow; if (!this.asc) { rows = rows.reverse(); arrow = up_arrow; } // Recreate rows for (var i = 0; i < rows.length; i++) { table.append(rows[i]); } // Show sorting arrow $(this).append(''); // Recolor the rows colorRows(); }); // Bind hover events to the table headers that are sortable $('thead').on('mouseover', 'th[data-sortable="true"]', function () { $(this).css('cursor', 'pointer'); }); $('thead').on('mouseout', 'th[data-sortable="true"]', function () { $(this).css('cursor', 'auto'); }); // Compare string values function comparer(index) { return function(a, b) { var valA = getCellValue(a, index); var valB = getCellValue(b, index); return $.isNumeric(valA) && $.isNumeric(valB) ? valA - valB : valA.localeCompare(valB); } } // Get a table cell's value function getCellValue(row, index) { var value = $(row).children('td').eq(index).html(); // Remove dollar signs and commas from dollar amounts to help enforce numeric comparison if (value.match(/\$/)) { value = value.replace(/(\$|,)/g, ''); } return value; } // Show/hide rows according to the view preferences var pref = $.parseJSON('{{ json_encode($info['view']) }}'); function viewPreferences() { $('tbody tr').each(function () { var row = $(this); var status = row.attr('data-status'); if (!pref[status]) { row.hide(); } else { row.show(); } }); colorRows(); } viewPreferences(); $('.status_step') .hover(function() { $(this).css({'cursor' : 'pointer', 'color' : '#E87A00'}); }, function() { $(this).css({'cursor' : 'pointer', 'color' : ''}); }) .click(function() { var item = $(this); var status = item.attr('data-status'); var visible = pref[status]; pref[status] = !visible; if (pref[status]) { item.addClass('show'); } else { item.removeClass('show'); item.css({'color' : '#cccccc'}); } // Save this user's view preferences var jqxhr = $.ajax( { type : 'POST', url : '{{ url('account/set-osaa-preference') }}', data : { 'preference' : 'bia_visible_status', '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); }); viewPreferences(); }) .each(function() { var item = $(this); var status = item.attr('data-status'); var visible = pref[status]; if (visible) { item.addClass('show'); } else { item.removeClass('show'); item.css({'color' : '#cccccc'}); } }); // Assessor info $('.assessor') .hover(function () { $(this).css({'cursor' : 'pointer', 'color' : '#005fa9', 'text-decoration' : 'underline'}); }, function () { $(this).css({'color' : '', 'text-decoration' : ''}); }) .click(function() { var item = $(this); var assessor_name = item.text(); var row = item.parents('tr'); var record = row.attr('data-record'); $('
') .appendTo('body') .dialog( { modal : false, draggable : true, resizable : true, height : 250, width : 500, title : assessor_name + ', BIA Assessor Information', open : function () { var dialog_object = $(this); dialog_object.html("
"); var jqxhr = $.ajax( { type : 'GET', url : '{{ url('forms/bia/') }}/' + record + '/assessor-info', 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 assessor information.\n\nThis page will be reloaded."); location.reload(); }) .complete(function () { }); }, close : function () { var dialog_object = $(this); $(dialog_object).remove(); } }); }); @stop @section('page_functions') {{--Help--}}
Payments & Reports
@stop @section('main_content') {{-- Success Bar --}} @if (Session::has('success'))
{{ Session::get('success') }}
@endif {{-- Errors --}} @if (Session::has('errors'))
@foreach ($errors->all() as $error) {{ $error }} @endforeach
@endif

{{ Session::get('year') }}-{{ intval(substr(Session::get('year'), 2, 2)) + 1 }} Reconciliation Report Forms

{{-- Form Status --}}
Form Count by Status
@foreach ($info['status_counts'] as $status => $count)
{{ $count }}
{{ $status }}
@endforeach
@if (count($info['forms']) > 0) @foreach ($info['forms'] as $form) @endforeach
ID # Status Assessor Total - $ Created At Received At Paid At
{{ $form->id }} {{ $form->status }} {{ $form->user->getDisplayFullName() }} ${{ number_format($form->total_amount, 2) }} {{ $form->created_at }} {{ $form->received_at }} {{ $form->paid_at }} @if (Helpers::strEqual($form->status, array('PEND', 'INSF', 'RECD', 'DONE')))
@endif @if (!Helpers::strEqual($form->status, 'DEL'))
@endif @if (Helpers::strEqual($form->status, array('PEND', 'INSF')))
@endif @if (Helpers::strEqual($form->status, array('RECD')))
@endif @if (Helpers::strEqual($form->status, 'DEL'))
@else
@endif
@else There are no BIA Assessment Reconciliation Report forms on record to display. @endif
@stop