gedankenstuecke/oh_data_uploader

View on GitHub
main/templates/main/index.html

Summary

Maintainability
Test Coverage
{% extends 'main/application.html' %}

{% block content %}

      <div class="jumbotron">
        <img alt="Brand" src="{% if config.logo_url %}{{config.logo_url}}{% else %}/static/default_logo.png{% endif %}" height="150px" align="left">
        <h1>Welcome to {{ config.project_title|default:"My Open Humans Project" }}</h1>
        <p>
          {{config.project_description|default:"This template demonstrates how you can run your own Open Humans data upload project"}}
        </p>
      </div>

      <div class="row">
        <div class="col-md-6">
          {% load utilities %}
          {{index_page|markdown}}
        </div>
        <div class="col-md-6">
          <h2>How it works</h2>
          <ol>
            <li><b>Log in or create an Open Humans account</b><br>
              You can upload your data for <i>{{config.project_title}}</i>
              once you have done this.
            </li>
            <li><b>Authorize {{config.project_title}} on <i>Open Humans</i></b><br>
              This authorizes us to deposit your archive into your Open Humans account.</li>
            <li><b>Upload your data.</b><br>
              You will be redirected back to {{config.project_title}} and can then
              upload your data.
              You'll be able to
              <a href="{{ oh_proj_page }}">access &amp; manage your data on
              Open Humans</a>.
            </li>
          </ol>

          {% if config.oh_client_id and config.oh_client_secret and file_num %}
          <a class="btn btn-primary btn-lg"
            href="{{ auth_url }}">
              Get started / Login
          </a>
          {% else %}
          <a class="btn btn-primary btn-lg"
            href="{% url 'project-admin:home' %}">
              Setup your project
          </a>
          {% endif %}
          <h2>FAQ</h2>
          <div class="panel panel-default">
            <div class="panel-heading">
              <h3 class="panel-title">Will my data be public?</h3>
            </div>
            <div class="panel-body">
              <p>
                The short answer: No. The longer answer: No, unless you decide that
                you want to make this data public. If that is the case then you can head over to
                <a href="{{ oh_proj_page }}">Open Humans</a>.
                and make the full archive data publicly available.
              </p>
            </div>
          </div>
          <small>Have more questions?
            <a href="/about">
              Read the full FAQ and About page
            </a>.
          </small>
        </div>
      </div>


{%endblock%}