Exemple #1
0
 def get(self):
     uid = self.get_secure_cookie('user')
     user = db.get_user(uid)
     sections = db.get_sections()
     forum = db.get_forum()
     wealthList = db.get_wealth_list()
     warning = self.get_argument('warning', None)
     self.render(
             't_config.html', title='Ran - Config',
             user=user, setions=sections, forum=forum,
             warning=warning, wealthList=wealthList,
             )
Exemple #2
0
 def get(self):
     sections = db.get_sections()
     forum = db.get_forum()
     wealthList = db.get_wealth_list()
     uid = self.get_secure_cookie('user')
     if uid:
         user = db.get_user(uid)
     self.render(
             't_new.html', title='Ran - New',
             sections=sections, forum=forum, user=user,
             wealthList=wealthList,
             )
     pass
Exemple #3
0
 def get(self):
     adminId = self.get_secure_cookie('admin')
     forum = db.get_forum()
     allUsers = db.get_all_users()
     allPosts = db.get_all_posts()
     allReplys = db.get_all_replys()
     wealthList = db.get_wealth_list()
     cUser = db.get_admin(adminId)
     self.render(
             't_admin.html', title='Ran - Admin',
             allUsers=allUsers, forum=forum, allReplys=allReplys,
             allPosts=allPosts, wealthList=wealthList, cUser=cUser,
             )
Exemple #4
0
 def get(self):
     pid = self.get_argument('pid')
     uid = self.get_secure_cookie('user')
     user = db.get_user(uid)
     replys = db.get_replys(pid)
     post = db.get_post_topic(pid)
     att = db.get_att(pid)
     forum = db.get_forum()
     wealthList = db.get_wealth_list()
     self.render(
             't_topic.html', title='Ran - Topic',
             user=user, forum=forum, replys=replys,
             post=post, wealthList=wealthList, att=att,
             )
Exemple #5
0
 def get(self):
     sections = db.get_sections()
     uid = self.get_secure_cookie('user')
     print 'uid: ', uid
     forum = db.get_forum()
     allPosts = db.get_all_posts_split_by_section()
     wealthList = db.get_wealth_list()
     if uid:
         user = db.get_user(uid)
     else:
         user = {}
     self.render(
             't_home.html', title='Ran - Home',
             user=user, forum=forum, sections=sections,
             allPosts=allPosts, wealthList=wealthList,
             )