SlideShare a Scribd company logo
OPEN ERP 7
CREATE A WORKFLOW
STEP BY STEP
1.Create state in column fields
2.Create button and field in form view
3.Create workflow activity
4.Create workflow transition
CREATE STATE IN COLUMN FIELDS
class crossovered_budget(osv.osv):
_inherit = "crossovered.budget"
_description = "inherited to crossovered.budget"
_columns = {
#other fields
'state' : fields.selection(
[('draft','Draft'),
('cancel', 'Cancelled'),
('check','Wait Approval Manager'),
('authorize','Wait Approval Dir Opr'),
('authorize_finance','Wait Approval Dir. Fin'),
('confirm','Wait Approval Finance'),
('validate','Validate'),
('done','Done')],
'Status', select=True, required=True, readonly=True)
}
CREATE BUTTON AND FIELD IN FORM VIEW
<header>
<button string="Confirm1" name="confirm" states="draft" type="workflow" class="oe_highlight"/>
<button string="Approve" name="check" states="check" type="workflow" class="oe_highlight"/>
<button string="Wait Approval Manager" name="authorize" states="authorize" type="workflow"
class="oe_highlight"/>
<button string="Wait Approval Dir. Operational" name="authorize_finance"
states="authorize_finance" type="workflow" class="oe_highlight"/>
<button string="Wait Approval Dir. Finance" name="confirm" states="confirm" type="workflow"
class="oe_highlight"/>
<button string="Done" name="done" states="validate" type="workflow" class="oe_highlight"/>
<button name="draft" states="cancel" string="Reset to Draft" type="workflow" />
<button string="Cancel Budget" name="cancel"
states="check,authorize,authorize_finance,confirm,validate" type="workflow"/>
<field name="state" widget="statusbar"
statusbar_visible="draft,check,authorize,authorize_finance,confirm,validate,done"/>
</header>
CREATE WORKFLOW ACTIVITY
<record model="workflow" id="wkf_crossovered_budget">
<field name="name">wkf.crossovered.budget</field>
<field name="osv">crossovered.budget</field>
<field name="on_create">True</field>
</record>
<record model="workflow.activity" id="act_draft">
<field name="wkf_id" ref="wkf_crossovered_budget" />
<field name="flow_start">True</field>
<field name="name">draft</field>
<field name="action">write({'state':'draft'})</field>
<field name="kind">function</field>
</record>
CREATE WORKFLOW ACTIVITY CONTINUE
<record model="workflow.activity" id="act_done">
<field name="wkf_id" ref="wkf_crossovered_budget" />
<field name="name">done</field>
<field name="flow_stop">True</field>
<field name="kind">stopall</field>
<field name="action">budget_done()</field>
<field name="join_mode">XOR</field>
</record>
CREATE WORKFLOW TRANSITION
<record model="workflow.transition" id="t1">
<field name="act_from" ref="act_draft" />
<field name="act_to" ref="act_confirm" />
<field name="signal">confirm</field>
</record>
<record model="workflow.transition" id="t2">
<field name="act_from" ref="act_confirm" />
<field name="act_to" ref="act_validate" />
<field name="signal">validate</field>
</record>
Related to button ActionRelated to button Action
THANK YOU
HOPE IT WILL BE USEFULL

More Related Content

Viewers also liked

Aggregate Demand and Aggregate Supply
Aggregate Demand and Aggregate SupplyAggregate Demand and Aggregate Supply
Aggregate Demand and Aggregate Supply
Swapan Singh 🎖
 
GEOGRAFI TINGKATAN 2 ; graf
GEOGRAFI TINGKATAN 2 ; grafGEOGRAFI TINGKATAN 2 ; graf
GEOGRAFI TINGKATAN 2 ; graf
Ramli Rem
 
Mej 2009
Mej 2009Mej 2009
Mej 2009
Kelo Riveros
 
Get Clean Presentation
Get Clean PresentationGet Clean Presentation
Get Clean Presentation
Johnine Bailey
 
Crisis Development 2008 02 06
Crisis Development 2008 02 06Crisis Development 2008 02 06
Crisis Development 2008 02 06
Oboni Riskope Associates Inc.
 
Job Seeker 2.0
Job Seeker 2.0Job Seeker 2.0
Job Seeker 2.0
Jobs2web
 
Odalisque in paintings
Odalisque in paintingsOdalisque in paintings
Odalisque in paintings
Makala (D)
 

Viewers also liked (9)

