Add bootstrap css
[disclosr.git] / documents / disclogsList.php
blob:a/documents/disclogsList.php -> blob:b/documents/disclogsList.php
  <?php
  include('template.inc.php');
  include_header_documents("");
  include_once('../include/common.inc.php');
   
  echo "<table>
  <tr><th>Agency Name</th><th>Disclosure Log URL recorded?</th><th>Do we monitor this URL?</th></tr>";
  $agenciesdb = $server->get_db('disclosr-agencies');
  $docsdb = $server->get_db('disclosr-documents');
  try {
  $rows = $agenciesdb->get_view("app", "byCanonicalName", null, true)->rows;
   
   
  if ($rows) {
  foreach ($rows as $row) {
   
  echo "<tr><td><b>" . $row->value->name . "</b> (".$row->id.")</td>\n";
   
  echo "<td>";
  if (isset($row->value->FOIDocumentsURL)) {
  echo '<a href="viewDocument.php?hash='.md5($row->value->FOIDocumentsURL).'">'
  .$row->value->FOIDocumentsURL.'</a>';
  } else {
  echo "<font color='red'>✘</font>";
  }
  echo "</td>\n<td>";
  if (isset($row->value->FOIDocumentsURL)) {
  if (file_exists("./scrapers/".$row->id.'.py')) {
  echo "<font color='green'>✔</font>";
  } else if (file_exists("./scrapers/".$row->id.'.txt')){
  echo "<font color='blue'><b>▬</b></font>";
  } else {
  echo "<font color='red'>✘</font>";
  }
  }
  echo "</td></tr>\n";
  }
  }
  } catch (SetteeRestClientException $e) {
  setteErrorHandler($e);
  }
  echo "</table>";
  include_footer_documents();
  ?>