Exemplo n.º 1
0
    public function frameResponse(\FrameResponseObject $frameResponseObject)
    {
        if (!$this->portfolioId) {
            print "no object id given!";
            exit;
        }
        $portfolio = \PortfolioModel::getById($this->portfolioId);
        $loader = new \Widgets\Loader();
        $loader->setWrapperId("artefactsWrapper");
        $loader->setMessage("loading artefacts ...");
        $loader->setCommand("loadArtefacts");
        $loader->setParams(array($this->portfolioId));
        $loader->setElementId("artefactsWrapper");
        $loader->setType("updater");
        $html .= <<<END
<script type="text/javascript">
\$(':checkbox').change(function() {
   sendRequest("UpdateSelectedArtefacts", {"artefactId": "{$this->artefactId}", "portfolio": "{$this->portfolioId}", "checked": \$(this).prop("checked")}, "", "data");
});
</script>
END;
        $rawHtml = new \Widgets\RawHtml();
        $rawHtml->setHtml($html);
        $frameResponseObject->addWidget($rawHtml);
        $frameResponseObject->addWidget($loader);
        return $frameResponseObject;
    }
Exemplo n.º 2
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     $actionBar = new \Widgets\ActionBar();
     $actionBar->setActions(array(array("name" => \Portfolio::getInstance()->getText("new"), "ajax" => array("onclick" => array("command" => "newArtefact", "params" => array(), "requestType" => "popup")))));
     $breadcrumb = new \Widgets\Breadcrumb();
     $breadcrumb->setData(array(array("name" => \Portfolio::getInstance()->getText("Manage Portfolios"))));
     $tabBar = new \Widgets\TabBar();
     $tabBar->setTabs(array(array("name" => \Portfolio::getInstance()->getText("Dashboard"), "link" => $this->getextension()->getExtensionUrl() . "/"), array("name" => \Portfolio::getInstance()->getText("Portfolio"), "link" => $this->getExtension()->getExtensionUrl() . "MyPortfolio/"), array("name" => \Portfolio::getInstance()->getText("Shared Portfolios"), "link" => $this->getExtension()->getExtensionUrl() . "SharedProfiles/")));
     $tabBar->setActiveTab(1);
     $clearer = new \Widgets\Clearer();
     $loader = new \Widgets\Loader();
     $loader->setWrapperId("portfoliosWrapper");
     $loader->setMessage("loading portfolios ...");
     $loader->setCommand("loadPortfolios");
     $loader->setParams(array());
     $loader->setElementId("portfoliosWrapper");
     $loader->setType("updater");
     $frameResponseObject->setTitle("Manage Portfolios");
     $frameResponseObject->addWidget($actionBar);
     $frameResponseObject->addWidget($breadcrumb);
     $frameResponseObject->addWidget($tabBar);
     $frameResponseObject->addWidget($clearer);
     $frameResponseObject->addWidget($loader);
     //$frameResponseObject->addWidget($rawHtml);
     return $frameResponseObject;
 }
Exemplo n.º 3
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     $currentUser = $GLOBALS["STEAM"]->get_current_steam_user();
     if (isset($this->id)) {
         $object = \steam_factory::get_object($GLOBALS["STEAM"]->get_id(), $this->id);
         if ($object instanceof \steam_exit) {
             $object = $object->get_exit();
             $this->id = $object->get_id();
         }
     } else {
         $object = $currentUser->get_trashbin();
         $this->id = $object->get_id();
     }
     if ($object && $object instanceof \steam_container) {
         $objects = $object->get_inventory();
     } else {
         $objects = array();
     }
     $this->getExtension()->addJS();
     $this->getExtension()->addCSS();
     $title = "Papierkorb";
     $actionBar = new \Widgets\ActionBar();
     $actionBar->setActions(array(array("name" => "Papierkorb leeren", "ajax" => array("onclick" => array("command" => "EmptyTrashbin", "params" => array("fromNameSpace" => "Trashbin"), "requestType" => "popup", "namespace" => "explorer")))));
     $loader = new \Widgets\Loader();
     $loader->setWrapperId("trashbinWrapper");
     $loader->setMessage("Lade Daten ...");
     $loader->setCommand("loadContent");
     $loader->setParams(array("id" => $this->id));
     $loader->setElementId("trashbinWrapper");
     $loader->setType("updater");
     $frameResponseObject->setTitle($title);
     $frameResponseObject->addWidget($actionBar);
     $frameResponseObject->addWidget($loader);
     return $frameResponseObject;
 }
