本文整理汇总了PHP中HTMLForm::setLabel方法的典型用法代码示例。如果您正苦于以下问题:PHP HTMLForm::setLabel方法的具体用法?PHP HTMLForm::setLabel怎么用?PHP HTMLForm::setLabel使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类HTMLForm
的用法示例。
在下文中一共展示了HTMLForm::setLabel方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: getHTML
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;
}
示例2: getConfigPopup
/**
* 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> <br />\n\t\t\t\t\t<small style=\"color:grey;\" id=\"APName" . $S->getID() . "\">" . ($S->A("xCalServerActive") == "1" ? "Import aktiviert" : "Import deaktiviert") . " </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;
}
}
示例3: getContextMenuHTML
public function getContextMenuHTML($identifier)
{
$F = new HTMLForm("dlSettings", array("dlCover"));
$F->setType("dlCover", "checkbox");
$F->setLabel("dlCover", "DL Cover?");
$F->setValue("dlCover", mUserdata::getGlobalSettingValue("trinityDBdlCover", "0"));
$F->setSaveRMEPCR("save", "./images/i2/save.gif", "Serie", "-1", "saveContextMenu", "function() { phynxContextMenu.stop(); }");
echo $F;
}
示例4: formLogin
function formLogin()
{
$T = new HTMLForm("login", array("benutzer", "password", "action"), "Anmeldung");
$T->setValue("action", "login");
$T->setType("action", "hidden");
$T->setType("password", "password");
$T->setLabel("password", "Passwort");
$T->setSaveCustomerPage("Anmelden", "", false, "function(){ document.location.reload(); }");
return $T . OnEvent::script("\$j(function(){ \$j('[name=benutzer]').trigger('focus'); });");
}
示例5: getCMSHTML
function getCMSHTML()
{
if (!$this->loggedIn) {
$T = new HTMLForm("login", array("benutzer", "password", "action"), "Anmeldung");
$T->setValue("action", "login");
$T->setType("action", "hidden");
$T->setType("password", "password");
$T->setLabel("password", "Passwort");
$T->setSaveCustomerPage("Anmelden", "", false, "function(){ document.location.reload(); }");
return $T;
}
$BRL = new Button("Aktualisieren");
$BRL->className("submitFormButton");
$BRL->onclick("document.location.reload();");
$BRL->style("float:right;margin-top:0px;");
$BRA = new Button("Abmelden");
$BRA->className("submitFormButton");
$BRA->onclick("CustomerPage.rme('logout', {}, function(transport){ document.location.reload(); });");
$BRA->style("background-color:#DDD;color:grey;margin-top:0px;float:right;margin-right:20px;");
return "\n\t\t<div style=\"max-width:1200px;\">\n\t\t\t<div style=\"display:inline-block;width:48%;vertical-align:top;margin-right:3%;\" id=\"contentLeft\">\n\t\t\t\t<h1>Auftrag</h1>\n\t\t\t\t<div class=\"content\" style=\"overflow:auto;\">\n\t\t\t\t\t" . $this->getAuftrag(array("GRLBMID" => 0)) . "\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t\t<div style=\"display:inline-block;width:48%;vertical-align:top;\" id=\"contentRight\">\n\t\t\t\t<h1>{$BRL}{$BRA}Lieferscheine</h1>\n\t\t\t\t<div class=\"content\" style=\"overflow:auto;\">\n\t\t\t\t\t" . $this->getLieferscheine(array()) . "\n\t\t\t\t</div>\n\t\t\t</div>" . OnEvent::script("\n\t\t\t\t\$('#contentRight .content .tableForSelection ').parent().css('max-height', \$(window).height() - \$('h1').outerHeight() - 40 - \$('#contentRight .Tab').outerHeight())\n\t\t\t\t\$('#contentLeft .content ').css('height', \$(window).height() - \$('h1').outerHeight() - 25)");
}
示例6: showAddress
function showAddress()
{
$html = "<script type=\"text/javascript\">\n\t\t\$(function() {\n\t\t\tjQuery.validator.addMethod('firmOrName', function(value, element, params) {\n\t\t\t\t\n\t\t\t\tif(\$('input[name=firma]').val() != '')\n\t\t\t\t\treturn true;\n\t\t\t\t\n\t\t\t\tif(\$('input[name=nachname]').val() == '')\n\t\t\t\t\treturn false;\n\t\t\t\t\n\t\t\t\tif(\$('input[name=vorname]').val() == '')\n\t\t\t\t\treturn false;\n\t\t\t\t\n\t\t\t\treturn true;\n\t\t\t}, 'Bitte geben Sie Ihren Firmennamen <b>oder</b> Ihren Vor- und Nachnamen ein.');\n\t\t});\n\t\t\$(function() {\n\t\t\t\$('#ticketAddress').validate({\n\t\t\t\trules: {\n\t\t\t\t\tnachname: {firmOrName: true},\n\t\t\t\t\t/*vorname: {firmOrName: true},\n\t\t\t\t\tfirma: {firmOrName: true},*/\n\t\t\t\t\tstrasse: 'required',\n\t\t\t\t\tnr: 'required',\n\t\t\t\t\tplz: 'required',\n\t\t\t\t\tort: 'required',\n\t\t\t\t\temail: {\n\t\t\t\t\t\trequired: true,\n\t\t\t\t\t\temail: true\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\tgroups: {\n\t\t\t\t\tstrasseNr: 'nr strasse',\n\t\t\t\t\tplzOrt: 'ort plz'\n\t\t\t\t},\n\n\t\t\t\tmessages: {\n\t\t\t\t\tstrasse: 'Bitte geben Sie Straße und Hausnummer ein',\n\t\t\t\t\tnr: 'Bitte geben Sie Straße und Hausnummer ein',\n\t\t\t\t\tplz: 'Bitte geben Sie Postleitzahl und Ort ein',\n\t\t\t\t\tort: 'Bitte geben Sie Postleitzahl und Ort ein',\n\t\t\t\t\temail: {required: 'Bitte geben Sie Ihre E-Mail-Adresse ein', email: 'Bitte geben Sie Ihre gültige E-Mail-Adresse ein'}\n\t\t\t\t},\n\t\t\t\t\n\t\t\t\terrorPlacement: function(error, element) {\n\t\t\t\t\tvar name = element.attr('name');\n\t\t\t\t\tif (name === 'strasse' || name === 'nr') {\n\t\t\t\t\t\terror.insertAfter('input[name=nr]');\n\t\t\t\t\t\treturn;\n\t\t\t\t\t} \n\t\t\t\t\t\n\t\t\t\t\tif (name === 'plz' || name === 'ort') {\n\t\t\t\t\t\terror.insertAfter('input[name=ort]');\n\t\t\t\t\t\treturn\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\terror.insertAfter(element);\n\t\t\t\t\t\n\t\t\t\t}\n\n\t\t\t});\n\t\t});\n\t\t\n\t\t</script>";
$F = new HTMLForm("ticketAddress", array("firma", "vorname", "nachname", "email", "strasse", "plz", "land", "action"), "Rechnungsdaten");
$F->setType("land", "select", "DE", ISO3166::getCountries());
$F->setType("strasse", "parser", null, array("CCTicketShop::strasseParser"));
$F->setType("plz", "parser", null, array("CCTicketShop::plzParser"));
$F->setType("action", "hidden");
$F->insertSpaceAbove("strasse", "Adresse");
$F->insertSpaceAbove("email", "Kontakt");
$F->setLabel("email", "E-Mail");
$F->setDescriptionField("email", "An diese Adresse werden die Rechnung und die Tickets verschickt.");
#$F->setLabel("tel", "Telefon");
$F->setLabel("strasse", "Straße/Nr");
$F->setLabel("plz", "PLZ/Ort");
$F->setValue("action", "handleAddress");
if (isset($_SESSION["ticketDataAddress"])) {
foreach ($_SESSION["ticketDataAddress"] as $k => $v) {
$F->setValue($k, $v);
}
}
$F->setSaveCustomerPage("Weiter", null, true, "function(){ document.location.reload(); }");
$html .= $F;
return $html;
}
示例7: getEditTableHTML
public function getEditTableHTML($cols = 2)
{
BPS::unsetProperty($this->className . "GUI", "edit");
if ($this->attributes == null) {
$this->attributes = PMReflector::getAttributesArrayAnyObject($this->object->getA());
}
if ($this->name == null) {
$this->name = $this->className;
}
$BA = $this->getAbortButton();
if (isset($this->features["CRMEditAbove"])) {
$BA->style("float:left;margin-left:10px;margin-top:10px;");
}
$abort = "<div>{$BA}</div><div style=\"clear:left;height:10px;\"></div>";
$tab = new HTMLForm($this->className . "Form", $this->attributes, $this->name . " editieren:");
if ($cols != 2) {
$tab->cols($cols);
}
foreach ($this->labels as $k => $v) {
$tab->setLabel($k, $v);
}
foreach ($this->types as $k => $v) {
$tab->setType($k, $v, null, isset($this->options[$k]) ? $this->options[$k] : null);
}
foreach ($this->spaces as $k => $v) {
$tab->insertSpaceAbove($k, $v);
}
foreach ($this->autocomplete as $k => $a) {
$tab->setAutoComplete($k, $a[0], $a[1]);
}
foreach ($this->fieldButtons as $k => $B) {
$tab->addFieldButton($k, $B);
}
foreach ($this->parsers as $n => $l) {
$tab->setType($n, "parser", null, array($l, $this->object));
}
$tab->setValues($this->object);
if ($this->object->getID() == -1) {
$save = $this->functionSaveNew;
} else {
$save = $this->functionSave;
}
$tab->setSaveClass($this->className, $this->object->getID(), str_replace(array("%CLASSNAME", "%CLASSID"), array($this->className, $this->object->getID()), $save), $this->name);
return $abort . $tab;
}
示例8: getForm
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;
}
示例9: showRegistration
function showRegistration()
{
$html = "<script type=\"text/javascript\">\n\t\t\$(function() {\n\t\t\t\$('#registrierungAdresse').validate({\n\t\t\t\trules: {\n\t\t\t\t\tfirma: 'required',\n\t\t\t\t\tstrasse: 'required',\n\t\t\t\t\tnr: 'required',\n\t\t\t\t\tplz: 'required',\n\t\t\t\t\tort: 'required',\n\t\t\t\t\t/*email: {\n\t\t\t\t\t\trequired: true,\n\t\t\t\t\t\temail: true\n\t\t\t\t\t},*/\n\t\t\t\t\tblz: 'required',\n\t\t\t\t\tkontonummer: 'required',\n\t\t\t\t\tuserVorNachname: 'required',\n\t\t\t\t\tuserEmail: {\n\t\t\t\t\t\trequired: true,\n\t\t\t\t\t\temail: true\n\t\t\t\t\t},\n\t\t\t\t\tuserUsername: 'required',\n\t\t\t\t\tuserPassword: {\n\t\t\t\t\t\trequired: true,\n\t\t\t\t\t\tminlength: 5\n\t\t\t\t\t},\n\t\t\t\t\tconfirmUserPassword: {\n\t\t\t\t\t\trequired: true,\n\t\t\t\t\t\tminlength: 5,\n\t\t\t\t\t\tequalTo: '#registrierungAdresse input[name=userPassword]'\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\tmessages: {\n\t\t\t\t\tfirma: 'Bitte geben Sie den Namen Ihrer Firma ein',\n\t\t\t\t\tstrasse: 'Bitte geben Sie die Straße Ihrer Firma ein',\n\t\t\t\t\tnr: 'Bitte geben Sie die Hausnummer Ihrer Firma ein',\n\t\t\t\t\tplz: 'Bitte geben Sie Ihre Postleitzahl Ihrer Firma ein',\n\t\t\t\t\tort: 'Bitte geben Sie Ihren Ort Ihrer Firma ein',\n\t\t\t\t\t//email: {required: 'Bitte geben Sie Ihre gültige E-Mail-Adresse ein', email: 'Bitte geben Sie Ihre gültige E-Mail-Adresse ein'},\n\t\t\t\t\tblz: 'Bitte geben Sie die Bankleitzahl Ihrer Firma ein',\n\t\t\t\t\tkontonummer: 'Bitte geben Sie die Kontonummer Ihrer Firma ein',\n\t\t\t\t\tuserVorNachname: 'Bitte geben Sie Ihren Vor- und Nachnamen ein',\n\t\t\t\t\tuserUsername: 'Bitte geben Sie einen Benutzernamen ein',\n\t\t\t\t\tuserEmail: {required: 'Bitte geben Sie Ihre gültige E-Mail-Adresse ein', email: 'Bitte geben Sie Ihre gültige E-Mail-Adresse ein'},\n\t\t\t\t\tconfirmUserPassword: {required: 'Bitte geben Sie Ihr Passwort ein', minlength: 'Bitte geben Sie mindestens fünf Zeichen ein', equalTo: 'Die Passwörter stimmen nicht überein'},\n\t\t\t\t\tuserPassword: {required: 'Bitte geben Sie Ihr Passwort ein', minlength: 'Bitte geben Sie mindestens fünf Zeichen ein'}\n\t\t\t\t}\n\t\t\t});\n\t\t\t\n\t\t\t\t\n\t\t\t\$('#registrierungAdresse input[name=userUsername]').focus(function() {\n\t\t\t\tvar vorNachname = \$('#registrierungAdresse input[name=userVorNachname]').val();\n\t\t\t\tif(vorNachname && !this.value) {\n\t\t\t\t\tthis.value = vorNachname.replace(' ', '.').toLowerCase();\n\t\t\t\t}\n\t\t\t});\n\t\t});\n\t\t\n\t\t</script>";
$html .= "<h1>Registrierung für PDFix</h1>";
$F = new HTMLForm("registrierungAdresse", array("firma", "strasse", "nr", "plz", "ort", "tel", "blz", "kontonummer", "zahlungsweise", "userVorNachname", "userUsername", "userPassword", "confirmUserPassword", "userEmail", "action"));
#$F->setType("anrede", "select", "3", Adresse::getAnreden());
$F->insertSpaceAbove("vorname");
$F->insertSpaceAbove("strasse", "Adresse");
$F->insertSpaceAbove("email", "Kontakt");
$F->insertSpaceAbove("blz", "Bank");
$F->insertSpaceAbove("firma", "<h2>Abrechnungsdaten</h2>");
$F->insertSpaceAbove("userVorNachname", "<h2 style=\"margin-top:20px;\">Benutzerdaten</h2>");
$F->insertSpaceAbove("zahlungsweise", "<h2 style=\"margin-top:20px;\">Zahlungsweise</h2>");
$F->setSaveCustomerPage("Jetzt registrieren", null, true, "function(){ document.location.href='./index.php?CC=RegistrationPDFix&thankR=1'; }");
$F->setLabel("email", "E-Mail");
$F->setLabel("tel", "Telefon");
$F->setLabel("strasse", "Straße");
$F->setLabel("userVorNachname", "Name");
$F->setLabel("userUsername", "Benutzername");
$F->setLabel("userPassword", "Passwort");
$F->setLabel("confirmUserPassword", "Passwort wiederholen");
$F->setLabel("userEmail", "E-Mail");
$kosten1Monat = Util::CLFormatCurrency(mUserdata::getUDValueS("PDFixKostenProMonat", "0") * 1, true);
$kosten3Monat = Util::CLFormatCurrency(mUserdata::getUDValueS("PDFixKostenPro3Monat", "0") * 1, true);
$kosten6Monat = Util::CLFormatCurrency(mUserdata::getUDValueS("PDFixKostenPro6Monat", "0") * 1, true);
$F->setType("confirmUserPassword", "password");
$F->setType("userPassword", "password");
$F->setType("action", "hidden");
$F->setType("zahlungsweise", "select", "1", array("1" => "Monatlich ({$kosten1Monat} + MwSt)", "3" => "Vierteljährlich ({$kosten3Monat} + MwSt)", "6" => "Halbjährlich ({$kosten6Monat} + MwSt)"));
$F->setValue("action", "register");
$html .= $F;
return $html;
}
示例10: alterAddress
public function alterAddress($data)
{
$Adresse = new Adresse($data["AdresseID"]);
$F = new HTMLForm("alterAddress", array("firma", "vorname", "nachname", "strasse", "nr", "plz", "ort", "action", "AdresseID"));
$F->setValues($Adresse);
$F->setValue("action", "alterAddress");
$F->setValue("AdresseID", $data["AdresseID"]);
$F->setType("action", "hidden");
$F->setType("AdresseID", "hidden");
$F->setLabel("strasse", "Straße");
$F->setSaveCustomerPage("Speichern", "", false, "function(){ CustomerPage.closePopup(); CustomerPage.rme('getAuftrag', {GRLBMID: {$data['GRLBMID']}}, function(transport){ \$('#contentLeft').html(transport); }); }");
echo $F;
}
示例11: getLoginScreen
function getLoginScreen()
{
$T = new HTMLForm("login", array("benutzer", "password", "action"), "Anmeldung");
$T->setValue("action", "login");
$T->setType("action", "hidden");
$T->setType("password", "password");
$T->setLabel("password", "Passwort");
$T->setSaveCustomerPage("Anmelden", "", false, "function(){ document.location.reload(); }");
return $T;
}
示例12: authenticationPopup
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();
}
示例13: getEditHTML
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;
}
示例14: editRepeatable
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;
}
示例15: testMailGUI
public function testMailGUI()
{
$F = new HTMLForm("mailTest", array("mailfrom", "mailto"));
$F->setSaveRMEPCR("Mailversand testen", "./images/i2/save.gif", "mInstallation", -1, "testMail", "function(transport){ \$('mailTestDetailsContent').update(transport.responseText); }");
$F->setLabel("mailfrom", "Absender");
$F->setDescriptionField("mailfrom", "E-Mail-Adresse");
$F->setLabel("mailto", "Empfänger");
$F->setDescriptionField("mailto", "E-Mail-Adresse");
echo $F . "<div id=\"mailTestDetailsContent\"></div>";
}