Aggregate Demand and Aggregate Supply
Aggregate Demand and Aggregate SupplyAggregate Demand and Aggregate Supply
Aggregate Demand and Aggregate Supply
 
GEOGRAFI TINGKATAN 2 ; graf
GEOGRAFI TINGKATAN 2 ; grafGEOGRAFI TINGKATAN 2 ; graf
GEOGRAFI TINGKATAN 2 ; graf
 
Patent 6730333
Patent 6730333Patent 6730333
Patent 6730333
 
Mej 2009
Mej 2009Mej 2009
Mej 2009
 
Get Clean Presentation
Get Clean PresentationGet Clean Presentation
Get Clean Presentation
 
Hotmail Add Other Account
Hotmail Add Other AccountHotmail Add Other Account
Hotmail Add Other Account
 
Crisis Development 2008 02 06
Crisis Development 2008 02 06Crisis Development 2008 02 06
Crisis Development 2008 02 06
 
Job Seeker 2.0
Job Seeker 2.0Job Seeker 2.0
Job Seeker 2.0
 
Odalisque in paintings
Odalisque in paintingsOdalisque in paintings
Odalisque in paintings
 

Similar to Open erp 7 workflow

Workflow functional concept on openerp7
Workflow functional concept on openerp7Workflow functional concept on openerp7
Workflow functional concept on openerp7
Aziza Mohamed
 
Elixir Paris Meetup
Elixir Paris MeetupElixir Paris Meetup
Elixir Paris Meetup
Joan Zapata
 
Dynamics ax 2012 workflow development
Dynamics ax 2012 workflow development Dynamics ax 2012 workflow development
Dynamics ax 2012 workflow development
Ahmed Farag
 
having trouble with my code I'm using VScode to code a javascript code.docx
having trouble with my code I'm using VScode to code a javascript code.docxhaving trouble with my code I'm using VScode to code a javascript code.docx
having trouble with my code I'm using VScode to code a javascript code.docx
Isaac9LjWelchq
 
07 b 01workflowdefinition
07 b 01workflowdefinition07 b 01workflowdefinition
07 b 01workflowdefinition
tflung
 
Clean Test Code
Clean Test CodeClean Test Code
Clean Test Code
David Völkel
 
Taming forms with React
Taming forms with ReactTaming forms with React
Taming forms with React
GreeceJS
 
Fusion payment
Fusion paymentFusion payment
Fusion payment
pathikpatel1
 
BPM-1 Introduction to Advanced Workflows
BPM-1 Introduction to Advanced WorkflowsBPM-1 Introduction to Advanced Workflows
BPM-1 Introduction to Advanced Workflows
Alfresco Software
 
PHPSpec - the only Design Tool you need - 4Developers
PHPSpec - the only Design Tool you need - 4DevelopersPHPSpec - the only Design Tool you need - 4Developers
PHPSpec - the only Design Tool you need - 4Developers
Kacper Gunia
 
A Sensational Exposé With Bewildering Demonstrations
A Sensational Exposé With Bewildering DemonstrationsA Sensational Exposé With Bewildering Demonstrations
A Sensational Exposé With Bewildering Demonstrations
Peter Gasston
 
Account.h Definition of Account class. #ifndef ACCOUNT_H #d.pdf
Account.h  Definition of Account class. #ifndef ACCOUNT_H #d.pdfAccount.h  Definition of Account class. #ifndef ACCOUNT_H #d.pdf
Account.h Definition of Account class. #ifndef ACCOUNT_H #d.pdf
anujmkt
 

Similar to Open erp 7 workflow (12)

Workflow functional concept on openerp7
Workflow functional concept on openerp7Workflow functional concept on openerp7
Workflow functional concept on openerp7
 
Elixir Paris Meetup
Elixir Paris MeetupElixir Paris Meetup
Elixir Paris Meetup
 
Dynamics ax 2012 workflow development
Dynamics ax 2012 workflow development Dynamics ax 2012 workflow development
Dynamics ax 2012 workflow development
 
having trouble with my code I'm using VScode to code a javascript code.docx
having trouble with my code I'm using VScode to code a javascript code.docxhaving trouble with my code I'm using VScode to code a javascript code.docx
having trouble with my code I'm using VScode to code a javascript code.docx
 
07 b 01workflowdefinition
07 b 01workflowdefinition07 b 01workflowdefinition
07 b 01workflowdefinition
 
Clean Test Code
Clean Test CodeClean Test Code
Clean Test Code
 
Taming forms with React
Taming forms with ReactTaming forms with React
Taming forms with React
 
