|
|
@ -26,6 +26,8 @@ namespace WF_WebAdmin.Service
|
|
|
|
// Créer une commande Npgsql
|
|
|
|
// Créer une commande Npgsql
|
|
|
|
var command = new NpgsqlCommand(commandText, connection);
|
|
|
|
var command = new NpgsqlCommand(commandText, connection);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
// Ajouter des paramètres à la commande
|
|
|
|
// Ajouter des paramètres à la commande
|
|
|
|
command.Parameters.AddWithValue("@content", quote.Content);
|
|
|
|
command.Parameters.AddWithValue("@content", quote.Content);
|
|
|
|
command.Parameters.AddWithValue("@langue", quote.Langue);
|
|
|
|
command.Parameters.AddWithValue("@langue", quote.Langue);
|
|
|
@ -34,6 +36,8 @@ namespace WF_WebAdmin.Service
|
|
|
|
command.Parameters.AddWithValue("@character", quote.Character);
|
|
|
|
command.Parameters.AddWithValue("@character", quote.Character);
|
|
|
|
command.Parameters.AddWithValue("@user", quote.User); // Assurez-vous que `quote.User` est correctement défini
|
|
|
|
command.Parameters.AddWithValue("@user", quote.User); // Assurez-vous que `quote.User` est correctement défini
|
|
|
|
command.Parameters.AddWithValue("@img_path", quote.ImgPath);
|
|
|
|
command.Parameters.AddWithValue("@img_path", quote.ImgPath);
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
try
|
|
|
|
try
|
|
|
|
{
|
|
|
|
{
|
|
|
@ -58,7 +62,7 @@ namespace WF_WebAdmin.Service
|
|
|
|
// Retourner l'objet DTO pour que vous puissiez l'utiliser ailleurs dans votre application
|
|
|
|
// Retourner l'objet DTO pour que vous puissiez l'utiliser ailleurs dans votre application
|
|
|
|
return quoteDTO;
|
|
|
|
return quoteDTO;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public Task RemoveQuote(Quote quote)
|
|
|
|
public Task RemoveQuote(Quote quote)
|
|
|
|
{
|
|
|
|
{
|
|
|
@ -84,36 +88,49 @@ namespace WF_WebAdmin.Service
|
|
|
|
return Task.FromResult(quoteDTO);
|
|
|
|
return Task.FromResult(quoteDTO);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public Task addQuote(Quote quote)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
throw new NotImplementedException();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public Task removeQuote(Quote quote)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
throw new NotImplementedException();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public Task<List<Quote>> getAllQuote()
|
|
|
|
public Task<List<Quote>> getAllQuote()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|
|
|
|
throw new NotImplementedException();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public Task<List<Quote>> getSomeQuote(int nb, int page)
|
|
|
|
public Task<List<Quote>> getSomeQuote(int nb, int page)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|
|
|
|
throw new NotImplementedException();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public Task<List<Quote>> getOnequote(int id)
|
|
|
|
public Task<List<Quote>> getOnequote(int id)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|
|
|
|
throw new NotImplementedException();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public Task<List<Quote>> reserchQuote(string reserch, List<string> argument)
|
|
|
|
public Task<List<Quote>> reserchQuote(string reserch, List<string> argument)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|
|
|
|
throw new NotImplementedException();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public Task<List<Quote>> getAllQuoteInvalid()
|
|
|
|
public Task<List<Quote>> getAllQuoteInvalid()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|
|
|
|
throw new NotImplementedException();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public Task<List<Quote>> getSomeQuoteInvalid(int nb, int page)
|
|
|
|
public Task<List<Quote>> getSomeQuoteInvalid(int nb, int page)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|
|
|
|
throw new NotImplementedException();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|