本文整理汇总了PHP中OnEvent类的典型用法代码示例。如果您正苦于以下问题:PHP OnEvent类的具体用法?PHP OnEvent怎么用?PHP OnEvent使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了OnEvent类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: check
public function check($touch = false)
{
$mbox = $this->connection();
#echo "<h1>Nachrichten in INBOX</h1><div style=\"overflow:auto;max-height:400px;\"><pre>";
$MC = imap_check($mbox);
$T = new HTMLTable(1, $touch ? "Mails" : "");
$T->setTableStyle("font-size:11px;");
$T->useForSelection();
$start = $MC->Nmsgs - 10;
if ($start < 1) {
$start = 1;
}
$result = imap_fetch_overview($mbox, "{$start}:{$MC->Nmsgs}", 0);
$result = array_reverse($result);
foreach ($result as $overview) {
#print_r($overview);
$T->addRow(array("\n\t\t\t\t<small style=\"color:grey;float:right;\">" . Util::CLDateParser($overview->udate) . "</small>\n\t\t\t\t" . str_replace("\"", "", $this->decodeBlubb($overview->from)) . "<br />\n\t\t\t\t<small style=\"color:grey;\">" . substr($this->decodeBlubb($overview->subject), 0, 50) . "</small>"));
$T->addCellEvent(1, "click", "\$j('#MailFrame').attr('src', './interface/rme.php?class=MailCheck&constructor=" . $this->getID() . "&method=showMailBody¶meters=\\'{$overview->uid}\\'');");
}
imap_close($mbox);
#echo "</pre></div>";
$BC = "";
if ($touch) {
$BC = new Button("Fenster\nschließen", "stop");
$BC->style("float:right;margin:10px;");
$BC->onclick(OnEvent::closePopup("MailCheck"));
}
echo "<div style=\"float:right;width:300px;\">";
echo $BC;
echo "<p>{$MC->Nmsgs} Nachricht" . ($MC->Nmsgs == 1 ? "" : "en") . "</p><div style=\"clear:both;\"></div>";
echo $T;
echo "</div>";
echo "\n\t\t\t<div style=\"border-right-style:solid;border-right-width:1px;width:699px;\" class=\"borderColor1\">\n\t\t\t\t<iframe id=\"MailFrame\" style=\"border:0px;width:699px;height:520px;\" src=\"./fheME/MailCheck/Home/index.html\"></iframe>\n\t\t\t</div>";
echo "<div style=\"clear:both;\"></div>";
}
示例2: getCMSHTML
function getCMSHTML()
{
$key = substr(Util::eK(), 0, 5);
if (!isset($_GET["key"]) or $key != $_GET["key"]) {
return "<span style=\"color:red;\">Bitte geben Sie den richtigen Schlüssel zum Aufrufen der Seite in der Adresszeile an.</span>";
}
registerClassPath("Einkaufszettel", Util::getRootPath() . "fheME/Einkaufszettel/Einkaufszettel.class.php");
/*
registerClassPath("GSRaumgruppe", Util::getRootPath()."FCalc/GSRaumgruppe/GSRaumgruppe.class.php");
registerClassPath("ObjektL", Util::getRootPath()."personalKartei/ObjekteL/ObjektL.class.php");
registerClassPath("mGSTaetigkeitGUI", Util::getRootPath()."FCalc/GSTaetigkeit/mGSTaetigkeitGUI.class.php");
registerClassPath("GSTaetigkeit", Util::getRootPath()."FCalc/GSTaetigkeit/GSTaetigkeit.class.php");
*
*/
$AC = anyC::get("Einkaufszettel");
$AC->addAssocV3("EinkaufszettelBought", "=", "0");
$AC->addOrderV3("EinkaufszettelName");
$html = "<style type=\"text/css\">\n\t\t\t\tbody {\n\t\t\t\t\tmargin:0px;\n\t\t\t\t\tmargin-top:10px;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t.entry {\n\t\t\t\t\tpadding:10px;\n\t\t\t\t\tborder-top-width:1px;\n\t\t\t\t\tborder-top-style:solid;\n\t\t\t\t\tborder-bottom-width:1px;\n\t\t\t\t\tborder-bottom-style:solid;\n\t\t\t\t\tfont-size:2em;\n\t\t\t\t\tmargin-bottom:10px;\n\t\t\t\t\tcursor:pointer;\n\t\t\t\t\t-webkit-touch-callout: none;\n\t\t\t\t\t-webkit-user-select: none;\n\t\t\t\t\t-khtml-user-select: none;\n\t\t\t\t\t-moz-user-select: none;\n\t\t\t\t\t-ms-user-select: none;\n\t\t\t\t\tuser-select: none;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t.entryTouch {\n\t\t\t\t\tbackground-color: #c5d674;\n\t\t\t\t}\n\t\t\t</style>\n\t\t\t<div id=\"einkaufsliste\">";
while ($E = $AC->getNextEntry()) {
$html .= "<div id=\"entry" . $E->getID() . "\" onclick=\"CustomerPage.rme('setBought', [" . $E->getID() . "], function(){ \$('#entry" . $E->getID() . "').remove(); if(\$('#einkaufsliste .nonEmpty').length == 0) \$('#emptyEntry').show(); });\" class=\"nonEmpty entry backgroundColor1 borderColor1\">" . ($E->A("EinkaufszettelMenge") > 1 ? $E->A("EinkaufszettelMenge") . " x " : "") . $E->A("EinkaufszettelName") . ($E->A("EinkaufszettelNameDetails") != "" ? "<br /><small style=\"color:grey;\">" . $E->A("EinkaufszettelNameDetails") . "</small>" : "") . "</div>";
}
$html .= "<div style=\"" . ($AC->numLoaded() == 0 ? "" : "display:none;") . "\" class=\"entry backgroundColor1 borderColor1\" id=\"emptyEntry\">Die Einkaufsliste enthält keine Einträge.<br /><small style=\"color:grey;\">" . Util::CLDateParser(time()) . "</small></div>";
$html .= "</div>";
return $html . OnEvent::script("\$('.entry').hammer().on('touch', function(){ \$(this).addClass('entryTouch'); }); \$('.entry').hammer().on('release', function(){ \$(this).removeClass('entryTouch'); });");
}
示例3: message
function message()
{
$BS = new Button("Nachricht", "comment_alt2_stroke", "iconicL");
$BS->style("float:left;");
$read = false;
$message = $this->messageParser();
#$this->A("NuntiusMessage");
if ($this->A("NuntiusRead") > "0") {
$read = true;
$BS = new Button("Nachricht", "check", "iconicL");
$BS->style("float:left;color:darkgreen;");
$ex = explode("\n", $message);
$message = "<span style=\"color:grey;\">" . $ex[0];
if (isset($ex[1])) {
$message .= " …";
}
$message .= "</span>";
}
$from = "";
$ex = explode(":", $this->A("NuntiusSender"));
if ($ex[0] == "Device") {
$D = new Device($ex[1]);
$from = $D->A("DeviceName");
}
if ($ex[0] == "FritzBox") {
$from = $this->A("NuntiusSender");
}
if ($ex[0] == "Mobile") {
$from = $this->A("NuntiusSender");
}
return "\n\t\t\t<div id=\"Nuntius" . $this->getID() . "\" style=\"cursor:pointer;" . ($read ? "" : "background-color:#efefef;") . "min-height:40px;margin-bottom:10px;margin-top:10px;\" onclick=\"" . OnEvent::rme($this, "read", "", "function(t){ \$j('#Nuntius" . $this->getID() . "').replaceWith(t.responseText); fheOverview.loadContent('mNuntiusGUI::getOverviewContent'); }") . "\">\n\t\t\t\t{$BS}\n\t\t\t\t<div style=\"margin-left:40px;\" class=\"\">\n\t\t\t\t\t<p><small style=\"float:right;color:grey;\">Von {$from}, " . Util::CLDateTimeParser($this->A("NuntiusTime")) . "</small>" . nl2br($message) . "</p>\n\t\t\t\t</div>\n\t\t\t</div>";
}
示例4: showMessageTimeout
function showMessageTimeout($timeout)
{
echo $this->messageParser();
if ($timeout > 0) {
echo OnEvent::script("window.setTimeout(function(){" . OnEvent::closePopup("Nuntius") . "}, {$timeout} * 1000);");
}
}
示例5: sendEmail
public static function sendEmail($subject, $body, $recipient)
{
$S = new SupportGUI();
$data = $S->getEMailData();
$mailfrom = $data["fromAddress"];
$mailto = $data["recipients"][$recipient][1];
$mimeMail2 = new PHPMailer(false, substr($mailfrom, stripos($mailfrom, "@") + 1));
$mimeMail2->CharSet = "UTF-8";
$mimeMail2->Subject = $subject;
$mimeMail2->From = $mailfrom;
$mimeMail2->Sender = $mailfrom;
$mimeMail2->FromName = $data["fromName"];
$mimeMail2->Body = wordwrap($body, 80);
$mimeMail2->AddAddress($mailto);
$B = new Button("Danke!", "./images/big/thanks.png", "icon");
$B->style("float:left;margin-right:10px;margin-bottom:20px;");
$BOK = new Button("OK", "bestaetigung");
$BOK->onclick(OnEvent::closePopup("Support"));
$BOK->style("float:right;margin:10px;");
if ($mimeMail2->Send()) {
echo "<h1>{$B} Danke für Ihre Unterstützung!</h1><p>Sie erhalten in Kürze eine Antwort per E-Mail.</p>{$BOK}<div style=\"clear:both;\"></div>";
} else {
echo "<p style=\"padding:5px;color:red;\">Fehler beim Senden der E-Mail. Bitte überprüfen Sie Ihre Server-Einstellungen im Admin-Bereich.</p><p>Nachfolgend wird Ihre Nachricht angezeigt, falls Sie sie in die Zwischenablage kopieren (Strg + c) und manuell an <b>{$mailto}</b> möchten.</p><pre style=\"color:grey;max-height:300px;font-size:10px;padding:5px;width:590px;overflow:auto;\">" . wordwrap(stripslashes($body), 80) . "</pre>{$BOK}<div style=\"clear:both;\"></div>";
}
}
示例6: getOffice3aRSS
public function getOffice3aRSS()
{
if (Environment::getS("blogShow", "1") == "0") {
return "";
}
$data = file_get_contents(Environment::getS("blogRSSURL", "http://blog.office3a.eu/feed/"));
if ($data === false) {
return "";
}
$html = "\n\t\t\t<div style=\"border-bottom:1px solid #DDD;position:relative;\" class=\"desktopButton\" onclick=\"window.open('" . Environment::getS("blogURL", "http://blog.office3a.eu/") . "', '_blank');\">\n\t\t\t\t<h1 style=\"font-size:2.0em;color:#999999;position:absolute;bottom:5px;\">" . Environment::getS("blogName", "office<span style=\"color:#A0C100;\">3a</span> blog") . "</h1>\n\t\t\t</div>\n\t\t\t<div id=\"blogContainer\" style=\"padding-left:30px;padding-right:30px;overflow:auto;\">";
try {
$XML = new SimpleXMLElement($data);
$i = 0;
foreach ($XML->channel->item as $item) {
$html .= "<h2 style=\"color:#999999;" . ($i > 0 ? "margin-top:30px;" : "") . "margin-bottom:0px;\">" . $item->title . "</h2>";
$html .= "<p style=\"color:#999999;margin-top:10px;\">" . $item->description . "<br />\n\t\t\t\t\t<small style=\"color:#AAA;\">" . Util::CLFormatDate(strtotime($item->pubDate), true) . "</small> <a style=\"float:right;color:#444;\" href=\"{$item->link}\">mehr...</a></p>";
#print_r($item);
$i++;
if ($i == 4) {
break;
}
}
$html .= "</div>" . OnEvent::script("\$j('#blogContainer').css('height', contentManager.maxHeight() - \$j('.desktopButton').outerHeight() - 20)");
return $html;
} catch (Exception $e) {
return "";
}
}
示例7: getHTML
function getHTML($id)
{
$B = new Button("Element\nlöschen", "trash", "icon");
$B->rmePCR("poolAnzeigeControl", $this->getID(), "deleteMe", "", OnEvent::closePopup("poolAnzeigeControl") . OnEvent::reload("Screen"));
$B->style("margin:10px;");
$gui = new HTMLGUIX($this);
$gui->name("Element");
$gui->displayMode("popupS");
$gui->attributes(array("poolAnzeigeControlCaption", "poolAnzeigeControlLabel", "poolAnzeigeControlNewLine", "poolAnzeigeControlClass", "poolAnzeigeControlSrc", "poolAnzeigeControlServer", "poolAnzeigeControlMaster", "poolAnzeigeControlValue", "poolAnzeigeControlUpdate", "poolAnzeigeControlGroup", "poolAnzeigeControlGroupDelay", "poolAnzeigeControlGroupDelayIf"));
$gui->label("poolAnzeigeControlNewLine", "Neue Zeile");
$gui->label("poolAnzeigeControlCaption", "Überschrift");
$gui->label("poolAnzeigeControlLabel", "Beschriftung");
$gui->label("poolAnzeigeControlOrder", "Reihenfolge");
$gui->label("poolAnzeigeControlClass", "Klasse");
$gui->label("poolAnzeigeControlSrc", "Bild");
$gui->label("poolAnzeigeControlServer", "Steuerung");
$gui->label("poolAnzeigeControlGroupDelay", "Verzögerung in s");
$gui->label("poolAnzeigeControlGroup", "Eigene Gruppe");
$gui->label("poolAnzeigeControlUpdate", "Update Gruppe(n)");
$gui->label("poolAnzeigeControlGroupDelayIf", "Wenn");
$gui->type("poolAnzeigeControlNewLine", "checkbox");
$gui->type("poolAnzeigeControlServer", "readonly");
$gui->type("poolAnzeigeControlClass", "select", array("manual" => "Statisch", "load" => "Laden", "value" => "Wert"));
$gui->type("poolAnzeigeControlGroupDelayIf", "select", array("" => "ohne", "on" => "Ein"));
if ($this->A("poolAnzeigeControlMasterValues") != "") {
$gui->type("poolAnzeigeControlMaster", "select", poolAnzeigeControl::values($this->A("poolAnzeigeControlMasterValues")));
}
$gui->descriptionField("poolAnzeigeControlUpdate", "Mehrere Gruppen durch Komma trennen");
$gui->descriptionField("poolAnzeigeControlNewLine", "Fügt eine neue Zeile vor dem Element ein");
$gui->space("poolAnzeigeControlClass");
$gui->space("poolAnzeigeControlServer");
$gui->space("poolAnzeigeControlUpdate");
return $B . $gui->getEditHTML();
}
示例8: getCMSHTML
function getCMSHTML()
{
$key = substr(Util::eK(), 0, 5);
if (!isset($_GET["key"]) or $key != $_GET["key"]) {
return "<span style=\"color:red;\">Bitte geben Sie den richtigen Schlüssel zum Aufrufen der Seite in der Adresszeile an.</span>";
}
registerClassPath("Einkaufszettel", Util::getRootPath() . "fheME/Einkaufszettel/Einkaufszettel.class.php");
/*
registerClassPath("GSRaumgruppe", Util::getRootPath()."FCalc/GSRaumgruppe/GSRaumgruppe.class.php");
registerClassPath("ObjektL", Util::getRootPath()."personalKartei/ObjekteL/ObjektL.class.php");
registerClassPath("mGSTaetigkeitGUI", Util::getRootPath()."FCalc/GSTaetigkeit/mGSTaetigkeitGUI.class.php");
registerClassPath("GSTaetigkeit", Util::getRootPath()."FCalc/GSTaetigkeit/GSTaetigkeit.class.php");
*
*/
$AC = anyC::get("Einkaufszettel");
$AC->addAssocV3("EinkaufszettelBought", "=", "0");
$AC->addJoinV3("EinkaufszettelKategorie", "EinkaufszettelEinkaufszettelKategorieID", "=", "EinkaufszettelKategorieID");
$AC->addOrderV3("EinkaufszettelKategorieName");
$AC->addOrderV3("EinkaufszettelName");
$html = "<style type=\"text/css\">\n\t\t\t\tbody {\n\t\t\t\t\tmargin:0px;\n\t\t\t\t\tmargin-top:10px;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t@media only screen and (max-width: 360px) {\n\t\t\t\t\thtml {\n\t\t\t\t\t\tzoom: .8;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t \n\t\t\t\t.entry {\n\t\t\t\t\tpadding:10px;\n\t\t\t\t\tborder-top-width:1px;\n\t\t\t\t\tborder-top-style:solid;\n\t\t\t\t\tborder-bottom-width:1px;\n\t\t\t\t\tborder-bottom-style:solid;\n\t\t\t\t\tfont-size:2em;\n\t\t\t\t\tmargin-bottom:10px;\n\t\t\t\t\tcursor:pointer;\n\t\t\t\t\t-webkit-touch-callout: none;\n\t\t\t\t\t-webkit-user-select: none;\n\t\t\t\t\t-khtml-user-select: none;\n\t\t\t\t\t-moz-user-select: none;\n\t\t\t\t\t-ms-user-select: none;\n\t\t\t\t\tuser-select: none;\n\t\t\t\t\t-webkit-tap-highlight-color:rgba(255,255,255,0);\n\t\t\t\t\twidth:100%;\n\t\t\t\t\tbox-sizing:border-box;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t.entryRestore {\n\t\t\t\t\tborder-top-width:1px;\n\t\t\t\t\tborder-top-style:solid;\n\t\t\t\t\tborder-bottom-width:1px;\n\t\t\t\t\tborder-bottom-style:solid;\n\t\t\t\t\tpadding:10px;\n\t\t\t\t\tfont-size:2em;\n\t\t\t\t\tmargin-bottom:10px;\n\t\t\t\t\tcursor:pointer;\n\t\t\t\t\t-webkit-touch-callout: none;\n\t\t\t\t\t-webkit-user-select: none;\n\t\t\t\t\t-khtml-user-select: none;\n\t\t\t\t\t-moz-user-select: none;\n\t\t\t\t\t-ms-user-select: none;\n\t\t\t\t\tuser-select: none;\n\t\t\t\t\tcolor:#444;\n\t\t\t\t\t-webkit-tap-highlight-color:rgba(255,255,255,0);\n\t\t\t\t\twidth:100%;\n\t\t\t\t\tbox-sizing:border-box;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t.backgroundColor4 {\n\t\t\t\t\tbackground-color: #eee;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t.entryTouch {\n\t\t\t\t\tbackground-color: #c5d674;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t.borderColor0 {\n\t\t\t\t\tborder-color:white;\n\t\t\t\t}\n\t\t\t</style>\n\t\t\t<div id=\"einkaufsliste\">";
$B = new Button("Wiederherstellen", "undo", "iconicL");
$last = null;
while ($E = $AC->getNextEntry()) {
if ($last != $E->A("EinkaufszettelKategorieName") and $last !== null) {
$html .= "<h1 style=\"padding-left:10px;padding-top:15px;padding-bottom:7px;\">" . $E->A("EinkaufszettelKategorieName") . "</h1>";
}
$html .= "\n\t\t\t\t<div\n\t\t\t\t\tid=\"entry" . $E->getID() . "\"\n\t\t\t\t\tontouchend=\"if(Touch.cancelNext) return; CustomerPage.rme('setBought', [" . $E->getID() . "], function(){ \$('#entry" . $E->getID() . "').hide(); \$('#restoreEntry" . $E->getID() . "').show(); \$('#emptyEntry').hide(); if(\$('#einkaufsliste .nonEmpty').length == 0) \$('#emptyEntry').show(); });\"\n\t\t\t\t\tclass=\"nonEmpty entry backgroundColor1 borderColor1\">\n\t\t\t\t\t\n\t\t\t\t\t" . ($E->A("EinkaufszettelMenge") > 1 ? $E->A("EinkaufszettelMenge") . " x " : "") . $E->A("EinkaufszettelName") . ($E->A("EinkaufszettelNameDetails") != "" ? "<br /><small style=\"color:grey;\">" . $E->A("EinkaufszettelNameDetails") . "</small>" : "") . "\n\t\t\t\t</div>\n\t\t\t\t<div \n\t\t\t\t\tclass=\"nonEmpty entryRestore backgroundColor4 borderColor0\"\n\t\t\t\t\tontouchend=\"if(Touch.cancelNext) return; CustomerPage.rme('setUnBought', [" . $E->getID() . "], function(){ \$('#entry" . $E->getID() . "').show(); \$('#restoreEntry" . $E->getID() . "').hide(); \$('#emptyEntry').hide(); if(\$('#einkaufsliste .nonEmpty').length == 0) \$('#emptyEntry').show(); });\"\n\t\t\t\t\tid=\"restoreEntry" . $E->getID() . "\" style=\"display:none;\">" . $E->A("EinkaufszettelName") . " {$B}</div>";
$last = $E->A("EinkaufszettelKategorieName");
}
$html .= "<div style=\"" . ($AC->numLoaded() == 0 ? "" : "display:none;") . "\" class=\"entry backgroundColor1 borderColor1\" id=\"emptyEntry\">Die Einkaufsliste enthält keine Einträge.<br /><small style=\"color:grey;\">" . Util::CLDateParser(time()) . "</small></div>";
$html .= "</div>";
return $html . OnEvent::script("\n\t\tvar Touch = {};\n\t\t\n\t\t\$(document).on('touchstart mousedown', '[ontouchend]', function(ev){\n\t\t\t\$(this).addClass('entryTouch'); \n\t\t\t\n\t\t\tTouch.startPos = [ev.clientX, ev.clientY];\n\t\t\tTouch.cancelNext = false;\n\t\t\tTouch.inAction = this;\n\t\t\n\t\t}); \n\t\t\n\t\t\$(document).on('touchend mouseup', '[ontouchend]', function(ev){\n\t\t\t\$(this).removeClass('entryTouch');\n\t\t\tTouch.inAction = false;\n\t\t});\n\t\t\t\n\t\t\$(document).on('touchmove mousemove', '[ontouchend]', function(ev){\n\t\t\tif(!Touch.inAction)\n\t\t\t\treturn;\n\n\t\t\tif(Math.abs(ev.clientX - Touch.startPos[0]) < 15 && Math.abs(ev.clientY - Touch.startPos[1]) < 15)\n\t\t\t\treturn;\n\n\t\t\tTouch.cancelNext = true;\n\t\t\t\$('.entryTouch').removeClass('entryTouch');\n\t\t\t\n\t\t\t//\$(ev.target).trigger('touchend');\n\t\t});\n\t");
}
示例9: getHTML
function getHTML($id)
{
#$p = mUserdata::getPluginSpecificData("mStatistik");
#if(!isset($p["pluginSpecificCanUseControlling"]))
# return;
$html = "";
#parent::getHTML($id);
$tab = new HTMLTable(1);
$tab->addRow("<div id=\"my_chartTodo\" style=\"height:200px;width:470px;\"></div>");
$tab->addRowClass("backgroundColor0");
$AC = $this->data();
$U = Users::getUsersArray(null, true);
$U[-1] = "Allgemein";
$T = new HTMLTable(6);
$T->addColStyle(2, "text-align:right;");
$T->addColStyle(3, "text-align:right;");
$T->addColStyle(4, "text-align:right;");
$T->addColStyle(5, "text-align:right;");
$T->addColStyle(6, "text-align:right;");
$T->addHeaderRow(array("Benutzer", "Gesamt", "Abgesch.", "Kalt", "Erst", "Folge"));
while ($A = $AC->n()) {
$T->addRow(array(isset($U[$A->A("TodoUserID")]) ? $U[$A->A("TodoUserID")] : "Benutzer ID " . $A->A("TodoUserID"), $A->A("gesamt"), $A->A("gesamtDM") . " (" . Util::CLNumberParserZ($A->A("gesamt") != 0 ? round($A->A("gesamtDM") / $A->A("gesamt") * 100, 2) : 0) . "%)", $A->A("gesamtKalt"), $A->A("gesamtErst"), $A->A("gesamtFolge")));
$T->addRowStyle("cursor:pointer;");
$T->addRowEvent("click", OnEvent::rme($this, "details", array($A->A("TodoUserID")), "function(t){ \$j('#contentScreenLeft').html(t.responseText); }"));
}
if ($AC->numLoaded() == 0) {
$T->addRow(array("Es liegen keine Daten vor"));
$T->addRowColspan(1, 4);
}
return "<p class=\"prettySubtitle\">Termine</p>" . $tab . $html . $T . OnEvent::script("\n\t\t\tvar plot = \$j.plot(\$j('#my_chartTodo'), " . $this->chart() . ", {\n\t\t\tseries: {\n\t\t\t\tpie: { show: true, innerRadius: 0.4 }\n\t\t\t}\n\t\t\t});" . OnEvent::rme($this, "getHeaderCenter", "", "function(transport){ \$j('#contentScreenCenterHeader').html(transport.responseText); }"));
}
示例10: getCMSHTML
function getCMSHTML()
{
if (!isset($_GET["terminalID"])) {
return "<p>Keine Terminal-ID per GET übergeben! (terminalID)</p>";
}
if (!isset($_GET["done"])) {
return "<p style=\"font-size:30px;\">\r\n\t\t\t\tTerminal IP: " . $_SERVER['REMOTE_ADDR'] . "<br>\r\n\t\t\t\tServer IP: " . $_SERVER['SERVER_ADDR'] . "</p>\r\n\t\t\t\t<p>\r\n\t\t\t\t<a href=\"#\" onclick=\"\$.jStorage.set('pKTransferStack', []); \$.jStorage.set('pKTimeStack', []); return false;\">Datenspeicher löschen</a>\r\n\t\t\t\t</p>" . OnEvent::script("window.setTimeout(function(){ document.location.href=\"?" . $_SERVER['QUERY_STRING'] . "&done=true\"; }, 3000);");
}
self::loadClasses();
$AC = self::getPersonal();
$json = $AC->asJSON();
$html = "\r\n\t\t<style type=\"text/css\">\r\n\t\t\thtml {\r\n\t\t\t\toverflow-y: hidden;\r\n\t\t\t}\r\n\t\t\tbody {\r\n\t\t\t\t/*background-image:url(./images/TimeTerminalBG.svg);\r\n\t\t\t\tbackground-size:100%;*/\r\n\t\t\t\tmargin:0px;\r\n\t\t\t}\r\n\t\t\t.message {\r\n\t\t\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t.overlay {\r\n\t\t\t\tposition: fixed;\r\n\t\t\t\ttop: 0;\r\n\t\t\t\tleft: 0;\r\n\t\t\t\twidth: 100%;\r\n\t\t\t\theight: 100%;\r\n\t\t\t\tbackground-color: #72c100;\r\n\t\t\t\tz-index: 1100;\r\n\t\t\t\tdisplay:none;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t.overlayCenter {\r\n\t\t\t\tposition: fixed;\r\n\t\t\t\ttop: 6%;\r\n\t\t\t\tleft: 3%;\r\n\t\t\t\twidth: 94%;\r\n\t\t\t\theight: 88%;\r\n\t\t\t\tbackground-color: white;\r\n\t\t\t\tz-index: 1101;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t.green {\r\n\t\t\t\tbackground-color:#72c100;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t.red {\r\n\t\t\t\tbackground-color:#c90021;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t.orange {\r\n\t\t\t\tbackground-color:orange;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t.touchField {\r\n\t\t\t\tbackground-color:#CCC;\r\n\t\t\t\tmargin-top:40px;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t.currentAction {\r\n\t\t\t\tbackground-color:#c5ffab;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t.overlay ul {\r\n\t\t\t\tlist-style-type:none;\r\n\t\t\t}\r\n\r\n\t\t\t.overlay li {\r\n\t\t\t\tfont-size:30px;\r\n\t\t\t\tfont-weight:normal;\r\n\t\t\t\tpadding-top:14px;\r\n\t\t\t\tpadding-bottom:14px;\r\n\t\t\t}\r\n\t\t</style>\r\n\t\t<script type=\"text/javascript\">\r\n\t\t\tvar months = new Array('" . implode("', '", Datum::getGerMonthArray()) . "');\r\n\t\t\tvar days = new Array('" . implode("', '", Datum::getGerWeekArray()) . "');\r\n\t\t\tvar action = '" . ($this->switch ? "G" : "K") . "';\r\n\t\t\tvar inOverlay = false;\r\n\t\t\tvar inTransfer = false;\r\n\t\t\tvar Personal = {$json};\r\n\t\t\tvar PersonalLastUpdate = " . time() . ";\r\n\t\t\tvar timeoutTransfer = null;\r\n\t\t\t\r\n\t\t\t\$(function(){\r\n\t\t\t\twindow.setInterval(function(){\r\n\t\t\t\t\tclokk();\r\n\t\t\t\t}, 1000 * 30);\r\n\t\t\t\t\r\n\t\t\t\tclokk();\r\n\t\t\t\t\r\n\t\t\t\t\$('#chipCode').focus();\r\n\t\t\t\t\r\n\t\t\t\twindow.setInterval(function(){\r\n\t\t\t\t\tif(inOverlay || document.activeElement.id == 'chipCode')\r\n\t\t\t\t\t\treturn;\r\n\t\t\t\t\t\r\n\t\t\t\t\t\$('#chipCode').focus();\r\n\t\t\t\t}, 1000);\r\n\t\t\t\t\r\n\t\t\t\twindow.setInterval(function(){\r\n\t\t\t\t\talive();\r\n\t\t\t\t}, 60000);\r\n\t\t\t});\r\n\t\t\t\r\n\t\t\tfunction alive(){\r\n\t\t\t\tCustomerPage.rme('alive', [" . $_GET["terminalID"] . ", PersonalLastUpdate], function(t){\r\n\t\t\t\t\t\$('#aliveStatus').css('background-color', 'green');\r\n\t\t\t\t\t\r\n\t\t\t\t\tif(t != ''){\r\n\t\t\t\t\t\tPersonal = JSON.parse(t);\r\n\t\t\t\t\t\tPersonalLastUpdate = Math.round(Date.now() / 1000);\r\n\t\t\t\t\t\t//console.log(Personal);\r\n\t\t\t\t\t}\r\n\t\t\t\t}, function(){\r\n\t\t\t\t\t\$('#aliveStatus').css('background-color', 'red');\r\n\t\t\t\t});\r\n\t\t\t}\r\n\r\n\t\t\tfunction clokk(){\r\n\t\t\t\tvar jetzt = new Date();\r\n\t\t\t\t\$('#clock').html(jetzt.getHours()+':'+(jetzt.getMinutes() < 10 ? '0' : '')+jetzt.getMinutes());\r\n\t\t\t\t\$('#day').html(days[jetzt.getDay()]+', '+jetzt.getDate()+'. '+months[jetzt.getMonth()]+' '+jetzt.getFullYear());\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tfunction heightContent(){\r\n\t\t\t\tvar max = \$j(window).height() / 100 * 88;\r\n\t\t\t\t\r\n\t\t\t\t\$j.each(\$j('.overlayContentSub'), function(k, v){\r\n\t\t\t\t\tmax -= \$j(v).outerHeight();\r\n\t\t\t\t});\r\n\r\n\t\t\t\treturn max;\r\n\t\t\t}\r\n\r\n\t\t\tfunction transfer(){\r\n\t\t\t\tif(inOverlay){\r\n\t\t\t\t\ttimeoutTransfer = window.setTimeout(function(){\r\n\t\t\t\t\t\ttransfer();\r\n\t\t\t\t\t}, 60000);\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tinTransfer = true;\r\n\t\t\t\tvar timeStack = \$.jStorage.get('pKTimeStack', []);\r\n\t\t\t\t\$.jStorage.set('pKTimeStack', []);\r\n\t\t\t\tinTransfer = false;\r\n\t\t\t\t\r\n\t\t\t\t\r\n\t\t\t\tvar transferStack = \$.jStorage.get('pKTransferStack', []);\r\n\t\t\t\tvar newTransferStack = transferStack.concat(timeStack);\r\n\t\t\t\t\$.jStorage.set('pKTransferStack', newTransferStack);\r\n\t\t\t\t\r\n\t\t\t\tif(newTransferStack.length > 0)\r\n\t\t\t\t\tCustomerPage.rme('stampStack', [JSON.stringify(newTransferStack)/*, PersonalLastUpdate*/], function(t){\r\n\t\t\t\t\t\t\$.jStorage.set('pKTransferStack', []);\r\n\t\t\t\t\t\t//console.log('Transfer succeeded!');\r\n\t\t\t\t\t\tcounter();\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t/*if(t != ''){\r\n\t\t\t\t\t\t\tPersonal = JSON.parse(t);\r\n\t\t\t\t\t\t\tPersonalLastUpdate = Math.round(Date.now() / 1000);\r\n\t\t\t\t\t\t}*/\r\n\t\t\t\t\t}, function(){\r\n\t\t\t\t\t\t//console.log('Transfer failed!');\r\n\t\t\t\t\t\tcounter();\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\ttimeoutTransfer = window.setTimeout(function(){\r\n\t\t\t\t\t\t\ttransfer();\r\n\t\t\t\t\t\t}, 60000);\r\n\t\t\t\t\t});\r\n\t\t\t}\r\n\r\n\t\t\tfunction counter(){\r\n\t\t\t\t\$('#transferCounter').html(\$.jStorage.get('pKTimeStack', []).length+'/'+\$.jStorage.get('pKTransferStack', []).length);\r\n\t\t\t}\r\n\r\n\t\t\tfunction stampp(){\r\n\t\t\t\tif(inTransfer){\r\n\t\t\t\t\twindow.setTimeout(function(){\r\n\t\t\t\t\t\tstampp();\r\n\t\t\t\t\t}, 20);\r\n\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\tinOverlay = true;\r\n\t\t\t\tvar stack = \$.jStorage.get('pKTimeStack', []);\r\n\t\t\t\tvar chip = \$('#chipCode').val();\r\n\t\t\t\t\r\n\t\t\t\tstack.push({'chip': chip, 'terminal': " . $_GET["terminalID"] . ", 'action': action, 'time': Math.round(Date.now() / 1000)});\r\n\t\t\t\t\$.jStorage.set('pKTimeStack', stack);\r\n\r\n\t\t\t\tvar usePersonal = null;\r\n\t\t\t\tfor (k in Personal) {\r\n\t\t\t\t//console.log(Personal[k].PersonalName+':'+Personal[k].PersonalChipNummer+';'+Personal[k].PersonalChipNummer2+';'+Personal[k].PersonalChipNummer3+';'+Personal[k].PersonalChipNummer4);\r\n\t\t\t\t\tif(chip == Personal[k].PersonalChipNummer){\r\n\t\t\t\t\t\tusePersonal = Personal[k];\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\tif(chip == Personal[k].PersonalChipNummer2){\r\n\t\t\t\t\t\tusePersonal = Personal[k];\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\tif(chip == Personal[k].PersonalChipNummer3){\r\n\t\t\t\t\t\tusePersonal = Personal[k];\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\tif(chip == Personal[k].PersonalChipNummer4){\r\n\t\t\t\t\t\tusePersonal = Personal[k];\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\r\n\t\t\t\tvar color = 'green';\r\n\t\t\t\t\$('#chipCode').val('');\r\n\t\t\t\tif(usePersonal)\r\n\t\t\t\t\t\$j('.overlayText').html(usePersonal.PersonalName);\r\n\t\t\t\telse\r\n\t\t\t\t\t\$j('.overlayText').html('Zeit erfasst');\r\n\t\t\t\t\$j('.overlayDetails').html('');\r\n\r\n\t\t\t\t\$('.overlay').addClass(color).show();\r\n\r\n\t\t\t\tmoep();\r\n\r\n\t\t\t\twindow.setTimeout(function(){\r\n\t\t\t\t\t\$('.overlay').hide().removeClass(color);\r\n\t\t\t\t\tinOverlay = false;\r\n\t\t\t\t}, " . (isset($_GET["wait"]) ? $_GET["wait"] : "1500") . ");\r\n\t\t\t\t\r\n\r\n\t\t\t\tif(timeoutTransfer){\r\n\t\t\t\t\twindow.clearTimeout(timeoutTransfer);\r\n\t\t\t\t\ttimeoutTransfer = null;\r\n\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\ttimeoutTransfer = window.setTimeout(function(){\r\n\t\t\t\t\ttransfer();\r\n\t\t\t\t}, 60000 * 2);\r\n\t\t\t\t\r\n\t\t\t\tcounter();\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tfunction moep(){\r\n\t\t\t\tif(typeof alex == 'undefined')\r\n\t\t\t\t\treturn;\r\n\t\t\t\tconsole.log(alex);\r\n\t\t\t\talex.beep();\r\n\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t\$('html').focus(function() {\r\n\t\t\t\tif(inOverlay)\r\n\t\t\t\t\treturn;\r\n\t\t\t\t\t\r\n\t\t\t\t\$('#chipCode').focus();\r\n\t\t\t}); \r\n\r\n\t\t\t\$(function(){\r\n\t\t\t\tmoep();\r\n\t\t\t\tcounter();\r\n\t\t\t\talive();\r\n\t\t\t\ttransfer();\r\n\t\t\t\t\r\n\t\t\t\t\$('.touchField').css('height', \$(window).height() - \$('#displayTime').outerHeight() - 60 - 130);\r\n\t\t\t\t\$('.touchField').hammer().on('touch release', function(ev){\r\n\t\t\t\t\tswitch(ev.type){\r\n\t\t\t\t\t\tcase 'touch':\r\n\t\t\t\t\t\t\t\$(ev.target).closest('.touchField').css('background-color', 'rgba(255,204,0,0.3)');\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tcase 'release':\r\n\t\t\t\t\t\t\t\$(ev.target).closest('.touchField').css('background-color', '');\r\n\t\t\t\t\t\t\taction = \$(ev.target).closest('.touchField').data('action');\r\n\t\t\t\t\t\t\t\$('.currentAction').removeClass('currentAction');\r\n\t\t\t\t\t\t\t\$(ev.target).closest('.touchField').addClass('currentAction');\r\n\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t}\r\n\t\t\t\t});\r\n\t\t\t});\r\n\r\n\t\t</script>";
$I = new HTMLInput("chipCode");
$I->id("chipCode");
$I->onEnter("stampp();");
$I->style("background-color:white;border:1px solid white;font-size:30px;width:96%;position:fixed;bottom:50px;");
$BK = new Button("Kommen", "arrow_right", "iconic");
$BK->style("font-size:200px;width:auto;");
$BG = new Button("Gehen", "arrow_left", "iconic");
$BG->style("font-size:200px;width:auto;");
$actschion = "\r\n\t\t\t<div>\r\n\t\t\t\t<div data-action=\"G\" class=\"touchField\" style=\"width:48%;display:inline-block;margin-right:4%;vertical-align:top;\">\r\n\t\t\t\t\t<p style=\"padding:30px;font-size:60px;\">Gehen<br />{$BG}</p>\r\n\t\t\t\t</div><div data-action=\"K\" class=\"touchField currentAction\" style=\"width:48%;display:inline-block;vertical-align:top;\">\r\n\t\t\t\t\t<p style=\"padding:30px;font-size:60px;text-align:right;\">Kommen<br />{$BK}</p>\r\n\t\t\t\t</div>\r\n\t\t\t</div>";
if ($this->switch) {
$actschion = "\r\n\t\t\t<div>\r\n\t\t\t\t<div data-action=\"K\" class=\"touchField\" style=\"width:48%;display:inline-block;margin-right:4%;vertical-align:top;\">\r\n\t\t\t\t\t<p style=\"padding:30px;font-size:60px;\">Kommen<br />{$BG}</p>\r\n\t\t\t\t</div><div data-action=\"G\" class=\"touchField currentAction\" style=\"width:48%;display:inline-block;vertical-align:top;\">\r\n\t\t\t\t\t<p style=\"padding:30px;font-size:60px;text-align:right;\">Gehen<br />{$BK}</p>\r\n\t\t\t\t</div>\r\n\t\t\t</div>";
}
$html .= "\r\n\t\t\t<div id=\"transferCounter\" style=\"position:absolute;top:0px;left:0px;padding:3px;color:grey;\"></div>\r\n\t\t\t<div id=\"aliveStatus\" style=\"position:absolute;top:0px;right:0px;height:10px;width:10px;\"></div>\r\n\t\t\t\r\n\t\t\t<div id=\"displayTime\">\r\n\t\t\t\t<div id=\"clock\" style=\"font-size:190px;text-align:center;margin-top:40px;color:#333;\"></div>\r\n\t\t\t\t<div id=\"day\" style=\"font-size:35px;text-align:right;padding-right:45px;margin-top:0px;color:#CCC;\"></div>\r\n\t\t\t</div>\r\n\t\t\t{$actschion}\r\n\t\t\t{$I}\r\n\t\t\t<div class=\"overlay\">\r\n\t\t\t\t<div class=\"overlayCenter\">\r\n\t\t\t\t\t<div class=\"overlayList\"></div>\r\n\t\t\t\t\t<p style=\"font-size:70px;margin-top:60px;font-weight:bold;\" class=\"overlayText\"></p>\r\n\t\t\t\t\t<p style=\"font-size:50px;margin-top:60px;\" class=\"overlayDetails\"></p>\r\n\t\t\t\t</div>\r\n\t\t\t</div>";
return $html;
}
示例11: getPopupEinstellungen
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;
}
示例12: sortable
public static function sortable($selector, $handle, $saveTo = null, $axis = "y", $connectWith = null, $placeholder = null, $onUpdateComplete = "", $additionalParameters = array())
{
if ($saveTo != null) {
$ex = explode("::", $saveTo);
$saveTo = OnEvent::rme($ex[0], $ex[1], array_merge(array("Sortable.serialize('{$selector}')"), $additionalParameters), $onUpdateComplete);
}
return "\n\t\t\$j('{$selector}').sortable({\n\t\t\t" . ($axis != "" ? "axis: '{$axis}', " : "") . "\n\t\t\tupdate: function(){" . ($saveTo == null ? "" : $saveTo) . "},\n\t\t\t" . ($connectWith != null ? "connectWith: \$j('{$connectWith}')," : "") . "\n\t\t\tdropOnEmpty: true,\n\t\t\t" . ($placeholder != null ? "placeholder: '{$placeholder}', " : "") . "\n\t\t\t" . ($handle != null ? "handle: \$j('{$handle}')" : "") . "\n\t\t});";
}
示例13: parserDate
public static function parserDate($w, $l, $E)
{
$r = "";
if ($E->A("JDownloadRenamed") == 0) {
$r .= OnEvent::script("\$j('#BrowsermJDownload" . $E->getID() . "').css('background-color', 'rgba(235, 64, 0, 0.4)');");
}
return Util::CLDateTimeParser($w) . $r;
}
示例14: openInPopup
public function openInPopup($className, $classID, $fieldName)
{
$C = new $className($classID);
$ITA = new HTMLInput("nicEditor", "textarea");
$ITA->id("nicEditor");
$ITA->style("width:998px;height:300px;");
echo $ITA;
echo OnEvent::script("\n\$j('#nicEditor').val('" . addslashes($C->A($fieldName)) . "'.makeHTML());\n\nsetTimeout(function(){\n\tnew nicEditor({\n\t\ticonsPath : './libraries/nicEdit/nicEditorIconsTiny.gif',\n\t\tbuttonList : ['save','bold','italic','underline','hr'],\n\t\tmaxHeight : 400,\n\n\t\tonSave : function(content, id, instance) {\n\t\t\tif(content.substr(0, 3) != '<p ' && content.substr(0, 3) != '<p>')\n\t\t\t\tcontent = '<p>'+content+'</p>';\n\t\t\t\n\t\t\t" . OnEvent::rme($C, "saveMultiEditField", array("'{$fieldName}'", "content.replace(/<br>/g, '<br />')")) . "\n\n\t\t\t" . OnEvent::closePopup("nicEdit") . "\n\t\t}\n\t}).panelInstance('nicEditor');}, 100);");
}
示例15: getOverviewContent
public function getOverviewContent()
{
$html = "<div class=\"touchHeader\"><span class=\"lastUpdate\" id=\"lastUpdatemWeckerGUI\"></span><p>Wecker</p></div>\n\t\t\t<div style=\"padding:10px;\">";
$B = new Button("Wecker anzeigen", "moon_stroke", "iconicL");
#Overlay.showDark();
$html .= "\n\t\t\t<div class=\"touchButton\" onclick=\"Wecker.loadThemAll(function(){ Wecker.show(); });\">\n\t\t\t\t" . $B . "\n\t\t\t\t<div class=\"label\">Wecker anzeigen</div>\n\t\t\t\t<div style=\"clear:both;\"></div>\n\t\t\t</div>";
$html .= "</div>" . OnEvent::script("if(\$j.jStorage.get('phynxWeckerActive', false) === true) Wecker.loadThemAll(function(){ Wecker.show(); });");
echo $html;
}