Permalink
Browse files

Integrate 08 changes from Juri

  • Loading branch information...
2 parents 4450c1e + eaa5f63 commit 86051007e59b6718c6a5e12a832f209498962c28 @johnf johnf committed Apr 6, 2007
Showing with 274 additions and 523 deletions.
  1. +12 −0 CHANGES
  2. +1 −0 COPYING
  3. +2 −0 TODO
  4. +1 −1 setup.py
  5. +2 −0 test.ini
  6. +3 −0 zookeepr.egg-info/paste_deploy_config.ini_tmpl
  7. +0 −30 zookeepr/config.ini
  8. +0 −4 zookeepr/config/routing.py
  9. +1 −1 zookeepr/config/wikiconfig.py
  10. +0 −13 zookeepr/controllers/about.py
  11. +1 −1 zookeepr/controllers/account.py
  12. +2 −1 zookeepr/controllers/cfp.py
  13. +0 −2 zookeepr/controllers/profile.py
  14. +1 −2 zookeepr/controllers/registration.py
  15. +11 −0 zookeepr/lib/helpers.py
  16. +11 −4 zookeepr/lib/wiki.py
  17. BIN zookeepr/public/favicon.png
  18. +0 −199 zookeepr/public/lca2007.css
  19. BIN zookeepr/public/mel8-logo.png
  20. +0 −2 zookeepr/public/print.css
  21. +204 −3 zookeepr/public/zookeepr.css
  22. +0 −29 zookeepr/templates/about/contact.myt
  23. +0 −59 zookeepr/templates/about/index.myt
  24. +0 −39 zookeepr/templates/about/openday.myt
  25. +0 −35 zookeepr/templates/about/partners.myt
  26. +0 −29 zookeepr/templates/about/press.myt
  27. +0 −15 zookeepr/templates/about/programme.myt
  28. +0 −7 zookeepr/templates/about/sponsors.myt
  29. +0 −7 zookeepr/templates/about/sydney.myt
  30. +1 −1 zookeepr/templates/account/expired.myt
  31. +1 −1 zookeepr/templates/account/in_progress.myt
  32. +1 −1 zookeepr/templates/account/password_confirmation_sent.myt
  33. +1 −1 zookeepr/templates/account/thankyou.myt
  34. +3 −3 zookeepr/templates/autohandler
  35. +1 −1 zookeepr/templates/cfp/thankyou.myt
  36. +1 −1 zookeepr/templates/error/500.myt
  37. +4 −8 zookeepr/templates/header.myt
  38. +1 −1 zookeepr/templates/openday/new.myt
  39. +1 −1 zookeepr/templates/payment/view.myt
  40. +1 −1 zookeepr/templates/registration/new.myt
  41. +1 −1 zookeepr/templates/registration/thankyou.myt
  42. +0 −11 zookeepr/tests/functional/test_about.py
  43. +1 −1 zookeepr/tests/functional/test_account.py
  44. +4 −1 zookeepr/tests/functional/test_profile.py
  45. +0 −6 zookeepr/tests/functional/test_routing.py
