Translations of this page:

Issues Templater Component

This is a templater component that allows to show list of issues somewhere within Claromentis. It doesn’t require any additional PHP code to work and can be inserted anywhere in VI template. All configuration is done using tag attributes within template.

Available starting from Claromentis 5.6

Parameters

Basic usage:

<component class="ICIssuesComponent" project_id="NN" fields="id,status,reporter">

This will show in row issues from Infocapture project with ID NN, as specified by project_id attribute.


Full list of parameters:

  • project_id, required. Infocapture project ID to take issues.
  • fields, required. List of columns to view splitted by comma. Default list is comments,attachments,id,reporter. Where all fields is:
    • edit_icon. Show icon with link to edit issue.
    • comments. Show number of comments.
    • attachments. Show number of attachments.
    • id. ID of issue with link to view page.
    • status. Issue status.
    • reporter. Name of issue reporter.
    • assigned. Name of assigned user.
    • created. Date of creation.
    • last_modified. Date of last modified
    • Any another form field. And you can set any another symbolic name from project form.
  • limit, optional. Number of issues to show. If defined, paging is disabled.
  • template. Location of template to use to show issues. Template structure is described below. Default is infocapture/issues_component.html
  • per_page, optional. Number of rows per page. Default value is “10”.
  • show_paging, optional. Show or hide paging. Default value is “1”. All values is “0” or “1”.
  • sort_field, optional. Field symname for sorting. Default is “_id_”.
  • sorting_dir, optional. Sorting direction, use with sort_field parameter. Default is “desc”
  • link_target, optional. Target parameter for link tag. Default is “_blank”
  • show_caption, optional. Show or hide project title. Default value is “1”. All values is “0” or “1”.
  • prefix, optional. Unique prefix for paging links. Default value is “st”
  • url_prefix, optional. Url for links of paging. Default value is ““

Custom templates

Custom layout allows to define any additional styling of issues table.

To do this, custom html template should be created, put somewhere within Claromentis and its location specified in template attribute. Path to template is entered without leading slash, starting from folder just below interface_.... As an example, location of default templates is “gallery/includes/component_horizontal.html” and “infocapture/issues_component.html”. Templates are usual Claromentis templates, so check this for help with their markup language.

This is a default template for issues table:

<div name="error" visible="0"></div>
<div name="data">
<table width="100%" class="table_main">
	<caption name="issues_caption"></caption>
	<thead>
		<tr name="issues_head" datasrc="">
			<th name="th"></th>
		</tr>
	</thead>
	<tbody name="issues_data" datasrc="">
		<tr name="tr" datasrc="">
			<td name="td"></td>
		</tr>
	</tbody>
	<tfoot>
		<tr>
			<td colspan="2" name="issues_pager" datasrc=""></td>
		</tr>
	</tfoot>
</table>
</div>

The following names are available to use within this template:

  • error - error block
  • data - issues main table block
  • issues_caption - project name of issues
  • issues_head - datasource for column names
    • th - column name container
  • issues_data - datasource for data rows
    • tr - data row container
    • td - column data container
  • issues_pager - block for pages list


And simple template for issues table. In simple template you can set custom apperance for data in table.

<div name="error" visible="0"></div>
<div name="data">
<table width="100%" class="table_main">
	<caption name="issues_caption"></caption>
	<col width="10" span="2">
	<thead>
		<tr>
			<th><img width="14" height="12" src="/intranet/infocapture/images/comment.gif"></th>
			<th><img width="6" height="14" src="/intranet/infocapture/images/files.gif"></th>
			<th>ID</th>
		</tr>
	</thead>
	<tbody name="issues_data" datasrc="">
		<tr>
			<td name="ic_col1"></td>
			<td name="ic_col2"></td>
			<td><b name="ic_col3"></b></td>
		</tr>
	</tbody>
	<tfoot>
		<tr>
			<td colspan="2" name="issues_pager" datasrc=""></td>
		</tr>
	</tfoot>
</table>
</div>

The following unique names are available to use within this template:

  • ic_colN - container for data of N column. Where N - is index of column in fields attribute of component. If fields attribute contains “comments,attachments,id”, when comments is first column and N=1 (ic_col1), attachments is second column and N=2 (ic_col2), id is third column and N=3 (ic_col3)
 
help/infocapture/issues_list.txt · Last modified: 07/06/2011 04:49 by inf2k
 
Recent changes RSS feed Creative Commons License Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki