Exemplo n.º 1
0
 public function getPopupEinstellungen()
 {
     $F = new HTMLForm("allgemeineWerte", array("OWMApiKey"));
     $F->getTable()->setColWidth(1, 120);
     $F->setValue("OWMApiKey", mUserdata::getGlobalSettingValue("OWMApiKey", ""));
     $F->setSaveRMEPCR("Speichern", "", "mOpenWeatherMap", "-1", "saveEinstellungen", OnEvent::closePopup("mOpenWeatherMap"));
     echo $F;
 }
Exemplo n.º 2
0
 public function testDownloadPopup()
 {
     $F = new HTMLForm("tdl", array("link"));
     $F->setType("link", "textarea");
     $F->getTable()->setColWidth(1, 60);
     $F->setSaveRMEPCR("test download", "", "JD", $this->getID(), "testDownload", "function(t){ \$j('#downloadResult').html(t.responseText); }");
     $F->setInputStyle("link", "font-size:10px;height:200px;");
     echo $F . "<pre style=\"padding:5px;\" id=\"downloadResult\"></pre>";
 }
Exemplo n.º 3
0
 public function getHTML($id)
 {
     $phtml = parent::getHTML($id);
     $monate = Datum::getGerMonthArray();
     $jahre = array(date("Y") - 1 => date("Y") - 1, date("Y") => date("Y"), date("Y") + 1 => date("Y") + 1);
     $f = new HTMLForm("Bericht", array("lightCRMKalBerichtMonth", "lightCRMKalBerichtYear"), "Anzeige:");
     $f->getTable()->setColWidth(1, "120px");
     $f->setType("lightCRMKalBerichtMonth", "select", ($this->userdata != null and isset($this->userdata["lightCRMKalBerichtMonth"])) ? $this->userdata["lightCRMKalBerichtMonth"] : 0, $monate);
     $f->setType("lightCRMKalBerichtYear", "select", ($this->userdata != null and isset($this->userdata["lightCRMKalBerichtYear"])) ? $this->userdata["lightCRMKalBerichtYear"] : 0, $jahre);
     $f->setLabel("lightCRMKalBerichtMonth", "Monat");
     $f->setLabel("lightCRMKalBerichtYear", "Jahr");
     $f->setSaveBericht($this);
     return $phtml . $f;
 }
Exemplo n.º 4
0
 public function downloadPopup()
 {
     $J = array();
     $AC = anyC::get("JD");
     while ($D = $AC->getNextEntry()) {
         $J[$D->getID()] = $D->A("JDName");
     }
     $F = new HTMLForm("tdl", array("link", "JD"));
     $F->setType("link", "textarea");
     $F->setType("JD", "select", null, $J);
     $F->getTable()->setColWidth(1, 60);
     $F->setSaveRMEPCR("Download", "", "mJD", -1, "download", "function(t){ \$j('#downloadResult').html(t.responseText); }");
     $F->setInputStyle("link", "font-size:10px;height:200px;");
     echo $F . "<pre style=\"padding:5px;\" id=\"downloadResult\"></pre>";
 }