Fusion payment
Fusion paymentFusion payment
Fusion payment
 
BPM-1 Introduction to Advanced Workflows
BPM-1 Introduction to Advanced WorkflowsBPM-1 Introduction to Advanced Workflows
BPM-1 Introduction to Advanced Workflows
 
PHPSpec - the only Design Tool you need - 4Developers
PHPSpec - the only Design Tool you need - 4DevelopersPHPSpec - the only Design Tool you need - 4Developers
PHPSpec - the only Design Tool you need - 4Developers
 
A Sensational Exposé With Bewildering Demonstrations
A Sensational Exposé With Bewildering DemonstrationsA Sensational Exposé With Bewildering Demonstrations
A Sensational Exposé With Bewildering Demonstrations
 
Account.h Definition of Account class. #ifndef ACCOUNT_H #d.pdf
Account.h  Definition of Account class. #ifndef ACCOUNT_H #d.pdfAccount.h  Definition of Account class. #ifndef ACCOUNT_H #d.pdf
Account.h Definition of Account class. #ifndef ACCOUNT_H #d.pdf
 

More from Junifar hidayat

Linux Swap
Linux SwapLinux Swap
Linux Swap
Junifar hidayat
 
Vlookup – microsoft excel
Vlookup – microsoft excelVlookup – microsoft excel
Vlookup – microsoft excel
Junifar hidayat
 
OpenERP Relation Account Invoice, Account Voucher, Account Move Line
OpenERP Relation Account Invoice, Account Voucher, Account Move LineOpenERP Relation Account Invoice, Account Voucher, Account Move Line
OpenERP Relation Account Invoice, Account Voucher, Account Move Line
Junifar hidayat
 
Firebase recycler adapter
Firebase recycler adapterFirebase recycler adapter
Firebase recycler adapter
Junifar hidayat
 
Save data in to sqlite
Save data in to sqliteSave data in to sqlite
Save data in to sqlite
Junifar hidayat
 
Android tab layout Simple Implementation
Android tab layout Simple ImplementationAndroid tab layout Simple Implementation
Android tab layout Simple Implementation
Junifar hidayat
 
Action button open erp
Action button open erpAction button open erp
Action button open erp
Junifar hidayat
 
OpenERP - Call specific Form / Tree view from Menu
OpenERP - Call specific Form / Tree view from MenuOpenERP - Call specific Form / Tree view from Menu
OpenERP - Call specific Form / Tree view from Menu
Junifar hidayat
 
Membuat virtual environment python
Membuat virtual environment pythonMembuat virtual environment python
Membuat virtual environment python
Junifar hidayat
 
Panduan microsoft outlook pemula
Panduan microsoft outlook pemulaPanduan microsoft outlook pemula
Panduan microsoft outlook pemula
Junifar hidayat
 
Binding radgridview into reportviewer
Binding radgridview into reportviewerBinding radgridview into reportviewer
Binding radgridview into reportviewer
Junifar hidayat
 
[Winform] Visual studio C# 2012 Setting themes with telerik themes library
[Winform] Visual studio C# 2012 Setting themes with telerik themes library[Winform] Visual studio C# 2012 Setting themes with telerik themes library
[Winform] Visual studio C# 2012 Setting themes with telerik themes library
Junifar hidayat
 
[Winform] Visual studio C# 2012 upload ftp
[Winform] Visual studio C# 2012 upload ftp[Winform] Visual studio C# 2012 upload ftp
[Winform] Visual studio C# 2012 upload ftp
Junifar hidayat
 

More from Junifar hidayat (13)

Linux Swap
Linux SwapLinux Swap
Linux Swap
 
Vlookup – microsoft excel
Vlookup – microsoft excelVlookup – microsoft excel
Vlookup – microsoft excel
 
OpenERP Relation Account Invoice, Account Voucher, Account Move Line
OpenERP Relation Account Invoice, Account Voucher, Account Move LineOpenERP Relation Account Invoice, Account Voucher, Account Move Line
OpenERP Relation Account Invoice, Account Voucher, Account Move Line
 
Firebase recycler adapter
Firebase recycler adapterFirebase recycler adapter
Firebase recycler adapter
 
Save data in to sqlite
Save data in to sqliteSave data in to sqlite
Save data in to sqlite
 
Android tab layout Simple Implementation
Android tab layout Simple ImplementationAndroid tab layout Simple Implementation
Android tab layout Simple Implementation
 
Action button open erp
Action button open erpAction button open erp
Action button open erp
 
