Example #1
0
    public function ajaxResponse(\AjaxResponseObject $ajaxResponseObject)
    {
        $rawHtml = new \Widgets\RawHtml();
        $boxManage = new \Widgets\PortfolioViewBox();
        $boxManage->setTitle(\Portfolio::getInstance()->getText("Belege verwalten"));
        $boxManage->setTitleLink($this->getExtension()->getExtensionUrl() . "ManageArtefacts/");
        $boxManage->setContent("this view helps in uploading and managing of desired artefacts");
        //$boxManage->setButtons(array(array("name"=>"Edit", "link"=>$this->getextension()->getExtensionUrl()."ManageArtefacts/"), array("name"=>"Manage Acess", "link"=>'')));
        /*
        $boxDiscuss = new \Widgets\PortfolioViewBox();
        $boxDiscuss->setTitle(gettext("Discuss View"));
        $boxDiscuss->setTitleLink($this->getextension()->getExtensionUrl()."ViewChart/");
        $boxDiscuss->setContent("Discuss view shows what other have commeted about ur artefacts.if needed this content  can be edited");
        $boxDiscuss->setButtons(array(array("name"=>"Edit", "link"=>"#"), array("name"=>"Manage Acess", "link"=>$this->getextension()->getExtensionUrl()."ManageArtefacts/")));
        */
        $boxcompetence = new \Widgets\PortfolioViewBox();
        $boxcompetence->setTitle(\Portfolio::getInstance()->getText("Kompetenzansicht"));
        $boxcompetence->setTitleLink($this->getextension()->getExtensionUrl() . "ViewCompetence/");
        $boxcompetence->setContent(" Competence view shows the grading of artifacts on the basis of comments given by friends and other group members");
        $boxcompetence->setButtons(array(array("name" => "Edit", "link" => "#"), array("name" => "Manage Acess", "link" => "#")));
        //TODO
        //		$box = new \Widgets\Box();
        //		$box->addWidget($boxManage);
        //		$box->addWidget($boxDiscuss);
        //		$box->addWidget($boxcompetence);
        $html = "";
        $html .= <<<END
    <div class="box" style="float: left; width: 316px;">
    <h3>{$this->portfolio->getName()}</h3>
    <br>
END;
        //		$html .= $box->getHtml();
        $html .= $boxManage->getHtml();
        //		$html .= $boxDiscuss->getHtml();
        $html .= $boxcompetence->getHtml();
        $html .= <<<END
    </div>
END;
        $rawHtml->setHtml($html);
        //$rawHtml->addWidget($box);
        $rawHtml->addWidget($boxManage);
        $rawHtml->addWidget($boxcompetence);
        $ajaxResponseObject->setStatus("ok");
        $ajaxResponseObject->addWidget($rawHtml);
        return $ajaxResponseObject;
    }
Example #2
0
    public function frameResponse(\FrameResponseObject $frameResponseObject)
    {
        $breadcrumb = new \Widgets\Breadcrumb();
        $breadcrumb->setData(array(array("name" => \Portfolio::getInstance()->getText("Shared 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" => gettext("Shared Portfolios"), "link" => $this->getExtension()->getExtensionUrl() . "SharedProfiles/")));
        $tabBar->setActiveTab(2);
        $clearer = new \Widgets\Clearer();
        $boxSearch = new \Widgets\PortfolioViewBox();
        $boxSearch->setTitle(\Portfolio::getInstance()->getText("Portfolios Shared With me "));
        $boxSearch->setContent(" Shows the details about the portfolio like creator,atifacts,acess limitsetc.");
        $boxSearch->setButtons(array(array("name" => "Get Connected", "link" => "#")));
        $boxSimilar = new \Widgets\PortfolioViewBox();
        $boxSimilar->setTitle(\Portfolio::getInstance()->getText("Portfolios I Am Sharing with others"));
        $boxSimilar->setContent(" Shows the details about the portfolio like friends who can see, comments,acess limitsetc.");
        $boxSimilar->setButtons(array(array("name" => "Get Connected", "link" => "#")));
        $html = <<<end



<style type="text/css">

}

select {
    border: 1px solid #D1D1D1;
}

select {
    margin-right: 0.25em;
    padding: 0.16em;
    }
    
   .box_view {
\t\tborder: 1px solid #ccc;
\t\tmargin: 5px 10px 15px 10px;
\t\tbackground-color: #ccffcc;
\t\twidth: 85%;
\t\tpadding:10px;
\t\tfloat: left;
}

a, a:link, a:active, a:visited {
    color: #3092CE;
    text-decoration: none;
    }
</style>



<div class="headline">
\t<h1>My Search Groups</h1>
</div>




<ul class="tabBar">
        
    <li class="tabIn"><a href="./..">Dashboard</a></li>
        
    <li class="tabIn"><a href="../profile/">Profile</a></li>
        
    <li class="tabIn"><a href="../myportfolio">Portfolio</a></li>
        
    <li class="tabOut"><a href="../groups/">Groups</a></li>
    
    <li style="clear: left;">
</li></ul>
<br>
<h2>Find Groups</h2>

<div class="text">
<input>
</div>
<div>
<input type="submit" value="Search"  name="search"  class="submit">
</div>


<br>


<td><div class="box_view">

     <h2><a href="">Group searched</a></h3>
     <p>Shows the details about the group.number of members connected,etc.</p>
     
     <div class="buttons">

<a class="button" ">get connected</a>
</div>
     
<td>
</div>
<td><div class="box_view">

     <h2><a href="">similar group 1 2</a></h3>
     <p>Shows the details about the group.number of members connected,etc.</p>
      
     <div class="buttons">

<a class="button" ">get connected</a>
</div>
     
<td>


</div>

end;
        $frameResponseObject->setTitle("Searchgroups");
        $rawHtml = new \Widgets\RawHtml();
        $rawHtml->setHtml($html);
        $frameResponseObject->addWidget($breadcrumb);
        $frameResponseObject->addWidget($tabBar);
        $frameResponseObject->addWidget($clearer);
        $frameResponseObject->addWidget($boxSearch);
        $frameResponseObject->addWidget($boxSimilar);
        //$frameResponseObject->addWidget($rawHtml);
        return $frameResponseObject;
    }