Exemplo n.º 4
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     $portfolio = \PortfolioModel::getById($this->portfolioId);
     $actionBar = new \Widgets\ActionBar();
     $actionBar->setActions(array(array("link" => "javascript:history.back()", "name" => "zurück"), array("name" => \Portfolio::getInstance()->getText("new"), "ajax" => array("onclick" => array("command" => "newArtefact", "params" => array(), "requestType" => "popup")))));
     $breadcrumb = new \Widgets\Breadcrumb();
     $breadcrumb->setData(array(array("name" => \Portfolio::getInstance()->getText("Belege des Portfolios »" . $portfolio->getName() . "«"))));
     $tabBar = new \Widgets\TabBar();
     $tabBar->setTabs(array(array("name" => \Portfolio::getInstance()->getText("Dashboard"), "link" => $this->getextension()->getExtensionUrl() . "/"), array("name" => \Portfolio::getInstance()->getText("Portfolio"), "link" => $this->getExtension()->getExtensionUrl() . "MyPortfolio/"), array("name" => \Portfolio::getInstance()->getText("Shared Portfolios"), "link" => $this->getExtension()->getExtensionUrl() . "SharedProfiles/")));
     $tabBar->setActiveTab(1);
     $clearer = new \Widgets\Clearer();
     $loader = new \Widgets\Loader();
     $loader->setWrapperId("artefactsWrapper");
     $loader->setMessage("loading artefacts ...");
     $loader->setCommand("loadArtefacts");
     $loader->setParams(array(0 => $this->portfolioId));
     $loader->setElementId("artefactsWrapper");
     $loader->setType("updater");
     $frameResponseObject->setTitle("Belege verwalten");
     $frameResponseObject->addWidget($actionBar);
     $frameResponseObject->addWidget($breadcrumb);
     $frameResponseObject->addWidget($tabBar);
     $frameResponseObject->addWidget($clearer);
     $frameResponseObject->addWidget($loader);
     //$frameResponseObject->addWidget($rawHtml);
     return $frameResponseObject;
 }
Exemplo n.º 5
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     $actionBar = new \Widgets\ActionBar();
     $this->getExtension()->addJS();
     $actionBar->setActions(array(array("name" => \Portfolio::getInstance()->getText("newArtefacts"), "ajax" => array("onclick" => array("command" => "newArtefactForm", "namespace" => "portfolio", "params" => "", "requestType" => "popup")))));
     //		array("name" => "Bild anfügen<img src=\"{$editIcon}\">", "command" => "EditMessageImage", "namespace" => "forum", "params" => "{'messageObjectId':'{$this->id}','forum':'{$forumId}'}", "type" => "popup");
     $breadcrumb = new \Widgets\Breadcrumb();
     $breadcrumb->setData(array(array("name" => \Portfolio::getInstance()->getText("Manage Artefacts"))));
     $tabBar = new \Widgets\TabBar();
     $tabBar->setTabs(array(array("name" => \Portfolio::getInstance()->getText("Dashboard"), "link" => $this->getextension()->getExtensionUrl() . "/"), array("name" => \Portfolio::getInstance()->getText("Competences"), "link" => $this->getExtension()->getExtensionUrl() . "ViewChart/"), array("name" => \Portfolio::getInstance()->getText("Artefacts"), "link" => $this->getExtension()->getExtensionUrl() . "ManageArtefacts/")));
     $tabBar->setActiveTab(2);
     $clearer = new \Widgets\Clearer();
     $loader = new \Widgets\Loader();
     $loader->setWrapperId("artefactsWrapper");
     $loader->setMessage("loading artefacts ...");
     $loader->setCommand("loadArtefacts");
     $loader->setParams($this->params);
     $loader->setElementId("artefactsWrapper");
     $loader->setType("updater");
     $frameResponseObject->setTitle("Manage Artefacts");
     $frameResponseObject->addWidget($actionBar);
     $frameResponseObject->addWidget($breadcrumb);
     $frameResponseObject->addWidget($tabBar);
     $frameResponseObject->addWidget($clearer);
     $frameResponseObject->addWidget($loader);
     //$frameResponseObject->addWidget($rawHtml);
     return $frameResponseObject;
 }
Exemplo n.º 6
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     $portfolios = \PortfolioModel::getMyPortfolios();
     $listViewer = new \Widgets\ListViewer();
     if (isset($this->portfolioId)) {
         $portfolioObject = new \PortfolioModel(\steam_factory::get_object($GLOBALS["STEAM"]->get_id(), $this->portfolioId));
     }
     if (isset($this->artefactId)) {
         $artefactObject = new \ArtefactModel(\steam_factory::get_object($GLOBALS["STEAM"]->get_id(), $this->artefactId));
     }
     $steamUser = $GLOBALS["STEAM"]->get_current_steam_user();
     //		/** check the rights of the log-in user */
     //		$threadObject_allowed_read = $threadObject->check_access_read($steamUser);
     //		$threadObject_write = $threadObject->check_access_write($steamUser);
     //		$threadObject_annotate = $threadObject->check_access_annotate($steamUser);
     $listViewer->setHeadlineProvider(new HeadlineProviderDebug());
     $listViewer->setContentProvider(new ContentProviderDebug());
     if (isset($portfolioObject)) {
         $listViewer->setContent($artefacts);
     } else {
         $listViewer->setContent($portfolios);
     }
     $frameResponseObject->addWidget($listViewer);
     return $frameResponseObject;
 }
