Odoo Help


workflow state error in project form

mirko lazzarini
on 7/1/13, 8:15 AM 986 views

i've a workflow with 3 states, i must add another state...

my actual row in "class task"

'state': fields.selection([('draft', 'New'),('open', 'In Progress'),('pending', 'Pending'), ('done', 'Done'), ('cancelled', 'Cancelled')], 'State', readonly=True, required=True,

with my new state

'state': fields.selection([('draft', 'New'),('open', 'In Progress'),('fatt', 'Da Fatturare'),('pending', 'Pending'), ('done', 'Done'), ('cancelled', 'Cancelled')], 'State', readonly=True, required=True,

to set the state:

*def set_fattura(self, cr, uid, ids, context=None):
    self.write(cr, uid, ids, {'state':'fatt'})
    return True*

When i try to change the state i obtain this error:

OpenErp Warning ErroreConvalida The value "fatt" for the field "account_analytic_account.state" is not in the selection

About This Community

This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.


Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

0 follower(s)


Asked: 7/1/13, 8:15 AM
Seen: 986 times
Last updated: 3/16/15, 8:10 AM