Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
5215 มุมมอง

I've created this filter in crm leads advanced filters


 [['date_action', '&lt;<=', timedelta.strftime('%Y-%m-%d')]] 
It has this issue 

 Uncaught Error: Failed to evaluate search criterions: 
{"code":400,"message":"Evaluation Error","data":{"type":"local_exception","debug":"Local evaluation failure\nNameError: name 'timedelta' is not defined\n\n{\"domains\":[[\"|\",[\"type\",\"=\",\"lead\"],[\"type\",\"=\",false]],\"[['date_action', '<=', timedelta.strftime('%Y-%m-%d')]]\"],\"contexts\":[{\"lang\":\"en_US\",\"tz\":\"Australia/Melbourne\",\"uid\":1,\"default_type\":\"lead\",\"stage_type\":\"lead\",\"empty_list_help_model\":\"crm.case.section\",\"needaction_menu_ref\":\"crm.menu_crm_opportunities\",\"search_default_unassigned\":1},\"{}\"],\"group_by_seq\":[\"{}\"]}"}}

http://119.9.51.242:8069/web/static/src/js/views.js:851


However if I remove timedelta and replace with just time it works fine, the issue is then that my timezone gives a delayed "Today"

[['date_action', '&lt;=', time.strftime('%Y-%m-%d')]] 

If I review my today tasks at 7:30 am on 30/05/2015 it only returns results up to 29/05/2015

อวตาร
ละทิ้ง
Related Posts ตอบกลับ มุมมอง กิจกรรม
Take Users Timezone แก้ไขแล้ว
3
ก.ค. 25
4968
Time & Date Issue แก้ไขแล้ว
6
ก.ย. 19
12271
2
มี.ค. 16
8545
0
มี.ค. 15
8941
Datetime and Time Zones - OpenERP 7 แก้ไขแล้ว
1
ม.ค. 24
13292