#NEWLINE# def _setup_resource_routes( self , resource , controller ) : #NEWLINE# #INDENT# path = ( '/' + resource ) #NEWLINE# self . mapper . connect ( resource , path , controller = controller , action = 'index' , conditions = dict ( method = [ 'GET' ] ) ) #NEWLINE# self . mapper . connect ( resource , path , controller = controller , action = 'create' , conditions = dict ( method = [ 'POST' ] ) ) #NEWLINE# self . mapper . connect ( resource , ( path + '/' ) , controller = controller , action = 'index' , conditions = dict ( method = [ 'GET' ] ) ) #NEWLINE# self . mapper . connect ( resource , ( path + '/' ) , controller = path , action = 'create' , conditions = dict ( method = [ 'POST' ] ) ) #NEWLINE# self . mapper . connect ( resource , ( path + '/{id}' ) , controller = controller , action = 'update' , conditions = dict ( method = [ 'PUT' ] ) ) #NEWLINE# self . mapper . connect ( resource , ( path + '/{id}' ) , controller = controller , action = 'delete' , conditions = dict ( method = [ 'DELETE' ] ) ) #NEWLINE# self . mapper . connect ( resource , ( path + '/{id}' ) , controller = controller , action = 'show' , conditions = dict ( method = [ 'GET' ] ) ) #NEWLINE# self . mapper . connect ( ( path + '/' ) , controller = controller , action = 'delete_all' , conditions = dict ( method = [ 'DELETE' ] ) ) #NEWLINE# self . mapper . connect ( ( path + '/{id}' ) , controller = controller , action = 'run_action' , conditions = dict ( method = [ 'POST' ] ) )