Exemplo n.º 5
0
 /**
  * Popup zur Konfiguration eines Servers.
  */
 public function getConfigPopup($echo = true)
 {
     // Button
     $BCreate = new Button("Server\nhinzufügen", "new");
     $BCreate->rmePCR("mxCal", "-1", "createNewServer", array(), OnEvent::reloadPopup("mxCal"));
     $htmlTableButton = new HTMLTable(1);
     $htmlTableButton->addRow($BCreate);
     // Liste der konfigurierten Server
     $userId = $_SESSION["S"]->getCurrentUser()->getID();
     $T = new HTMLTable(1, "xCal Server");
     $BDeleteRaw = new Button("Eintrag löschen", "./images/i2/delete.gif", "icon");
     $BDeleteRaw->style("float: right;");
     $serverList = anyC::get("xCal", "xCalUserID", $userId);
     $counter = 0;
     while ($S = $serverList->getNextEntry()) {
         $BDelete = clone $BDeleteRaw;
         $BDelete->onclick("deleteClass('xCal','" . $S->getID() . "', function() { Popup.refresh('mxCal'); }, 'Eintrag wirklich löschen?');");
         $F = new HTMLForm("xCal_" . $S->A("xCalID"), array("xCalName", "xCalUrl", "xCalServerActive"));
         $F->getTable()->setColWidth(1, 120);
         $F->setValues($S);
         $F->setLabel("xCalName", "Bezeichnung");
         $F->setLabel("xCalUrl", "URL");
         $F->setLabel("xCalServerActive", "Für den Import verwenden");
         $F->setType("xCalServerActive", "checkbox");
         $F->useRecentlyChanged();
         $F->setSaveClass("xCal", $S->getID(), "''");
         $display = "none";
         if ($S->A("xCalName") == "" && $S->A("xCalUrl") == "") {
             $display = "";
         }
         $div = "<div\n\t\t\t\t\tonmouseover=\"this.className = 'backgroundColor3';\" \n\t\t\t\t\tonmouseout=\"this.className = '';\" \n\t\t\t\t\tstyle=\"padding:3px;cursor:pointer;\" \n\t\t\t\t\tonclick=\"if(\$('APDetails" . $S->getID() . "').style.display == 'none') new Effect.BlindDown('APDetails" . $S->getID() . "'); else new Effect.BlindUp('APDetails" . $S->getID() . "');\">\n\t\t\t\t\t{$BDelete}<span id=\"APPosition" . $S->getID() . "\">" . ($S->A("xCalName") != "" ? $S->A("xCalName") : "Neuer Server") . "</span>&nbsp;<br />\n\t\t\t\t\t<small style=\"color:grey;\" id=\"APName" . $S->getID() . "\">" . ($S->A("xCalServerActive") == "1" ? "Import aktiviert" : "Import deaktiviert") . "&nbsp;</small>\n\t\t\t\t</div>";
         $T->addRow(array($div . "<div id=\"APDetails" . $S->getID() . "\" style=\"display:" . $display . ";\">" . $F . "</div>"));
         $T->addRowClass("backgroundColor0");
         $T->addCellClass(1, "borderColor1");
         $counter++;
     }
     if ($counter == 0) {
         $T->addRow("Keine Server eingetragen!");
     }
     if ($echo == "" || $echo === true) {
         echo $htmlTableButton . $T;
     } else {
         return $htmlTableButton . $T;
     }
 }
Exemplo n.º 6
0
 function popup($ibanField, $bicField)
 {
     $F = new HTMLForm("ibanCalc", array("land", "kontonummer", "bankleitzahl", "ibanField", "bicField"));
     $F->getTable()->setColWidth(1, 120);
     $I = new IBAN();
     $l = array();
     foreach ($I->Countries() as $c) {
         $IC = new IBANCountry($c);
         if (!$IC->IsSEPA()) {
             continue;
         }
         $l[$c] = ISO3166::getCountryToCode($c) . " ({$c})";
     }
     asort($l);
     $F->setType("land", "select", "DE", $l);
     $F->setType("ibanField", "hidden");
     $F->setType("bicField", "hidden");
     $F->setValue("ibanField", $ibanField);
     $F->setValue("bicField", $bicField);
     $F->setSaveRMEPCR("Berechnen", "", "IBANCalc", "-1", "calc", "function(t){ \$j('#ibanCalcResult').html(t.responseText); }");
     echo $F . "<div id=\"ibanCalcResult\"></div>";
 }
