-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathSections.php
65 lines (62 loc) · 3.67 KB
/
Sections.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
<?php require_once 'includes/initialize.php';
$p =4;
require_once './layouts/header.php';
?>
</head>
<body>
<?php include_once 'layouts/navigation.php'; ?>
<div class="container-fluid">
<div class="row-fluid">
<div class="span2">
<?php require_once './layouts/options-settings.php'; ?>
</div>
<div class="span10">
<?php if (isset($message)){ echo $message;} ?>
<div class="row-fluid">
<div class="hero-unit table table-bordered span12">
<h4>SETTINGS : Sections </h4>
<form>
<input name="filter" onkeyup="filterTable(this, sf)" placeholder="Enter Search Value" type="text" autofocus />
</form>
<table class="table-bordered table" id="sf">
<thead style="position: relative">
<th style="width: 10%">Section No.</th>
<th>Sections</th>
<th style="width: 10%">District</th>
</thead>
<?php
$volumes = Volume::find_all();
if($volumes){
foreach ($volumes as $volume){
?>
<tr>
<td style="vertical-align: top"><?php echo $volume->no ?></td>
<td>
<table class="table table-bordered table-striped">
<tr>
<?php $sections = Section::find_for_volume($volume->id,$session->location); if ($sections){
foreach ($sections as $section) { ?>
<td>
<?php echo $section->no . " - ". $section->name ?>
<a href="Sections-Edit.php?id=<?php echo base64_encode($section->id) ?>"><img title="View / Edit" src="img/edit.jpg" width="15px" height="15px" /></a> <a href="Delete.php?id=<?php echo base64_encode($section->id) ?>&s=section"onclick="return confirm('Remove?')" title="Remove"><img src="img/remove.png" width="15px" height="15px" /></a>
</td>
<?php }
} ?>
</tr>
</table>
</td>
<td style="vertical-align: top"><?php echo $volume->district ?></td>
</tr>
<?php }} else { ?>
<tr>
<td colspan="7"><div class="alert-info">NO SECTIONS FOUND. <a href="Sections-Add.php">Add </a> new Section</div></td>
</tr>
<?php } ?>
</table>
</div>
</div>
</div><!--/row-->
</div><!--/span-->
</div><!--/row-->
</div>
<?php require_once 'layouts/footer.php';