module.exports = exports = { prefix: '/api/v1/db', middleware: [ 'auth:ApiRoute' ], get: { // Get the database ref node config for the specified database '/:PageId/:NodeId/get/:DatabaseId': ['controller::api:v1:FormDatabase.get_config'], // Get the column config records for the specified database '/:PageId/:NodeId/get/:DatabaseId/columns': [ 'controller::api:v1:FormDatabase.get_columns' ], // Get the row records for the specified database '/:PageId/:NodeId/get/:DatabaseId/data': [ 'controller::api:v1:FormDatabase.get_data' ], }, post: { // Create a new database ref config '/:PageId/:NodeId/create': ['controller::api:v1:FormDatabase.create_new'], // Set the column configs for a database ref '/:PageId/:NodeId/set/:DatabaseId/columns': [ 'controller::api:v1:FormDatabase.set_columns' ], // Set the database name '/:PageId/:NodeId/set/:DatabaseId/Name': [ 'controller::api:v1:FormDatabase.set_name' ], // Delete the specified database ref '/:PageId/:NodeId/drop/:DatabaseId': [ 'controller::api:v1:FormDatabase.drop_database' ], // Set the row data for the specified database ref '/:PageId/:NodeId/set/:DatabaseId/data': ['controller::api:v1:FormDatabase.set_data'], }, }