콘텐츠로 건너뛰기
메뉴
커뮤니티에 참여하려면 회원 가입을 하시기 바랍니다.
신고된 질문입니다
2 답글
2626 화면

Hi, 

Currently we are using odoo 13. we created python code for auto seq in sales crm . 

Currently i exploring the Odoo 17, and I use the below steps to add the auto seq.  But it didnot work.   and there is not error .. Please advise

1. Customer fields   - 

   x_enquiry_number 


Sequence (added): 


Automated action 


Below code added in the execute code section

Execute code: 

if not vals.get('x_enquiry_number'): 

         vals['x_enquiry_number'] = self.env['ir.sequence'].next_by_code('enquiry.seq') 



Thanks 



아바타
취소
베스트 답변

Hello Arul,

Please review and test the provided code; it could be helpful for your purposes.
Write the automated action on creation and remove the condition.
vals['x_enquiry_number'] = env['ir.sequence'].next_by_code('enquiry.seq')

Thanks,
info@creyox.com


아바타
취소
작성자

Thanks
Trigger On creation is not found in the automated action (odoo 17)

작성자 베스트 답변

Thanks.

Trigger "On Creation" not listed in the automated action/rules.. 

Thanks 

아바타
취소

You can use On save option instead of On creation.

관련 게시물 답글 화면 활동
1
3월 24
2827
0
3월 24
3233
2
4월 25
4143
2
1월 25
3876
1
3월 24
3328