OpenERP - Call specific Form / Tree view from Menu
OpenERP - Call specific Form / Tree view from MenuOpenERP - Call specific Form / Tree view from Menu
OpenERP - Call specific Form / Tree view from Menu
 
Membuat virtual environment python
Membuat virtual environment pythonMembuat virtual environment python
Membuat virtual environment python
 
Panduan microsoft outlook pemula
Panduan microsoft outlook pemulaPanduan microsoft outlook pemula
Panduan microsoft outlook pemula
 
Binding radgridview into reportviewer
Binding radgridview into reportviewerBinding radgridview into reportviewer
Binding radgridview into reportviewer
 
[Winform] Visual studio C# 2012 Setting themes with telerik themes library
[Winform] Visual studio C# 2012 Setting themes with telerik themes library[Winform] Visual studio C# 2012 Setting themes with telerik themes library
[Winform] Visual studio C# 2012 Setting themes with telerik themes library
 
[Winform] Visual studio C# 2012 upload ftp
[Winform] Visual studio C# 2012 upload ftp[Winform] Visual studio C# 2012 upload ftp
[Winform] Visual studio C# 2012 upload ftp
 

Recently uploaded

Artificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopmentArtificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopment
Octavian Nadolu
 
Best 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERPBest 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERP
Pixlogix Infotech
 
Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
mikeeftimakis1
 
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
名前 です男
 
“I’m still / I’m still / Chaining from the Block”
“I’m still / I’m still / Chaining from the Block”“I’m still / I’m still / Chaining from the Block”
“I’m still / I’m still / Chaining from the Block”
Claudio Di Ciccio
 
Driving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success StoryDriving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success Story
Safe Software
 
Mariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceXMariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceX
Mariano Tinti
 
HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
panagenda
 
RESUME BUILDER APPLICATION Project for students
RESUME BUILDER APPLICATION Project for studentsRESUME BUILDER APPLICATION Project for students
RESUME BUILDER APPLICATION Project for students
KAMESHS29
 
Presentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of GermanyPresentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of Germany
innovationoecd
 
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
SOFTTECHHUB
 
20240605 QFM017 Machine Intelligence Reading List May 2024
20240605 QFM017 Machine Intelligence Reading List May 202420240605 QFM017 Machine Intelligence Reading List May 2024
20240605 QFM017 Machine Intelligence Reading List May 2024
Matthew Sinclair
 
Microsoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdfMicrosoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdf
Uni Systems S.M.S.A.
 
“Building and Scaling AI Applications with the Nx AI Manager,” a Presentation...
“Building and Scaling AI Applications with the Nx AI Manager,” a Presentation...“Building and Scaling AI Applications with the Nx AI Manager,” a Presentation...
“Building and Scaling AI Applications with the Nx AI Manager,” a Presentation...
Edge AI and Vision Alliance
 
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAUHCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
panagenda
 
Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1
DianaGray10
 
AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial IntelligenceAI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
IndexBug
 
How to Get CNIC Information System with Paksim Ga.pptx
How to Get CNIC Information System with Paksim Ga.pptxHow to Get CNIC Information System with Paksim Ga.pptx
How to Get CNIC Information System with Paksim Ga.pptx
danishmna97
 
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Paige Cruz
 
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
Neo4j
 

Recently uploaded (20)

Artificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopmentArtificial Intelligence for XMLDevelopment
Artificial Intelligence for XMLDevelopment
 
Best 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERPBest 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERP
 
Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
 
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
 
“I’m still / I’m still / Chaining from the Block”
“I’m still / I’m still / Chaining from the Block”“I’m still / I’m still / Chaining from the Block”
“I’m still / I’m still / Chaining from the Block”
 
Driving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success StoryDriving Business Innovation: Latest Generative AI Advancements & Success Story
Driving Business Innovation: Latest Generative AI Advancements & Success Story
 
Mariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceXMariano G Tinti - Decoding SpaceX
Mariano G Tinti - Decoding SpaceX
 
HCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAUHCL Notes and Domino License Cost Reduction in the World of DLAU
HCL Notes and Domino License Cost Reduction in the World of DLAU
 
RESUME BUILDER APPLICATION Project for students
RESUME BUILDER APPLICATION Project for studentsRESUME BUILDER APPLICATION Project for students
RESUME BUILDER APPLICATION Project for students
 
Presentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of GermanyPresentation of the OECD Artificial Intelligence Review of Germany
Presentation of the OECD Artificial Intelligence Review of Germany
 
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
Why You Should Replace Windows 11 with Nitrux Linux 3.5.0 for enhanced perfor...
 