View
12 CHANGES
@@ -1,6 +1,18 @@
Changes for Zookeepr
====================
+0.3.19
+------
+
+ * Added license info (Jiri Baum)
+ * Added mel8 logos (Jiri Baum)
+ * Remove deprecated about controller (Jiri Baum)
+ * Integrated lca200[78].css (John Ferlito)
+ * Removed config.ini (John Ferlito)
+ * Added contact email address into config (Jiri Baum)
+ * Wiki UTF8 Fix (Jiri Baum)
+ * Bump version
+
0.3.18
------
View
@@ -0,0 +1 @@
+Zookeepr is licensed under the GNU GPL version 2 only.
View
2 TODO
@@ -27,3 +27,5 @@ displayname can't be 'new', can't be all numbers, must be urlable, hsouldnt have
* When someone registers we should generate an invoice
* It should be due in two weeks
* If they don't pay in two weeks they loose there accomodation and it goes back into the pool
+
+ * Generalise templates so they aren't lca specific. Move stuff into a config file eg conference name
View
@@ -2,7 +2,7 @@
setup(
name='zookeepr',
- version="0.3.18",
+ version="0.3.19",
#description="",
#author="",
#author_email="",
View
@@ -29,6 +29,8 @@ dynamic_html_dir = %(here)s/dynamic_html
commsecure_secret = foo
commsecure_merchantid = bar
+contact_email = contact@yourdomain.com
+
# We're using SQLAlchemy, the database is initialised in
# `Globals.__init__()`, and connected to per thread/request in
# `BaseController.__call__()`. Note the URL syntax depends
@@ -40,3 +40,6 @@ dburi = sqlite://filename=%(here)s/somedb.db
# and a shared secret
commsecure_merchantid = TestZookeeprMerchantID
commsecure_secret = zing
+
+# Contact email for the committee
+contact_email = contact@yourdomain.com
View
@@ -1,30 +0,0 @@
-[DEFAULT]
-debug = true
-email_to = you@yourdomain.com
-smtp_server = localhost
-error_email_from = paste@exceptions.com
-
-[server:main]
-use = egg:PasteScript#wsgiutils
-host = 0.0.0.0
-port = 5000
-
-[app:main]
-use = egg:zookeepr
-cache_dir = %(here)s/cache
-app_instance_uuid = {aa5109d1-b668-4a21-9a70-ad15316b1b38}
-session_key = zookeepr
-session_secret = +faGdXY9RZsRRGe0phmwcn7ID
-
-# We're using SQLAlchemy, the database is initialised in
-# `Globals.__init__()`, and connected to per thread/request in
-# `BaseController.__call__()`. Note the URL syntax depends
-# on the SQLAlchemy documentation for `global_connect`.
-dburi = sqlite://filename=%(here)s/somedb.db
-
-# Do not set debug to true or uncomment the line below
-# on a production environment otherwise in the event of
-# an error occurring the visitor will be presented with
-# interactive debugging tools and these could be used to
-# execute malicious code.
-set debug = false
@@ -43,10 +43,6 @@ def make_map():
m.connect('/account/:action', controller='account')
m.connect('/account/reset_password/:url_hash', controller='account', action='reset_password')
- # special case for the about controller
- m.connect('/about/', controller='about', action='view', id='index')
- m.connect('/about/:id', controller='about', action='view')
-
# OpenDay
m.connect('openday', '/OpenDay', controller='openday', action='new')
m.connect('/Openday', controller='openday', action='new')
@@ -38,7 +38,7 @@ class Config(DefaultConfig):
# Wiki identity ----------------------------------------------------
# Site name, used by default for wiki name-logo [Unicode]
- sitename = u'linux.conf.au 2007'
+ sitename = u'linux.conf.au 2008'
# Wiki logo. You can use an image, text or both. [Unicode]
# For no logo or text, use '' - the default is to show the sitename.
@@ -1,13 +0,0 @@
-from zookeepr.lib.base import *
-
-class AboutController(BaseController):
- """Display information about a specific part of the conference.
- """
- def view(self, id):
- """View the information.
-
- ``view`` is the primary action associated with this controller.
- It does no processing of information, only returns a response
- from the templates.
- """
- return render_response("about/%s.myt" % id)
@@ -273,7 +273,7 @@ def new(self):
# generate welcome message
body = render('account/new_account_email.myt',
fragment=True)
- s.sendmail("seven-contact@lca2007.linux.org.au",
+ s.sendmail(request.environ['paste.config']['app_conf'].get('contact_email'),
c.person.email_address,
body)
s.quit()
@@ -64,7 +64,8 @@ def submit(self):
s = smtplib.SMTP(request.environ['paste.config']['app_conf'].get('app_smtp_server'))
# generate the message from a template
body = render('cfp/submission_response.myt', id=c.registration.url_hash, fragment=True)
- s.sendmail("seven-contact@lca2007.linux.org.au", c.registration.email_address, body)
+ s.sendmail(request.environ['paste.config']['app_conf'].get('contact_email'),
+ c.registration.email_address, body)
s.quit()
return render_response('cfp/thankyou.myt')
@@ -31,5 +31,3 @@ def view(self):
return super(ProfileController, self).view()
-
-
@@ -153,7 +153,6 @@ class RegistrationController(BaseController, Create, Update, List):
permissions = { 'remind': [AuthRole('organiser')],
}
-
def is_same_person(self):
return c.signed_in_person == c.registration.person
@@ -212,7 +211,7 @@ def new(self):
try:
s = smtplib.SMTP(request.environ['paste.config']['app_conf'].get('app_smtp_server'))
body = render('registration/response.myt', id=c.person.url_hash, fragment=True)
- s.sendmail("seven-contact@lca2007.linux.org.au", c.person.email_address, body)
+ s.sendmail(request.environ['paste.config']['app_conf'].get('contact_email'), c.person.email_address, body)
s.quit()
except:
pass
View
@@ -72,3 +72,14 @@ def radio(name, value, label=None):
else:
lab = '<label for="%s">%s</label>' % (id_str, label)
return i + lab
+
+def contact_email(text=None):
+ """ E-mail link for the conference contact.
+
+ Renders a link to the committee; optionally takes a text, which will be
+ the text of the anchor (defaults to the e-mail address).
+ """
+ email = request_config().environ['paste.config']['app_conf']['contact_email']
+ if text==None:
+ text = '<tt>'+email+'</tt>'
+ return '<a href="mailto:'+email+'">'+text+'</a>'
View
@@ -65,15 +65,18 @@ def get_wiki_response(request, start_response):
moinReq.run()
start_response(moinReq.status, moinReq.headers)
dbsession.close()
- return [moinReq.output()]
+ res = ''.join(moinReq.output())
+ if type(res)==str:
+ res = res.decode('utf8', 'replace')
+ return res
def wiki_here():
from zookeepr.lib.base import request
def start_response(status, headers, exc_info=None):
pass
try:
- wiki_content = ''.join(get_wiki_response(request, start_response))
+ wiki_content = get_wiki_response(request, start_response)
match = cleaner_regexp.search(wiki_content)
if match:
return match.groups()[0]
@@ -87,9 +90,13 @@ def start_response(status, headers, exc_info=None):
pass
request.environ['PATH_INFO'] = '/' + page_name
- soup = BeautifulSoup(''.join(get_wiki_response(request, start_response)))
+ soup = BeautifulSoup(get_wiki_response(request, start_response))
try:
- content = soup.findAll('div', id='content')[0]
+ content = soup.findAll('div', id='content')
+ if len(content)==0:
+ content = '(no content)'
+ else:
+ content = content[0]
return '<div class="wiki">\n%s\n</div>' % (content,)
except IndexError:
print "soup is: %r" % (soup.prettify(),)
View
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.

0 comments on commit 8605100

Please sign in to comment.