<commit_before>{% load tz %}
{% load staticfiles %}
{% load dashboard_tags %}
<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <!-- The above 3 meta tags *must* come first in the head; any other head content must come *after* these tags -->
    <title>Project Dashboard</title>

    <!-- Latest compiled and minified CSS -->
    <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css" integrity="<KEY>" crossorigin="anonymous">

    <!-- Optional theme -->
    <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap-theme.min.css" integrity="<KEY>" crossorigin="anonymous">

    <!-- datatables -->
    <link rel="stylesheet" href="//cdn.datatables.net/1.10.12/css/jquery.dataTables.min.css">
    <link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css">

    <!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
    <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
    <!--[if lt IE 9]>
      <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script>
      <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
    <![endif]-->
  </head>
  <body>
    <a href="https://github.com/cmheisel/project-status-dashboard"><img style="position: absolute; top: 0; right: 0; border: 0;" src="https://camo.githubusercontent.com/a6677b08c955af8400f44c6298f40e7d19cc5b2d/68747470733a2f2f73332e616d617a6f6e6177732e636f6d2f6769746875622f726962626f6e732f666f726b6d655f72696768745f677261795f3664366436642e706e67" alt="Fork me on GitHub" data-canonical-src="https://s3.amazonaws.com/github/ribbons/forkme_right_gray_6d6d6d.png"></a>
    <div class="row">
      <div class="col-md-1">&nbsp;</div>
    <div class="col-md-10">
      <h1>Project Dashboard</h1>
      <p class="lead">Fresh progess updates from JIRA</p>
      <small><a href="{% google_sheet_url %}" title="Edit this table">Edit <span class="glyphicon glyphicon-edit"></span></a> || Updated: {{ updated }}</small>
    <table class="table table-striped table-bordered table-hover table-condensed" id="projects">
        <thead class="thead">
          <tr>
          {% for key in data.0.keys %}
              <th rowspan="2">{{ key }}</th>
          {% endfor %}
              <th data-orderable="false" data-search="false" rowspan="2">JIRA</th>
              <th data-orderable="false" data-search="false" colspan="2">Today</th>
              <th data-orderable="false" data-search="false" colspan="2">Last week</th>
          </tr>
          <tr>
            <th>Complete</th>
            <th>Scope</th>
            <th>Complete</th>
            <th>Scope</th>
          </tr>

        </thead>
        <tbody>
        {% for row in data %}
            <tr>
                {% for value in row.values %}
                <td>{{ value }}</td>
                {% endfor %}
                <td>
                  {% if row.xtras.jira_summary %}
                    <a href="{{ JIRA_URL }}/secure/IssueNavigator.jspa?mode=hide&amp;requestId={{ row.xtras.jira_summary.filter_id }}" title="View JIRA filter"><span class="glyphicon glyphicon-filter"></span></a>
                  {% endif %}
                </td>
                {% if row.xtras.jira_summary_errors %}
                <td class="danger" colspan="2">
                  <dl>
                    <dt>Errors:</dt>
                    {% for error in row.xtras.jira_summary_errors %}
                    <dd>{{ error }}</dd>
                    {% endfor %}
                  </dl>
                </td>
                {% else %}
                  {% with current=row.xtras.jira_summary previous=row.xtras.week_ago_summary %}
                  {% progress_report current previous %}
                  {% endwith %}
                {% endif %}

                {% with current=row.xtras.week_ago_summary previous=None %}
                {% progress_report current previous %}
                {% endwith %}
            </tr>
        {% endfor %}
      </tbody>
    </table>
  </div>
          <div class="col-md-1">&nbsp;</div>
  </div>
    <!-- jQuery (necessary for Bootstrap's JavaScript plugins) -->
    <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
    <!-- Latest compiled and minified JavaScript -->
    <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js" integrity="<KEY>" crossorigin="anonymous"></script>
    <!-- datatables -->
    <script src="//cdn.datatables.net/1.10.12/js/jquery.dataTables.min.js"></script>
    <script src="//cdn.datatables.net/1.10.12/js/dataTables.bootstrap.min.js"></script>

    <script type="text/javascript">
    jQuery.extend({
        getQueryParameters : function(str) {
          return (str || document.location.search).replace(/(^\?)/,'').split("&").map(function(n){return n = n.split("="),this[n[0]] = n[1],this}.bind({}))[0];
        }
    });
    $(document).ready(function() {
      var query_params = $.getQueryParameters();
      $('#projects').DataTable({
        "lengthMenu": [[-1, 5, 10, 15, 20], ["All", 5, 10, 15, 20]]
      });
      if ("filter" in query_params){
        $('#projects').DataTable().search(query_params['filter']).draw();
      }
    });
    </script>
  </body>
</html><commit_msg>Handle deep linking to filters<commit_after>{% load tz %}
{% load staticfiles %}
{% load dashboard_tags %}
<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <!-- The above 3 meta tags *must* come first in the head; any other head content must come *after* these tags -->
    <title>Project Dashboard</title>

    <!-- Latest compiled and minified CSS -->
    <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css" integrity="<KEY>" crossorigin="anonymous">

    <!-- Optional theme -->
    <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap-theme.min.css" integrity="<KEY>" crossorigin="anonymous">

    <!-- datatables -->
    <link rel="stylesheet" href="//cdn.datatables.net/1.10.12/css/jquery.dataTables.min.css">
    <link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css">

    <!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
    <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
    <!--[if lt IE 9]>
      <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script>
      <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
    <![endif]-->
  </head>
  <body>
    <a href="https://github.com/cmheisel/project-status-dashboard"><img style="position: absolute; top: 0; right: 0; border: 0;" src="https://camo.githubusercontent.com/a6677b08c955af8400f44c6298f40e7d19cc5b2d/68747470733a2f2f73332e616d617a6f6e6177732e636f6d2f6769746875622f726962626f6e732f666f726b6d655f72696768745f677261795f3664366436642e706e67" alt="Fork me on GitHub" data-canonical-src="https://s3.amazonaws.com/github/ribbons/forkme_right_gray_6d6d6d.png"></a>
    <div class="row">
      <div class="col-md-1">&nbsp;</div>
    <div class="col-md-10">
      <h1>Project Dashboard</h1>
      <p class="lead">Fresh progess updates from JIRA</p>
      <small><a href="{% google_sheet_url %}" title="Edit this table">Edit <span class="glyphicon glyphicon-edit"></span></a> || Updated: {{ updated }}</small>
    <table class="table table-striped table-bordered table-hover table-condensed" id="projects">
        <thead class="thead">
          <tr>
          {% for key in data.0.keys %}
              <th rowspan="2">{{ key }}</th>
          {% endfor %}
              <th data-orderable="false" data-search="false" rowspan="2">JIRA</th>
              <th data-orderable="false" data-search="false" colspan="2">Today</th>
              <th data-orderable="false" data-search="false" colspan="2">Last week</th>
          </tr>
          <tr>
            <th>Complete</th>
            <th>Scope</th>
            <th>Complete</th>
            <th>Scope</th>
          </tr>

        </thead>
        <tbody>
        {% for row in data %}
            <tr>
                {% for value in row.values %}
                <td>{{ value }}</td>
                {% endfor %}
                <td>
                  {% if row.xtras.jira_summary %}
                    <a href="{{ JIRA_URL }}/secure/IssueNavigator.jspa?mode=hide&amp;requestId={{ row.xtras.jira_summary.filter_id }}" title="View JIRA filter"><span class="glyphicon glyphicon-filter"></span></a>
                  {% endif %}
                </td>
                {% if row.xtras.jira_summary_errors %}
                <td class="danger" colspan="2">
                  <dl>
                    <dt>Errors:</dt>
                    {% for error in row.xtras.jira_summary_errors %}
                    <dd>{{ error }}</dd>
                    {% endfor %}
                  </dl>
                </td>
                {% else %}
                  {% with current=row.xtras.jira_summary previous=row.xtras.week_ago_summary %}
                  {% progress_report current previous %}
                  {% endwith %}
                {% endif %}

                {% with current=row.xtras.week_ago_summary previous=None %}
                {% progress_report current previous %}
                {% endwith %}
            </tr>
        {% endfor %}
      </tbody>
    </table>
  </div>
          <div class="col-md-1">&nbsp;</div>
  </div>
    <!-- jQuery (necessary for Bootstrap's JavaScript plugins) -->
    <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
    <!-- Latest compiled and minified JavaScript -->
    <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js" integrity="<KEY>" crossorigin="anonymous"></script>
    <!-- datatables -->
    <script src="//cdn.datatables.net/1.10.12/js/jquery.dataTables.min.js"></script>
    <script src="//cdn.datatables.net/1.10.12/js/dataTables.bootstrap.min.js"></script>

    <script type="text/javascript">
    $(document).ready(function() {
      var hash = window.location.hash;
      $('#projects').DataTable({
        "lengthMenu": [[-1, 5, 10, 15, 20], ["All", 5, 10, 15, 20]]
      });
      if (hash){
        $('#projects').DataTable().search(hash).draw();
      }
      $('#projects_filter input').on('keyup', function(){
        window.location.hash = this.value;
      })
    });
    </script>
  </body>
</html>
{'fraction_non_alphanumeric': 0.17849898580121704, 'fraction_numerical': 0.04047575142909828, 'mean_word_length': 2.3707271597265382, 'pattern_counts': {'":': 2, '<': 221, '<?xml version=': 0, '>': 221, 'https://': 18, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '650165', 'n_tokens_mistral': 3869, 'n_tokens_neox': 3422, 'n_words': 619}