20240605 QFM017 Machine Intelligence Reading List May 2024
20240605 QFM017 Machine Intelligence Reading List May 202420240605 QFM017 Machine Intelligence Reading List May 2024
20240605 QFM017 Machine Intelligence Reading List May 2024
 
Microsoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdfMicrosoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdf
 
“Building and Scaling AI Applications with the Nx AI Manager,” a Presentation...
“Building and Scaling AI Applications with the Nx AI Manager,” a Presentation...“Building and Scaling AI Applications with the Nx AI Manager,” a Presentation...
“Building and Scaling AI Applications with the Nx AI Manager,” a Presentation...
 
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAUHCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
HCL Notes und Domino Lizenzkostenreduzierung in der Welt von DLAU
 
Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1Communications Mining Series - Zero to Hero - Session 1
Communications Mining Series - Zero to Hero - Session 1
 
AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial IntelligenceAI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
 
How to Get CNIC Information System with Paksim Ga.pptx
How to Get CNIC Information System with Paksim Ga.pptxHow to Get CNIC Information System with Paksim Ga.pptx
How to Get CNIC Information System with Paksim Ga.pptx
 
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdfObservability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
Observability Concepts EVERY Developer Should Know -- DeveloperWeek Europe.pdf
 
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
 

Open erp 7 workflow

  • 1. OPEN ERP 7 CREATE A WORKFLOW
  • 2. STEP BY STEP 1.Create state in column fields 2.Create button and field in form view 3.Create workflow activity 4.Create workflow transition
  • 3. CREATE STATE IN COLUMN FIELDS class crossovered_budget(osv.osv): _inherit = "crossovered.budget" _description = "inherited to crossovered.budget" _columns = { #other fields 'state' : fields.selection( [('draft','Draft'), ('cancel', 'Cancelled'), ('check','Wait Approval Manager'), ('authorize','Wait Approval Dir Opr'), ('authorize_finance','Wait Approval Dir. Fin'), ('confirm','Wait Approval Finance'), ('validate','Validate'), ('done','Done')], 'Status', select=True, required=True, readonly=True) }
  • 4. CREATE BUTTON AND FIELD IN FORM VIEW <header> <button string="Confirm1" name="confirm" states="draft" type="workflow" class="oe_highlight"/> <button string="Approve" name="check" states="check" type="workflow" class="oe_highlight"/> <button string="Wait Approval Manager" name="authorize" states="authorize" type="workflow" class="oe_highlight"/> <button string="Wait Approval Dir. Operational" name="authorize_finance" states="authorize_finance" type="workflow" class="oe_highlight"/> <button string="Wait Approval Dir. Finance" name="confirm" states="confirm" type="workflow" class="oe_highlight"/> <button string="Done" name="done" states="validate" type="workflow" class="oe_highlight"/> <button name="draft" states="cancel" string="Reset to Draft" type="workflow" /> <button string="Cancel Budget" name="cancel" states="check,authorize,authorize_finance,confirm,validate" type="workflow"/> <field name="state" widget="statusbar" statusbar_visible="draft,check,authorize,authorize_finance,confirm,validate,done"/> </header>
  • 5. CREATE WORKFLOW ACTIVITY <record model="workflow" id="wkf_crossovered_budget"> <field name="name">wkf.crossovered.budget</field> <field name="osv">crossovered.budget</field> <field name="on_create">True</field> </record> <record model="workflow.activity" id="act_draft"> <field name="wkf_id" ref="wkf_crossovered_budget" /> <field name="flow_start">True</field> <field name="name">draft</field> <field name="action">write({'state':'draft'})</field> <field name="kind">function</field> </record>
  • 6. CREATE WORKFLOW ACTIVITY CONTINUE <record model="workflow.activity" id="act_done"> <field name="wkf_id" ref="wkf_crossovered_budget" /> <field name="name">done</field> <field name="flow_stop">True</field> <field name="kind">stopall</field> <field name="action">budget_done()</field> <field name="join_mode">XOR</field> </record>
  • 7. CREATE WORKFLOW TRANSITION <record model="workflow.transition" id="t1"> <field name="act_from" ref="act_draft" /> <field name="act_to" ref="act_confirm" /> <field name="signal">confirm</field> </record> <record model="workflow.transition" id="t2"> <field name="act_from" ref="act_confirm" /> <field name="act_to" ref="act_validate" /> <field name="signal">validate</field> </record> Related to button ActionRelated to button Action
  • 8. THANK YOU HOPE IT WILL BE USEFULL