File: /data/www/webtemplate/wtv2/codedoc/wtGroup.php
<?php
/**
* WebTemplate Core
*
* @version 2.0
* @module WebTemplate Core
*/
/**
* The class representing Group Nodes
*
* @class WTGroup
* @extends WTNode
*/
class WTGroup extends WTNode {
function getFormAttributeHTML($attributeInfo, $values) {
/*
$html = "";
$attributeName = $attributeInfo["Attribute Name"];
if($attributeName == "Type") {
$view = $GLOBALS["WT"]->getRequestValue("view");
$label = "Type:";
$groupType = $GLOBALS["WT"]->getNode("Config/Options/Group Types/$view");
$control = '<input type="hidden" name="attr' . $attributeInfo["__guid"] . '" value="' . $groupType->m_guid . '"/>' . $view;
return WTNode::getFormRowHTML($label, $control);
}
if($attributeName == "Joining Fee") {
$view = $GLOBALS["WT"]->getRequestValue("view");
if($view != "Member Group") {
return "";
}
}
if($attributeName == "Value") {
$view = $GLOBALS["WT"]->getRequestValue("view");
$label = "Value";
switch($view) {
case 'Contact Group':
return "";
case 'Member Group':
return "";
$label = "Joining Fee ($):";
break;
case 'Supply Chain Group':
$label = "Markup (%):";
break;
case 'Discount Group':
$label = "Discount (%)";
break;
}
$control = '<input name="attr' . $attributeInfo["__guid"] . '" value="' . htmlEntities($values["Value"]) . '">';
return WTNode::getFormRowHTML($label, $control);;
}
*/
$html = $html . parent::getFormAttributeHTML($attributeInfo, $values);
return $html;
}
}
?>