#NEWLINE# def get_urls( self ) : #NEWLINE# #INDENT# from django.conf.urls import url , include #NEWLINE# from xadmin.views.base import BaseAdminView #NEWLINE# if settings . DEBUG : #NEWLINE# #INDENT# self . check_dependencies ( ) #NEWLINE# #UNINDENT# def wrap( view , cacheable = False ) : #NEWLINE# #INDENT# def wrapper( * args , **kwargs ) : #NEWLINE# #INDENT# return self . admin_view ( view , cacheable ) ( * args , ** kwargs ) #NEWLINE# #UNINDENT# return update_wrapper ( wrapper , view ) #NEWLINE# #UNINDENT# urlpatterns = [ url ( '^jsi18n/$' , wrap ( self . i18n_javascript , cacheable = True ) , name = 'jsi18n' ) ] #NEWLINE# urlpatterns += [ url ( path , ( wrap ( self . create_admin_view ( clz_or_func ) ) if ( ( type ( clz_or_func ) == type ) and issubclass ( clz_or_func , BaseAdminView ) ) else include ( clz_or_func ( self ) ) ) , name = name ) for ( path , clz_or_func , name ) in self . _registry_views ] #NEWLINE# for ( model , admin_class ) in self . _registry . iteritems ( ) : #NEWLINE# #INDENT# view_urls = [ url ( path , wrap ( self . create_model_admin_view ( clz , model , admin_class ) ) , name = ( name % ( model . _meta . app_label , model . _meta . model_name ) ) ) for ( path , clz , name ) in self . _registry_modelviews ] #NEWLINE# urlpatterns += [ url ( ( '^%s/%s/' % ( model . _meta . app_label , model . _meta . model_name ) ) , include ( view_urls ) ) ] #NEWLINE# #UNINDENT# return urlpatterns