Skip to Content
Menu
This question has been flagged
1 Reply
3131 Views

Hello Odoo Forum,

I´m trying to implement this 2 step automated action.

1. After a sale order is confirmed to create a new project

2.Use a project template for the crated new project

So for the first step I implemented nicely, but the second stage I´m getting a error.

So for duplicating a existing project I´m using the following Python command:


env ['project.project']. browse (2) .copy ({'id': record.id})


my project template I want to duplicade as the ID=2.

Can anyone help, or point to where can I see more information on this?

Thank you

Avatar
Discard
Best Answer

Hello, try without passing parameters to the copy () method

env ['project.project']. browse (2) .copy ()


Keep in mind that some fields are not copied, and also if you added fields with a module and they are required it will not work. You would have to pass values to all those fields that are required and are not copied 

Avatar
Discard
Related Posts Replies Views Activity
0
Jan 23
1880
0
May 23
2803
1
Jul 22
2149
1
Mar 22
1783
0
Jun 21
1360