 <?php
Yii::app()->setLanguage(isset(Yii::app()->session['lang']) ? Yii::app()->session['lang'] : 'ar'); 
$lang=Yii::app()->getLanguage();
 ?>
<section class="financialStatements">
    <section class="financialStatements-section1">
        <div class="container">
            <div class="row">
                <div class="col-sm-offset-1 col-sm-10 col-xs-offset-0 col-xs-12">
                 
                </div>
            </div>
            <div class="row">
               <div class=" col-sm-12 col-xs-offset-0 col-xs-12"> 
               <div class="row">
               <div class="flex-cards-container">
             <?php
//$categories=Category::model()->getArticleByCategory('financial-statements' );
                $categories=Category::model()->getArticleByCategory('financial-statements' ) ;
                   // var_dump($categories->articles);die();

                    if($categories!=null)
                    {
                    foreach($categories as $report)
                    {
               ?>
              <div class=" col-sm-3 col-xs-6 card-container">
         
                <div class="card-item col-xs-12"> 
                    <div class="card-title text-center"><?php echo ($lang=='ar'?$report->title:$report->en_title) ?></div>
                    <div class="card-date text-center"></div>
                    <div class="view-download-file row">
                        <div class="col-xs-5 view-file text-center">
                        <?php echo '
                           <a href="'.Yii::app()->request->baseUrl.'/uploads/Article/files/'.$report->attachment_title.'" target="_blank">
                             ';
                             ?>
                           <li class="fa fa-eye ">
                            </li></a> 
                        </div>
                        <div class="col-xs-2 line-div text-center">
                            <div class="row">|</div> 
                        </div>
                        <div class="col-xs-5 download-file text-center">
                        <?php 
                            echo  '
                            <a href="'.Yii::app()->request->baseUrl.'/uploads/Article/files/'.$report->attachment_title.'" download>
                            ';
                            ?>
                            <li class="glyphicon glyphicon-download-alt">
                            </li></a>
                        </div>  
                    </div>
                 </div>
                
                </div>
<?php }}  ?>  
                   
               </div>
            </div> 
        </div>
    </section>
</section>
<script  type="application/javascript" src="<?php echo Yii::app()->request->baseUrl; ?>/js/script.js"></script>
<script>
// $('.financialStatements-section1 .card-item').hover(function(){
//     $($(this).children('.financialStatements-section1 .view-download-file.row')).toggleClass('hover-style');
// });
</script>
