|
@@ -234,7 +234,7 @@ const userId = <?=$user->id?>;
|
|
|
<div class="mb-3" id="assigned-tests-map" style="height: 480px;" data-maps data-lat="<?=$first_location->latitude?>" data-lng="<?=$first_location->longitude?>" data-zoom="10">
|
|
<div class="mb-3" id="assigned-tests-map" style="height: 480px;" data-maps data-lat="<?=$first_location->latitude?>" data-lng="<?=$first_location->longitude?>" data-zoom="10">
|
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
- <table class="table table-sm table-hover">
|
|
|
|
|
|
|
+ <table id="assigned-tests-table" class="table table-sm table-hover">
|
|
|
<col style="width: 10%;" />
|
|
<col style="width: 10%;" />
|
|
|
<col style="width: 30%;" />
|
|
<col style="width: 30%;" />
|
|
|
<col style="width: 20%;" />
|
|
<col style="width: 20%;" />
|
|
@@ -246,9 +246,9 @@ const userId = <?=$user->id?>;
|
|
|
<th>ID</th>
|
|
<th>ID</th>
|
|
|
<th>Location</th>
|
|
<th>Location</th>
|
|
|
<th>Project</th>
|
|
<th>Project</th>
|
|
|
- <th>Assigned</th>
|
|
|
|
|
- <th>Due</th>
|
|
|
|
|
- <th></th>
|
|
|
|
|
|
|
+ <th data-type="date" data-format="DD/MM/YYYY">Assigned</th>
|
|
|
|
|
+ <th data-type="date" data-format="DD/MM/YYYY">Due</th>
|
|
|
|
|
+ <th data-sortable="false"></th>
|
|
|
</tr>
|
|
</tr>
|
|
|
</thead>
|
|
</thead>
|
|
|
<?php
|
|
<?php
|
|
@@ -279,12 +279,8 @@ const userId = <?=$user->id?>;
|
|
|
<td class="align-middle">
|
|
<td class="align-middle">
|
|
|
<a href="/account/projects/<?=$project->id?>"><?=htmlspecialchars($project->name)?></a>
|
|
<a href="/account/projects/<?=$project->id?>"><?=htmlspecialchars($project->name)?></a>
|
|
|
</td>
|
|
</td>
|
|
|
- <td class="align-middle">
|
|
|
|
|
- <?=$date_assigned?>
|
|
|
|
|
- </td>
|
|
|
|
|
- <td class="align-middle">
|
|
|
|
|
- <?=$date_due?>
|
|
|
|
|
- </td>
|
|
|
|
|
|
|
+ <td class="align-middle"><?=$date_assigned?></td>
|
|
|
|
|
+ <td class="align-middle"><?=$date_due?></td>
|
|
|
<td class="align-middle text-right">
|
|
<td class="align-middle text-right">
|
|
|
</td>
|
|
</td>
|
|
|
</tr>
|
|
</tr>
|
|
@@ -371,7 +367,7 @@ const userId = <?=$user->id?>;
|
|
|
|
|
|
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
- <table class="table table-sm table-hover">
|
|
|
|
|
|
|
+ <table id="completed-tests-table" class="table table-sm table-hover">
|
|
|
<col style="width: 10%;" />
|
|
<col style="width: 10%;" />
|
|
|
<col style="width: 30%;" />
|
|
<col style="width: 30%;" />
|
|
|
<col style="width: 20%;" />
|
|
<col style="width: 20%;" />
|
|
@@ -383,9 +379,9 @@ const userId = <?=$user->id?>;
|
|
|
<th>ID</th>
|
|
<th>ID</th>
|
|
|
<th>Location</th>
|
|
<th>Location</th>
|
|
|
<th>Project</th>
|
|
<th>Project</th>
|
|
|
- <th>Assigned</th>
|
|
|
|
|
- <th>Completed</th>
|
|
|
|
|
- <th></th>
|
|
|
|
|
|
|
+ <th data-type="date" data-format="DD/MM/YYYY">Assigned</th>
|
|
|
|
|
+ <th data-type="date" data-format="DD/MM/YYYY">Completed</th>
|
|
|
|
|
+ <th data-sortable="false"></th>
|
|
|
</tr>
|
|
</tr>
|
|
|
</thead>
|
|
</thead>
|
|
|
<?php
|
|
<?php
|
|
@@ -415,12 +411,8 @@ const userId = <?=$user->id?>;
|
|
|
<td class="align-middle">
|
|
<td class="align-middle">
|
|
|
<a href="/account/projects/<?=$project->id?>"><?=htmlspecialchars($project->name)?></a>
|
|
<a href="/account/projects/<?=$project->id?>"><?=htmlspecialchars($project->name)?></a>
|
|
|
</td>
|
|
</td>
|
|
|
- <td class="align-middle">
|
|
|
|
|
- <?=$assigned_date?>
|
|
|
|
|
- </td>
|
|
|
|
|
- <td class="align-middle">
|
|
|
|
|
- <?=$test_date?>
|
|
|
|
|
- </td>
|
|
|
|
|
|
|
+ <td class="align-middle"><?=$assigned_date?></td>
|
|
|
|
|
+ <td class="align-middle"><?=$test_date?></td>
|
|
|
<td class="align-middle text-right">
|
|
<td class="align-middle text-right">
|
|
|
<a class="btn btn-outline-primary" href="/account/tests/<?=$test->id?>">View</a>
|
|
<a class="btn btn-outline-primary" href="/account/tests/<?=$test->id?>">View</a>
|
|
|
</td>
|
|
</td>
|
|
@@ -529,3 +521,22 @@ const userId = <?=$user->id?>;
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
|
|
|
+
|
|
|
|
|
+<script type="module">
|
|
|
|
|
+ import { DataTable } from "/js/simple-datatables.module.js";
|
|
|
|
|
+
|
|
|
|
|
+ const options = {
|
|
|
|
|
+ perPage: 25,
|
|
|
|
|
+ };
|
|
|
|
|
+
|
|
|
|
|
+ const assignedTestsTable = document.getElementById("assigned-tests-table");
|
|
|
|
|
+ if(assignedTestsTable) {
|
|
|
|
|
+ new DataTable("#assigned-tests-table", options);
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ const completedTestsTable = document.getElementById("completed-tests-table");
|
|
|
|
|
+ if(completedTestsTable) {
|
|
|
|
|
+ new DataTable("#completed-tests-table", options);
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+</script>
|