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

Hi everyone, 

I am new here and working on the task which I am adding customer data to Odoo res.partner model through python using API. 

My question is: Is there any ways or tip that I can use to get the last update date, max_id or something like this? 

My data will be continuously added and I do not want duplicate records. So, I want to have one parameter which I can use to get the last added customer and start to create/update customers from that time on.

So if the same customer is existing: update the data

If not: create a new one


아바타
취소

Odoo have create_date, write_date

create_date --> while create the record the date time will update

write_date --> While any change happened it will update that date time

Are you using xmlrpc call or Rest API?

작성자

@subbarao I am using external API

작성자 베스트 답변

@shalin wilson what is the difference between last_updated and write_date?

아바타
취소
베스트 답변

__last_update field is there in res.partner and its automatically  updates 
is it enough for you to check the DateTime??

아바타
취소
베스트 답변

If Odoo create record with external API with success, returns its ID. See External API documentation.

아바타
취소
관련 게시물 답글 화면 활동
0
10월 20
4303
3
7월 23
2762
1
11월 20
10818
2
6월 18
3876
0
5월 15
4028