Changeset 1496


Ignore:
Timestamp:
Jan 9, 2012, 2:17:40 PM (10 years ago)
Author:
Martin Svensson
Message:

References #337 The specimen tube wizard restarts automatically with a delay of 2s. The restart-process can be stopped by pressing the 'Stop'-button.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/net.sf.basedb.reggie/trunk/resources/specimentube.jsp

    r1460 r1496  
    7272var currentStep = 1;
    7373var usedBox = '';
     74var restartTimer;
    7475
    7576var caseInfo = null;
     
    787788  }
    788789  msg += '</ul>';
     790  msg += '<p></p>';
     791  msg += '<div id=restartSection><i>Wizard will restart automatically...</i></div>';
    789792  setInnerHTML('done', msg);
    790793  Main.show('done');
    791   //Main.show('gorestart');
     794  Main.show('gostop');
     795  restartTimer = setTimeout('goRestart(true)',2000);
    792796}
    793797
     
    811815  }
    812816  caseInfo = response.caseInfo;
     817}
     818
     819function goStop()
     820{
     821  clearTimeout(restartTimer);
     822  Main.hide('restartSection');
     823  Main.hide('gostop');
     824  Main.show('gorestart');
    813825}
    814826</script>
     
    977989  </tr>
    978990  </table>
    979   </div>
     991  </div> 
    980992   
    981993  <div class="error" id="errorMessage" style="display: none; width: 800px; margin-left: 20px; margin-bottom: 0px;"></div>
     
    9881000      <td><base:button id="gonext" title="Next" image="gonext.gif" onclick="goNext(true)"/></td>
    9891001      <td><base:button id="gocreate" title="Create" image="gonext.gif" onclick="goCreate()" style="display: none;"/></td>
    990       <td><base:button id="goupdate" title="Update" image="gonext.gif" onclick="goCreate()" style="display: none;"/></td>
     1002      <td><base:button id="goupdate" title="Update" image="gonext.gif" onclick="goCreate()" style="display: none;"/></td>     
    9911003      <td><base:button id="gorestart" title="Restart" image="goback.gif" onclick="goRestart(true)" style="display: none;"/></td>
     1004      <td><base:button id="gostop" title="Stop" image="cancel.gif" onclick="goStop()" style="display:none;"/></td>
    9921005      <td id="gonext.message" class="message"></td>
    9931006    </tr>
Note: See TracChangeset for help on using the changeset viewer.