Example #3
0
 public function frameResponse(\FrameResponseObject $frameResponseObject)
 {
     $artefact = \Artefacts::getById($this->artefactId);
     $actionBar = new \Widgets\ActionBar();
     $actionBar->setActions(array(array("link" => "javascript:history.back()", "name" => "zurück"), array("name" => \Portfolio::getInstance()->getText("Beleg hinzufügen"), "ajax" => array("onclick" => array("command" => "UploadArtefactMessage", "params" => array("id" => $this->artefactId), "requestType" => "popup")))));
     $breadcrumb = new \Widgets\Breadcrumb();
     //	$breadcrumb->setData(array(array("name"=>gettext("Manage Artefacts"))));
     //	$breadcrumb->setData(array($artefact->getRoom()));
     $breadcrumb->setData(array(array("name" => $artefact->getName())));
     $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/"), array("name" => $artefact->getName(), "link" => "#")));
     $tabBar->setActiveTab(3);
     $clearer = new \Widgets\Clearer();
     /*
     $loader = new \Widgets\Loader();
     $loader->setWrapperId("artefactsWrapper");
     $loader->setMessage("loading artefacts ...");
     $loader->setCommand("loadArtefacts");
     $loader->setParams(array());
     $loader->setElementId("artefactsWrapper");
     $loader->setType("updater");
     */
     $boxTip = new \Widgets\Box();
     $boxTip->setTitle(\Portfolio::getInstance()->getText("Content of your Artefact"));
     $boxTip->setContent($artefact->getName() . "<br>" . +$artefact->getDescription());
     //		$content = "<pre>";
     $content = "";
     //		$attributes = $artefact->get_attributes();
     //		foreach ($attributes as $attribute) {
     //			$content .= $attribute . "<br>";
     //		}
     $content .= "Mime Type : " . $artefact->getMimeType() . "<br>";
     //		$content .= "</pre>";
     $boxTip->setContent($content);
     $boxInfo = new \Widgets\Box();
     $boxInfo->setTitle(\Portfolio::getInstance()->getText("Last Changes"));
     $boxInfo->setContent("TODO: Keine Änderungen vorhanden");
     $boxDownload = new \Widgets\Box();
     $boxDownload->setTitle(\Portfolio::getInstance()->getText("Download Artefact"));
     $boxDownload->setContent("<a href>TODO: Download</a>");
     $boxDiscuss = new \Widgets\PortfolioViewBox();
     $boxDiscuss->setTitle(\Portfolio::getInstance()->getText("Discuss View"));
     $boxDiscuss->setTitleLink($this->getextension()->getExtensionUrl() . "ViewChart/");
     $boxDiscuss->setContent("Discuss view shows what other have commeted about your artefacts.if needed this content  can be edited");
     $boxDiscuss->setButtons(array(array("name" => "Edit", "link" => "#"), array("name" => "Manage Acess", "link" => $this->getextension()->getExtensionUrl() . "ManageArtefacts/")));
     $boxCompetences = new \Widgets\PortfolioViewBox();
     $boxCompetences->setTitle(\Portfolio::getInstance()->getText("Competences"));
     $htmlCompetences = "";
     $competences = $artefact->getCompetences();
     foreach ($competences as $competence) {
         $htmlCompetences .= "<br>" . $competence->short . ": " . $competence->name;
     }
     $boxCompetences->setContent($htmlCompetences);
     $url = \ExtensionMaster::getInstance()->getUrlForObjectId($artefact->get_id(), "competences");
     $boxCompetences->setButtons(array(array("name" => "Set Competences", "link" => $url)));
     $frameResponseObject->setTitle("Manage Artefacts");
     $frameResponseObject->addWidget($actionBar);
     $frameResponseObject->addWidget($breadcrumb);
     $frameResponseObject->addWidget($tabBar);
     $frameResponseObject->addWidget($clearer);
     $frameResponseObject->addWidget($boxTip);
     $frameResponseObject->addWidget($clearer);
     $frameResponseObject->addWidget($boxInfo);
     $frameResponseObject->addWidget($clearer);
     $frameResponseObject->addWidget($boxDownload);
     $frameResponseObject->addWidget($clearer);
     $frameResponseObject->addWidget($boxCompetences);
     $frameResponseObject->addWidget($clearer);
     //$frameResponseObject->addWidget($rawHtml);
     return $frameResponseObject;
 }
