<?php

$Annuncements       = new Announcement;
$url                = explode('/',  $_SERVER['REQUEST_URI']);
$AnnouceID	    	= $url[count($url)-1];
$Annouce_Details    = $Annuncements->viewWithApproved($AnnouceID);
if(empty ($Annouce_Details)) { ?>
<div class="alert alert-danger" role="alert">
    <button class="close" data-dismiss="alert"></button>
   <strong><?php print CommonLanguage::getMessage('no_annoc');?></strong>
</div>
<?php  die (); } 
?>
<style>
    .bg-master-lighter {
        border:none;
        background-color:#fff;
        border-top:1px solid #ddd;  
    }
</style>
<div class="wrapper">
    <div class="panel invoice">
        <div class="panel-body">
            <div class="row">
                <h1><?php print CommonLanguage::getMessage('view_announcement');?></h1>
                <div class="col-md-12 ">
                    <div class="col-md-3">
                        <label><strong><?php print CommonLanguage::getMessage('title');?> :</strong></label>
                        
                            <?php echo $Annouce_Details[0]['Announcement_Title']?>
                        
                    </div>  
                    <div class="col-md-3">
                        <label><strong><?php print CommonLanguage::getMessage('subtitle');?> :</strong></label>
                        
                            <?php echo $Annouce_Details[0]['Announcement_Subtitle']?>
                      
                    </div>  
                    <div class="col-md-3">
                        <label><strong><?php print CommonLanguage::getMessage('Date');?> :</strong></label>
                            <?php echo $Annouce_Details[0]['Announcement_DateCreated'].'/'.$Annouce_Details[0]['Post_Time']?>

                    </div>  
                </div>
                <br>
                <div class="col-md-12">
                    <div class="col-md-1">
                        <label><strong><?php print CommonLanguage::getMessage('msg');?> :</strong></label>
                    </div>
                        <div class="col-md-11">
                                <?php echo $Annouce_Details[0]['Announcement_Content'];?>
                        </div>
                    </div>
                </div>
                <br>
                <nav class="navbar navbar-default bg-master-lighter sm-padding-10" role="navigation">
                    <div class="container-fluid">
                        <div class="collapse navbar-collapse" id="sub-nav">
                            <div class="row"> 
                                <div class="col-sm-4 ">
                                    <ul class="nav navbar-nav navbar-center">
                                        <li><a href="#"  title="Print" data-target="#printmodal" data-toggle="modal" onclick="javascript:window.print();"><i class="fa fa-print"></i></a></li>
                                        <li><a href="#" data-toggle="tooltip" data-placement="top" title="Download"><i class="fa fa-download"></i></a></li>
                                    </ul>
                                </div>
                                <div class="col-sm-4 pull-right">
                                    <ul class="nav navbar-nav navbar-right">
                                        <li>
                                            <a href="#" class="p-r-10"><img width="25" height="25" alt="" class="icon-pdf" data-src-retina="<?php echo SITE_LINK; ?>img/invoice/pdf2x.png" data-src="<?php echo SITE_LINK; ?>img/invoice/pdf2x.png" src="<?php echo SITE_LINK; ?>img/invoice/pdf2x.png"></a>
                                        </li>
                                        <li>
                                            <a href="#" class="p-r-10"><img width="25" height="25" alt="" class="icon-image" data-src-retina="<?php echo SITE_LINK; ?>img/invoice/image2x.png" data-src="<?php echo SITE_LINK; ?>img/invoice/image2x.png" src="<?php echo SITE_LINK; ?>img/invoice/image2x.png"></a>
                                        </li>
                                        <li>
                                            <a href="#" class="p-r-10"><img width="25" height="25" alt="" class="icon-doc" data-src-retina="<?php echo SITE_LINK; ?>img/invoice/doc2x.png" data-src="<?php echo SITE_LINK; ?>img/invoice/doc2x.png" src="<?php echo SITE_LINK; ?>img/invoice/doc2x.png"></a>
                                        </li>
                                        <li><a href="#" class="p-r-10" onclick="$.Pages.setFullScreen(document.querySelector('html'));return false"><i class="fa fa-expand"></i></a></li>
                                    </ul>
                                </div>
                            </div>
                        </div>
                    </div>
                </nav>
            </div>
        </div>
    </div>
