Permalink
Browse files

Merge commit '9eb7ca4e8ed9420eb753bfc33c911d6992c81557' into development

  • Loading branch information...
2 parents 563e28d + 9eb7ca4 commit f3f6e366702606dea76e0408e1497a5049c6d09f @amol- amol- committed Apr 17, 2012
Showing with 8,023 additions and 1,369 deletions.
  1. +1 −1 devtools/commands/quickstart.py
  2. +187 −123 devtools/commands/quickstart_jinja/about.html
  3. +0 −59 devtools/commands/quickstart_jinja/authentication.html
  4. +5 −5 devtools/commands/quickstart_jinja/data.html
  5. +1 −1 devtools/commands/quickstart_jinja/environ.html
  6. +0 −13 devtools/commands/quickstart_jinja/footer.html
  7. +0 −8 devtools/commands/quickstart_jinja/header.html
  8. +36 −19 devtools/commands/quickstart_jinja/index.html
  9. +47 −40 devtools/commands/quickstart_jinja/master.html
  10. +0 −32 devtools/commands/quickstart_jinja/sidebars.html
  11. +183 −102 devtools/commands/quickstart_mako/about.mak
  12. +0 −54 devtools/commands/quickstart_mako/authentication.mak
  13. +4 −8 devtools/commands/quickstart_mako/data.mak
  14. +1 −4 devtools/commands/quickstart_mako/environ.mak
  15. +0 −8 devtools/commands/quickstart_mako/header.mak
  16. +33 −20 devtools/commands/quickstart_mako/index.mak
  17. +51 −95 devtools/commands/quickstart_mako/master.mak
  18. +0 −6 devtools/commands/quickstart_mako/movie.mak
  19. +4 −6 devtools/templates/turbogears/+package+/controllers/root.py_tmpl
  20. +11 −0 devtools/templates/turbogears/+package+/lib/helpers.py_tmpl
  21. +0 −69 devtools/templates/turbogears/+package+/public/css/admin.css
  22. +686 −0 devtools/templates/turbogears/+package+/public/css/bootstrap-responsive.css
  23. +12 −0 devtools/templates/turbogears/+package+/public/css/bootstrap-responsive.min.css
  24. +3,990 −0 devtools/templates/turbogears/+package+/public/css/bootstrap.css
  25. +689 −0 devtools/templates/turbogears/+package+/public/css/bootstrap.min.css
  26. +0 −319 devtools/templates/turbogears/+package+/public/css/style.css
  27. BIN devtools/templates/turbogears/+package+/public/images/add.png
  28. BIN devtools/templates/turbogears/+package+/public/images/contentbg.png
  29. BIN devtools/templates/turbogears/+package+/public/images/delete.png
  30. BIN devtools/templates/turbogears/+package+/public/images/error.png
  31. BIN devtools/templates/turbogears/+package+/public/images/glyphicons-halflings-white.png
  32. BIN devtools/templates/turbogears/+package+/public/images/glyphicons-halflings.png
  33. BIN devtools/templates/turbogears/+package+/public/images/header_inner2.png
  34. BIN devtools/templates/turbogears/+package+/public/images/headerbg.png
  35. BIN devtools/templates/turbogears/+package+/public/images/info.png
  36. BIN devtools/templates/turbogears/+package+/public/images/inputbg.png
  37. BIN devtools/templates/turbogears/+package+/public/images/loginbg.png
  38. BIN devtools/templates/turbogears/+package+/public/images/loginbottombg.png
  39. BIN devtools/templates/turbogears/+package+/public/images/loginheader-left.png
  40. BIN devtools/templates/turbogears/+package+/public/images/loginheader-right.png
  41. BIN devtools/templates/turbogears/+package+/public/images/menu-item-actibg-first.png
  42. BIN devtools/templates/turbogears/+package+/public/images/menu-item-actibg.png
  43. BIN devtools/templates/turbogears/+package+/public/images/menu-item-border.png
  44. BIN devtools/templates/turbogears/+package+/public/images/menubg.png
  45. BIN devtools/templates/turbogears/+package+/public/images/ok.png
  46. BIN devtools/templates/turbogears/+package+/public/images/pagebg.png
  47. BIN devtools/templates/turbogears/+package+/public/images/pencil.png
  48. BIN devtools/templates/turbogears/+package+/public/images/star.png
  49. BIN devtools/templates/turbogears/+package+/public/images/strype2.png
  50. BIN devtools/templates/turbogears/+package+/public/images/turbogears_logo.png
  51. BIN devtools/templates/turbogears/+package+/public/images/turbogears_logo_big.png
  52. BIN devtools/templates/turbogears/+package+/public/images/warning.png
  53. +1,726 −0 devtools/templates/turbogears/+package+/public/javascript/bootstrap.js
  54. +6 −0 devtools/templates/turbogears/+package+/public/javascript/bootstrap.min.js
  55. 0 devtools/templates/turbogears/+package+/public/javascript/empty
  56. +192 −131 devtools/templates/turbogears/+package+/templates/about.html
  57. +0 −67 devtools/templates/turbogears/+package+/templates/authentication.html
  58. +34 −25 devtools/templates/turbogears/+package+/templates/data.html
  59. +3 −6 devtools/templates/turbogears/+package+/templates/debug.html
  60. +1 −4 devtools/templates/turbogears/+package+/templates/environ.html
  61. +2 −5 devtools/templates/turbogears/+package+/templates/error.html
  62. +16 −11 devtools/templates/turbogears/+package+/templates/footer.html
  63. +0 −12 devtools/templates/turbogears/+package+/templates/header.html
  64. +38 −26 devtools/templates/turbogears/+package+/templates/index.html
  65. +12 −13 devtools/templates/turbogears/+package+/templates/login.html
  66. +42 −32 devtools/templates/turbogears/+package+/templates/master.html
  67. +0 −34 devtools/templates/turbogears/+package+/templates/sidebars.html
  68. +9 −11 devtools/templates/turbogears/+package+/tests/functional/test_root.py_tmpl
  69. +1 −0 devtools/templates/turbogears/development.ini_tmpl
