From 46eeb2d31fd6f566b1aa80089b71770ca12f4d1d Mon Sep 17 00:00:00 2001 From: "Ujjvala Collins (OpenERP)" Date: Mon, 31 Jan 2011 10:55:59 +0530 Subject: [PATCH 1/5] [FIX] crm, hr_payroll: Corrected date problem in ymls. bzr revid: uco@tinyerp.com-20110131052559-pnmgnhkcop52186r --- addons/crm/test/test_crm_meeting.yml | 2 +- addons/crm/test/test_crm_opportunity.yml | 4 ++-- addons/crm/test/test_crm_phonecall.yml | 6 +++--- addons/hr_payroll/test/payroll_register.yml | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/addons/crm/test/test_crm_meeting.yml b/addons/crm/test/test_crm_meeting.yml index d7c8a4691d6..d143de3d24a 100644 --- a/addons/crm/test/test_crm_meeting.yml +++ b/addons/crm/test/test_crm_meeting.yml @@ -7,7 +7,7 @@ !record {model: crm.meeting, id: crm_meeting_regardingpresentation0}: categ_id: crm.categ_meet2 date: !eval time.strftime('%Y-%m-%d 16:04:00') - date_deadline: !eval "'%s-%s-%s 00:04:00' %(datetime.now().year,datetime.now().month,datetime.now().day+1)" + date_deadline: !eval "'%s-%s-%d 00:04:00' %(datetime.now().year, (datetime.now()+timedelta(1)).month, (datetime.now()+timedelta(1)).day)" duration: 8.0 email_from: info@balmerinc.be location: Ahmedabad diff --git a/addons/crm/test/test_crm_opportunity.yml b/addons/crm/test/test_crm_opportunity.yml index 3a25db66381..a31c7af8fb2 100644 --- a/addons/crm/test/test_crm_opportunity.yml +++ b/addons/crm/test/test_crm_opportunity.yml @@ -51,7 +51,7 @@ I click on "schedule call" button and select planned date for the call. - !record {model: crm.opportunity2phonecall, id: crm_opportunity2phonecall_abcfuelcounits0}: - date: !eval "'%s-%s-%s 11:15:00' %(datetime.now().year,datetime.now().month,datetime.now().day+1)" + date: !eval "'%s-%s-%s 11:15:00' %(datetime.now().year, (datetime.now()+timedelta(1)).month, (datetime.now()+timedelta(1)).day)" name: 'ABC FUEL CO 829264 - 10002 units' section_id: crm.section_sales_department user_id: base.user_demo @@ -72,7 +72,7 @@ I can see phonecall record after click on "Schedule call" wizard. - !record {model: crm.phonecall, id: crm_phonecall_abcfuelcounits0}: - date: !eval "'%s-%s-%s 11:15:00' %(datetime.now().year,datetime.now().month,datetime.now().day+1)" + date: !eval "'%s-%s-%s 11:15:00' %(datetime.now().year, (datetime.now()+timedelta(1)).month, (datetime.now()+timedelta(1)).day)" duration: 3.0 name: 'ABC FUEL CO 829264 - 10002 units' partner_address_id: base.res_partner_address_1 diff --git a/addons/crm/test/test_crm_phonecall.yml b/addons/crm/test/test_crm_phonecall.yml index 98020d345e6..a5726da8cd7 100644 --- a/addons/crm/test/test_crm_phonecall.yml +++ b/addons/crm/test/test_crm_phonecall.yml @@ -64,8 +64,8 @@ - !record {model: crm.meeting, id: crm_meeting_interviewcall0}: alarm_id: base_calendar.alarm3 - date: !eval "'%s-%s-%s 09:00:00' %(datetime.now().year,datetime.now().month,datetime.now().day+1)" - date_deadline: !eval "'%s-%s-%s 17:00:00' %(datetime.now().year,datetime.now().month,datetime.now().day+1)" + date: !eval "'%s-%s-%s 09:00:00' %(datetime.now().year, (datetime.now()+timedelta(1)).month, (datetime.now()+timedelta(1)).day)" + date_deadline: !eval "'%s-%s-%s 17:00:00' %(datetime.now().year, (datetime.now()+timedelta(1)).month, (datetime.now()+timedelta(1)).day)" duration: 8.0 email_from: info@balmerinc.be name: Interview call @@ -81,7 +81,7 @@ phonecall. - !record {model: crm.phonecall2phonecall, id: crm_phonecall2phonecall_interviewcall0}: - date: !eval "'%s-%s-%s 19:49:00' %(datetime.now().year,datetime.now().month,datetime.now().day+1)" + date: !eval "'%s-%s-%s 19:49:00' %(datetime.now().year, (datetime.now()+timedelta(1)).month, (datetime.now()+timedelta(1)).day)" name: Interview call section_id: crm.section_sales_department user_id: base.user_root diff --git a/addons/hr_payroll/test/payroll_register.yml b/addons/hr_payroll/test/payroll_register.yml index 4a16dafe6ed..ce2284c8cc2 100644 --- a/addons/hr_payroll/test/payroll_register.yml +++ b/addons/hr_payroll/test/payroll_register.yml @@ -26,7 +26,7 @@ I create a payroll register record. - !record {model: hr.payroll.register, id: hr_payroll_register_payroll0}: - date: !eval "'%s-%s-%s' %(datetime.now().year,datetime.now().month,datetime.now().day+1)" + date: !eval "'%s-%s-%s' %(datetime.now().year, (datetime.now()+timedelta(1)).month, (datetime.now()+timedelta(1)).day)" line_ids: - employee_id: hr_payroll.hr_employee_keith0 name: payroll1 From 7c4d853ea2f19935be7877d80904629332e83fdc Mon Sep 17 00:00:00 2001 From: "Ujjvala Collins (OpenERP)" Date: Mon, 31 Jan 2011 11:13:23 +0530 Subject: [PATCH 2/5] [FIX] lunch, hr_recruitment: Corrected date problem in ymls. bzr revid: uco@tinyerp.com-20110131054323-jw446osaptu8zteq --- addons/hr_recruitment/test/test_hr_recruitment.yml | 4 ++-- addons/lunch/test/test_lunch.yml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/addons/hr_recruitment/test/test_hr_recruitment.yml b/addons/hr_recruitment/test/test_hr_recruitment.yml index ae322475a62..56feac0d199 100644 --- a/addons/hr_recruitment/test/test_hr_recruitment.yml +++ b/addons/hr_recruitment/test/test_hr_recruitment.yml @@ -84,8 +84,8 @@ !record {model: crm.meeting, id: crm_meeting_fresher0}: alarm_id: base_calendar.alarm1 count: 0.0 - date: !eval "'%s-%s-%s 00:00:00' %(datetime.now().year,datetime.now().month,datetime.now().day+1)" - date_deadline: !eval "'%s-%s-%s 08:00:00' %(datetime.now().year,datetime.now().month,datetime.now().day+1)" + date: !eval "'%s-%s-%s 00:00:00' %(datetime.now().year, (datetime.now()+timedelta(1)).month, (datetime.now()+timedelta(1)).day)" + date_deadline: !eval "'%s-%s-%s 08:00:00' %(datetime.now().year, (datetime.now()+timedelta(1)).month, (datetime.now()+timedelta(1)).day)" day: 0.0 duration: 8.0 name: Fresher diff --git a/addons/lunch/test/test_lunch.yml b/addons/lunch/test/test_lunch.yml index 0b5e756f8b3..2158685ea21 100644 --- a/addons/lunch/test/test_lunch.yml +++ b/addons/lunch/test/test_lunch.yml @@ -66,7 +66,7 @@ I create a new lunch order "LU002" for the "Club1" product, at another date. - !record {model: lunch.order, id: lunch_order_1}: - date: !eval "'%s-%s-%s' %(datetime.now().year,datetime.now().month,datetime.now().day+2)" + date: !eval "'%s-%s-%s' %(datetime.now().year, (datetime.now()+timedelta(2)).month, (datetime.now()+timedelta(2)).day)" product: 'lunch_product_club1' price: 2.75 user_id: base.user_root From 17819cb028e460cab68fc05a6e9150a72833917f Mon Sep 17 00:00:00 2001 From: "Ujjvala Collins (OpenERP)" Date: Tue, 1 Feb 2011 13:09:06 +0530 Subject: [PATCH 3/5] [FIX] crm_helpdesk: Added missing filters 'unclosed', 'next actions' on search view suggested on lp:710317. bzr revid: uco@tinyerp.com-20110201073906-48ri7vk89k986roc --- addons/crm_helpdesk/crm_helpdesk_view.xml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/addons/crm_helpdesk/crm_helpdesk_view.xml b/addons/crm_helpdesk/crm_helpdesk_view.xml index fe2f727c248..90262ac5601 100644 --- a/addons/crm_helpdesk/crm_helpdesk_view.xml +++ b/addons/crm_helpdesk/crm_helpdesk_view.xml @@ -234,6 +234,11 @@ search + + From f529e319f587e7e5bedc05e380bae39f5abaa7ba Mon Sep 17 00:00:00 2001 From: "Ujjvala Collins (OpenERP)" Date: Wed, 2 Feb 2011 14:54:49 +0530 Subject: [PATCH 4/5] [REVERT] crm_helpdesk: Reverted the search view changes on crm_helpdesk. bzr revid: uco@tinyerp.com-20110202092449-gnsqfevmwzxn65a0 --- addons/crm_helpdesk/crm_helpdesk_view.xml | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/addons/crm_helpdesk/crm_helpdesk_view.xml b/addons/crm_helpdesk/crm_helpdesk_view.xml index 90262ac5601..fe2f727c248 100644 --- a/addons/crm_helpdesk/crm_helpdesk_view.xml +++ b/addons/crm_helpdesk/crm_helpdesk_view.xml @@ -234,11 +234,6 @@ search - - From 3cc1e3a3117069753b91327aab28b995ab88334f Mon Sep 17 00:00:00 2001 From: "Ujjvala Collins (OpenERP)" Date: Thu, 10 Feb 2011 10:28:03 +0530 Subject: [PATCH 5/5] [FIX] crm: Fixed problem of email field when meeting is scheduled from opportunity. Corrected separator string on meetings. lp bug: https://launchpad.net/bugs/715708 fixed bzr revid: uco@tinyerp.com-20110210045803-48y5wl6am3gfihc5 --- addons/crm/crm.py | 5 ++++- addons/crm/crm_meeting_view.xml | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/addons/crm/crm.py b/addons/crm/crm.py index a3cc084d362..e436bd17600 100644 --- a/addons/crm/crm.py +++ b/addons/crm/crm.py @@ -303,7 +303,10 @@ class crm_case(object): if not add: return {'value': {'email_from': False}} address = self.pool.get('res.partner.address').browse(cr, uid, add) - return {'value': {'email_from': address.email, 'phone': address.phone}} + if address.email: + return {'value': {'email_from': address.email, 'phone': address.phone}} + else: + return {'value': {'phone': address.phone}} def _history(self, cr, uid, cases, keyword, history=False, subject=None, email=False, details=None, email_from=False, message_id=False, attach=[], context=None): mailgate_pool = self.pool.get('mailgate.thread') diff --git a/addons/crm/crm_meeting_view.xml b/addons/crm/crm_meeting_view.xml index 2524277b3a2..aba69889f57 100644 --- a/addons/crm/crm_meeting_view.xml +++ b/addons/crm/crm_meeting_view.xml @@ -59,7 +59,7 @@ - +