Add tabs to the "wizard" for creation of new trials

This commit is contained in:
Karsten Heiken
2011-07-31 17:28:46 +02:00
parent 965d5b5c5a
commit 08be8918e4

View File

@@ -14,14 +14,14 @@
<?php echo validation_errors(); ?> <?php echo validation_errors(); ?>
<ul> <ul>
<li> <li>
<label>Versuchname <span class="req">*</span></label> <h4>Versuchsbezeichnung <span class="req">*</span></h4>
<div> <div>
<input type="text" name="name" class="short text" value="<?=set_value('name')?>"> <input type="text" name="name" class="short text" value="<?=set_value('name')?>">
<?=form_error('name')?> <?=form_error('name')?>
</div> </div>
</li> </li>
<li> <li>
<label>Beschreibung</label><br /> <h4>Beschreibung</h4>
<label class="note">Eine Beschreibung ist hilfreich, wenn andere Mitarbeiter an diesem Projekt mitarbeiten möchten.</label> <label class="note">Eine Beschreibung ist hilfreich, wenn andere Mitarbeiter an diesem Projekt mitarbeiten möchten.</label>
<div> <div>
<textarea name="description" rows="6" cols="60" class="textarea"><?=set_value('description')?></textarea> <textarea name="description" rows="6" cols="60" class="textarea"><?=set_value('description')?></textarea>
@@ -29,13 +29,15 @@
</div> </div>
</li> </li>
<li> <li>
<label>3D-Modell</label><br /> <h4>3D-Modell</h4>
<? <?
$defaultmodel = "foo"; $defaultmodel = "foo";
if(isset($defaultmodel)): if(isset($defaultmodel)):
?> ?>
<label class="note"><strong>Für dieses Projekt ist ein Standardmodell vorhanden.</strong><br /> <div class="notice">
Wenn Sie hier eine neue Datei hochladen, wird für diesen Versuch das hier angegebene Modell verwendet.</label> <strong>Für dieses Projekt ist ein Standardmodell vorhanden.</strong><br />
Wenn Sie hier eine neue Datei hochladen, wird für diesen Versuch das hier angegebene Modell verwendet.
</div>
<? <?
endif; endif;
?> ?>
@@ -49,41 +51,55 @@
<div class="box"> <div class="box">
<h3>Parameter für die Berechnung</h3> <h3>Programmspezifische Parameter für die Berechnung</h3>
<? <?
$defaultconfig = "foo"; $defaultconfig = "foo";
if(isset($defaultconfig)): if(isset($defaultconfig)):
?> ?>
<p> <div class="notice">
<strong>Für dieses Projekt ist eine Standardkonfiguration vorhanden.</strong><br /> <strong>Für dieses Projekt ist eine Standardkonfiguration vorhanden.</strong><br />
Das folgende Formular enthält die Standardparameter. Diese können für diesen Versuch nach Belieben angepasst werden. <br /> Das folgende Formular enthält die Standardparameter. Diese können für diesen Versuch nach Belieben angepasst werden. <br />
Die Standardkonfiguration wird dabei nicht verändert. Die Standardkonfiguration wird dabei nicht verändert.
</p> </div>
<? <?
endif; endif;
?> ?>
<table> <p>Bitte wählen Sie zunächst das Programm aus, mit dem Sie eine Berechnung durchführen möchten:</p>
<thead> <ul class="tabs">
<tr> <li class="active"><a href="#tab1">Ultimate Scattering Tool</a></li>
<th scope="col" width="40%">Parameter</th> <li><a href="#tab2">Crazy Little Simulator</a></li>
<th scope="col" width="40%">Wert</th> </ul>
<th scope="col">Einheit</th>
</tr> <div class="tab_container">
</thead> <div id="tab1" class="tab_content">
<tbody> <table>
<thead>
<tr>
<th scope="col" width="40%">Parameter</th>
<th scope="col" width="40%">Wert</th>
<th scope="col">Einheit</th>
</tr>
</thead>
<tbody>
<? <?
foreach($parameters as $param): foreach($parameters as $param):
?> ?>
<tr> <tr>
<td><abbr title="<?=$param['description']?>"><?=$param['readable']?></abbr></td> <td><abbr title="<?=$param['description']?>"><?=$param['readable']?></abbr></td>
<td><input type="text" name="<?=$param['fieldname']?>" class="short text" value="<?=set_value($param['fieldname'])?>"><?=form_error($param['fieldname'])?></td> <td><input type="text" name="<?=$param['fieldname']?>" class="short text" value="<?=set_value($param['fieldname'])?>"><?=form_error($param['fieldname'])?></td>
<td><?=$param['unit']?></td> <td><?=$param['unit']?></td>
</tr> </tr>
<? <?
endforeach; endforeach;
?> ?>
</tbody> </tbody>
</table> </table>
</div>
<div id="tab2" class="tab_content">
<p>foobar</p>
</div>
</div>
</div> </div>
</form> </form>