diff --git a/addons/document_change/__terp__.py b/addons/document_change/__terp__.py
index 78d62ff9e71..ae230e0bdef 100644
--- a/addons/document_change/__terp__.py
+++ b/addons/document_change/__terp__.py
@@ -36,6 +36,7 @@
'document_change_sequence.xml',
'document_change_workflow.xml',
'document_phase_workflow.xml',
+ 'document_process_workflow.xml',
],
'demo_xml': [ ],
'installable': True,
diff --git a/addons/document_change/document_change.py b/addons/document_change/document_change.py
index 237d7abfc49..7dadacba952 100644
--- a/addons/document_change/document_change.py
+++ b/addons/document_change/document_change.py
@@ -68,7 +68,7 @@ class doucment_change_process_phase(osv.osv):
'type': fields.selection([('control_required', 'Control Required'),('no_control', 'No Control')], 'Type'),
'date_control': fields.date('Control Date', select=True),
'phase_ids':fields.many2one('document.change.process.phase','Phase Type'),
- 'state': fields.selection([('draft', 'Draft'),('started', 'Started'),('validate', 'To Validate'), ('end', 'End')], 'Status'),
+ 'state': fields.selection([('draft', 'Draft'),('started', 'Started'),('validate', 'To Validate'), ('end', 'End')], 'Status', readonly=True),
'phase_document_ids':fields.many2many('ir.attachment','phase_document_rel','phase_id','document_id','Document'),
}
_defaults = {
@@ -165,7 +165,7 @@ class doucment_change_process(osv.osv):
'create_date':fields.datetime('Creation',readonly=True),
'latest_modified_date':fields.function(_latestmodification, method=True, type='date', string="Lastest Modification"), #TODO no year!
'date_expected':fields.datetime('Expected Production'),
- 'state':fields.selection([('draft', 'Draft'),('progress', 'Progress'),('confirmed', 'To Validate'), ('done', 'Done'),('done', 'Done'),('cancel','Cancelled')], 'Status'),
+ 'state':fields.selection([('draft', 'Draft'),('progress', 'Progress'),('confirmed', 'To Validate'), ('done', 'Done'),('cancel','Cancelled')], 'Status', readonly=True),
'process_phase_ids':fields.one2many('document.change.process.phase','process_id','Phase'),
'process_document_ids': fields.many2many('ir.attachment','document_changed_process_rel','process_id','change_id','Document To Change'),
'pending_directory_id' :fields.many2one('document.directory','Pending Directory ID'),
diff --git a/addons/document_change/document_change_view.xml b/addons/document_change/document_change_view.xml
index fa40eb87765..b5f6f5862bd 100644
--- a/addons/document_change/document_change_view.xml
+++ b/addons/document_change/document_change_view.xml
@@ -419,8 +419,14 @@
-
-
+
+
+
+
+
+
+
+
diff --git a/addons/document_change/document_process_workflow.xml b/addons/document_change/document_process_workflow.xml
new file mode 100644
index 00000000000..207c6cc3669
--- /dev/null
+++ b/addons/document_change/document_process_workflow.xml
@@ -0,0 +1,68 @@
+
+
+
+
+ document.change.process.phase.basic
+ document.change.process.phase
+ True
+
+
+
+
+
+ True
+ draft
+
+
+
+ in_progress
+ button_in_progress()
+ function
+
+
+
+ pending
+ button_pending()
+ function
+
+
+
+ to validate
+ button_done()
+ function
+
+
+
+ done
+ button_end()
+ function
+
+
+
+
+
+
+ button_in_progress
+
+
+
+
+ button_pending
+
+
+
+
+ button_in_progress
+
+
+
+
+ button_validate
+
+
+
+
+ button_done
+
+
+
\ No newline at end of file