summaryrefslogtreecommitdiffstats
path: root/library/SSRS/Object/ReportParameter.php
diff options
context:
space:
mode:
Diffstat (limited to 'library/SSRS/Object/ReportParameter.php')
-rwxr-xr-xlibrary/SSRS/Object/ReportParameter.php22
1 files changed, 22 insertions, 0 deletions
diff --git a/library/SSRS/Object/ReportParameter.php b/library/SSRS/Object/ReportParameter.php
index 75fb8ab..32ea31a 100755
--- a/library/SSRS/Object/ReportParameter.php
+++ b/library/SSRS/Object/ReportParameter.php
@@ -15,4 +15,26 @@ class SSRS_Object_ReportParameter extends SSRS_Object_Abstract {
public $name;
public $value;
+ public function getValidValues() {
+ $data = false;
+
+ if (key_exists('ValidValues', $this->data)) {
+ $data = array();
+
+ if (is_object($this->data['ValidValues']->ValidValue)) {
+ $data[$this->data['ValidValues']->ValidValue->Label] = $this->data['ValidValues']->ValidValue->Value;
+ } else {
+ foreach ($this->data['ValidValues']->ValidValue AS $value) {
+ $data[$value->Label] = $value->Value;
+ }
+ }
+
+ if (!empty($this->data['AllowBlank'])) {
+ $data['AllowBlank'] = '';
+ }
+ }
+
+ return $data;
+ }
+
}