{if $action == ''}
<html>
  <head>
    <link type="text/css" rel="stylesheet" href="templates/{$global_template}/css/styles_refill.css">
    <link rel="stylesheet" href="jquery/jquery-ui.css">
    <script src="jquery/jquery-1.12.4.js"></script>
    <script src="jquery/jquery-ui.js"></script>
    <script src="jquery/globalize.js"></script>
    <script src="jquery/globalize.culture.de-DE.js"></script>
    <script src="jquery/jquery.mousewheel.js"></script>
    <style type="text/css">
      .spinner {
      width: 200px;
      height: 15px;
      font-size: 12px !important;
      }
    </style>
    <script>
      $( function() {
        $( ".spinner" ).spinner({
          step: 0.1,
          numberFormat: "i",
          min:0,
          decimals:0
        });
        Globalize.culture( "de-DE" );

      } );
         function trackKeys(evnt,regEx) {
         	var keyCode = evnt.keyCode ? evnt.keyCode : evnt.which;
       	return !!String.fromCharCode(keyCode).match(regEx);
         }
       //-->
    </script>
    <style>
      .StandardTable thead th{
      background: lightgray;
      border: 1px solid #656565;
      font-size:12px;
      font-family:Arial;
      padding-top:5px;
      padding-bottom:5px;
      padding-left:5px;
      padding-right:5px;
      }
      textarea{
      border: 1px solid #888;
      height: 6.7em;
      width: 48.5em;
      }
      select{
      width:630px;
      }
    </style>
  </head>
  <body>
    <br />
    <br />
    <div class="header">
      <div>
        <div>{$erfs_titel}</div>
      </div>
    </div>
    <form action="?action=register" method='post' name='erfassen'>
      <div class="pat_list_box">
        {if $erfs_error == '1'}
        <table width="70%" class="errorTable" align="center">
          <tr>
            <td>
              <img src="templates/{$global_template}/images/pflichtfelder/achtung_gross.gif">
            </td>
            <td><b>Achtung!</b><br>
              {$erfs_error_text}
            </td>
          </tr>
        </table>
        <br />
        {/if}
        {if $erfs_abschluss == '0'}
        <fieldset>
          <legend>
            <b>Lehrveranstaltung erfassen</b>
          </legend>
          <br />
          <br />
          <table cellspacing="0" cellpadding="0" width="100%" border="0" class="StandardTable">
            <tr>
              <td>
                Titel der Lehrveranstaltung (LV)
              </td>
              <td valign="top">
                <!--<textarea name="titel" id="titel" size="60">{$erfs_value_titel}</textarea>-->
                <input type="text" name="titel"  id="titel"  size="101" value="{$erfs_value_titel}">
              </td>
            </tr>
            <tr>
              <td>&nbsp;
              </td>
              <td>&nbsp;
              </td>
            </tr>
            <script language="javascript" type="text/javascript">
              function einblenden ($verid) {
                  /* Bei Exkursionen Erfassungsfeld einblenden*/
              	if (document.getElementById("art").value == "5") {
              		document.getElementById("exkursion1").style.visibility = "visible";
              		document.getElementById("lehrstd1").style.visibility = "hidden";
                    document.getElementById("exk_datumvon2").disabled = true;
                    document.getElementById("exk_datumbis2").disabled = true;
                    document.getElementById("exk_beschreibung2").disabled = true;
                    document.getElementById("exk_stdanreise2").disabled = true;
                    document.getElementById("exk_stdabreise2").disabled = true;

                    //<![CDATA[
                    $(document).ready(function(){
                            var id = "exkursion1";
                            var id2 = "lehrstd1";
                            var id3 = "extracurr";
                            $("#" + id).fadeIn("slow");
                            $("#" + id2).fadeOut("slow");
                            $("#" + id3).fadeOut("slow");
                    });
                    //]]>

                  }else{
                      document.getElementById("exkursion1").style.visibility = "hidden";
                      document.getElementById("lehrstd1").style.visibility = "visible";
                    //<![CDATA[
                    $(document).ready(function(){
                      var id = "exkursion1";
                      var id2 = "lehrstd1";
                      var id3 = "extracurr";
                      $("#" + id).fadeOut("slow");
                      $("#" + id2).fadeIn("slow");
                      $("#" + id3).fadeOut("slow");
                    });
                    //]]>
                  }
                  if (document.getElementById("art").value == "6") {
                    /*Hinweis zu Extracurricularer Klausurenkurs einblenden*/
                    //<![CDATA[
                    $(document).ready(function(){
                      var id = "exkursion1";
                      var id2 = "lehrstd1";
                      var id3 = "extracurr";
                      $("#" + id).fadeOut("slow");
                      $("#" + id2).fadeIn("slow");
                      $("#" + id3).fadeIn("slow");
                    });
                    //]]>
                  }
              }
            </script>
            <tr>
              <td>
                Art der LV
              </td>
              <td valign="top">
                <select name="art" id="art" size=5 onchange="einblenden();">
                {section name=table_data1 loop=$table_data1}
                <option value="{$table_data1[table_data1].verid}" {if $erfs_value_art == $table_data1[table_data1].verid} selected {/if} >{$table_data1[table_data1].bezeichnung}</option>
                {/section}
                </select>
              </td>
            </tr>
            <tr>
              <td>&nbsp;
              </td>
              <td>&nbsp;
              </td>
            </tr>
            <tr id="lehrstd1">
              <td>
                Summe eigene Lehrstunden (LVS)
              </td>
              <td valign="top">
                <!--<input type="number" step="0.1" name="std" size="101" value="{$erfs_value_std}">-->
                <input type="text" class="spinner" name="std" id="std" size="101" value="{$erfs_value_std}" onKeypress="return trackKeys(event,/[0-9,]/);">
              </td>
            </tr>
            <tr>
              <td>&nbsp;
              </td>
              <td>&nbsp;
              </td>
            </tr>
            <tr>
              <td>
                Hinweise
              </td>
              <td valign="top">
                <textarea name="hinweise">{$erfs_value_hinweise}</textarea>
              </td>
            </tr>
          </table>
          <br />
          <p align='center'>
            <input type='submit' name='senden' value="Speichern">
          </p>
          <br />
        </fieldset>
    </form>
    <br />
    <br />
    <fieldset>
    <legend>
    <b>Erfasste Lehrveranstaltungen</b>
    </legend>
    <table cellspacing="0" cellpadding="2" width="100%" border="1">
    <tr>
    <td>
    <b>lfd.Nr.</b>
    </td>
    <td>
    <b>Titel der Lehrveranstaltung (LV)</b>
    </td>
    <td>
    <b>Art der LV</b>
    </td>
    <!--
      <td>
      <b>Krankheitsbedingte Merkmale</b>
      </td>
      <td>
      <b>gemeinsame&nbsp;LV</b>
      </td>
        <td>
        <b>Anzahl der Lehrenden</b>
        </td>
        <td>
        <b>Maß der<br>Lehrbeteiligung (%)</b>
        </td>
        <td>
        <b>Namen der Lehrenden</b>
        </td>
        <td>
        <b>Teachingfaktor</b>
        </td>
        -->
    <td align="right">
    <b>Summe eigene Lehrstunden (LVS)</b>
    </td>
    <td>
    <b>Hinweise</b>
    </td>
    <td align="center">
    <b>Edit</b>
    </td>
    <tr>
    {section name=table_data2 loop=$table_data2}
    {if $smarty.section.table_data2.rownum != ''}
    <tr>
    <td>
    {$smarty.section.table_data2.rownum}
    </td>
    <td>
    {$table_data2[table_data2].titel}
    </td>
    <td>
    {$table_data2[table_data2].veranstaltung}
    </td>
    <!--
      <td>
      {$table_data2[table_data2].krankheitsmerkmal}
      </td>
      <td>
      {$table_data2[table_data2].gemlv_form}
      </td>
        <td>
        {$table_data2[table_data2].anzgemlv}
        </td>
        <td>
        {$table_data2[table_data2].massgemlv}%
        </td>
        <td>
        {$table_data2[table_data2].namegemlv}
        </td>
        <td>
        {$table_data2[table_data2].teamteaching_form}
        </td>
        -->
    <td align="right">
    {$table_data2[table_data2].lvs}
    </td>
    <td>
    {$table_data2[table_data2].hinweise}
    </td>
    <td align="center">
    <a href=?edit={$table_data2[table_data2].dsid}><img title = "Lehrveranstaltung bearbeiten" border="0" height=10 src="templates/{$global_template}/images/edit.png"></a>
    &nbsp;
    <a href="?action=del&dsid={$table_data2[table_data2].dsid}"><img title = 'Lehrveranstaltung l&ouml;schen' border="0" height=10 src="templates/{$global_template}/images/drop.png"></a>
    </td>
    </tr>
    {/if}
    {/section}
    <tr>
    <td colspan="3">&nbsp;</td>
    <td align="right"><b>Summe: {$erfs_value_summe_jahr}</b></td>
    <td colspan="2">&nbsp;</td>
    </tr>
    </table>
    </fieldset>
    {/if}
    <br />
    <br />
    </div>
  </body>
</html>
{/if}