Exemplo n.º 7
0
 public function share()
 {
     $fields = array();
     $US = Users::getUsers();
     while ($U = $US->getNextEntry()) {
         if ($U->getID() == Session::currentUser()->getID()) {
             continue;
         }
         $fields[] = "User" . $U->getID();
     }
     $US->resetPointer();
     echo "<p>In diesem Fenster bestimmen Sie andere Systembenutzer, die auf Ihren Kalender zugreifen können. Falls es andere Systembenutzer gibt.</p>";
     if (count($fields) == 0) {
         return;
     }
     $F = new HTMLForm("shareMailBox", $fields);
     $F->getTable()->setColWidth(1, 120);
     #$F->setValue("MailKontoID", $MailKontoID);
     #$F->setType("MailKontoID", "hidden");
     while ($U = $US->getNextEntry()) {
         $F->setLabel("User" . $U->getID(), $U->A("name"));
         $F->setType("User" . $U->getID(), "select", null, array("none" => "kein Zugriff", "read" => "lesen", "read.create" => "lesen und erstellen"));
     }
     $UD = new mUserdata();
     $shareWith = $UD->getAsArray("shareCalendar");
     foreach ($shareWith as $v => $n) {
         $v = str_replace("shareCalendarTo", "", $v);
         $F->setValue("User{$v}", $n);
     }
     $F->setSaveRMEPCR("Speichern", "", "mKalender", "-1", "saveShare", OnEvent::closePopup("mKalender"));
     echo $F;
 }
Exemplo n.º 8
0
 function getForm()
 {
     if ($this->form != null) {
         return $this->form;
     }
     if ($this->formID == null) {
         $this->formID = "edit" . get_class($this->object);
     }
     $F = new HTMLForm($this->formID == null ? "edit" . get_class($this->object) : $this->formID, $this->attributes == null ? $this->object : $this->attributes, strpos($this->displayMode, "popup") === false ? $this->operationsButton() . $this->name : null);
     $F->getTable()->setColWidth(1, 120);
     $F->getTable()->addTableClass("contentEdit");
     $ID = $this->object->getID();
     if (BPS::getProperty("HTMLGUI", "insertAsNew", false)) {
         $ID = -1;
         BPS::unsetProperty("HTMLGUI", "insertAsNew");
     }
     if ($this->showSave) {
         $F->setSaveClass(get_class($this->object), $ID, $this->functionEntrySave, $this->name);
     }
     $F->isEditable($this->showInputs);
     foreach ($this->object->getA() as $n => $v) {
         $F->setValue($n, $v);
         $F->setLabel($n, str_replace($this->object->getClearClass(), "", $n));
     }
     foreach ($this->types as $n => $l) {
         $F->setType($n, $l, null, isset($this->options[$n]) ? $this->options[$n] : null);
     }
     foreach ($this->labels as $n => $l) {
         $F->setLabel($n, T::_($l));
     }
     foreach ($this->placeholders as $n => $l) {
         $F->setPlaceholder($n, $l);
     }
     foreach ($this->descriptionsField as $n => $l) {
         $F->setDescriptionField($n, T::_($l));
     }
     foreach ($this->parsers as $n => $l) {
         $F->setType($n, "parser", null, array($l, $this->object));
     }
     foreach ($this->spaces as $n => $l) {
         $F->insertSpaceAbove($n, T::_($l));
     }
     foreach ($this->fieldButtons as $n => $B) {
         $F->addFieldButton($n, $B);
     }
     foreach ($this->fieldEvents as $k => $v) {
         $F->addJSEvent($v[0], $v[1], $v[2]);
     }
     foreach ($this->hiddenLines as $n) {
         $F->inputLineStyle($n, "display:none;");
     }
     foreach ($this->inputStyles as $k => $n) {
         $F->setInputStyle($k, $n);
     }
     foreach ($this->autocomplete as $k => $a) {
         $F->setAutoComplete($k, $a[0], $a[1], $a[2]);
     }
     $this->form = $F;
     return $F;
 }