Exemplo n.º 7
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     $tpl = new \Worksheet\Template($this->id);
     $worksheet = new \Worksheet\Worksheet($this->id);
     $worksheet->validateRole("build");
     $tplBlocks = array();
     /* get all blocks for this worksheet */
     $blocks = $worksheet->getBlocks();
     foreach ($blocks as $block) {
         $tplBlocks[] = array("id" => $block->getId(), "name" => $block->getName(), "content" => $block->getBuildViewHtml(), "type" => $block->getType(), "order" => $block->getOrder());
     }
     if (count($blocks) == 0) {
         $tplBlocks = false;
     }
     $tpl->assign("blocks", $tplBlocks);
     $tpl->display("Build.template.html");
     /* action bar */
     $actionBar = new \Widgets\ActionBar();
     $actionBar->setActions(array(array("name" => "Eine Aufgabe hinzufügen", "link" => PATH_URL . "worksheet/AddBlock/" . $this->id), array("name" => "Arbeitsblatt veröffentlichen", "link" => PATH_URL . "worksheet/Deploy/" . $this->id)));
     $frameResponseObject->addWidget($actionBar);
     /* template output */
     $tpl->parse($frameResponseObject);
     /* page title */
     $frameResponseObject->setTitle($worksheet->getName());
     $frameResponseObject->setHeadline(array(array("name" => $worksheet->getName(), "link" => PATH_URL . "worksheet/Build/" . $this->id)));
     return $frameResponseObject;
 }
Exemplo n.º 8
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     $html = "";
     if (isset($this->params[0]) && $this->params[0] != "") {
         $extension = \ExtensionMaster::getInstance()->getExtensionById($this->params[0]);
         $html = $extension->getInfoHtml();
     } else {
         $content = \Admin::getInstance()->loadTemplate("ExtensionIndex.template.html");
         $extensions = \ExtensionMaster::getInstance()->getAllExtensions();
         foreach ($extensions as $extension) {
             $content->setCurrentBlock("BLOCK_EXTERNSION");
             $content->setVariable("EXTERNSION_ID", $extension->getId());
             $content->setVariable("EXTERNSION_NAME", $extension->getName());
             $content->setVariable("EXTERNSION_ICON", "");
             $content->setVariable("EXTERNSION_VERSION", $extension->getVersion());
             $content->parse("BLOCK_EXTERNSION");
         }
         $html = $content->get();
     }
     $rawHtml = new \Widgets\RawHtml();
     $rawHtml->setHtml($html);
     $frameResponseObject->setTitle("Extension Information");
     $frameResponseObject->addWidget($rawHtml);
     return $frameResponseObject;
 }
Exemplo n.º 9
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     $tpl = new \Worksheet\Template($this->id);
     $worksheet = new \Worksheet\Worksheet($this->id);
     $worksheet->validateRole("edit");
     $worksheet->validateStatus(2);
     $tplBlocks = array();
     /* get all blocks for this worksheet */
     $blocks = $worksheet->getBlocks();
     foreach ($blocks as $block) {
         $tplBlocks[] = array("id" => $block->getId(), "name" => $block->getName(), "content" => $block->getCorrectHtml(), "type" => $block->getType(), "order" => $block->getOrder());
     }
     if (count($blocks) == 0) {
         $tplBlocks = false;
     }
     $tpl->assign("blocks", $tplBlocks);
     $tpl->display("Correct.template.html");
     $sourceWorksheet = new \Worksheet\Worksheet($this->source);
     /* action bar */
     $actionBar = new \Widgets\ActionBar();
     $actionBar->setActions(array(array("name" => "Arbeitsblatt zurückgeben", "link" => "javascript: worksheet_finish('" . $this->source . "')"), array("name" => "Speichern", "link" => "javascript: worksheet_save()")));
     $frameResponseObject->addWidget($actionBar);
     /* template output */
     $tpl->parse($frameResponseObject);
     /* action bar */
     $actionBar = new \Widgets\ActionBar();
     $actionBar->setActions(array(array("name" => "Arbeitsblatt zurückgeben", "link" => "javascript: worksheet_finish('" . $this->source . "')"), array("name" => "Speichern", "link" => "javascript: worksheet_save()")));
     $frameResponseObject->addWidget($actionBar);
     /* page title */
     $frameResponseObject->setTitle($worksheet->getName());
     $frameResponseObject->setHeadline(array(array("name" => $sourceWorksheet->getName(), "link" => PATH_URL . "worksheet/View/" . $this->source), array("name" => "Arbeitsblätter korrigieren", "link" => PATH_URL . "worksheet/CopyList/" . $this->source), array("name" => $worksheet->getName())));
     return $frameResponseObject;
 }
Exemplo n.º 10
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     $activities = \CompetenceRaster::getActivityFields();
     $jobs = \CompetenceRaster::getJobs();
     $facets = \CompetenceRaster::getFacets();
     $listViewer = new \Widgets\ListViewer();
     \CompetenceRaster::initReadCompetences();
     $steamUser = $GLOBALS["STEAM"]->get_current_steam_user();
     //print("<pre>".print_r($activities,true)."</pre>");
     //print("<pre>".print_r(\CompetenceRaster::$competences,true)."</pre>");
     $html_text = "";
     $html_text .= "<h2>Bereiche</h2><br>";
     foreach ($activities as $activity) {
         $html_text .= $activity->name . ":<br>" . $activity->description . "<br><br>";
     }
     $html_text .= "<h2>Jobs</h2><br>";
     foreach ($jobs as $activity) {
         $html_text .= $activity->name . ":<br>" . $activity->description . "<br><br>";
     }
     $html_text .= "<h2>Aspekte</h2><br>";
     foreach ($facets as $activity) {
         $html_text .= $activity->name . ":<br>" . $activity->description . "<br><br>";
     }
     $html_text .= "<h2>Kompetenzen</h2><br>";
     foreach (\CompetenceRaster::getCompetences() as $activity) {
         //foreach (\CompetenceRaster::$competences as $activity){
         $html_text .= "Name: " . $activity->name . "<br>ID: " . $activity->job . "<br>facet: " . $activity->facet . "<br>activity: " . $activity->activity . "<br>index: " . $activity->index . "<br>" . "Beschreibung: " . $activity->description . "<br><br>";
     }
     $rawHtml = new \Widgets\RawHtml();
     $rawHtml->setHtml($html_text);
     $frameResponseObject->addWidget($rawHtml);
     return $frameResponseObject;
 }