Example #4
0
    public function frameResponse(\FrameResponseObject $frameResponseObject)
    {
        $breadcrumb = new \Widgets\Breadcrumb();
        $breadcrumb->setData(array(array("name" => \Portfolio::getInstance()->getText("Portfolio/"), "link" => $this->getExtension()->getExtensionUrl() . "Myportfolio/"), array("name" => \Portfolio::getInstance()->getText("My Friends and Groups"))));
        $actionBar = new \Widgets\ActionBar();
        $actionBar->setActions(array(array("name" => \Portfolio::getInstance()->getText("Search"), "link" => $this->getExtension()->getExtensionUrl() . "Searchgroups/"), array("name" => \Portfolio::getInstance()->getText("Create New"), "link" => $this->getExtension()->getExtensionUrl() . "Creategroups/")));
        $menu = new \Widgets\DropdownBox();
        $menu->setLabel(\Portfolio::getInstance()->getText("Type Of Group"));
        $menu->addOption(\Portfolio::getInstance()->getText("All Groups"));
        $menu->addOption(\Portfolio::getInstance()->getText("Groups Made by me"));
        $menu->addOption(\Portfolio::getInstance()->getText("Groups i am Connected"));
        $boxGroup = new \Widgets\PortfolioViewBox();
        $boxGroup->setTitle(\Portfolio::getInstance()->getText("Group One"));
        $boxGroup->setContent(" Shows the details about the group.number of members connected,etc.");
        $boxGroup->setButtons(array(array("name" => "Dlete Group", "link" => "#")));
        $clearer = new \Widgets\Clearer();
        $boxGroup2 = new \Widgets\PortfolioViewBox();
        $boxGroup2->setTitle(\Portfolio::getInstance()->getText("Group two name"));
        $boxGroup2->setContent(" Shows the details about the group.number of members connected,etc.");
        $boxGroup2->setButtons(array(array("name" => "Dlete Group", "link" => "#")));
        $html = <<<end



<style type="text/css">

select {
    border: 1px solid #D1D1D1;
}

select {
    margin-right: 0.25em;
    padding: 0.16em;
    }
    
   .box_view {
\t\tborder: 1px solid #ccc;
\t\tmargin: 5px 10px 15px 10px;
\t\tbackground-color: #ccffcc;
\t\twidth: 85%;
\t\tpadding:10px;
\t\tfloat: left;
}

a, a:link, a:active, a:visited {
    color: #3092CE;
    text-decoration: none;
    }
</style>



<div class="headline">
\t<h1>My Friends and Groups</h1>
</div>

<div class="actionBar">
    
\t<a href="../Searchgroups/" class="button">Search</a>
\t
\t<a href="../Creategroups/" class="button">Create New</a>
\t
\t<a href="" class="button">Add Friend</a>
\t
</div>



<select tabindex="1" name="options" id="filter_options" class="select autofocus">
\t<option selected="selected" value="all">All Groups</option>
\t<option value="admin">Groups made by me</option>
\t<option value="member">Groups i am connected to </option>
\t<option value="invite">Groups I'm Invited To(shows pending group requests)</option>
</select>

<br>


<td><div class="box_view">

     <h2><a href="">Group name 1</a></h3>
     <p>Shows the details about the group.number of members connected,etc.</p>
     
     <div class="buttons">

<a class="button" ">Delete Group</a>
</div>
     
<td>
</div>
<td><div class="box_view">

     <h2><a href="">Group name 2</a></h3>
     <p>Shows the details about the group.number of members connected,etc.</p>
      
     <div class="buttons">

<a class="button" ">Delete Group</a>
</div>
     
<td>


</div>

end;
        $frameResponseObject->setTitle("Groups");
        $rawHtml = new \Widgets\RawHtml();
        $rawHtml->setHtml($html);
        $frameResponseObject->addWidget($breadcrumb);
        $frameResponseObject->addWidget($actionBar);
        $frameResponseObject->addWidget($clearer);
        $frameResponseObject->addWidget($menu);
        $frameResponseObject->addWidget($clearer);
        $frameResponseObject->addWidget($boxGroup);
        $frameResponseObject->addWidget($boxGroup2);
        //$frameResponseObject->addWidget($rawHtml);
        return $frameResponseObject;
    }