<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>{$language.lblAdmin} : {$language.lblQueuedEmails}</title>
{include file='CommonStyles.tpl'}
{include file='CommonJavaScript.tpl'}
<link href="{$view_styles}/grid_listing.css"rel="stylesheet" type="text/css" />
<link href="{$view_styles}/right-menu.css"rel="stylesheet" type="text/css" />
<link href="{$view_styles}/colorbox.css" rel="stylesheet" type="text/css" />
{include file='CommonCustomStyles.tpl'}
</head><body>
<div class="outer_container">  
  {include file='CommonTop.tpl'}
  <!--End:Header Container-->
  <!--**************************************START CONTAINER SECTION**************************************************-->
  <div class="content_container2 clearfix">
   <div class="right-sidebar">
      <div class="side_wrapper">
        {include file="NewsLetterRightBlock.tpl"}
      </div>
    </div> 
    <!--End: Right Block-->
    <div class="left_wrapper">
     <div class="content_wrapper">
	 <div class="strict_fixing_right">
	   {include file='ContentLanguageOptions.tpl'}
	   </div>
          <h2>{$language.lblQueuedEmails}</h2>  
          <div id="common_message"></div>
          <div class="inner_content_wrapper">
          {if $resQueuedMails}<div class="grid_table00" > 
            <table width="100%" border="0" cellspacing="0" cellpadding="0">
            <thead>
              <tr>
                <th align="left" valign="middle" width="30%">{$language.lblSubject}</th>
                <th align="left" valign="middle">{$language.lblScheduledDate}</th>
                <th align="left" valign="middle" width="14%">{$language.lblCountQueuedMails}</th>
                <th align="left" valign="middle" width="14%">{$language.lblTotalSent}</th>
                <th align="left" valign="middle" width="20"></th>
              </tr>
              </thead>
              {foreach from=$resQueuedMails item=queuedMail key=i}
              {assign var="id" value=$queuedMail.mailQueueID|default:''}
              <tbody>
              <tr>

                <td align="left" valign="top">{$queuedMail.mailSubject} <br /></td>
                <td align="left" valign="top">
				{if $queuedMail.mailScheduledTime neq '0000-00-00 00:00:00'}
				{$queuedMail.mailScheduledTime|date_format:$date_format} {$queuedMail.mailScheduledTime|date_format:$time_format}<br />{/if}</td>
                <td align="left" valign="top">{$queuedMail.totalEmailCount}</td>
                <td align="left" valign="top">{$queuedMail.totalRemainingCount}</td>
                <td align="left" valign="top">
                    {html->anchor href="emailqueue/ajaxpreview/id/$id/" id="mailqueue_$id" class="fancylink preview icon-set" title="{$language.lblPreview}"  history="emailqueue"}
                  </td>
              </tr>
              {foreachelse}
              <tr>
              <td colspan="7">{$language.msgNoProducttypeAvailable} </td>
              </tr>
              </tbody>
              {/foreach}              
            </table>
            </div>
               <div class="fixing_right pagination_outer">{paginate->layout key="page" label_record="{$language.lblRecorsFound}" label_pages="{$language.lblPages}"} </div>
               <div class="clear"></div>
            {else}
            <div id="common_message" class="message_info">{$language.msgNoRecords}</div>
            {/if} 
          <!--End:Table Listing-->
          </div>
        </div>
        <!--End:Border 3-->
      </div>
      <!--End:Border 2-->
  </div>
  <!--***************************************END CONTAINER SECTION*************************************************-->
  <!--End:Content Container-->
   {include file='CommonBottom.tpl'} 
</div>
<!--End:Outer Container-->
<script type="text/javascript">
$(document).ready(function(){						 
	$('.side_wrapper ul li a[rel=queuedEmailList]').addClass('selected'); 	
	 setSideMenu();
});
</script>
<script type="text/javascript" src="{$common_js}/jquery-ui-1.10.2.custom.min.js"></script>
<script type="text/javascript" src="{$view_javascript}/emailqueue.page.js"></script>
<script type="text/javascript" src="{$view_javascript}/jquery.colorbox.js"></script>
{include file='CommonJavaScriptBottom.tpl'} 
{html->messages_script id="common_message" section="newsletter"}
</body>
</html>