Exemplo n.º 9
0
 function getHTML($id)
 {
     $this->addOrderV3("PatchID");
     $this->lCV3($id);
     $gui = new HTMLGUI();
     $gui->setName("Updates");
     $gui->setAttributes($this->collector);
     $gui->setCollectionOf($this->collectionOf, "Update");
     $gui->setShowAttributes(array("PatchDescription", "PatchExecuted"));
     $gui->setParser("PatchExecuted", "Util::catchParser");
     $gui->setParser("PatchDescription", "mPatchGUI::descriptionParser");
     #$gui->setIsDisplayMode(true);
     #$gui->setEditInDisplayMode(true,"contentLeft");
     #$gui->setDeleteInDisplayMode(false);
     $BXML = new Button("XML\nerzeugen", "empty");
     $BXML->style("float:right;");
     $BXML->windowRme("mPatch", "-1", "getXML", "");
     if (strpos($_SERVER["SCRIPT_FILENAME"], "/nemiah") === false) {
         $BXML = "";
     }
     $BU = new Button("Updates\naktualisieren", "refresh");
     $BU->rmePCR("mPatch", "-1", "update", "", "function(transport){ if(transport.responseText != 'error') " . OnEvent::reload("Right") . " else new Effect.BlindDown('errorMessage'); }");
     $T = new HTMLTable(1, "Einzelne Aktualisierungen");
     $T->addRow(array($BU . $BXML . "\n\t\t\t\t\t<div id=\"errorMessage\" style=\"display:none;color:red;\">Es konnte keine Verbindung zum Updates-Server hergestellt werden.<br />Bitte stellen Sie folgende Voraussetzungen sicher:\n\t\t\t\t\t<ul>\n\t\t\t\t\t\t<li>Der Server mit Ihrer Installation kann eine Verbindung ins Internet aufbauen.</li>\n\t\t\t\t\t\t<li>Sie benutzen die aktuellste Version des Update-Plugins.</li>\n\t\t\t\t\t</ul></div>"));
     $html = OnEvent::script("var Patch = { popup: { 'width':600, 'hPosition': 'center', hasX: false } }") . $T;
     /*"
     		<table>
     			<colgroup>
     				<col class=\"backgroundColor3\" />
     			</colgroup>
     			<tr>
     				<td>
     					".(strpos($_SERVER["SCRIPT_FILENAME"], "/nemiah") !== false ? "<input
     						style=\"float:right;\"
     						onclick=\"windowWithRme('mPatch','','getXML','');\"
     						type=\"button\"
     						class=\"bigButton backgroundColor2\"
     						value=\"XML\nerzeugen\"
     					/>" : "")."
     					<input
     						style=\"background-image:url(./images/navi/refresh.png);\"
     						onclick=\"rme('mPatch','','update','','if(transport.responseText != \'error\') contentManager.reloadFrameRight(); else new Effect.BlindDown(\'errorMessage\');');\"
     						type=\"button\"
     						class=\"bigButton backgroundColor2\"
     						value=\"Updates\naktualisieren\"
     					/>
     				</td>
     			</tr>
     		</table>";*/
     #else
     #	$html = "";
     $F = new HTMLForm("updateForm", array("file"), "Die Anwendung aktualisieren");
     $F->getTable()->setColWidth(1, 120);
     $F->setType("file", "file");
     $F->setLabel("file", "Paket");
     $F->addJSEvent("file", "onChange", "Overlay.showDark(0.1, 0.8); " . OnEvent::popup("Anwendungsaktualisierung", "mPatch", "-1", "processUpdate", array("fileName"), "", "Patch.popup"));
     $F->setDescriptionField("file", "Hier aktualisieren Sie Ihre komplette Anwendung mit einem neuen Paket, das Sie von Furtmeier Hard- und Software erhalten haben.<br /><br />Sie können damit sowohl neue Versionen (Update) einspielen als auch eine mit Plugins erweiterte Version (Upgrade) einrichten.<br /><br />Alle Dateien werden vorher gesichert und alle eingetragenen Daten bleiben erhalten.");
     try {
         return ($id == -1 ? $F . "<div style=\"height:30px;\"></div>" . $html : "") . $gui->getBrowserHTML($id);
     } catch (Exception $e) {
     }
     return $html;
 }
