Browse Source

changed templates regarding conrols section

php2python
Holger Frey 7 years ago
parent
commit
7a919daacf
  1. 4
      ordr2/static/css/style.css
  2. 60
      ordr2/templates/account/login.jinja2
  3. 20
      ordr2/templates/errors/forbidden.jinja2
  4. 20
      ordr2/templates/errors/not_found.jinja2
  5. 15
      ordr2/templates/layout.jinja2
  6. 120
      ordr2/templates/pages/faq.jinja2
  7. 66
      ordr2/templates/pages/welcome.jinja2

4
ordr2/static/css/style.css

@ -718,3 +718,7 @@ hgroup .info { @@ -718,3 +718,7 @@ hgroup .info {
.page-controls h1 { font-size: 25px; }
}
/*================ STYLES FOR php2python BRANCH ================*/
input[value="password:mapping"] + div { margin-bottom:10px; }

60
ordr2/templates/account/login.jinja2

@ -4,34 +4,36 @@ @@ -4,34 +4,36 @@
{% block subtitle %} Login {% endblock subtitle %}
{% block content %}
<div class="container">
<div class="row">
<div class="span6 offset3">
<h1>Log in</h1>
{{ macros.flash_messages() }}
</div>
</div>
<div class="row">
<div class="span6 offset3">
<form action="{{request.resource_url(request.root, 'account', 'login')}}" method="post" class="form-horizontal">
<fieldset class="control-group">
<label for="input01" class="control-label">Username</label>
<div class="controls">
<input type="text" name="username" class="span3" size="30">
</div>
</fieldset>
<fieldset class="control-group">
<label for="password" class="control-label">Password</label>
<div class="controls">
<input type="password" name="password" class="span3" size="30">
</div>
</fieldset>
<fieldset class="form-actions">
<input type="hidden" name="csrf_token" value="{{get_csrf_token()}}">
<button class="btn primary large" type="submit">Log in</button>
</fieldset>
</form>
</div>
</div>
<div class="content">
<div class="container">
<div class="row">
<div class="span6 offset3">
<h1>Log in</h1>
{{ macros.flash_messages() }}
</div>
</div>
<div class="row">
<div class="span6 offset3">
<form action="{{request.resource_url(request.root, 'account', 'login')}}" method="post" class="form-horizontal">
<fieldset class="control-group">
<label for="input01" class="control-label">Username</label>
<div class="controls">
<input type="text" name="username" class="span3" size="30">
</div>
</fieldset>
<fieldset class="control-group">
<label for="password" class="control-label">Password</label>
<div class="controls">
<input type="password" name="password" class="span3" size="30">
</div>
</fieldset>
<fieldset class="form-actions">
<input type="hidden" name="csrf_token" value="{{get_csrf_token()}}">
<button class="btn primary large" type="submit">Log in</button>
</fieldset>
</form>
</div>
</div>
</div>
</div>
{% endblock content %}

20
ordr2/templates/errors/forbidden.jinja2

@ -3,16 +3,18 @@ @@ -3,16 +3,18 @@
{% block subtitle %} Access Denied {% endblock subtitle %}
{% block content %}
<div class="container">
<div class="row">
<div class="content">
<div class="container">
<div class="row">
<div class="span12">
<hgroup id="access-denied">
<h1>Access Denied!!!</h1>
<p class="info">You do not have the permission to access this page.</p>
</hgroup>
</div>
<div class="span12">
<hgroup id="access-denied">
<h1>Access Denied!!!</h1>
<p class="info">You do not have the permission to access this page.</p>
</hgroup>
</div>
</div>
</div>
</div>
</div>
{% endblock content %}

20
ordr2/templates/errors/not_found.jinja2

@ -3,16 +3,18 @@ @@ -3,16 +3,18 @@
{% block subtitle %} Not Found {% endblock subtitle %}
{% block content %}
<div class="container">
<div class="row">
<div class="content">
<div class="container">
<div class="row">
<div class="span12">
<hgroup id="access-denied">
<h1>These are not the droids<br>you are looking for</h1>
<p class="info">Whatever you wanted to see was not found on this server.</p>
</hgroup>
</div>
<div class="span12">
<hgroup id="access-denied">
<h1>These are not the droids<br>you are looking for</h1>
<p class="info">Whatever you wanted to see was not found on this server.</p>
</hgroup>
</div>
</div>
</div>
</div>
</div>
{% endblock content %}

15
ordr2/templates/layout.jinja2

@ -11,7 +11,8 @@ @@ -11,7 +11,8 @@
<link rel="stylesheet" href="{{request.static_url('ordr2:static/css/bootstrap.css')}}" type="text/css" media="screen">
<link rel="stylesheet" href="{{request.static_url('ordr2:static/css/bootstrap-responsive.css')}}" type="text/css" media="screen">
<link rel="stylesheet" href="{{request.static_url('ordr2:static/css/style.css')}}" type="text/css" media="screen" />
<link rel="stylesheet" href="{{request.static_url('ordr2:static/css/style.css')}}" type="text/css" media="screen" />
<link rel="stylesheet" href="{{request.static_url('deform:static/css/form.css')}}" type="text/css" media="screen" />
<!--[if !IE 7]>
<style type="text/css">
#wrap {display:table;height:100%}
@ -46,7 +47,7 @@ @@ -46,7 +47,7 @@
</ul>
{% else %}
<ul class="nav">
<li {% if context.nav_highlight == 'register' %} class="active" {% endif %}><a href="{{request.resource_url(request.root, 'register')}}">Register</a></li>
<li {% if context.nav_highlight == 'register' %} class="active" {% endif %}><a href="{{request.resource_url(request.root, 'account', 'register')}}">Register</a></li>
<li {% if context.nav_highlight == 'about' %} class="active" {% endif %}><a href="{{request.resource_url(request.root, 'about')}}">About</a></li>
</ul>
<form action="{{request.resource_url(request.root, 'account', 'login')}}" method="post" class="navbar-form pull-right">
@ -59,11 +60,11 @@ @@ -59,11 +60,11 @@
</div>
</div>
</header>
<div class="content {#<?php echo ($controls) ? ' controls' : ''; ?>#}">
{% block content %}
<p>No content</p>
{% endblock content %}
</div>
{% block content %}
<p>No content</p>
{% endblock content %}
<footer>
<div class="copy">

120
ordr2/templates/pages/faq.jinja2

@ -3,72 +3,74 @@ @@ -3,72 +3,74 @@
{% block subtitle %} FAQ {% endblock subtitle %}
{% block content %}
<div class="container">
<h1>Frequently Asked Questions</h1>
<div class="content">
<div class="container">
<h1>Frequently Asked Questions</h1>
<section>
<h2>Account</h2>
<section>
<h2>Account</h2>
<div class="well">
<h3>
Why can't I log in? It always says: &quot;You entered the wrong unsername and/or password.&quot;
</h3>
<p>
First of all, just because <em>ordr</em> tells you that you have entered a wrong username or password doesn't mean that's necesseraily true. Sound dumb? But actually this is a security measure, which helps against brood force attacks because the adversary doesn't know if the username he guessed was correct or not.
</p>
<p>
Usually there are two common reasons why you can't log in. There are:
</p>
<ol>
<li><em>Your account hasn't been activated by an admin yet.</em> &ndash; In this case ask a admin if he already has activated your account.</li>
<li><em>You mistyped your password or username.</em> &ndash; Just try it another time and make sure caps log isn't activated.</li>
</ol>
</div>
<div class="well">
<h3>
Why can't I log in? It always says: &quot;You entered the wrong unsername and/or password.&quot;
</h3>
<p>
First of all, just because <em>ordr</em> tells you that you have entered a wrong username or password doesn't mean that's necesseraily true. Sound dumb? But actually this is a security measure, which helps against brood force attacks because the adversary doesn't know if the username he guessed was correct or not.
</p>
<p>
Usually there are two common reasons why you can't log in. There are:
</p>
<ol>
<li><em>Your account hasn't been activated by an admin yet.</em> &ndash; In this case ask a admin if he already has activated your account.</li>
<li><em>You mistyped your password or username.</em> &ndash; Just try it another time and make sure caps log isn't activated.</li>
</ol>
</div>
<div class="well">
<h3>
Why can't I choose my own username?
</h3>
<p>
We want to enforce a specific guideline for the username. Namely <em>first name</em> followed immediately by the <em>last name</em>. This way everyone can easily identify the person, who placed an order. So please enter your real name into the registration form. Otherwise your account may not been activated because no one knows who you are.
</p>
</div>
<div class="well">
<h3>
Why can't I choose my own username?
</h3>
<p>
We want to enforce a specific guideline for the username. Namely <em>first name</em> followed immediately by the <em>last name</em>. This way everyone can easily identify the person, who placed an order. So please enter your real name into the registration form. Otherwise your account may not been activated because no one knows who you are.
</p>
</div>
<div class="well">
<h3>
Why can I only edit my email after I registered?
</h3>
<p>
Your username depends on your first and last name. Changing the username is not allowed, therefore you are also not allowed to change your first and last name afterwards. Even admins can not change your first/last name and your username.
</p>
</div>
</section>
<div class="well">
<h3>
Why can I only edit my email after I registered?
</h3>
<p>
Your username depends on your first and last name. Changing the username is not allowed, therefore you are also not allowed to change your first and last name afterwards. Even admins can not change your first/last name and your username.
</p>
</div>
</section>
<section>
<h2>Ordering</h2>
<section>
<h2>Ordering</h2>
<div class="well">
<h3>
I have an consumable, which I am ordering regulary but isn't in the databse. Can I add it?
</h3>
<p>
Unfortunately you can not add consumables to the databse yourself. But ask an admin or purchaser. They're certainly to help you out.
</p>
</div>
</section>
<div class="well">
<h3>
I have an consumable, which I am ordering regulary but isn't in the databse. Can I add it?
</h3>
<p>
Unfortunately you can not add consumables to the databse yourself. But ask an admin or purchaser. They're certainly to help you out.
</p>
</div>
</section>
<section>
<h2>Miscellaneous</h2>
<section>
<h2>Miscellaneous</h2>
<div class="well">
<h3>
I have found a bug where can I report it?
</h3>
<p>
If you have found a bug or an issue with the software please use <a href="https://git.cpi.imtek.uni-freiburg.de/holgi/ordr2/issues">this page here</a>.
You need an <a href="https://wiki.cpi.imtek.uni-freiburg.de/CPIvServerDocumentation/GogsGitServer">gogs</a> account to submit an issue. Please be as specific as you can be.
</p>
</div>
</section>
<div class="well">
<h3>
I have found a bug where can I report it?
</h3>
<p>
If you have found a bug or an issue with the software please use <a href="https://git.cpi.imtek.uni-freiburg.de/holgi/ordr2/issues">this page here</a>.
You need an <a href="https://wiki.cpi.imtek.uni-freiburg.de/CPIvServerDocumentation/GogsGitServer">gogs</a> account to submit an issue. Please be as specific as you can be.
</p>
</div>
</section>
</div>
</div>
{% endblock content %}

66
ordr2/templates/pages/welcome.jinja2

@ -3,38 +3,40 @@ @@ -3,38 +3,40 @@
{% block subtitle %} Welcome {% endblock subtitle %}
{% block content %}
<div class="container">
<div class="content">
<div class="container">
<div class="row">
<div class="span12">
<hgroup id="welcome">
<h1>Welcome to <span class="brand">ordr</span>!</h1>
<p class="quote">An order management system to simplify your shopping for laboratory supplies.</p>
</hgroup>
</div>
</div>
<div class="row">
<div class="span12">
<hgroup id="welcome">
<h1>Welcome to <span class="brand">ordr</span>!</h1>
<p class="quote">An order management system to simplify your shopping for laboratory supplies.</p>
</hgroup>
</div>
</div>
<div class="row">
<div class="span12">
<p>
<strong>What can order do for you?</strong> It will simplify the process of ordering laboratory supplies by using the power of the newest web technologies. Interested? Just follow the three steps below!
</p>
</div>
</div>
<div class="row">
<div class="span12">
<p>
<strong>What can order do for you?</strong> It will simplify the process of ordering laboratory supplies by using the power of the newest web technologies. Interested? Just follow the three steps below!
</p>
</div>
</div>
<div class="row">
<div class="span4">
<h2>1. Register</h2>
<p>Registration is easy as 1-2-3. Just fill out the form on <?php echo anchor('account/register', 'this page');?> and as soon as an admin has activated your account the shopping can begin!</p>
</div>
<div class="span4">
<h2>2. Place an Order</h2>
<p>A lot of the chemicals, supllies and so forth are already stored in the database, so you don't have to fill out the order form your self!</p>
</div>
<div class="span4">
<h2>3. Get notified</h2>
<p>As soons as your purchase has arrived you will automatically get notified. Or you can use the orders overview to check what the working status is.</p>
</div>
</div>
</div>{% endblock content %}
<div class="row">
<div class="span4">
<h2>1. Register</h2>
<p>Registration is easy as 1-2-3. Just fill out the form on <?php echo anchor('account/register', 'this page');?> and as soon as an admin has activated your account the shopping can begin!</p>
</div>
<div class="span4">
<h2>2. Place an Order</h2>
<p>A lot of the chemicals, supllies and so forth are already stored in the database, so you don't have to fill out the order form your self!</p>
</div>
<div class="span4">
<h2>3. Get notified</h2>
<p>As soons as your purchase has arrived you will automatically get notified. Or you can use the orders overview to check what the working status is.</p>
</div>
</div>
</div>
</div>
{% endblock content %}