Quantcast
Channel: Yii Framework Forum
Viewing all articles
Browse latest Browse all 18717

Reporting - Pass Parameters

$
0
0
hey i have successfully created static reports with the help of jasphp extension :)

i have created the necessary reports and stored them inside the project :unsure:


now i want to pass the parameters to generate some reports :( :(

this is my actionReport in the Controller (for static reports)
public function actionReport()
	{
            $reportfiledir =getcwd() . '/reports/';
            $filename = $_GET['file'] . '.jrxml';
                    $title = 'Hello World!';
                    Yii::app()->jasPHP->create(
                    $reportfiledir ,
                    $filename,
                    array(
                    'SUBREPORT_DIR'=>'./',
                    'title' => $title,'parameter1'=>$_GET['p']
                    ));
		
                
	
        }


this is the code in the view to get the report
(for static reports)
<?php echo CHtml::link('Generate PDF report', array('report','type'=>'jasphp', 'file' => 'report4dasad','p'=>'1')) ?>


can somebody tell me how to pass parameters ?? :( :(

thank you in advance ;D

Viewing all articles
Browse latest Browse all 18717

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>