CMS 3D CMS Logo

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
Functions | Variables
web_templates Namespace Reference

Functions

def usual_validation_dataset_template (dataset_name, root_link, ref_file, dir_link, paths_to_pictures, source_file)
 

Variables

 create_main_list_element
 
 main_page_template
 
 usual_validation_template
 

Function Documentation

◆ usual_validation_dataset_template()

def web_templates.usual_validation_dataset_template (   dataset_name,
  root_link,
  ref_file,
  dir_link,
  paths_to_pictures,
  source_file 
)

Definition at line 62 of file web_templates.py.

References join(), and FastTimerService_cff.range.

62 def usual_validation_dataset_template(dataset_name, root_link, ref_file, dir_link, paths_to_pictures, source_file):
63  chunk_list = lambda l,n: [l[i:i+n] for i in range(0, len(l), n)]
64  rows_paths = chunk_list(paths_to_pictures,2)
65  cell_template = ' <td style="width: 640px;"><A href=%s><IMG src="%s" width="640" align="center" border="0"></A></td>'
66  row_template = ''' <tr>
67 %s </tr>\n'''
68  rows = ''.join([row_template % ''.join([ cell_template % (path,path) for path in row]) for row in rows_paths])
69  reference = '<A href=%s>Reference</A>' % ref_file if ref_file else 'Reference not available'
70  source = '<A href=%s>Input Source</A>' % source_file if ref_file else 'Source not available' #ALL source files seem empty... need to check
71  return ''' <h3>%s ( <A href=%s>Root File</A> ) ( %s ) ( %s ) ( <A href=%s>Full Directory Content</A> )</h3>
72  <table style="text-align: left; " border="1" cellpadding="2" cellspacing="1">
73  <tbody>
74 %s
75  </tbody>
76  </table>
77 ''' % (dataset_name, root_link, reference, source, dir_link, rows)
78 
def usual_validation_dataset_template(dataset_name, root_link, ref_file, dir_link, paths_to_pictures, source_file)
static std::string join(char **cmd)
Definition: RemoteFile.cc:19

Variable Documentation

◆ create_main_list_element

web_templates.create_main_list_element

Definition at line 33 of file web_templates.py.

◆ main_page_template

web_templates.main_page_template

Definition at line 2 of file web_templates.py.

◆ usual_validation_template

web_templates.usual_validation_template

Definition at line 36 of file web_templates.py.