Exemplo n.º 11
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     $jsWrapper = new \Widgets\JSWrapper();
     $jsWrapper->setJs('self.location.href="' . PATH_URL . "favorite/index/" . '"');
     $frameResponseObject->addWidget($jsWrapper);
     return $frameResponseObject;
 }
Exemplo n.º 12
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     $tpl = new \Worksheet\Template($this->id);
     $worksheet = new \Worksheet\Worksheet($this->id);
     $worksheet->validateRole("view");
     $tplBlocks = array();
     /* get all blocks for this worksheet */
     $blocks = $worksheet->getBlocks();
     foreach ($blocks as $block) {
         $tplBlocks[] = array("id" => $block->getId(), "name" => $block->getName(), "content" => $block->getViewHtml(), "type" => $block->getType(), "order" => $block->getOrder());
     }
     if (count($blocks) == 0) {
         $tplBlocks = false;
     }
     $tpl->assign("blocks", $tplBlocks);
     $tpl->display("View.template.html");
     /* action bar */
     $actionBar = new \Widgets\ActionBar();
     $actionBar->setActions(array(array("name" => "Arbeitsblätter korrigieren", "link" => PATH_URL . "worksheet/CopyList/" . $this->id), array("name" => "Arbeitsblatt ausfüllen", "link" => PATH_URL . "worksheet/StartEdit/" . $this->id)));
     $frameResponseObject->addWidget($actionBar);
     /* template output */
     $tpl->parse($frameResponseObject);
     /* page title */
     $frameResponseObject->setTitle($worksheet->getName());
     $frameResponseObject->setHeadline(array(array("name" => $worksheet->getName(), "link" => PATH_URL . "worksheet/View/" . $this->id)));
     return $frameResponseObject;
 }
Exemplo n.º 13
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     if (isset($this->id)) {
         $object = \steam_factory::get_object($GLOBALS["STEAM"]->get_id(), $this->id);
         if ($object instanceof \steam_document) {
             $mimetype = $object->get_attribute(DOC_MIME_TYPE);
             $objName = $object->get_name();
             $objDesc = trim($object->get_attribute(OBJ_DESC));
             if ($objDesc === 0 || $objDesc === "") {
                 $name = $objName;
             } else {
                 $name = $objDesc . " (" . $objName . ")";
             }
             $actionBar = new \Widgets\ActionBar();
             $actionBar->setActions(array(array("name" => "Anzeigen", "link" => PATH_URL . "Explorer/ViewDocument/" . $this->id . "/"), array("name" => "Bearbeiten", "link" => PATH_URL . "Explorer/EditDocument/" . $this->id . "/"), array("name" => "Eigenschaften", "ajax" => array("onclick" => array("command" => "properties", "params" => array("id" => $this->id), "requestType" => "popup"))), array("name" => "Rechte", "ajax" => array("onclick" => array("command" => "Sanctions", "params" => array("id" => $this->id), "requestType" => "popup")))));
             $contentText = new \Widgets\TextareaCode();
             $contentText->setWidth(945);
             $contentText->setRows(50);
             $contentText->setData($object);
             $contentText->setContentProvider(\Widgets\DataProvider::contentProvider());
             $clearer = new \Widgets\Clearer();
             // 				$html = "";
             // 				if ($mimetype == "image/png" || $mimetype == "image/jpeg" || $mimetype == "image/gif") {  // Image
             // 					$html = "<div style=\"text-align:center\"><img style=\"max-width:100%\" title=\"{$name}\" alt=\"Bild: {$name}\" src=\"" . PATH_URL . "Download/Document/" . $this->id . "/\"></div>";
             // 				} else if ($mimetype == "text/html") {
             // 					$html = strip_tags($object->get_content(),"<h1><h2><h3><h4><h5><p><a><div><style><b><i><strong><img>");
             // 				} else if (strstr($mimetype, "text")) {
             // 					$html = "<pre>{$object->get_content()}</pre>";
             // 				} else {
             // 					header("location: " . PATH_URL . "Download/Document/" . $this->id . "/");
             // 				}
             // 				$rawHtml = new \Widgets\RawHtml();
             // 				$rawHtml->setHtml($html);
             //$rawHtml->addWidget($breadcrumb);
             //$rawHtml->addWidget($environment);
             //$rawHtml->addWidget($loader);
             $frameResponseObject->setTitle($name);
             $frameResponseObject->addWidget($actionBar);
             //$frameResponseObject->addWidget($rawHtml);
             $frameResponseObject->addWidget($contentText);
             $frameResponseObject->addWidget($clearer);
             return $frameResponseObject;
         }
     } else {
         ExtensionMaster::getInstance()->send404Error();
     }
 }
