<!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.lblAffiliate} : {$language.lblPaymentReport} : {$language.lblTransactions}</title>
{include file='CommonStyles.tpl'}
<link rel="stylesheet" type="text/css" href="{$view_styles}/ui.daterangepicker.css" />
<link rel="stylesheet" type="text/css" href="{$view_styles}/affiliates.css" />
{include file='CommonJavaScript.tpl'}
{literal}
<style>
.Unread a {
	color: #FE7800;
}
</style>
{/literal}
</head>
<body>
<div class="outer_container">
 {include file='CommonTop.tpl'} 
  <!--End:Header Container--> <!--***********************************************************************END HEADER CONTAINER******************************************************-->
  <div class="content_container2">
    <!-- left wrapper starts-->
    <div class="left_wrapper">
    <div class="content_wrapper">
    
    	 <div class="search_tab fixing_right">
                <ul>
                  <li class="first">
                  {html->anchor href="/payment/pending/$link" class="search_tab_a" caption=$language.lblPendingPayments}
                  </li>
                  <li>{html->anchor href="/payment/received/$link" class="search_tab_a"  caption=$language.lblReceivedPayments}</li>
                  <li class="last">{html->anchor href="/payment/transaction/$link" class="search_tab_a  active" caption=$language.lblTransactions}</li>
                </ul>
      </div>
            <div id="common_message"></div>
      <h2>{$language.lblTransactions}</h2>
      <!-- Inner Content Container starts-->
      <div class="inner_content_wrapper">
      
          <div class="search_container">
  <div class="inner">
  {form->start name="frmSearchProduct"  method="post"}
  {form->hidden id="searchAlert" name="searchAlert" value=$language.errStartEndDate}
  <table width="100%" border="0" cellspacing="0" cellpadding="0"   >
  <tr>
    <td width="11%" align="left" valign="middle" class="left">{$language.lblTransactionDate} &nbsp;</td>
    <td width="20%" align="left" valign="middle">
   		<div class="textfield">
        <div class="text-box-div-date">{form->textbox name="date" type="text" id="daterange" class="text-box date-field" readonly="true"} </div>
        </div>
    </td>
	<td width="10%" align="left" valign="middle" class="left">{$language.lblTransactionID} &nbsp;</td>
    <td width="20%" align="left" valign="middle">
     <div class="textfield">
          <div class="text-box-div">
            {form->textbox name="transactionID" id="transactionID" value=$transactionID type="text" class="text-box"}
          </div>
        </div>
     </td>
	 
      <td width="20%" align="left" valign="middle" class="padding-r-10"> 
                  	{form->submit name="searchTransaction" value={$language.lblSearch} class="button01"}
                    {html->anchor href="/payment/transaction/" class="action-link" caption=$language.lblResetFields}
     </td>
  </tr>