Exemplo n.º 10
0
 public function manageMailsettings()
 {
     $F = new HTMLForm("mailsettings", array("systemEmail"));
     $F->getTable()->setColWidth(1, 120);
     $F->useRecentlyChanged();
     $F->setValue("systemEmail", mUserdata::getGlobalSettingValue("mailSystemEmail", ""));
     $F->setLabel("systemEmail", "System E-Mail");
     $F->setDescriptionField("systemEmail", "Absender-Adresse für Systemnachrichten");
     $F->setSaveRMEPCR("Speichern", "", "mInstallation", -1, "manageMailsettingsSave", OnEvent::closePopup("mInstallation"));
     echo $F;
 }
Exemplo n.º 11
0
 public function getPopupManager($rootDir = null, $class = null, $classID = null, $usePool = false, $fieldDefaultFile = "", $uploadTargetFilename = null)
 {
     if ($rootDir != null) {
         $T = new HTMLTable(1);
         #$rel = "$rootDir";
         $root = FileStorage::getFilesDir() . $rootDir;
         $_SESSION["BPS"]->setProperty("mFileGUI", "path", $root);
         $_SESSION["BPS"]->setProperty("mFileGUI", "root", $root);
         $F = new File($root);
         $F->loadMe();
         if ($F->getA() == null) {
             if (is_writable(FileStorage::getFilesDir())) {
                 mkdir($root, 0777, true);
             } else {
                 $B = new Button("", "stop");
                 $B->type("icon");
                 $B->style("float:left;margin-right:10px;");
                 $T->addRow($B . "Das Verzeichnis <code>{$rootDir}</code> existiert nicht und kann nicht automatisch angelegt werden, da keine Schreibberechtigung für <code>specifics</code> vorliegt.");
                 die($T);
             }
         }
     }
     $bps = $this->getMyBPSData();
     if (strpos($bps["path"], $bps["root"]) === false) {
         $bps["path"] = $bps["root"];
     }
     if ($bps != -1 and isset($bps["path"])) {
         $this->setDir($bps["path"]);
     }
     $this->hideDirs(true);
     $gui = new HTMLGUIX();
     $gui->object($this);
     $cols = array();
     if ($fieldDefaultFile != "") {
         $C = new $class($classID);
         self::$fieldDefaultFile = array($C, $C->A($fieldDefaultFile), $fieldDefaultFile);
         $cols[] = "isDefault";
         $gui->colWidth("isDefault", 20);
         $gui->parser("isDefault", "mFileGUI::parserDefault");
     }
     $cols[] = "FileName";
     $gui->attributes($cols);
     $gui->parser("FileName", "mFileGUI::nameParser2");
     $gui->options(true, false, false);
     $gui->name("Datei");
     $gui->addToEvent("onDelete", OnEvent::reloadPopup("mFile"));
     $oldFiles = "";
     if ($class != null and $classID != null) {
         $AC = anyC::get("Datei", "DateiClassID", $classID);
         $AC->addAssocV3("DateiClass", "=", $class);
         $oldFiles = new HTMLTable(2, "Verknüpfte Dateien");
         while ($F = $AC->getNextEntry()) {
             $BDL = new Button("Datei herunterladen", "./plugins/Files/download.png", "icon");
             $BDL->onclick("windowWithRme('File','" . $F->A("DateiPath") . "','download','');");
             $BDL->style("float:right;");
             $oldFiles->addRow(array($BDL . $F->A("DateiName")));
         }
     }
     $BPool = new Button("Pool\nanzeigen", "./lightCRM/Mail/images/attach.png");
     $BPool->style("float:right;margin:10px;");
     $BPool->onclick(OnEvent::popupSidePanel("mFile", -1, "sidePanelPool", array("'{$class}Pool'", "'{$rootDir}'")));
     if ($usePool and $rootDir) {
         echo $BPool . "<div style=\"clear:both;\"></div>";
         if (file_exists(FileStorage::getFilesDir() . "{$class}Pool")) {
             echo OnEvent::script("window.setTimeout(function(){ if(\$j('#editDetailsmFileSidePanel').length > 0) return; " . OnEvent::popupSidePanel("mFile", -1, "sidePanelPool", array("'{$class}Pool'", "'{$rootDir}'")) . "}, 100);");
         }
     }
     $F = new HTMLForm("fileUpload", array("datei"));
     $s = array("path" => $bps["path"], "class" => "File");
     if ($uploadTargetFilename != null) {
         $s["targetFilename"] = $uploadTargetFilename;
     }
     $F->setType("datei", "file", null, $s);
     $F->addJSEvent("datei", "onChange", OnEvent::reloadPopup("mFile"));
     $F->getTable()->setColWidth(1, 120);
     echo "<p class=\"prettyTitle\">/" . basename($bps["path"]) . "</p><p style=\"color:grey;margin-top:-15px;margin-bottom:10px;\"><small>" . dirname(realpath($bps["path"])) . "</small></p>" . $F . $gui->getBrowserHTML(-1) . $oldFiles;
 }