Exemplo n.º 14
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     $currentUser = $GLOBALS["STEAM"]->get_current_steam_user();
     if (isset($this->id)) {
         $object = \steam_factory::get_object($GLOBALS["STEAM"]->get_id(), $this->id);
         if ($object instanceof \steam_exit) {
             $object = $object->get_exit();
             $this->id = $object->get_id();
         }
     } else {
         $object = $currentUser->get_attribute("USER_BOOKMARKROOM");
         $this->id = $object->get_id();
     }
     if ($object && $object instanceof \steam_container) {
         $objects = $object->get_inventory();
     } else {
         $objects = array();
     }
     $this->getExtension()->addJS();
     $this->getExtension()->addCSS();
     $title = "Lesezeichen";
     $bookmarkParentFolderId = $currentUser->get_attribute("USER_BOOKMARKROOM")->get_id();
     if ($this->id != $bookmarkParentFolderId) {
         $title .= " - " . $object->get_name();
     }
     $breadcrumb = new \Widgets\Breadcrumb();
     $breadcrumb->setData(array("", array("name" => "<img src=\"" . PATH_URL . "explorer/asset/icons/mimetype/reference_folder.png\"></img> " . $title . " ")));
     //$bookmarkIcon = \Bookmarks::getInstance()->getAssetUrl() . "icons/bookmark.png";
     //$breadcrumb = new \Widgets\Breadcrumb();
     //$breadcrumb->setData(array(array("name"=>"<img src=\"{$bookmarkIcon}\"> Lesezeichenordner")));
     $actionBar = new \Widgets\ActionBar();
     $actionBar->setActions(array(array("name" => "Ordner anlegen", "ajax" => array("onclick" => array("command" => "newElement", "params" => array("id" => $this->id), "requestType" => "popup")))));
     //$actionBar->setActions(array(array("name"=>"Neu", "ajax"=>array("onclick"=>array("command"=>"newelement"))), array("name"=>"Eigenschaften", "link"=>PATH_URL."explorer/properties/"), array("name"=>"Rechte", "link"=>PATH_URL."explorer/rights/")));
     $loader = new \Widgets\Loader();
     $loader->setWrapperId("bookmarksWrapper");
     $loader->setMessage("Lade Lesezeichen ...");
     $loader->setCommand("loadBookmarks");
     $loader->setParams(array("id" => $this->id));
     $loader->setElementId("bookmarksWrapper");
     $loader->setType("updater");
     $frameResponseObject->setTitle("Lesezeichen");
     $frameResponseObject->addWidget($actionBar);
     $frameResponseObject->addWidget($breadcrumb);
     $frameResponseObject->addWidget($loader);
     return $frameResponseObject;
 }
Exemplo n.º 15
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     $rawWidget = $this->displayWorkplans();
     $frameResponseObject->setTitle("Projektplanverwaltung");
     $frameResponseObject->setHeadline("Projektplanverwaltung");
     $frameResponseObject->addWidget($rawWidget);
     return $frameResponseObject;
 }
Exemplo n.º 16
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     $rawHtml = new \Widgets\RawHtml();
     $rawHtml->setHtml("<center>Noch nicht fertig.</center>");
     $frameResponseObject->setTitle("Impressum");
     $frameResponseObject->addWidget($rawHtml);
     return $frameResponseObject;
 }
Exemplo n.º 17
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     $portfolios = \PortfolioModel::getMyPortfolios();
     $listViewer = new \Widgets\ListViewer();
     $listViewer->setHeadlineProvider(new HeadlineProviderMyPortfolios());
     $listViewer->setContentProvider(new ContentProviderMyPortfolios());
     $listViewer->setContent($portfolios);
     $frameResponseObject->addWidget($listViewer);
     return $frameResponseObject;
 }
Exemplo n.º 18
0
    public function frameResponse(\FrameResponseObject $frameResponseObject)
    {
        $filePersistence = PATH_URL . "debug/filePersistence/";
        $rawHtml = new \Widgets\RawHtml();
        $rawHtml->setHtml(<<<END
<h1>Platform Tests</h1>
<a href="{$filePersistence}">Testing File-Persistence.</a>
END
);
        $frameResponseObject->addWidget($rawHtml);
        return $frameResponseObject;
    }
Exemplo n.º 19
0
 public function getHtmlForFullScreen(\FrameResponseObject $frameResponseObject)
 {
     $objectId = $this->id;
     $content = '<img src=' . PATH_URL . 'download/image/' . $objectId . '/946/710"
       border="0"
       title="Vollbild"
      >';
     $widget = new \Widgets\RawHtml();
     $widget->setHtml($content);
     $frameResponseObject->addWidget($widget);
     return $frameResponseObject;
 }
Exemplo n.º 20
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     if (!\PortfolioExtensionModel::init()) {
         $html .= "Portfolio Räume bereits initialisiert<br>";
     } else {
         $html .= "E-Portfolio erfolgreich initialisiert";
     }
     $rawHtml = new \Widgets\RawHtml();
     $rawHtml->setHtml($html);
     $frameResponseObject->addWidget($rawHtml);
     return $frameResponseObject;
 }
