{% set active_page='impschedules'%}{% extends "base.html" %}
{% block title %}Implementation Schedules {% endblock %}
{% block content %}
    <script src="{{url_for('static', filename='jquery.tablesorter.min.js')}}"></script>

	<h1>Implementation Schedules</h1>
    <p class="lead">All available implementation schedules are listed below.</p>
    <table class="table">
        <thead>
            <th>Organisation name</th><th>Schedule id</th><th>Edit</th><th>Delete</th>
        </thead>
    <tbody>
	{% for schedule in impschedules %}
    <tr>
        <td><a href="{{url_for('organisation', id=schedule.Publisher.publisher_code_actual)}}">{{schedule.Publisher.publisher_actual}}</a></td>
        <td>{{schedule.ImpSchedule.id}}</td>
        <td><a href="{{url_for('edit_schedule', publisher_id=schedule.Publisher.publisher_code_actual, id=schedule.ImpSchedule.id)}}"><i class="icon-pencil"></i></a></td>
        <td><a href="{{url_for('delete_schedule', publisher_id=schedule.Publisher.publisher_code_actual, id=schedule.ImpSchedule.id)}}" data-confirm="Are you sure you want to delete this schedule? This action cannot be undone!"><i class="icon-trash"></i></a></td>
    </tr>
	{% endfor %}
    </tbody>
    </table>
<script type="text/javascript">
$(document).ready(function() {
	$('a[data-confirm]').click(function(ev) {
		var href = $(this).attr('href');
		if (!$('#dataConfirmModal').length) {
			$('body').append('<div id="dataConfirmModal" class="modal" role="dialog" aria-labelledby="dataConfirmLabel" aria-hidden="true"><div class="modal-header"><button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button><h3 id="dataConfirmLabel">Please Confirm</h3></div><div class="modal-body"></div><div class="modal-footer"><button class="btn" data-dismiss="modal" aria-hidden="true">Cancel</button><a class="btn btn-primary" id="dataConfirmOK">OK</a></div></div>');
		} 
		$('#dataConfirmModal').find('.modal-body').text($(this).attr('data-confirm'));
		$('#dataConfirmOK').attr('href', href);
		$('#dataConfirmModal').modal({show:true});
		return false;
	});
});
</script>

{% endblock %}

Add implementation schedules list for admin
Add implementation schedules list for admin
