It works with my needs, but I don't understand how it works. can you explain it to me;
@api.model
def create(self, vals):
vals['classiffy_lead']='leads_processed'
print(vals)
# Nếu vals chưa được thiết lập user_id thì gán giá trị user_id vào vals
if not 'user_id' in vals:
vals['classiffy_lead'] = 'leads_init'
if not 'user_id' in vals:
vals['user_id'] = 8
return super(crm_lead, self).create(vals)