Exemplo n.º 21
0
    public function frameResponse(\FrameResponseObject $frameResponseObject)
    {
        $html = <<<end
<style type="text/css">



</style>
<div class="actionBar">
    
\t<a href="../Fileupload/"class="button">Manual Upload</a>
\t
\t
</div>

<div>
<h1> Add Weblink</h1>
</div>

<div>
<ul class="tabBar">
<li class="tabIn">
<li class="tabIn">
<a href="../WizardCertificates/">EDUCATIONAL CERTIFICATES</a>
</li>
<li class="tabIn">
<a href="">ADDITIONAL CERTIFICATES</a>
</li>
<li class="tabOut">
<a href="">WEB LINKS</a>
</li>
<li class="tabIn">
<a href="../WizardBlogs/">BLOGS</a>
</li>
<li class="tabIn">
<a href="../Editprofile/">PROFILE</a>
</li>
<br>
<br>

<h3><font color="red"> In this page user get LINKS to youtube or other needfull site via which user can select the deired weblinks which should be seen on his/her E-portfolio
</font></h3>

\t

end;
        $frameResponseObject->setTitle("Wizard Links");
        $rawHtml = new \Widgets\RawHtml();
        $rawHtml->setHtml($html);
        $frameResponseObject->addWidget($rawHtml);
        return $frameResponseObject;
    }
Exemplo n.º 22
0
    public function frameResponse(\FrameResponseObject $frameResponseObject)
    {
        $html = <<<end
<style type="text/css">



</style>

<div class="actionBar">
    
\t<a href="../Fileupload/"class="button">Manual Upload</a>
\t
\t
</div>

<div>
<h1> Qualification Details</h1>
</div>

<div>
<ul class="tabBar">
<li class="tabOut">
<a href="">EDUCATIONAL CERTIFICATES</a>
</li>
<li class="tabIn">
<a href="">ADDITIONAL CERTIFICATES</a>
</li>
<li class="tabIn">
<a href="../WizardLinks/">WEB LINKS</a>
</li>
<li class="tabIn">
<a href="../WizardBlogs/">BLOGS</a>
</li>
<li class="tabIn">
<a href="../Editprofile/">PROFILE</a>
</li>

<br>
<br>

<h3><font color="red"> here user can see diffrent set of folders named school, bachelors, Masters,Phd,etc. by clicking on which user will be guided to upload the desired artifacts</font></h3>
\t


end;
        $frameResponseObject->setTitle("Wizard Certificates");
        $rawHtml = new \Widgets\RawHtml();
        $rawHtml->setHtml($html);
        $frameResponseObject->addWidget($rawHtml);
        return $frameResponseObject;
    }
Exemplo n.º 23
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     header("HTTP/1.0 403 Not Found");
     $content = \NotAccess::getInstance()->loadTemplate("403-inline.template.html");
     $content->setVariable("TITLE", "Kein Zugriff");
     $content->setVariable("MESSAGE", "Sie haben keine Zugriff auf dieses Dokument.<br/><br/><a href=\"javascript:history.back();\">Der einzige Weg führt zurück.</a>");
     $rawHtml = new \Widgets\RawHtml();
     $rawHtml->setHtml($content->get());
     $rawHtml->setCss(\NotAccess::getInstance()->readCss());
     $frameResponseObject->setTitle("Sie haben keinen Zugriff (Fehler 403).");
     $frameResponseObject->addWidget($rawHtml);
     return $frameResponseObject;
 }
Exemplo n.º 24
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     header("HTTP/1.0 404 Not Found");
     $content = \NotFound::getInstance()->loadTemplate("404-inline.template.html");
     $content->setVariable("TITLE", "Endstation Hbf");
     $content->setVariable("MESSAGE", "Sie haben das Ende erreicht. Hier war noch niemand zuvor. Nicht mal wir Entwickler.<br/><br/><a href=\"javascript:history.back();\">Der einzige Weg führt zurück.</a>");
     $rawHtml = new \Widgets\RawHtml();
     $rawHtml->setHtml($content->get());
     $rawHtml->setCss(\NotFound::getInstance()->readCss());
     $frameResponseObject->setTitle("Seite nicht gefunden (Fehler 404).");
     $frameResponseObject->addWidget($rawHtml);
     return $frameResponseObject;
 }
Exemplo n.º 25
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     if (isset($this->id)) {
         $object = \steam_factory::get_object($GLOBALS["STEAM"]->get_id(), $this->id);
         if ($object instanceof \steam_exit) {
             $object = $object->get_exit();
             $this->id = $object->get_id();
         }
     } else {
         $object = \School\Model\FolderSchoolBookmark::getSchoolBookmarkFolderObject();
         $this->id = $object->get_id();
     }
     if ($object && $object instanceof \steam_container) {
         $objects = $object->get_inventory();
     } else {
         $objects = array();
     }
     $this->getExtension()->addJS();
     $breadcrumb = new \Widgets\Breadcrumb();
     $breadcrumb->setData(array(array("name" => "Schul-Lesezeichenordner")));
     $actionBar = new \Widgets\ActionBar();
     $actionBar->setActions(array(array("name" => "Neues Lesezeichen", "link" => "#"), array("name" => "Ordner anlegen", "link" => "#")));
     //	$actionBar->setActions(array(array("name"=>"Neues Lesezeichen", "ajax"=>array("onclick"=>array("command"=>"newBookmark", "params"=>array("id"=>$this->id), "requestType"=>"popup"))), array("name"=>"Ordner anlegen", "ajax"=>array("onclick"=>array("command"=>"createFolder", "params"=>array("id"=>$this->id), "requestType"=>"popup")))));
     //$actionBar->setActions(array(array("name"=>"Neu", "ajax"=>array("onclick"=>array("command"=>"newelement"))), array("name"=>"Eigenschaften", "link"=>PATH_URL."explorer/properties/"), array("name"=>"Rechte", "link"=>PATH_URL."explorer/rights/")));
     $loader = new \Widgets\Loader();
     $loader->setWrapperId("schoolBookmarksWrapper");
     $loader->setMessage("Lade meine Schule...");
     $loader->setCommand("loadSchoolBookmarks");
     $loader->setParams(array("id" => $this->id));
     $loader->setElementId("schoolBookmarksWrapper");
     $loader->setType("updater");
     $frameResponseObject->setTitle("Meine Schule");
     $frameResponseObject->setHeadline(array(array("name" => "DIESE SEITE FUNTIONIERT NACH DEM NÄCHSTEN UPDATE.")));
     $frameResponseObject->addWidget($actionBar);
     $frameResponseObject->addWidget($breadcrumb);
     $frameResponseObject->addWidget($loader);
     return $frameResponseObject;
 }
