update article + retrait
This commit is contained in:
@@ -168,7 +168,6 @@ public class ArticleRepositoryImpl implements ArticleRepository {
|
||||
sql.append(")");
|
||||
}
|
||||
|
||||
System.out.println();
|
||||
// Compte le nombre total d'articles
|
||||
int totalCount = countArticlePageable(critere);
|
||||
|
||||
@@ -334,7 +333,16 @@ public class ArticleRepositoryImpl implements ArticleRepository {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void updateArticle(int id) {
|
||||
|
||||
public int updateArticle(Article article) {
|
||||
String sql = "UPDATE ARTICLES_VENDUS " +
|
||||
"SET nom_article = ?, " +
|
||||
"description = ?," +
|
||||
"date_debut_encheres = ?," +
|
||||
"date_fin_encheres = ?," +
|
||||
"prix_initial = ?," +
|
||||
"no_categorie = ? " +
|
||||
"WHERE no_article = ?";
|
||||
jdbcTemplate.update(sql, article.getNom(), article.getDesc(), article.getDateDebutEnch(), article.getDateFinEnch(), article.getPrixInitial(), article.getNumCategorie(), article.getId());
|
||||
return article.getId();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user