0
|
1 <tool id="iReport" name="iReport dev" version="1">
|
|
2 <description> create an HTML report </description>
|
|
3
|
|
4
|
|
5 <command interpreter="bash">
|
|
6
|
|
7 iReport.sh
|
|
8 --galaxypath ${report.files_path}
|
|
9 --htmlout ${report}
|
|
10 --minwidth ${minwidth}
|
|
11 --coverimage "-${coverimage}"
|
|
12 #for $i, $t in enumerate($tabs)
|
|
13 --tab ${t.tabtitle}
|
|
14 #for $j, $u in enumerate($t.content)
|
|
15 #if $u.filetype.itemtype == "image"
|
|
16 --item "${t.tabtitle}:${u.filetype.itemtype}:${u.filetype.item}:${u.filetype.break}:${u.filetype.zoomlevel}:${u.filetype.zoomenable}:${u.filetype.align}"
|
|
17 #else if $u.filetype.itemtype == "table"
|
|
18 #if $u.filetype.collink.columnhyperlink == "Y"
|
|
19 --item "${t.tabtitle}:${u.filetype.itemtype}:${u.filetype.item}:${u.filetype.break}:${u.filetype.fancy}:Y:${u.filetype.collink.urlcol}:${u.filetype.collink.urlprefix}:${u.filetype.collink.urlsuffix}:${u.filetype.collink.urlitems}"
|
|
20 #else
|
|
21 --item "${t.tabtitle}:${u.filetype.itemtype}:${u.filetype.item}:${u.filetype.break}:${u.filetype.fancy}:N"
|
|
22 #end if
|
|
23 #else if $u.filetype.itemtype == "link"
|
|
24 --item "${t.tabtitle}:${u.filetype.itemtype}:${u.filetype.item}:${u.filetype.break}:${__app__.security.encode_id($u.filetype.item.id)}:${u.filetype.ireport}:${u.filetype.item2}"
|
|
25 #else if $u.filetype.itemtype == "weblink"
|
|
26 --item "${t.tabtitle}:${u.filetype.itemtype}:${u.filetype.item}:${u.filetype.break}:${u.filetype.item2}"
|
|
27 #else
|
|
28 --item "${t.tabtitle}:${u.filetype.itemtype}:${u.filetype.item}:${u.filetype.break}"
|
|
29 #end if
|
|
30 #end for
|
|
31 #end for
|
|
32 --label "${label}"
|
|
33 </command>
|
|
34
|
|
35 <inputs>
|
|
36 <param name="label" type="text" size="100" label="Name of Report" />
|
|
37 <param name="coverimage" type="text" size="100" label="Link to cover image" help="Optional. A default image will be used if not specified"/>
|
|
38 <param name="minwidth" type="integer" min="0" max="5000" value="1200" label="Width of page (in pixels)" />
|
|
39 <repeat name="tabs" title="Tab" default="1" >
|
|
40 <param name="tabtitle" type="text" size="50" label="Enter tab name">
|
|
41 <sanitizer>
|
|
42 <valid initial="default">
|
|
43 <add preset="string.printable"/>
|
|
44 <remove value="""/>
|
|
45 <remove value="\"/>
|
|
46 <remove value="
"/>
|
|
47 <remove value="
"/>
|
|
48 <remove value="&"/>
|
|
49 <remove value=":"/>
|
|
50 <remove value=" "/>
|
|
51 </valid>
|
|
52 <mapping initial="none">
|
|
53 <add source="\" target="\\"/>
|
|
54 <add source=""" target="==quote=="/>
|
|
55 <add source="&" target="&&"/>
|
|
56 <add source="
" target="&n"/>
|
|
57 <add source="
" target="&r"/>
|
|
58 <add source=":" target="==colon=="/>
|
|
59 <add source=" " target="_s_"/>
|
|
60 </mapping>
|
|
61 </sanitizer>
|
|
62 </param>
|
|
63 <repeat name="content" title="Content-Item" default="1">
|
|
64 <conditional name="filetype">
|
|
65 <param name="itemtype" type="select" label="Select Item Type" >
|
|
66 <option value="" > Please choose item type </option>
|
|
67 <option value="text" > Text Field </option>
|
|
68 <option value="textfile" > Text File from history </option>
|
|
69 <option value="image"> Image </option>
|
|
70 <option value="pdf" > PDF File </option>
|
|
71 <option value="table"> Table </option>
|
|
72 <option value="link" > Link to file </option>
|
|
73 <option value="links"> Links to files in archive</option>
|
|
74 <option value="weblink" > Web link </option>
|
|
75 <validator type="empty_field" />
|
|
76 </param>
|
|
77 <when value="text">
|
|
78 <param name="item" type="text" area="true" size="10x100" label="Text to display." help="can explicitly add whitespace adding \n in your text for a newline or \t for a tab. HTML tags em, strong, b, i, h1-h6 tags" >
|
|
79 <sanitizer>
|
|
80 <valid initial="default">
|
|
81 <add preset="string.printable"/>
|
|
82 <remove value="\"/>
|
|
83 <remove value="/"/>
|
|
84 <remove value=","/>
|
|
85 <remove value=":"/>
|
|
86 <remove value="<"/>
|
|
87 <remove value=">"/>
|
|
88 <remove value="'"/>
|
|
89 <remove value="""/>
|
|
90 <remove value="
"/>
|
|
91 <remove value="
"/>
|
|
92 <remove value="&"/>
|
|
93 <remove value=":"/>
|
|
94 <remove value=" "/>
|
|
95 </valid>
|
|
96 <mapping initial="none">
|
|
97 <add source="\" target="\\"/>
|
|
98 <add source="/" target="==slash=="/>
|
|
99 <add source="&" target="&&"/>
|
|
100 <add source="
" target="&n"/>
|
|
101 <add source="
" target="&r"/>
|
|
102 <add source=":" target="&c"/>
|
|
103 <add source=" " target="==space=="/>
|
|
104 <add source="," target="==comma=="/>
|
|
105 <add source="<" target="==lt=="/>
|
|
106 <add source=">" target="==gt=="/>
|
|
107 <add source="'" target="==apos=="/>
|
|
108 <add source=""" target="==quote=="/>
|
|
109 <add source=":" target="==colon=="/>
|
|
110 </mapping>
|
|
111 </sanitizer>
|
|
112 </param>
|
|
113 <param name="break" type="boolean" checked="False" truevalue="Y" falsevalue="N" label="Insert break after item?"/>
|
|
114 </when>
|
|
115 <when value="textfile">
|
|
116 <param name="item" type="data" label="Text File" help="Text file to display verbatim"/>
|
|
117 <param name="break" type="boolean" checked="False" truevalue="Y" falsevalue="N" label="Insert break after item?" help="Insert a line break to force next item to appear below this one. If unchecked, the browser will decide layout"/>
|
|
118 </when>
|
|
119 <when value="image">
|
|
120 <param name="item" type="data" label="Image File" format="png,svg,jpg,jpeg" help="Supported formats: png, jpg, svg. If image is scaled by choice of width, zoom-on-mousover effect is added."/>
|
|
121 <param name="zoomlevel" type="integer" min="0" max="5000" value="250" label="Width (in pixels)" help="enter 0 to keep original size" />
|
|
122 <param name="zoomenable" type="boolean" checked="True" truevalue="Y" falsevalue="N" label="Enable zoom-on-mouseover effect?" help="If checked and nonzero width, zoom-on-mousover effect added"/>
|
|
123 <param name="align" type="select" label="Alignment of image (float)" help="Use left or right align to have images and text next to each other. Always specify image first (with alignment), then text, if you want to show them side by side." >
|
|
124 <option value="none" > default (recommended) </option>
|
|
125 <option value="left" > left </option>
|
|
126 <option value="right" > right </option>
|
|
127 <option value="middle"> center </option>
|
|
128 <!--<option value="top"> top </option>
|
|
129 <option value="bottom"> bottom </option>-->
|
|
130 </param>
|
|
131 <param name="break" type="boolean" checked="False" truevalue="Y" falsevalue="N" label="Insert break after item?" help="Insert a line break to force next item to appear below this one. If unchecked, the browser will decide layout"/>
|
|
132 </when>
|
|
133 <when value="table">
|
|
134 <param name="item" type="data" label="Table File" help="must be a tab-delimited file with a 1-line header" />
|
|
135 <param name="fancy" type="boolean" checked="True" truevalue="Y" falsevalue="N" label="Fancy table?" help="If selected, will create, sortable, searchable, paginated table. Otherwise not (for small tables)"/>
|
|
136 <conditional name="collink">
|
|
137 <param name="columnhyperlink" type="select" label="create url links from one of the columns in your table?" help="For example: from column with gene names, link to genecards page">
|
|
138 <option value="N"> No </option>
|
|
139 <option value="Y"> Yes </option>
|
|
140 </param>
|
|
141 <when value="Y">
|
|
142 <param name="urlcol" type="data_column" data_ref="item" multiple="False" label="Column to turn in to weblinks" />
|
|
143 <param name="urlprefix" type="text" size="75" label="URL prefix" help="this will be placed before value in column to form the weblink. e.g. for genecards use: http://www.genecards.org/cgi-bin/carddisp.pl?gene=">
|
|
144 <sanitizer>
|
|
145 <valid initial="default">
|
|
146 <add preset="string.printable"/>
|
|
147 <remove value="&"/>
|
|
148 <remove value=":"/>
|
|
149 <remove value="/"/>
|
|
150 <remove value=" "/>
|
|
151 </valid>
|
|
152 <mapping initial="none">
|
|
153 <add source="&" target="==amp=="/>
|
|
154 <add source=":" target="==colon=="/>
|
|
155 <add source="/" target="//"/>
|
|
156 <add source=" " target=""/>
|
|
157 </mapping>
|
|
158 </sanitizer>
|
|
159 </param>
|
|
160 <param name="urlsuffix" type="text" size="75" label="URL suffix" help="this will be placed before value in column to form the weblink. e.g. For genecards, there is no suffix">
|
|
161 <sanitizer>
|
|
162 <valid initial="default">
|
|
163 <add preset="string.printable"/>
|
|
164 <remove value="&"/>
|
|
165 <remove value="/"/>
|
|
166 <remove value=" "/>
|
|
167 </valid>
|
|
168 <mapping initial="none">
|
|
169 <add source="&" target="&&"/>
|
|
170 <add source="/" target="//"/>
|
|
171 <add source=" " target=""/>
|
|
172 </mapping>
|
|
173 </sanitizer>
|
|
174 </param>
|
|
175 <param name="urlitems" type="data" label="(Not yet implemented) Archive with files to link to" optional="true" help="Optional. Only if you want to link column entries to local files instead of websites" format="zip,gz,bz2,tar"/>
|
|
176 </when>
|
|
177 </conditional>
|
|
178 <param name="break" type="boolean" checked="False" truevalue="Y" falsevalue="N" label="Insert break after item?" help="Insert a line break to force next item to appear below this one. If unchecked, the browser will decide layout"/>
|
|
179 </when>
|
|
180 <when value="pdf">
|
|
181 <param name="item" type="data" label="PDF File" format="pdf"/>
|
|
182 <param name="break" type="boolean" checked="False" truevalue="Y" falsevalue="N" label="Insert break after item?" help="Insert a line break to force next item to appear below this one. If unchecked, the browser will decide layout"/>
|
|
183 </when>
|
|
184 <when value="link">
|
|
185 <param name="item" type="data" label="File to link to" />
|
|
186 <param name="item2" type="text" size="100" label="link text" help="text to display as a link"/>
|
|
187 <param name="ireport" type="boolean" checked="False" truevalue="Y" falsevalue="N" label="is the link another iReport?"/>
|
|
188 <param name="break" type="boolean" checked="False" truevalue="Y" falsevalue="N" label="Insert break after item?" help="Insert a line break to force next item to appear below this one. If unchecked, the browser will decide layout"/>
|
|
189 </when>
|
|
190 <when value="links">
|
|
191 <param name="item" type="data" label="Archive with files to link to" help="links will be created to each file in the archive. Supported formats: zip, gz, tar, bz2"/>
|
|
192 <param name="break" type="boolean" checked="False" truevalue="Y" falsevalue="N" label="Insert break after item?" help="Insert a line break to force next item to appear below this one. If unchecked, the browser will decide layout" />
|
|
193 </when>
|
|
194 <when value="weblink">
|
|
195 <param name="item" type="text" size="100" label="web location to link to " help="url to link to">
|
|
196 <sanitizer>
|
|
197 <valid initial="default">
|
|
198 <add preset="string.printable"/>
|
|
199 <remove value="&"/>
|
|
200 <remove value=":"/>
|
|
201 </valid>
|
|
202 <mapping initial="none">
|
|
203 <add source="&" target="==amp=="/>
|
|
204 <add source=":" target="==colon=="/>
|
|
205 </mapping>
|
|
206 </sanitizer>
|
|
207 </param>
|
|
208 <param name="item2" type="text" size="100" label="link text" help="text to display as a link"/>
|
|
209 <param name="break" type="boolean" checked="False" truevalue="Y" falsevalue="N" label="Insert break after item?" help="Insert a line break to force next item to appear below this one. If unchecked, the browser will decide layout"/>
|
|
210 </when>
|
|
211 </conditional>
|
|
212 </repeat>
|
|
213 </repeat>
|
|
214
|
|
215
|
|
216
|
|
217 </inputs>
|
|
218
|
|
219 <outputs>
|
|
220 <data format="html" name="report" label="HTML report: ${label}"/>
|
|
221 </outputs>
|
|
222
|
|
223 <help>
|
|
224 Description of tool for the users
|
|
225 </help>
|
|
226 </tool>
|