summaryrefslogtreecommitdiff
path: root/framework/Web/Services
diff options
context:
space:
mode:
authorxue <>2006-02-13 03:19:48 +0000
committerxue <>2006-02-13 03:19:48 +0000
commitacf77801d4066055cfc3c20e5b634722923f865f (patch)
tree4ef2616f4be993aca6aeb64cb723aeaa35f88274 /framework/Web/Services
parent6f6f20be24c841e61f999a4cff0bb86cf671aa56 (diff)
Anonymous modules are allowed now.
Diffstat (limited to 'framework/Web/Services')
-rw-r--r--framework/Web/Services/TPageService.php26
1 files changed, 5 insertions, 21 deletions
diff --git a/framework/Web/Services/TPageService.php b/framework/Web/Services/TPageService.php
index ad1320b3..988f665a 100644
--- a/framework/Web/Services/TPageService.php
+++ b/framework/Web/Services/TPageService.php
@@ -696,30 +696,14 @@ class TPageConfiguration extends TComponent
{
$properties=$node->getAttributes();
$type=$properties->remove('class');
- if(($id=$properties->itemAt('id'))===null)
- throw new TConfigurationException('pageserviceconf_module_invalid',$configPath);
- if(isset($this->_modules[$id]))
- {
- if($type===null || $type===$this->_modules[$id][0])
- {
- $this->_modules[$id][1]=array_merge($this->_modules[$id][1],$properties->toArray());
- $elements=$this->_modules[$id][2]->getElements();
- foreach($node->getElements() as $element)
- $elements->add($element);
- }
- else
- {
- $node->setParent(null);
- $this->_modules[$id]=array($type,$properties->toArray(),$node);
- }
- }
- else if($type===null)
+ $id=$properties->itemAt('id');
+ if($type===null)
throw new TConfigurationException('pageserviceconf_moduletype_required',$id,$configPath);
+ $node->setParent(null);
+ if($id===null)
+ $this->_modules[]=array($type,$properties->toArray(),$node);
else
- {
- $node->setParent(null);
$this->_modules[$id]=array($type,$properties->toArray(),$node);
- }
}
}