Exemplo n.º 26
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     $user = $GLOBALS["STEAM"]->get_current_steam_user();
     $testObject = \steam_factory::create_room($GLOBALS["STEAM"]->get_id(), "Test Workflow2", $user->get_workroom());
     $testObject->set_attribute("OBJ_TYPE", "WORKPLAN_CONTAINER");
     $workplanExtension = \Workplan::getInstance();
     $workplanExtension->addJS();
     $content = $workplanExtension->loadTemplate("workplan_create.template.html");
     $rawWidget = new \Widgets\RawHtml();
     $rawWidget->setHtml("Test container wurde erstellt!");
     $frameResponseObject->setTitle("Projektplan erstellen");
     $frameResponseObject->addWidget($rawWidget);
     return $frameResponseObject;
 }
Exemplo n.º 27
0
    public function frameResponse(\FrameResponseObject $frameResponseObject)
    {
        $html = <<<end
<style type="text/css">



</style>

<div class="actionBar">
    
\t<a href="../Fileupload/"class="button">Manual Upload</a>
\t
\t
</div>

<div>
<h1> Add Blogs</h1>
</div>

<div>
<ul class="tabBar">
<li class="tabIn">
<a href="../WizardCertificates/">EDUCATIONAL CERTIFICATES</a>
</li>
<li class="tabIn">
<a href="">ADDITIONAL CERTIFICATES</a>
</li>
<li class="tabIn">
<a href="../WizardLinks/">WEB LINKS</a>
</li>
<li class="tabOut">
<a href="">BLOGS</a>
</li>
<li class="tabIn">
<a href="../Editprofile/">PROFILE</a>
</li>

\t<br>
\t<br>
\t
<h3><font color="red"> shows all previously written blogs and out of those user gets an option to select the desired ones</font></h3>\t

end;
        $frameResponseObject->setTitle(" WizardBlogs ");
        $rawHtml = new \Widgets\RawHtml();
        $rawHtml->setHtml($html);
        $frameResponseObject->addWidget($rawHtml);
        return $frameResponseObject;
    }
Exemplo n.º 28
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     $path = $this->params;
     $portal = \lms_portal::get_instance();
     $user = \lms_steam::get_current_user();
     if (!\lms_steam::is_steam_admin($user)) {
         //TODO: REDIRECT!!
     }
     if ($_SERVER["REQUEST_METHOD"] == "POST") {
         $values = $_POST["values"];
         $start_date = iso_to_unix($values["start"]);
         $end_date = iso_to_unix($values["end"]);
         // TODO PROBLEM CHECKING MISSING
         $courses = \steam_factory::get_object($GLOBALS["STEAM"]->get_id(), STEAM_COURSES_GROUP, CLASS_GROUP);
         $all_user = \steam_factory::groupname_to_object($GLOBALS["STEAM"]->get_id(), STEAM_ALL_USER);
         $new_semester = \steam_factory::create_group($GLOBALS["STEAM"]->get_id(), $values["name"], $courses, FALSE, $values["desc"]);
         $new_semester_admins = \steam_factory::create_group($GLOBALS["STEAM"]->get_id(), "admins", $new_semester, FALSE, "admin group for " . $values["desc"]);
         $new_semester_admins->set_attribute("OBJ_TYPE", "semester_admins");
         $new_semester_admins->add_member($user);
         $new_semester->set_insert_access($new_semester_admins, TRUE);
         $new_semester->set_read_access($all_user, TRUE);
         $new_semester->set_attributes(array("SEMESTER_START_DATE" => $start_date, "SEMESTER_END_DATE" => $end_date));
         // CACHE ZURÜCKSETZEN
         $cache = get_cache_function("ORGANIZATION");
         $cache->drop("lms_steam::get_semesters");
         header("Location: " . PATH_URL . "semester/index/" . $values["name"] . "/all");
     }
     $content = \Semester::getInstance()->loadTemplate("semester_create.template.html");
     $content->setVariable("INFO_TEXT", gettext("So, you want to start a new semester?") . " " . gettext("Please fill out the requested values on the right.") . "<br/><br/>" . str_replace("%SEMESTER", STEAM_CURRENT_SEMESTER, gettext("And don't forget to reset the current semester in the etc/koala.def.php, which is <b>%SEMESTER</b> at the moment.")));
     $content->setVariable("LABEL_NAME", gettext("Shortname"));
     $content->setVariable("INFO_NAME", gettext("IMPORTANT: Don't use any slashes, commas or dots in this name. Keep it short, like 'WS0607' or 'SS06'."));
     $content->setVariable("LABEL_DESC", gettext("Name"));
     $content->setVariable("INFO_DESC", gettext("Examples: 'Wintersemester 06/07', or 'Sommersemester 2006'"));
     $content->setVariable("LABEL_START_DATE", gettext("Starting date of semester"));
     $content->setVariable("LABEL_END_DATE", gettext("Ending date of semester"));
     $content->setVariable("INFO_DATE_FORMAT", gettext("Please type in the date in the following format: YYYY-MM-DD"));
     $content->setVariable("LABEL_CREATE", gettext("Create Semester"));
     /* TODO: Portal anpassen
     		$portal->set_page_main(
     			array(array("link" => PATH_URL.SEMESTER_URL."/", "name" => gettext("Semester")), array("link" => "", "name" => gettext("Create new"))),
     			$content->get(),
     			""
     		);
     		*/
     $rawHtml = new \Widgets\RawHtml();
     $rawHtml->setHtml($content->get());
     $frameResponseObject->addWidget($rawHtml);
     return $frameResponseObject;
 }
