1. Sven Hendriks
  2. cpstub

Commits

Sven Hendriks  committed 2fd7346

Re-adding mako templates and base.css

  • Participants
  • Parent commits 55e9919
  • Branches default

Comments (0)

Files changed (4)

File cpstub/project_template/project_name/web/static/css/base.css

View file
  • Ignore whitespace
+body {
+  background: #ffffff;
+  font-family: helvetica, arial, sans-serif;
+  text-color: #505050;
+  text-align: center;
+  width: 800px;
+  margin: 0 auto;
+}
+
+div.wrapper {
+  text-align: left;
+}
+
+div.header {
+  background: #d0d0d0;
+}
+
+div.content {
+}
+
+div.footer {
+  background: #a0a0a0;
+}

File cpstub/project_template/project_name/web/view/base.tmpl

View file
  • Ignore whitespace
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+  <head>
+    <title>${title}</title>
+    <link href="/static/css/base.css" type="text/css" rel="stylesheet" />
+  </head>
+  <body>
+    <div class="wrapper">
+      <div class="header">Header</div><br/>
+      <div class="content">${self.body()}</div><br/>
+      <div class="footer">Footer</div>
+    </div>
+  </body>
+</html>
+

File cpstub/project_template/project_name/web/view/hello.tmpl

View file
  • Ignore whitespace
+<%inherit file="base.tmpl"/>
+<h1>${content}</h1>

File setup.py

View file
  • Ignore whitespace
             'project_template/setup.py.tmpl',
             'project_template/project_name/__init__.py.tmpl',
             'project_template/project_name/web/__init__.py.tmpl',
-            'project_template/project_name/web/control/*',
-            'project_template/project_name/web/model/*',
-            'project_template/project_name/web/view/*',
-            #'project_template/project_name/web/static/*',
-            'project_template/project_name/web/static/css/*',
-            'project_template/project_name/web/static/js/*',
-            'project_template/project_name/web/static/images/*',
+            'project_template/project_name/web/control/*.*',
+            'project_template/project_name/web/model/*.*',
+            'project_template/project_name/web/view/*.*',
+            'project_template/project_name/web/static/css/*.*',
+            'project_template/project_name/web/static/js/*.*',
+            'project_template/project_name/web/static/images/*.*',
         ],
     }
 ,