# -*-coding=utf8-*- from torngas.helpers.route_helper import url, RouteLoader route = RouteLoader(path='/') urls = route.urlhelper('Main.views', url('Index', r'/', 'main_handler.Main') ) if __name__ == '__main__': pass
#!/usr/bin/env python # -*- coding: utf-8 -*- from torngas.helpers.route_helper import url, RouteLoader route = RouteLoader(path='/') urls = route.urlhelper('helloworld.views', #也可以传递对象 url('Index', r'/', 'main_handler.Main') ) if __name__ == '__main__': pass
#-*-coding=utf8-*- from torngas.helpers.route_helper import url, RouteLoader route = RouteLoader(path_prefix='Main.views', path='/', app_folder='Main') urls = route.urlhelper( url('Index', r'/', 'view=main_handler,handler=Main') )
#-*-coding=utf8-*- from torngas.helpers.route_helper import url, RouteLoader route = RouteLoader(path_prefix='Main.views', path='/', app_name='Main') urls = route.urlhelper(url('Index', r'/', 'view=main_handler,handler=Main'))
#!/usr/bin/env python # -*- coding: utf-8 -*- from torngas.helpers.route_helper import url, RouteLoader route = RouteLoader(path='/') urls = route.urlhelper( 'helloworld.views', #也可以传递对象 url('Index', r'/', 'main_handler.Main')) if __name__ == '__main__': pass
# -*-coding=utf8-*- from torngas.helpers.route_helper import url, RouteLoader from . import SUBAPP_NAME route = RouteLoader(path='/', subapp_name='Main') urls = route.urlhelper( url('Index', r'/', 'views.main_handler.Main') ) if __name__ == '__main__': pass