[ADD]project:sequence file added for task stage
bzr revid: kbh@tinyerp.com-20121122131222-3u3rybnfpfr1ajw8
This commit is contained in:
@@ -73,6 +73,7 @@ Dashboard / Reports for Project Management will include:
|
||||
'report/project_cumulative.xml',
|
||||
'board_project_view.xml',
|
||||
'res_config_view.xml',
|
||||
'project_sequence.xml',
|
||||
],
|
||||
'demo': ['project_demo.xml'],
|
||||
'test': [
|
||||
|
||||
@@ -39,7 +39,7 @@ class project_task_type(osv.osv):
|
||||
_columns = {
|
||||
'name': fields.char('Stage Name', required=True, size=64, translate=True),
|
||||
'description': fields.text('Description'),
|
||||
'sequence': fields.integer('Sequence'),
|
||||
'sequence': fields.char('Sequence'),
|
||||
'case_default': fields.boolean('Common to All Projects',
|
||||
help="If you check this field, this stage will be proposed by default on each new project. It will not assign this stage to existing projects."),
|
||||
'project_ids': fields.many2many('project.project', 'project_task_type_rel', 'type_id', 'project_id', 'Projects'),
|
||||
@@ -50,12 +50,11 @@ class project_task_type(osv.osv):
|
||||
help="This stage is not visible, for example in status bar or kanban view, when there are no records in that stage to display."),
|
||||
}
|
||||
_defaults = {
|
||||
'sequence': 1,
|
||||
'sequence': lambda obj, cr, uid, context: obj.pool.get('ir.sequence').get(cr, uid, 'project.task.type'),
|
||||
'state': 'open',
|
||||
'fold': False,
|
||||
'case_default': True,
|
||||
}
|
||||
_order = 'sequence'
|
||||
|
||||
def short_name(name):
|
||||
"""Keep first word(s) of name to make it small enough
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<openerp>
|
||||
<data noupdate="1">
|
||||
|
||||
<record id="seq_project_task_type" model="ir.sequence.type">
|
||||
<field name="name">Project Task Type"</field>
|
||||
<field name="code">project.task.type</field>
|
||||
</record>
|
||||
|
||||
<record id="seq_task_type" model="ir.sequence">
|
||||
<field name="name">Project Task Type</field>
|
||||
<field name="code">project.task.type</field>
|
||||
<field name="padding">1</field>
|
||||
</record>
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
Reference in New Issue
Block a user