Exemplo n.º 29
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     $portfolios = \PortfolioModel::getMyPortfolios();
     $artefacts = \ArtefactModel::getAllArtefacts();
     foreach ($portfolios as $portfolio) {
         $portfolio->delete();
     }
     foreach ($artefacts as $artefact) {
         $artefact->delete();
     }
     $rawHtml = new \Widgets\RawHtml();
     $rawHtml->setHtml("E-Portfolio erfolgreich zurückgesetzt");
     $frameResponseObject->addWidget($rawHtml);
     return $frameResponseObject;
 }
Exemplo n.º 30
0
    public function frameResponse(\FrameResponseObject $frameResponseObject)
    {
        $rapidfeedback = \steam_factory::get_object($GLOBALS["STEAM"]->get_id(), $this->id);
        $RapidfeedbackExtension = \Rapidfeedback::getInstance();
        $survey = \steam_factory::get_object($GLOBALS["STEAM"]->get_id(), $this->params[1]);
        $survey_object = new \Rapidfeedback\Model\Survey($rapidfeedback);
        $xml = \steam_factory::get_object_by_name($GLOBALS["STEAM"]->get_id(), $survey->get_path() . "/survey.xml");
        $user = $GLOBALS["STEAM"]->get_current_steam_user();
        $RapidfeedbackExtension->addCSS();
        $RapidfeedbackExtension->addJS();
        $content = $RapidfeedbackExtension->loadTemplate("rapidfeedback_results.template.html");
        $content->setCurrentBlock("BLOCK_RESULTS");
        $content->setVariable("RESULTS_LABEL", "Auswertung");
        if ($survey->get_attribute("RAPIDFEEDBACK_RESULTS") != 1) {
            $content->setVariable("RESULTS_AMOUNT", $survey->get_attribute("RAPIDFEEDBACK_RESULTS") . " Abgaben");
        } else {
            $content->setVariable("RESULTS_AMOUNT", $survey->get_attribute("RAPIDFEEDBACK_RESULTS") . " Abgabe");
        }
        $survey_object->parseXML($xml);
        $survey_object->generateResults($survey);
        $questions = $survey_object->getQuestions();
        $question_html = '
		<script type="text/javascript" src="https://www.google.com/jsapi"></script>
    	<script type="text/javascript">
      		google.load("visualization", "1", {packages:["corechart"]});
		</script>';
        for ($count = 0; $count < count($questions); $count++) {
            $question_html = $question_html . $questions[$count]->getResultHTML($count + 1);
        }
        $content->setVariable("QUESTIONS_HTML", $question_html);
        $content->setVariable("BACK_LABEL", "Zurück");
        $content->setVariable("BACK_URL", $RapidfeedbackExtension->getExtensionUrl() . "Index/" . $this->id);
        $content->parse("BLOCK_RESULTS");
        $group = $rapidfeedback->get_attribute("RAPIDFEEDBACK_GROUP");
        if ($group->get_name() == "learners") {
            $parent = $group->get_parent_group();
            $courseOrGroup = "Kurs: " . $parent->get_attribute("OBJ_DESC") . " (" . $parent->get_name() . ")";
            $courseOrGroupUrl = PATH_URL . "semester/" . $parent->get_id();
        } else {
            $courseOrGroup = "Gruppe: " . $group->get_name();
            $courseOrGroupUrl = PATH_URL . "groups/" . $group->get_id();
        }
        $rawWidget = new \Widgets\RawHtml();
        $rawWidget->setHtml($content->get());
        $frameResponseObject->addWidget($rawWidget);
        $frameResponseObject->setHeadline(array(array("name" => $courseOrGroup, "link" => $courseOrGroupUrl), array("name" => "Rapid Feedback", "link" => $RapidfeedbackExtension->getExtensionUrl() . "Index/" . $rapidfeedback->get_id()), array("name" => "Auswertung")));
        return $frameResponseObject;
    }