public async Task <IActionResult> GetAllTable(string NomeDB) { await Db.Connection.OpenAsync(); var query = new AdminPostQuery(Db); var result = await query.AllTableAsync(NomeDB); return(new OkObjectResult(result)); }
public async Task <IActionResult> GetAllDB() { await Db.Connection.OpenAsync(); var query = new AdminPostQuery(Db); var result = await query.AllDBAsync(); return(new OkObjectResult(result)); }
public async Task <IActionResult> PutOne(string NomeDB, string NomeTable, string NewNomeTable, [FromBody] AdminModel body) { await Db.Connection.OpenAsync(); var query = new AdminPostQuery(Db); var result = await query.FirstPostTableAsync(NomeDB, NomeTable, NewNomeTable); if (result is null) { return(new NotFoundResult()); } return(new OkObjectResult(result)); }