Admin/developer toolbar to speed up tool development.

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Admin/developer toolbar to speed up tool development.

Renaud Gaujoux
Hi Galaxy team,

for making galaxy tools development easier I made a little change to my
file 'tool_form.mako': it allows to reload a tool config from the tool's
page itself, using a simple ajax links.
The general idea is to provide the administrators/developers with a
toolbar of useful quick links.
Some are some screenshots are attached. It is a very quick(dirty?)
solution that does not handle error cases etc... but maybe you will find
the principle interesting.

The code is the following at line 201 of file 'tool_form.mako':

<div class="toolFormTitle">
<table><tbody><tr>
<td>
      %if tool.has_multiple_pages:
          ${tool.name} (step ${tool_state.page+1} of ${tool.npages})</div>
      %else:
          ${tool.name}
      %endif
</td>
          %if trans.user and app.config.is_admin_user( trans.user ):
<td><a onclick="$('.adminOptions').toggle();return false;" href="#"
style="font-size: 8pt; color: rgb(48, 48, 170);">+ Options</a></td>
<td style="display: none;" class="adminOptions">::</td>
<td style="display: none; font-size: 8pt;" class="adminOptions">
<a class="icon-button arrow-circle tooltip"
onclick="$.post('/admin/tool_reload', {tool_id:'nmf'}, function(data){
$('#result').toggle(); $('#result').html(data);
$('#result').html($('#result .donemessage'));
$('#result').toggle().delay(3000); location.reload();}); return false;"
href="#" title="Reload&nbsp;config">Relaod&nbsp;config</a>
</td>
          %endif
</tr></tbody></table>
          %if trans.user and app.config.is_admin_user( trans.user ):
<div id="result"></div>
          %endif
</div>

Bests,
Renaud

Renaud Gaujoux
Computational Biology - University of Cape Town
South Africa



 

###
UNIVERSITY OF CAPE TOWN

This e-mail is subject to the UCT ICT policies and e-mail disclaimer published on our website at http://www.uct.ac.za/about/policies/emaildisclaimer/ or obtainable from +27 21 650 4500. This e-mail is intended only for the person(s) to whom it is addressed. If the e-mail has reached you in error, please notify the author. If you are not the intended recipient of the e-mail you may not use, disclose, copy, redirect or print the content. If this e-mail is not related to the business of UCT it is sent by the sender in the sender's individual capacity.

###
 


_______________________________________________
galaxy-dev mailing list
[hidden email]
http://lists.bx.psu.edu/listinfo/galaxy-dev

tool-option.png (5K) Download Attachment
tool-option2.png (8K) Download Attachment