Exemplo n.º 12
0
 function authenticationPopup()
 {
     $allowedUsers = Environment::getS("allowedUsers", null);
     if ($allowedUsers !== null) {
         return;
     }
     $F = new HTMLForm("appserver", array("appServer"), "Application Server");
     $F->useRecentlyChanged();
     $F->setLabel("appServer", "App-Server");
     if (function_exists("ldap_connect")) {
         $F->getTable()->setTableStyle("margin-bottom:30px;");
     }
     $F->getTable()->setColWidth(1, 120);
     $F->setValue("appServer", mUserdata::getGlobalSettingValue("AppServer", ""));
     $F->setDescriptionField("appServer", "Wenn Sie einen Application Server betreiben, tragen Sie hier bitte die URL ein, um die Benutzer mit diesem Server zu authentifizieren.");
     $F->setSaveRMEPCR("Speichern", "", "Users", "", "saveAppServer", OnEvent::closePopup("Users"));
     echo $F;
     if (!function_exists("ldap_connect")) {
         return;
     }
     echo "<span></span><div class=\"backgroundColor1 Tab\"><p>Active Directory</p></div>";
     $LD = LoginData::get("ADServerUserPass");
     BPS::setProperty("LoginDataGUI", "preset", "adServer");
     $gui = new LoginDataGUI($LD == null ? -1 : $LD->getID());
     $gui->loadMeOrEmpty();
     if ($LD != null) {
         $gui->setA($LD->getA());
     }
     $gui->getPopup();
 }
Exemplo n.º 13
0
 function getEditHTML()
 {
     $this->object->loadMeOrEmpty();
     if ($this->object->getID() == -1) {
         $this->addToEvent("onSave", "\$('contentLeft').update('');");
     }
     $F = new HTMLForm($this->formID == null ? "edit" . get_class($this->object) : $this->formID, $this->attributes == null ? $this->object : $this->attributes, strpos($this->displayMode, "popup") === false ? $this->operationsButton() . $this->name : null);
     $F->getTable()->setColWidth(1, 120);
     if ($this->showSave) {
         $F->setSaveClass(get_class($this->object), $this->object->getID(), $this->functionEntrySave, $this->name);
     }
     $F->isEditable($this->showInputs);
     foreach ($this->object->getA() as $n => $v) {
         $F->setValue($n, $v);
         $F->setLabel($n, str_replace($this->object->getClearClass(), "", $n));
     }
     foreach ($this->types as $n => $l) {
         $F->setType($n, $l, null, isset($this->options[$n]) ? $this->options[$n] : null);
     }
     foreach ($this->labels as $n => $l) {
         $F->setLabel($n, $l);
     }
     foreach ($this->descriptionsField as $n => $l) {
         $F->setDescriptionField($n, $l);
     }
     foreach ($this->parsers as $n => $l) {
         $F->setType($n, "parser", null, array($l, $this->object));
     }
     foreach ($this->spaces as $n => $l) {
         $F->insertSpaceAbove($n, $l);
     }
     foreach ($this->fieldButtons as $n => $B) {
         $F->addFieldButton($n, $B);
     }
     foreach ($this->fieldEvents as $k => $v) {
         $F->addJSEvent($v[0], $v[1], $v[2]);
     }
     foreach ($this->hiddenLines as $n) {
         $F->inputLineStyle($n, "display:none;");
     }
     foreach ($this->inputStyles as $k => $n) {
         $F->setInputStyle($k, $n);
     }
     foreach ($this->autocomplete as $k => $a) {
         $F->setAutoComplete($k, $a[0], $a[1]);
     }
     return $this->topButtons() . $this->sideButtons() . $F;
 }
