[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
gnue common/src/GDataFormatter.py designer/src/...
From: |
Jason Cater |
Subject: |
gnue common/src/GDataFormatter.py designer/src/... |
Date: |
Sun, 22 Dec 2002 20:46:03 -0500 |
CVSROOT: /cvsroot/gnue
Module name: gnue
Changes by: Jason Cater <address@hidden> 02/12/22 20:46:03
Modified files:
common/src : GDataFormatter.py
designer/src/templates/forms: SimpleDetail.py
reports/samples/foobulations: monthly.grd
Log message:
better fix for formatting dates in reports [temporary]
CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/gnue/common/src/GDataFormatter.py.diff?tr1=1.3&tr2=1.4&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/gnue/designer/src/templates/forms/SimpleDetail.py.diff?tr1=1.8&tr2=1.9&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gnue/gnue/reports/samples/foobulations/monthly.grd.diff?tr1=1.18&tr2=1.19&r1=text&r2=text
Patches:
Index: gnue/common/src/GDataFormatter.py
diff -c gnue/common/src/GDataFormatter.py:1.3
gnue/common/src/GDataFormatter.py:1.4
*** gnue/common/src/GDataFormatter.py:1.3 Sun Dec 22 20:43:25 2002
--- gnue/common/src/GDataFormatter.py Sun Dec 22 20:46:03 2002
***************
*** 34,42 ****
def applyFormatting (value, mask):
# This obviously doesn't do anything with the mask yet
# Just returns a string
if value == None:
return ""
! else:
! if mask and type(value) == type(DateTime):
return value.strftime(mask)
! return "%s" % value
--- 34,46 ----
def applyFormatting (value, mask):
# This obviously doesn't do anything with the mask yet
# Just returns a string
+ print value, mask, type(value)
if value == None:
return ""
! elif mask:
! try:
return value.strftime(mask)
! except AttributeError:
! pass
!
! return "%s" % value
Index: gnue/designer/src/templates/forms/SimpleDetail.py
diff -c gnue/designer/src/templates/forms/SimpleDetail.py:1.8
gnue/designer/src/templates/forms/SimpleDetail.py:1.9
*** gnue/designer/src/templates/forms/SimpleDetail.py:1.8 Thu Nov 7
23:32:05 2002
--- gnue/designer/src/templates/forms/SimpleDetail.py Sun Dec 22 20:46:03 2002
***************
*** 49,54 ****
--- 49,55 ----
#
def Start(self, form, current):
self.form = form
+ self.current = current
***************
*** 256,271 ****
'name': 'dts%s' % tableKey })
# Create a single page on which to place blocks and labels
! page = None
! for child in self.form._children:
! if child._type == 'GFPage':
! page = child
! break
!
! if not page:
! page = self.AddElement('page', self.form,
! { 'name': 'pg%s' % tableKey })
!
# We will need a block to hold our entries...
--- 257,265 ----
'name': 'dts%s' % tableKey })
# Create a single page on which to place blocks and labels
! page = self.current['page']
! logic = self.current['logic']
! layout = self.current['layout']
# We will need a block to hold our entries...
***************
*** 278,284 ****
attrs['rows'] = 10
# Create the block
! block = self.AddElement('block', page, attrs)
masterSchema = self.GetSourceSchema(self.variables['connection'],
self.variables['mastertable'])
--- 272,278 ----
attrs['rows'] = 10
# Create the block
! block = self.AddElement('block', logic, attrs)
masterSchema = self.GetSourceSchema(self.variables['connection'],
self.variables['mastertable'])
Index: gnue/reports/samples/foobulations/monthly.grd
diff -c gnue/reports/samples/foobulations/monthly.grd:1.18
gnue/reports/samples/foobulations/monthly.grd:1.19
*** gnue/reports/samples/foobulations/monthly.grd:1.18 Fri Nov 1 00:02:49 2002
--- gnue/reports/samples/foobulations/monthly.grd Sun Dec 22 20:46:03 2002
***************
*** 51,57 ****
<out:row>
<firstrow><out:col><field name="name"
section="nameBreak"/></out:col></firstrow>
<notfirstrow><out:col/></notfirstrow>
! <out:col align="center"><field name="foodate"/></out:col>
<out:col align="right"><field name="foobs"/></out:col>
</out:row>
</section>
--- 51,57 ----
<out:row>
<firstrow><out:col><field name="name"
section="nameBreak"/></out:col></firstrow>
<notfirstrow><out:col/></notfirstrow>
! <out:col align="center"><field name="foodate"
format="%m/%d/%Y"/></out:col>
<out:col align="right"><field name="foobs"/></out:col>
</out:row>
</section>
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- gnue common/src/GDataFormatter.py designer/src/...,
Jason Cater <=