</table>
 </div> </div><!--END:sEARCH cONTAINER-->  
 {if $resListTransactions} {html->anchor class="link-style01 fixing_right" href="{$link}/export/1/" caption="{$language.lblExportToCsv}"}
{form->close} 
<div class="clear"></div>
<div class="grid01"> 
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="grid_table00"  >
			<thead>
              <tr>
                 <th align="left" valign="middle" class="sort{if $sortByOption eq 'stransactionID'}{$sortByOrder}{/if}">
                 {html->anchor href="/payment/transaction/$normallink/sortby/stransactionID/orderby/$sortByTransactionID/" title="{$language.lblTransactionID}" 	content="{$language.lblTransactionID}"}
                 </th>
                  <th align="left" valign="middle" class="sort{if $sortByOption eq 'stransactionDate'}{$sortByOrder}{/if}">
                {html->anchor href="/payment/transaction/$normallink/sortby/stransactionDate/orderby/$sortByTransactionDate/" title="{$language.lblTransactionDate}" 	content="{$language.lblTransactionDate}"}
                </th>
                  <th align="left" valign="middle" class="sort{if $sortByOption eq 'stransactionType'}{$sortByOrder}{/if}">
                {html->anchor href="/payment/transaction/$normallink/sortby/stransactionType/orderby/$sortByTransactionType/" title="{$language.lblTransactionType}" 	content="{$language.lblTransactionType}"}
                </th>
                 <th  align="left" valign="middle" class="sort{if $sortByOption eq 'stransactionAmt'}{$sortByOrder}{/if}">
                {html->anchor href="/payment/transaction/$normallink/sortby/stransactionAmt/orderby/$sortByTransactionAmt/" title="{$language.lblTransactionAmount}" 	content="{$language.lblAmountReceived}"}
                </th>
                <th align="left" valign="middle" class="">
                {$language.lblTransactionDetails}
                </th>
              </tr> 
              </thead>
              <tbody>             
              {foreach item="resListTransaction" from=$resListTransactions key="key1"}
              <tr>
                <td align="left" valign="middle">
                <div class={if $resListTransaction.readStatus eq 'Unread'}Unread{assign var="setStar" value="&#42;"}{else}{assign var="setStar" value=""}{/if}>
                {html->anchor href="/payment/transactiondetails/transactionID/{$resListTransaction.transactionID}/"  history="yes" trid="{$resListTransaction.transactionID}" content="{$resListTransaction.transactionID} {$setStar}"}</div>
                </td>
                 <td align="left" valign="middle">
                {$resListTransaction.completedDate|date_format:$date_format} {$resListTransaction.completedDate|date_format:$time_format}</td>  
                <td align="left" valign="middle">{$resListTransaction.transactionType}</td>
                 <td align="left" valign="middle">
                 <strong>                
                  {$resListTransaction.commissionAmount|price} </strong></td>
                 <td align="left" valign="middle">{$resListTransaction.transDescriptionAffiliate}</td>
              </tr>
              {/foreach}
            </tbody>
            </table>
</div>            
            {else}
               <div id="common_message"  class="message_info"> {$language.msgNoRecords}</div>
            {/if}
          <!--End:From Listing--> 
    </div>
    </div>
    </div>
     <!-- left wrapper ends--> 
    <!-- right side bar starts-->
    <div class="right-sidebar">
      <div class="side_wrapper"> 
        <!-- right side menu starts--> 
        {include file='AffReportSideMenu.tpl'} 
        <!-- right side menu ends--> 
      </div>
    </div>
    <!-- right side bar ends-->
    <div class="clear"></div>
  </div>
  <!-- Content Container ends--> 
  <!-- Footer starts--> 
  {include file='CommonBottom.tpl'} 
  <!-- Footer ends--> 
</div>
<!-- Outer container ends--> 
{form->rootpath_script}
{form->basepath_script}
<script type="text/javascript" src="{$view_javascript}/message.plugin.js"></script>
<script>
{literal}
var d 		= new Date();
var nd 		= new Date(d.getFullYear(),d.getMonth(),d.getDate()+1,d.getHours()-1,d.getMinutes(),d.getSeconds());	
 $(function(){	  
	 $('#daterange').daterangepicker({arrows: false,presets:{		
			specificDate: 'Specific Date', 
			dateRange: 'Date Range'
		},presetRanges: [
			{text: 'Today', dateStart: 'today', dateEnd: 'today' },
			{text: 'Last 7 days', dateStart: 'today-7days', dateEnd: 'today' },
			{text: 'Month to date', dateStart: function(){ return Date.parse('today').moveToFirstDayOfMonth();  }, dateEnd: 'today' },
			{text: 'Previous Month', dateStart: function(){ return Date.parse('1 month ago').moveToFirstDayOfMonth();  }, dateEnd: function(){ return Date.parse('1 month ago').moveToLastDayOfMonth();  } }

		],latestDate:nd,dateFormat:datePickerDateFormat,placeHolder:'dateOverView',rangeDays:90,rangeSplitter:' - ',datepickerOptions: {maxDate:nd}});
	});
	
$('.ui-daterangepicker-dateRange').addClass('ui-state-active');	

$(document).ready(function(e) {
$('.side_menu').find("a[rel='payment']").addClass('selected').removeBorder();
$('.main_menu').find("a[rel='affReports']").addClass('active');

});
{/literal}
</script>
</body>
</html>