Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
1 Trả lời
1344 Lượt xem

i have project module in which there are stages  of task like "done", cancel etc. now i want to add some more stages. module name "project.task.type"  how it could be possible.
this how it appear in my peoject.task module 

the are stages of my task like ongoing and inactive was created by myself through configuration setting now i want that these to be created when project module would be install 

Ảnh đại diện
Huỷ bỏ
Câu trả lời hay nhất

Hi,

If you need to add new stages to the project module you can use the code and try to add the code to the data folder and keep it as a data file

<?xml version="1.0" encoding="utf-8"?>

<odoo>

    <data noupdate="1">

               <record id="stage_id" model="project.project.stage">

                <field name="sequence">15</field>

                <field name="name">In Progress</field>

              </record>

    </data>

</odoo>

   



or do you need to override the existing stages you can use this method - the project_project_stage_0 id is already added in the demo file for the stage  To Do you can replace it with Draft

<record id="project.project_project_stage_0" model="project.project.stage"> style="background-color:#fafafa;font-size:11pt;">
            <field name="name">Draft</field>
            <field name="sequence">10</field>
    </record>

   


Hope it helps

Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
4
thg 7 24
4772
0
thg 9 24
5295
0
thg 12 21
2221
0
thg 12 20
2953
2
thg 8 25
3523