Ejemplo n.º 1
0
<?php

require '../library/SSRS/Report.php';
$options = array('username' => 'testing', 'password' => 'password');
$ssrs = new SSRS_Report('http://localhost/reportserver/', $options);
$result = $ssrs->loadReport('/Reports/Reference_Report');
$ssrs->setSessionId($result->executionInfo->ExecutionID);
$output = $ssrs->render('HTML4.0');
// PDF | XML | CSV
echo $output;
Ejemplo n.º 2
0
 public function testRenderConvertsDeviceInfo()
 {
     $soapMock = $this->getMockFromWsdl(dirname(__FILE__) . '/ReportTest/ReportExecution2005.wsdl', 'SoapClientMockRender2');
     $soapMock->expects($this->any())->method('Render2')->with($this->equalTo(array('Format' => 'CSV', 'DeviceInfo' => '<DeviceInfo><Toolbar>true</Toolbar><Recurse><Test>works</Test></Recurse></DeviceInfo>', 'PaginationMode' => 'Another')));
     $ssrs = new SSRS_Report('http://test/ReportServer');
     $ssrs->setSoapExecution($soapMock)->setSessionId('test');
     $result = $ssrs->render('CSV', array('Toolbar' => true, 'Recurse' => array('Test' => 'works')), 'Another');
 }
Ejemplo n.º 3
0
<?php

require dirname(__FILE__) . '/../library/SSRS/Report.php';
$options = array('username' => 'testing', 'password' => 'password');
$ssrs = new SSRS_Report('http://localhost/reportserver/', $options);
$result = $ssrs->listChildren('/Reports', true);
foreach ($result->CatalogItems as $item) {
    echo $item->Name . ': ' . $item->Path . PHP_EOL;
}
Ejemplo n.º 4
0
<?php

require '../library/SSRS/Report.php';
$options = array('username' => 'testing', 'password' => 'password');
$ssrs = new SSRS_Report('http://localhost/reportserver/', $options);
$results = $ssrs->listRenderingExtensions();
echo '<table border="1" width="100%">';
echo '<tr>';
echo '<th>ExtensionType</th>';
echo '<th>Name</th>';
echo '<th>LocalisedName</th>';
echo '<th>Visible</th>';
echo '<th>IsModelGenerationSupported</th>';
echo '</tr>';
foreach ($results->Extensions->Extension as $extension) {
    $extension->Visible = empty($extension->Visible) ? "Null" : $extension->Visible;
    $extension->IsModelGenerationSupported = empty($extension->IsModelGenerationSupported) ? "Null" : $extension->IsModelGenerationSupported;
    echo '<tr>';
    echo '<td>' . $extension->ExtensionType . '</td>';
    echo '<td>' . $extension->Name . '</td>';
    echo '<td>' . $extension->LocalizedName . '</td>';
    echo '<td>' . $extension->Visible . '</td>';
    echo '<td>' . $extension->IsModelGenerationSupported . '</td>';
    echo '</tr>';
}
echo '</table>';
Ejemplo n.º 5
0
<?php

require '../library/SSRS/Report.php';
$options = array('username' => 'testing', 'password' => 'password');
$ssrs = new SSRS_Report('http://localhost/reportserver/', $options);
$ItemPath = '/Reports/Reference_Report';
$result = $ssrs->getItemDefinition($ItemPath);
header('Content-Type:text/xml');
echo $result;
<?php

require '../library/SSRS/Report.php';
include_once 'Zend/Debug.php';
$options = array('username' => 'CaymanUnreg', 'password' => 'Gottex2011');
$ssrs = new SSRS_Report('http://212.203.112.85/reportserver/', $options);
$result = $ssrs->loadReport('/Off Shore/Cayman Weekly Risk');
Zend_Debug::dump($result);
//die();
$reportParameters = array('managedaccount' => '1');
$parameters = new SSRS_Object_ExecutionParameters($reportParameters);
$ssrs->setSessionId($result->executionInfo->ExecutionID)->setExecutionParameters($parameters);
$output = $ssrs->render('HTML4.0');
// PDF | XML | CSV
echo $output;