Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
Zope
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
Zope
Commits
b8757f3a
Commit
b8757f3a
authored
Dec 29, 1998
by
Jim Fulton
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cleaned up formatting of generated reports and fixed bug for record reports
parent
2af8d36c
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
16 deletions
+19
-16
lib/python/Shared/DC/ZRDB/Aqueduct.py
lib/python/Shared/DC/ZRDB/Aqueduct.py
+12
-16
lib/python/Shared/DC/ZRDB/customDefaultReport.dtml
lib/python/Shared/DC/ZRDB/customDefaultReport.dtml
+7
-0
No files found.
lib/python/Shared/DC/ZRDB/Aqueduct.py
View file @
b8757f3a
...
...
@@ -96,8 +96,8 @@
##############################################################################
__doc__
=
'''Shared classes and functions
$Id: Aqueduct.py,v 1.
29 1998/12/29 17:02:55
jim Exp $'''
__version__
=
'$Revision: 1.
29
$'
[
11
:
-
2
]
$Id: Aqueduct.py,v 1.
30 1998/12/29 19:55:01
jim Exp $'''
__version__
=
'$Revision: 1.
30
$'
[
11
:
-
2
]
import
Globals
,
os
from
Globals
import
HTMLFile
,
Persistent
...
...
@@ -235,10 +235,10 @@ def default_input_form(id,arguments,action='query',
string
.
joinfields
(
map
(
lambda
a
:
(
'<tr><th>%s</th>
\
n
'
' <td><input name="%s"
\
n
'
' width=30 value="%s">'
'</td></tr>'
(
'<tr>
<th>%s</th>
\
n
'
'
<td><input name="%s"
\
n
'
'
width=30 value="%s">'
'
</td></tr>'
%
(
nicify
(
a
[
0
]),
(
a
[
1
].
has_key
(
'type'
)
and
...
...
@@ -286,29 +286,26 @@ def custom_default_report(id, result, action='', no_table=0,
):
columns
=
result
.
_searchable_result_columns
()
__traceback_info__
=
columns
heading
=
(
'<tr>
\
n
%s
\
n
</tr>'
%
heading
=
(
'<tr>
\
n
%s
</tr>'
%
string
.
joinfields
(
map
(
lambda
c
:
' <th>%s</th>
\
n
'
%
nicify
(
c
[
'name'
]),
'
<th>%s</th>
\
n
'
%
nicify
(
c
[
'name'
]),
columns
),
''
)
)
if
no_table
:
tr
,
_tr
,
td
,
_td
,
delim
=
'<p>'
,
'</p>'
,
''
,
''
,
', '
else
:
tr
,
_tr
,
td
,
_td
,
delim
=
'<tr>'
,
'</tr>'
,
'<td>'
,
'</td>'
,
''
if
no_table
:
tr
=
'<p>'
,
'</p>'
else
:
tr
,
_tr
=
'<tr>'
,
'</tr>'
if
no_table
:
tr
,
_tr
,
td
,
_td
,
delim
=
'<p>'
,
'</p>'
,
''
,
''
,
',
\
n
'
else
:
tr
,
_tr
,
td
,
_td
,
delim
=
'<tr>'
,
'</tr>'
,
'<td>'
,
'</td>'
,
'
\
n
'
row
=
[]
for
c
in
columns
:
n
=
c
[
'name'
]
if
goofy
(
n
)
>=
0
:
n
=
'expr="_vars[
\
'
%s]"'
%
(
`'"'+n`
[
2
:])
row
.
append
(
'
%s<!--#var %s%s-->%s
\
n
'
row
.
append
(
'
%s<!--#var %s%s-->%s
'
%
(
td
,
n
,
c
[
'type'
]
!=
's'
and
' null=""'
or
''
,
_td
))
row
=
(
'
%s
\
n
%s
\
n
%s'
%
(
tr
,
string
.
joinfields
(
row
,
delim
),
_tr
))
row
=
(
'
%s
\
n
%s
\
n
%s'
%
(
tr
,
string
.
joinfields
(
row
,
delim
),
_tr
))
return
custom_default_report_src
(
id
=
id
,
heading
=
heading
,
row
=
row
,
action
=
action
,
no_table
=
no_table
)
...
...
@@ -446,7 +443,6 @@ def decapitate(html, RESPONSE=None,
return html
def delimited_output(results,REQUEST,RESPONSE):
delim=REQUEST['
output
-
delimiter
']
try: output_type=REQUEST['
output
-
type
']
...
...
lib/python/Shared/DC/ZRDB/customDefaultReport.dtml
View file @
b8757f3a
...
...
@@ -2,12 +2,15 @@
<!--#if sequence-start-->
<!--#if previous-sequence-->
<a href="<!--#var URL--><!--#var sequence-query
-->query_start=<!--#var
previous-sequence-start-number-->">
(Previous <!--#var previous-sequence-size--> results)
</a>
<!--#/if previous-sequence-->
%(else no_table)[<table border>
%(heading)s
%(else)]
...
...
@@ -17,13 +20,17 @@
%(row)s
<!--#if sequence-end-->
%(else no_table)[</table>%(else)]
<!--#if next-sequence-->
<a href="<!--#var URL--><!--#var sequence-query
-->query_start=<!--#var
next-sequence-start-number-->">
(Next <!--#var next-sequence-size--> results)
</a>
<!--#/if next-sequence-->
<!--#/if sequence-end-->
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment