#/usr/bin/env python
#encoding:utf-8

import tornado.web

class BaseHandler(tornado.web.RequestHandler):
    pass
# encoding:utf-8

import tornado.web


class BaseHandler(tornado.web.RequestHandler):

    @property
    def db(self):
        return self.application.db

add db