- g.db.execute('update votes set title = ?, description = ?, category = ?, is_transparent = ?, is_public = ?, is_open = ? where id = ?',
- [request.form['title'], request.form['description'], request.form['category'], transparent, public, isopen, voteid])
+ elif request.form['status'] == u'Terminé':
+ isterminated = 1
+ if vote['is_open']:
+ isopen = 1
+ g.db.execute('update votes set title = ?, description = ?, category = ?, is_transparent = ?, is_public = ?, is_open = ?, is_terminated = ? where id = ?',
+ [request.form['title'], request.form['description'], request.form['category'], transparent, public, isopen, isterminated, voteid])