Widgets are the GUI elements that can perform some controlling tasks. In OpenERP, we can see a few of widgets that have significance in the views like statuses of the any process, seeing states of an object, or getting lists out of huge data, or splitting data.
Some interesting widgets I came across are:
selection: this widget adds a drop down list when we have many2one field, for example displaying only journal name where a journal_id is a many2one field.
<field name="journal_id" widget="selection"/>
progressbar: this widget is used to show the progress of a task in percentage, so we add a float field in the model and then use in the view.
'progress': fields.float('Progress', readonly=True, help='Shows you the progress made today on the reconciliation process')
statusbar: this widget can display the various states of a task, for this we add a selection field in the model,
],'State', select=True, readonly=True,
help=' * The \'Draft\' state is used when a user is encoding a new and unconfirmed Invoice. \
\n* The \'Pro-forma\' when invoice is in Pro-forma state,invoice does not have an invoice number. \
\n* The \'Open\' state is used when user create invoice,a invoice number is generated.Its in open state till user does not pay invoice. \
\n* The \'Paid\' state is set automatically when the invoice is paid. Its related journal entries may or may not be reconciled. \
\n* The \'Cancelled\' state is used when user cancel invoice.'),
this field describes all the states of an invoice: draft/open/proforma/paid etc.