Answers for "odoo - add one2many field programmatically"

0

odoo - add one2many field programmatically

def action_create_estimation_lines(self):
  default_fases = ['Analysis','Functional Design','Development','Testing', 'Server Push']
  count = 1
  estimation_lines = []

  for fase in default_fases:
    estimation_line = {'analyse_line_id':self.id,'name':fase,'sequence':count}
    count = count + 1
    estimation_lines.append((0,0, estimation_line))
  self.estimation_line_ids = estimation_lines
Posted by: Guest on January-15-2022

Code answers related to "odoo - add one2many field programmatically"

Python Answers by Framework

Browse Popular Code Answers by Language