<!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>
<title>{$language.lblAdmin} : {$language.lblManifests}</title>
{include file='CommonStyles.tpl'}
{include file='CommonJavaScript.tpl'}
{include file='CommonCustomStyles.tpl'}
<link href="{$view_styles}/jquery-ui-1.8.19.custom.css" rel="stylesheet" type="text/css" />
<link rel="stylesheet" type="text/css" href="{$view_styles}/grid_listing.css" media="screen" />
<link rel="stylesheet" type="text/css" href="{$view_styles}/ui.daterangepicker.css" />
{form->basepath_script}
{form->rootpath_script}
</head>
<body>
<div class="outer_container"> {include file='CommonTop.tpl'} 
  <!--End:Header Container--> 
  <!--***********************************************************************END HEADER CONTAINER******************************************************-->
  <div class="content_container">
    <div class="content_wrapper">
      <h2>{$language.lblManifests} </h2>
      <div class="inner_content_wrapper">
        <div id="common_message"></div>
        {form->start name="formShippingSearch" action="" method="post" enctype="multipart/form-data"}
        <div class="search_container">
          <div class="inner wide-box">
           <ul class="clearfix">
                <li class="column">
                  <p class="label-field01">{$language.lblLogisticPartner}</p>
                  <span class="textfield01">
 						{form->select name="sm_main" options=$resSmServices class="select-box" value="{$smGroupID|default:''}" validate="required" error=$language.lblErrorShippingMethod}
                 </span>
                </li>
                <li class="column">
                  <p class="label-field01">{$language.lblManifestNumber}</p>
                  <span class="textfield01">
                    {form->textbox name="manifestNumber" class="text-box"}
                  </span>
                </li>
                <li class="column">
                  <p class="label-field01">{$language.lblLastUpdatedDate}</p>
                 <span class="textfield01">               
                   <div class="text-box-div-date"> 
                      {form->textbox id="date" name="date" readonly="readonly" class="date-field" value=$hiddenFromDate|default:''}
                   </div>
                 </span>
                </li>
                <li class="column">
                  <p class="label-field01">&nbsp;</p>
                {form->submit name="submitSearch" form="formShippingSearch" class="button01" tabindex="1" value={$language.lblSearch}}
                {html->anchor href="/shipment/manifests/" caption="<span class=listall>{$language.lblListAll}</span>" class="action-link"}
                {form->hidden name="productType" id="productType" value=4}
                </li>
              </ul>
            <div class="clear"></div>
          </div>
        </div>
       
        <!--END:sEARCH cONTAINER--> 
        {form->close}
        {if $resManifests}
        <div class="grid_table00"> 
          <table width="100%" border="0" cellspacing="0" cellpadding="0"   >
            <tr>
			  <th align="left" valign="middle"  width="90" >Manifest ID
              </th>

			  <th align="center" valign="middle" >{$language.lblCreatedDate}
              </th>
              <th align="center" valign="middle" > {$language.lblLogisticPartner} </th>
              </th>
              <th align="left" valign="middle" >&nbsp;</th>
            </tr>
            {foreach from=$resManifests item="manifest" key="key1"}
            <tr {if $key1%2!=0} class="shade01" {/if}>
			  <td align="center" valign="middle">
				{$manifest.manifestNumber}
			  </td>
			  <td align="center" valign="middle">
				{$manifest.manifestCreateDate|date_format:$date_format}
			  </td>
             			<td align="center" valign="middle">
				{if $manifest.logisticPartner}{$manifest.logisticPartner} {else} Other{/if}
			  </td>  
          
			
              <td align="center" valign="middle"><center>
                                       {html->anchor history="yes" href="shipment/download/id/{$manifest.manifestID}/" class="" caption="Download"} 
				</center></td>
            </tr>
            {/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 class="message_info"> {$language.msgNoRecords}</div>
          {/if}
        <!--End:Table Listing--> 
      </div>
      <!--End: left Block-->
      <div class="clear"></div>
    </div>
  </div>
  <!--End:Content Container--> 
  {include file='CommonBottom.tpl'}
</div>
<!--End:Outer Container--> 
{include file='CommonJavaScriptBottom.tpl'} 
{html->messages_script id="common_message"} 
<script type="text/javascript" src="{$view_javascript}/manifests.page.js"></script> 
<script type="text/javascript" src="{$common_js}/date.js"></script>
<script type="text/javascript" src="{$view_javascript}/daterangepicker.jQuery.js"></script>
<script type="text/javascript" src="{$view_javascript}/jquery-ui-timepicker-addon.js"></script>
<script type="text/javascript">
var lblSelectAction			= '{$language.lblSelectAction}';
var lblSelectItem			= '{$language.lblSelectItem}';
var msgSelectSearchCriteria	= '{$language.msgSelectSearchCriteria}';
var lblSelectBusiness		= "{$language.lblSelectBusiness}";
var msgConfirmDelete		= "{$language.msgConfirmDelete}";
{literal}
$(function(){
	 $('#date').daterangepicker({arrows: false});
	 });
{/literal}
</script>

</body>
</html>