@@ -134,7 +134,7 @@ class QuickstartCommand(command.Command):
action="store_false", dest="migrations", default=True)
parser.add_option("--enable-tw1",
- help="disable sqlalchemy-migrate model migrations",
+ help="use toscawidgets 1.x in place of 2.x version",
action="store_true", dest="tw1", default=False)
parser.add_option("--minimal",

Large diffs are not rendered by default.

Oops, something went wrong.
@@ -1,59 +0,0 @@
-{% extends "master.html" %}
-
-{% block master_title %}
-Learning TurboGears 2.1: Quick guide to authentication.
-{% endblock %}
-
-{% block contents %}
- {{ sidebar_top() }}
- {{ sidebar_bottom() }}
- <div id="getting_started">
- <h2>Authentication &amp; Authorization in a TG2 site.</h2>
- <p>If you have access to this page, this means you have enabled authentication and authorization
- in the quickstart to create your project.</p>
- <p>
- The paster command will have created a few specific controllers for you. But before you
- go to play with those controllers you'll need to make sure your application has been
- properly bootstapped.
- This is dead easy, here is how to do this:
- </p>
-
- <span class="code">
- paster setup-app development.ini
- </span>
-
- <p>
- inside your application's folder and you'll get a database setup (using the preferences you have
- set in your development.ini file). This database will also have been prepopulated with some
- default logins/passwords so that you can test the secured controllers and methods.
- </p>
- <p>
- To change the comportement of this setup-app command you just need to edit the <span class="code">websetup.py</span> file.
- </p>
- <p>
- Now try to visiting the <a href="{{ tg.url('/manage_permission_only') }}">manage_permission_only</a> URL. You will be challenged with a login/password form.
- </p>
- <p>
- Only managers are authorized to visit this method. You will need to log-in using:
- <p>
- <span class="code">
- login: manager
- </span>
- </p>
- <p>
- <span class="code">
- password: managepass
- </span>
- </p>
- </p>
- <p>
- Another protected resource is <a href="{{ tg.url('/editor_user_only') }}">editor_user_only</a>. This one is protected by a different set of permissions.
- You will need to be <span class="code">editor</span> with a password of <span class="code">editpass</span> to be able to access it.
- </p>
- <p>
- The last kind of protected resource in this quickstarted app is a full so called <a href="{{ tg.url('/secc') }}">secure controller</a>. This controller is protected globally.
- Instead of having a @require decorator on each method, we have set an allow_only attribute at the class level. All the methods in this controller will
- require the same level of access. You need to be manager to access <a href="{{ tg.url('/secc') }}">secc</a> or <a href="{{ tg.url('/secc/some_where') }}">secc/some_where</a>.
- </p>
- </div>
-{% endblock %}
@@ -20,11 +20,11 @@
<p>The data provided in the template call is:
<table>
{% for key,value in params.iteritems() %}
- <tr>
- <td>{{ key }}</td>
- <td>{{ value }}</td>
- </tr>
+ <tr>
+ <td>{{ key }}</td>
+ <td>{{ value }}</td>
+ </tr>
{% endfor %}
</table>
</p>
-{% endblock %}
+{% endblock %}
@@ -11,7 +11,7 @@
component list of variables provided by the Components, and at last
the "wsgi." namespace with very useful information about your WSGI Server</p>
<p>The keys in the environment are:
- <table>
+ <table class="table">
{% for key in environment.keys()|sort %}
<tr>
<td>{{ key }}</td>
@@ -1,13 +0,0 @@
-{% macro footer() %}
-<div id="footer">
- <div class="flogo">
- <img src="{{ tg.url('/images/under_the_hood_blue.png') }}" alt="TurboGears" />
- <p><a href="http://www.turbogears.org/2.1/">Powered by TurboGears 2</a></p>
- </div>
- <div class="foottext">
- <p>TurboGears is a open source front-to-back web development
- framework written in Python. Copyright (c) 2005-2009 </p>
- </div>
- <div class="clearingdiv"></div>
-</div>
-{% endmacro %}
@@ -1,8 +0,0 @@
-{% macro header() -%}
-<div id="header">
- <h1>
- Welcome to TurboGears 2
- <span class="subtitle">The Python web metaframework</span>
- </h1>
-</div>
-{%- endmacro %}
@@ -6,27 +6,44 @@
{% block contents %}
- {{ sidebar_top() }}
- <div id="getting_started">
- <h2>Presentation</h2>
- <p>TurboGears 2 is rapid web application development toolkit designed to make your life easier.</p>
- <ol id="getting_started_steps">
- <li class="getting_started">
+<div class="row">
+ <div class="span8 hidden-phone hidden-tablet">
+ <div class="hero-unit">
+ <h1>Welcome to TurboGears 2.1</h1>
+ <p>If you see this page it means your installation was successful!</p>
+ <p>TurboGears 2 is rapid web application development toolkit designed to make your life easier.</p>
+ <p>
+ <a class="btn btn-primary btn-large" href="http://www.turbogears.org" target="_blank">
+ {{h.icon('book', True)}} Learn more
+ </a>
+ </p>
+ </div>
+ </div>
+ <div class="span4">
+ <a class="btn btn-small" href="http://www.turbogears.org/2.1/docs/">{{h.icon('book')}} TG2 Documents</a> <span class="label label-success">new</span> Read everything in the Getting Started section<br/>
+ <a class="btn btn-small" href="http://docs.turbogears.org/1.0">{{h.icon('book')}} TG1 Documents</a> (still useful, although a lot has changed for TG2)<br/>
+ <a class="btn btn-small" href="http://groups.google.com/group/turbogears">{{h.icon('comment')}} Join the Mail List</a> for general TG use/topics
+ </div>
+</div>
+
+<div class="row">
+ <div class="span4">
<h3>Code your data model</h3>
- <p> Design your data model, Create the database, and Add some bootstrap data.</p>
- </li>
- <li class="getting_started">
+ <p> Design your data <code>model</code>, Create the database, and Add some bootstrap data.</p>
+ </div>
+
+ <div class="span4">
<h3>Design your URL architecture</h3>
- <p> Decide your URLs, Program your controller methods, Design your
- templates, and place some static files (CSS and/or JavaScript). </p>
- </li>
- <li class="getting_started">
+ <p> Decide your URLs, Program your <code>controller</code> methods, Design your
+ <code>templates</code>, and place some static files (CSS and/or Javascript). </p>
+ </div>
+
+ <div class="span4">
<h3>Distribute your app</h3>
<p> Test your source, Generate project documents, Build a distribution.</p>
- </li>
- </ol>
- </div>
- <div class="clearingdiv" />
- <div class="notice"> Thank you for choosing TurboGears.
- </div>
+ </div>
+</div>
+
+<div class="notice"> Thank you for choosing TurboGears.</div>
+
{% endblock %}
@@ -1,55 +1,62 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<!DOCTYPE html>
<html>
- {% from "header.html" import header with context %}
- {% from "sidebars.html" import sidebar_bottom, sidebar_top with context %}
- {% from "footer.html" import footer with context %}
<head>
- <meta content="text/html; charset=UTF-8" http-equiv="Content-Type"
- content="{{ response.content_type }}; charset={{ response.charset }}"/>
+ <meta charset="charset={{ response.charset }}"/>
{% block master_head %}
{% endblock %}
<title>{% block master_title %}{% endblock %}</title>
- <link rel="stylesheet" type="text/css" media="screen" href="{{ tg.url('/css/style.css') }}" />
- <link rel="stylesheet" type="text/css" media="screen" href="{{ tg.url('/css/admin.css') }}" />
+ <link rel="stylesheet" type="text/css" media="screen" href="{{tg.url('/css/bootstrap.min.css')}}" />
+ <link rel="stylesheet" type="text/css" media="screen" href="{{tg.url('/css/bootstrap-responsive.min.css')}}" />
+ <style>
+ .footer { margin-top: 45px; padding: 35px 0 36px; border-top: 1px solid #e5e5e5; }
+ .footer p { margin-bottom: 0; color: #555; }
+ </style>
</head>
<body>
- {{ header() }}
- <ul id="mainmenu">
- <li class="first"><a href="{{ tg.url('/') }}" class="{% if page == 'index' %}active{% endif %}">Welcome</a></li>
- <li><a href="{{ tg.url('/about') }}" class="{% if page == 'about' %}active{% endif %}">About</a></li>
- {% if tg.auth_stack_enabled %}
- <li><a href="{{ tg.url('/auth') }}" class="{% if page=='auth' %}active{% endif %}">Authentication</a></li>
- {% endif %}
+ <div class="container">
- <li><a href="{{ tg.url('/environ') }}" class="{% if page == 'environ' %}active{% endif %}">WSGI Environment</a></li>
- <li><a href="http://groups.google.com/group/turbogears">Contact</a></li>
- {% if tg.auth_stack_enabled %}
- {% if request.identity %}
- <li id="login" class="loginlogout"><a href="{{ tg.url('/logout_handler') }}">Logout</a></li>
- <li id="admin" class="loginlogout"><a href="{{ tg.url('/admin') }}">Admin</a></li>
- {% else %}
- <li id="login" class="loginlogout"><a href="{{ tg.url('/login') }}">Login</a></li>
- {% endif %}
- {% endif %}
- </ul>
- <div id="content">
- {% if page %}
- <div class="currentpage">
- Now Viewing: {{ page }}
+ <!-- Navbar -->
+ <div class="navbar">
+ <div class="navbar-inner">
+ <div class="container">
+ <a class="brand" href="#"><img src="{{tg.url('/images/turbogears_logo.png')}}" alt="TurboGears 2"/>turbogears2</a>
+ <ul class="nav">
+ <li class="{% if page == 'index' %}active{% endif %}"><a href="{{ tg.url('/') }}">Welcome</a></li>
+ <li><a href="{{ tg.url('/about') }}" class="{% if page == 'about' %}active{% endif %}">About</a></li>
+ <li><a href="{{ tg.url('/environ') }}" class="{% if page == 'environ' %}active{% endif %}">WSGI Environment</a></li>
+ </ul>
+
+ {% if tg.auth_stack_enabled %}
+ <ul class="nav pull-right">
+ {% if request.identity %}
+ <li py:if="request.identity"><a href="{{tg.url('/logout_handler')}}">Logout</a></li>
+ <li py:if="request.identity"><a href="{{tg.url('/admin')}}">Admin</a></li>
+ {% else %}
+ <li py:if="not request.identity"><a href="{{tg.url('/login')}}">Login</a></li>
+ {% endif %}
+ </ul>
+ {% endif %}
+ </div>
+ </div>
</div>
- {% endif %}
- {% with flash=tg.flash_obj.render('flash', use_js=False) %}
- {{ flash|safe }}
- {% endwith %}
+ <!-- Flash messages -->
- {% block contents %}
- {% endblock %}
+ {% with flash=tg.flash_obj.render('flash', use_js=False) %}
+ <div class="row"><div class="span8 offset2">
+ {{ flash|safe }}
+ </div></div>
+ {% endwith %}
+
+ {% block contents %}
+ {% endblock %}
- <!-- End of main_content -->
- {{ footer() }}
- </div>
+ <!-- End of main_content -->
+ <footer class="footer hidden-tablet hidden-phone">
+ <a class="pull-right" href="http://www.turbogears.org/2.1/"><img style="vertical-align:middle;" src="{{tg.url('/images/under_the_hood_blue.png')}}" alt="TurboGears 2" /></a>
+ <p>Copyright &copy; turbogears2 {{h.current_year()}}</p>
+ </footer>
+ </div>
</body>
</html>
@@ -1,32 +0,0 @@
-
-{% macro sidebar_top() %}
- <div id="sb_top" class="sidebar">
- <h2>Get Started with TG2</h2>
- <ul class="links">
- <li>
- {% if page=='index' %}
- <span><a href="{{ tg.url('/about') }}">About this page</a> A quick guide to this TG2 site </span>
- {% else %}
- <span><a href="{{ tg.url('/') }}">Home</a> Back to your Quickstart Home page </span>
- {% endif %}
- </li>
- <li><a href="http://www.turbogears.org/2.1/docs/">TG2 Documents</a> - Read everything in the Getting Started section</li>
- <li><a href="http://docs.turbogears.org/1.0">TG1 docs</a> (still useful, although a lot has changed for TG2) </li>
- <li><a href="http://groups.google.com/group/turbogears"> Join the TG Mail List</a> for general TG use/topics </li>
- </ul>
- </div>
-{% endmacro %}
-
-{% macro sidebar_bottom() %}
- <div id="sb_bottom" class="sidebar">
- <h2>Developing TG2</h2>
- <ul class="links">
- <li><a href="http://trac.turbogears.org/query?status=new&amp;status=assigned&amp;status=reopened&amp;group=type&amp;milestone=2.1&amp;order=priority">TG2 Trac tickets</a> What's happening now in TG2 development</li>
- <li><a href="http://trac.turbogears.org/timeline">TG Dev timeline</a> (recent ticket updates, svn checkins, wiki changes)</li>
- <li><a href="http://svn.turbogears.org/trunk">TG2 SVN repository</a> For checking out a copy</li>
- <li><a href="http://turbogears.org/2.1/docs/main/Contributing.html#installing-the-development-version-of-turbogears-2-from-source">Follow these instructions</a> For installing your copy</li>
- <li><a href="http://trac.turbogears.org/browser/trunk">TG2 Trac's svn view</a> In case you need a quick look</li>
- <li><a href="http://groups.google.com/group/turbogears-trunk"> Join the TG-Trunk Mail List</a> for TG2 discuss/dev </li>
- </ul>
- </div>
-{% endmacro %}
Oops, something went wrong.

0 comments on commit f3f6e36

Please sign in to comment.