Exemplo n.º 14
0
 public function editRepeatable($todoID)
 {
     $F = new HTMLForm("RepeatableForm", array("TodoRepeat", "TodoRepeatWeekOfMonth", "TodoRepeatDayOfWeek", "TodoRepeatInterval", "TodoRepeatUntil"), "Wiederholungen");
     $F->getTable()->setColWidth(1, 120);
     $T = new Todo($todoID);
     $F->setValues($T);
     $F->setValue("TodoRepeatUntil", Util::CLDateParserE($T->A("TodoRepeatUntil")));
     $F->setLabel("TodoRepeat", "Wiederholen");
     $F->setLabel("TodoRepeatWeekOfMonth", "Tag");
     $F->setLabel("TodoRepeatDayOfWeek", "Tage");
     $F->setLabel("TodoRepeatInterval", "Intervall");
     $F->setLabel("TodoRepeatDayOfWeek", "Tage");
     $F->setLabel("TodoRepeatUntil", "Bis");
     $F->setType("TodoRepeatInterval", "select", null, array("Wöchentlich", "Jede 2. Woche", "Jede 3. Woche", "Jede 4. Woche"));
     $F->setType("TodoRepeatUntil", "date");
     #$currentWeek = ceil((date("d", $T->A("TodoFromDay")) - date("w", $T->A("TodoFromDay")) - 1) / 7) + 1;
     #echo $currentWeek;
     $D = new Datum($T->A("TodoFromDay"));
     $nthDay = $D->getNthDayOfMonth();
     if ($nthDay > 4) {
         $nthDay = 4;
     }
     $weeks = array(0 => "am " . date("d", $T->A("TodoFromDay")) . ". jeden Monats");
     $weeks[$nthDay] = "jeden {$nthDay}. " . Util::CLWeekdayName(date("w", $T->A("TodoFromDay"))) . " des Monats";
     $weeks[127] = "am letzten Tag des Monats";
     $F->setType("TodoRepeat", "select", "", Todo::$repeatTypes);
     $F->setType("TodoRepeatWeekOfMonth", "select", "", $weeks);
     #$F->setType("TodoRepeatDayOfWeek", "checkbox");
     $F->setType("TodoRepeatDayOfWeek", "parser", $T->A("TodoRepeatDayOfWeek"), array("mTodoGUI::parserDayOfWeek"));
     $F->hideIf("TodoRepeat", "!=", "monthly", "onchange", array("TodoRepeatWeekOfMonth"));
     $F->hideIf("TodoRepeat", "!=", "daily", "onchange", array("TodoRepeatDayOfWeek"));
     $F->hideIf("TodoRepeat", "!=", "weekly", "onchange", array("TodoRepeatInterval", "TodoRepeatUntil"));
     $F->setSaveClass("Todo", $todoID, "function(){ /*\$j('#eventAdditionalContent').slideUp();*/ contentManager.reloadFrame('contentScreen'); Kalender.refreshInfoPopup(); }", "Aktivität");
     return $F;
 }