Ejemplo n.º 1
0
 public function showBimItem()
 {
     /*$GLOBALS['phpgw_info']['flags']['noheader'] = false;
     		$GLOBALS['phpgw_info']['flags']['nofooter'] = false;
     		$GLOBALS['phpgw_info']['flags']['xslt_app'] = false;
     		$GLOBALS['phpgw']->common->phpgw_header(true);*/
     $GLOBALS['phpgw']->js->validate_file('yui3', 'yui/yui-min', 'phpgwapi');
     $GLOBALS['phpgw']->js->validate_file('yahoo', 'bim.modellist', 'bim');
     $modelGuid = phpgw::get_var("modelGuid");
     //$modelId = 3;
     if (empty($modelGuid)) {
         echo "No guid!";
     } else {
         $GLOBALS['phpgw']->xslttpl->add_file(array('bim_showSingleItem'));
         $sobimitem = new sobimitem_impl($this->db);
         /* @var $bimItem BimItem */
         $bimItem = $sobimitem->getBimItem($modelGuid);
         $GLOBALS['phpgw']->xslttpl->set_xml_data($bimItem->getXml());
         $this->setupBimCss();
     }
 }
Ejemplo n.º 2
0
 public function testUpdateBimItem()
 {
     $sobim = new sobimitem_impl($this->db);
     $bimItem = $sobim->getBimItem($this->projectGuid);
     $xml = new SimpleXMLElement($bimItem->getXml());
     $xml->attributes->name = $this->newProjectName;
     $bimItem->setXml($xml->asXML());
     $this->assertTrue($sobim->updateBimItem($bimItem));
 }