From c2d3bf17441a88ff6111864c62a123bf3224613a Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Wed, 25 Aug 2010 17:19:54 +0530 Subject: [PATCH 001/244] [FIX]:date format is not change according lang. bzr revid: apa@tinyerp.com-20100825114954-1154iy1l7lxadsy9 --- bin/report/report_sxw.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/bin/report/report_sxw.py b/bin/report/report_sxw.py index 6e7c6b95696..07a4be6db19 100644 --- a/bin/report/report_sxw.py +++ b/bin/report/report_sxw.py @@ -110,7 +110,7 @@ class _date_format(str, _format): if self.val: if getattr(self,'name', None): date = datetime.strptime(self.name, DT_FORMAT) - return date.strftime(str(self.lang_obj.date_format)) + return date.strftime(str(self.lang_obj.date_format)) return self.val class _dttime_format(str, _format): @@ -263,10 +263,11 @@ class rml_parse(object): # return str(value) if not isinstance(value, time.struct_time): - try: - date = datetime.datetime(str(value), parse_format) - except:# sometimes it takes converted values into value, so we dont need conversion. - return str(value) + return time.strftime(date_format, time.strptime(value, parse_format)) +# try: +# date = datetime.datetime(str(value), parse_format) +# except:# sometimes it takes converted values into value, so we dont need conversion. +# return str(value) else: date = datetime(*value.timetuple()[:6]) return date.strftime(date_format) From 0d1871526b877abe2dd8bb2242db1f5221da1222 Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Wed, 25 Aug 2010 18:41:51 +0530 Subject: [PATCH 002/244] [FIX]:date format is not change according lang. bzr revid: apa@tinyerp.com-20100825131151-aptf93zove4eb08k --- bin/report/report_sxw.py | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/report/report_sxw.py b/bin/report/report_sxw.py index 07a4be6db19..74cce73686d 100644 --- a/bin/report/report_sxw.py +++ b/bin/report/report_sxw.py @@ -253,6 +253,7 @@ class rml_parse(object): date_format = self.lang_dict['date_format'] parse_format = DT_FORMAT if date_time: + value=value.split('.')[0] date_format = date_format + " " + self.lang_dict['time_format'] parse_format = DHM_FORMAT From 2d53dd6b15357aa897629b481a726e6b63cedc88 Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Wed, 25 Aug 2010 19:34:45 +0530 Subject: [PATCH 003/244] [IMP]:account:Improved Profit And Loss report. bzr revid: apa@tinyerp.com-20100825140445-85xc8cj0m6j3qvhu --- .../report/account_profit_horizontal.rml | 48 ++++++++----------- 1 file changed, 20 insertions(+), 28 deletions(-) diff --git a/addons/account/report/account_profit_horizontal.rml b/addons/account/report/account_profit_horizontal.rml index 76d462aacf8..9926a1581cf 100644 --- a/addons/account/report/account_profit_horizontal.rml +++ b/addons/account/report/account_profit_horizontal.rml @@ -3,7 +3,6 @@ @@ -71,7 +70,7 @@ - + @@ -142,9 +141,9 @@ - - - + + + @@ -184,33 +183,26 @@ - + - - - - [[ get_company(data) ]] - - - - Profit And Loss Account + Profit And Loss - [[ get_data(data) or removeParentNode('para')]] + [[ get_data(data) or removeParentNode('para')]] Chart of Account Fiscal Year Filter By [[ get_filter(data)!='No Filter' and get_filter(data) ]] - Display Account + Display Account Printing Date @@ -220,25 +212,25 @@ [[ get_filter(data)=='Date' or removeParentNode('blockTable') ]] Start Date - End Date - + End Date + - [[ get_start_date(data)]] - [[get_end_date(data) ]] + [[ formatLang(get_start_date(data),date=True) ]] + [[ formatLang(get_end_date(data),date=True) ]] [[ get_filter(data)=='Periods' or removeParentNode('blockTable') ]] Start Period - End Period - + End Period + [[ get_start_period(data) or removeParentNode('para') ]] [[ get_end_period(data) or removeParentNode('para') ]] - + - [[ (data['form']['display_account']=='bal_all' and 'All') or (data['form']['display_account']=='bal_movement' and 'With movements') or 'With balance is not equal to 0']] + [[ (data['form']['display_account']=='bal_all' and 'All') or (data['form']['display_account']=='bal_movement' and 'With movements') or 'With balance is not equal to 0']] [[ formatLang(time.strftime('%Y-%m-%d %H:%M:%S'), date_time = True) ]] @@ -273,12 +265,12 @@ - [[ repeatIn(get_lines(),'a' ) ]] [[ a['code'] ]][[ a['level']<3 and ( setTag('para','para',{'style':'terp_default_Bold_9'})) or removeParentNode('font') ]] + [[ repeatIn(get_lines(),'a' ) ]] [[ a['code'] ]][[ a['level']<4 and ( setTag('para','para',{'style':'terp_default_Bold_9'})) or removeParentNode('font') ]] - [[ '. '*(a['level']-1) ]][[ a['level']<3 and ( setTag('para','para',{'style':'terp_default_Bold_9'})) or removeParentNode('font') ]][[ a['name'] ]] + [[ '. '*(a['level']-1) ]][[ a['level']<4 and ( setTag('para','para',{'style':'terp_default_Bold_9'})) or removeParentNode('font') ]][[ a['name'] ]] @@ -286,12 +278,12 @@ - [[ a['code1'] ]][[ a['level1']<3 and ( setTag('para','para',{'style':'terp_default_Bold_9'})) or removeParentNode('font') ]] + [[ a['code1'] ]][[ a['level1']<4 and ( setTag('para','para',{'style':'terp_default_Bold_9'})) or removeParentNode('font') ]] - [[ '. '*(a['level1']-1) ]][[ a['level1']<3 and ( setTag('para','para',{'style':'terp_default_Bold_9'})) or removeParentNode('font') ]][[ a['name1'] ]] + [[ '. '*(a['level1']-1) ]][[ a['level1']<4 and ( setTag('para','para',{'style':'terp_default_Bold_9'})) or removeParentNode('font') ]][[ a['name1'] ]] From c35a6a29bec558d18eb62eeaf01a3c7f6c8b1522 Mon Sep 17 00:00:00 2001 From: apa-tiny Date: Thu, 26 Aug 2010 10:46:04 +0530 Subject: [PATCH 004/244] [IMP]:account:Improved Profit And Loss report.(both) bzr revid: apa@tinyerp.com-20100826051604-ltdusr9cni5g8a6i --- .../report/account_profit_horizontal.rml | 2 +- addons/account/report/account_profit_loss.rml | 45 ++++++++----------- 2 files changed, 20 insertions(+), 27 deletions(-) diff --git a/addons/account/report/account_profit_horizontal.rml b/addons/account/report/account_profit_horizontal.rml index 9926a1581cf..d22e2e18a20 100644 --- a/addons/account/report/account_profit_horizontal.rml +++ b/addons/account/report/account_profit_horizontal.rml @@ -1,6 +1,6 @@ -