<!-- include 'header' -->
<script src="<?= WEB_SITE_GLOBAL ?>js/invoice.js"></script>
<link href="<?= WEB_SITE_GLOBAL ?>css/datepicker.min.css" rel="stylesheet" type="text/css">
<script src="<?= WEB_SITE_GLOBAL ?>js/datepicker.min.js"></script>
<script src="<?= WEB_SITE_GLOBAL ?>js/datepicker.zh.js"></script>
<body>
	<div class="mainLayout">
		<div class="mainMenu">
			<div class="menuItem">
				<a href="#" class="mLogo">CLD</a>
				<ul>
					<!-- include 'menuReceipt' -->
				</ul>
			</div>
			
		</div>
		<div class="warpContent">
			<div class="subMenu fL">
				<div class="menuItem">
					<ul>
						<!-- include 'invoiceMenu' -->
					</ul>
				</div>
			</div>
			<div class="adminContent autoHeight">
				<legend>
					{{staffDetail.username}}开票汇总 <a href="/invoiceAggregateStaffReceivablesDetail?&sidKey={{sidKey}}">{{staffDetail.username}}收款汇总</a>
				</legend>
				<div class="demandCate">
				<form action="/invoiceAggregateStaffDetail/1/{{status}}?&sidKey={{sidKey}}" id="iaa" method="get">
					<ul class="cateList">
	  					<li>  
	  					<a <!-- if {{status}}=='All' --> class="now" <!-- endif -->  href="/invoiceAggregateStaffDetail?&sidKey={{sidKey}}">所有</a>
	  					<a <!-- if {{status}}=='UNRECORD' --> class="now" <!-- endif --> href="/invoiceAggregateStaffDetail/1/UNRECORD?&sidKey={{sidKey}}" title="未入账">未入账</a>
	  					<a <!-- if {{status}}=='RECORD' --> class="now" <!-- endif --> href="/invoiceAggregateStaffDetail/1/RECORD?&sidKey={{sidKey}}" title="已入账">已入账</a>
	  					<a <!-- if {{status}}=='BOUNCED' --> class="now" <!-- endif --> href="/invoiceAggregateStaffDetail/1/BOUNCED?&sidKey={{sidKey}}" title="已退票">已退票</a>
	  					<a <!-- if {{status}}=='PARTRECORD' --> class="now" <!-- endif --> href="/invoiceAggregateStaffDetail/1/PARTRECORD?&sidKey={{sidKey}}" title="部分入账">部分入账</a>
	  					</li>
	  					<li>
	  						<select name="sidKey" node-invoicetype>
	  						<!-- loop staffList -->
	  							<option <!-- if {{staffList' value.sid}}=={{staffDetail.sid}} --> selected <!-- endif --> value="{{staffList' value.sidKey}}">{{staffList' value.username}}</option>
	  						<!-- endloop -->
	  						</select>
	  					</li>
							<li>
								<div class="search">
									<div class="input-append">
										<input class="datepicker-here span3" name="date" value="{{date}}" placeholder="按出票时间筛选" data-range="true" 
										data-multiple-dates-separator=" : " data-language="zh" type="text">
										<button class="btn btn-small" type="submit">查询</button>
									</div>
								</div>
							</li>
							<li><div class="search"><div class="input-append">
									<input class="span3" placeholder="开票单位" name="MebSea" value="{{MebSeaEn}}" type="text">
									<button class="btn btn-small" node-irmMebSea type="submit">搜索</button>
								</div>
							</div></li>
					</ul>
					</form>
	  		</div>
				<div class="saeaList">
					<table class="table table-hover">
						<tbody>
							<tr class="thead">
							<th>开票人</th>
							<th>开票流水</th>
							<th>开票金额</th>
							<th>开票单位（抬头）</th>
							<th>开票内容</th>
							<th>出票时间</th>
							<th>状态</th>
							<th>收款流水号</th>
							<th>收款金额</th>
							</tr>
							
		  				
		  				<!-- loop list -->
						<tr>
						
						<td>{{list' value.userName}}</td>
							<td><a href="#invdetail" node-invoice='INFO' data-isKey="{{list' value.iidKeyK}}" data-toggle="modal">{{list' value.invoiceSerial}}</a></td>
							<td>
								<!-- if !empty({{list' value.invoiceType}}) -->
	                        	<b>￥{{list' value.invoicePrice}}</b><sup>专</sup>
	                          <!-- else -->
	                          <b>￥{{list' value.invoicePrice}}</b>
	                          <!-- endif -->
							</td>
							
							<td>
								<!-- if !empty({{list' value.invoiceType}}) -->
	                                   	{{list' value.invoiceCompany}}
	                                    <!-- else -->
	                                    {{list' value.invoiceTitle}}
	                                    <!-- endif -->
							</td>
							<!-- <td>{{invoiceList' value.invoiceNo}}</td> -->
							<td>{{list' value.invoiceElement}}</td>
							<td>
							{{list' value.printTime}}
							</td>
							
							<td>
							<!-- if {{list' value.untreadStatus}}==2 -->
	                                                                 已退票
	                        <!-- endif -->
							</td>
							
							<td>
							<!-- loop list' value.irList -->
							<a href="#billing" node-invoice='INFO' data-type="receivables" data-isKey="{{list' value' value.iridKeyK}}" data-toggle="modal">{{list' value' value.receivablesSerial}}</a>&nbsp;
							<!-- endloop -->
							</td>
							<td>
							<!-- if {{list' value.sumPrice}}==0 -->
							<!-- elseif {{list' value.sumPrice}}=={{list' value.invoicePrice}} -->
							<b >￥{{list' value.sumPrice}}</b>
							<!-- elseif {{list' value.sumPrice}}>{{list' value.invoicePrice}} -->
							<b class="colOrange">￥{{list' value.sumPrice}}</b>
							<!-- elseif {{list' value.sumPrice}}<{{list' value.invoicePrice}} -->
							<b class="colRed">￥{{list' value.sumPrice}}</b>
							<!-- endif -->
							</td>
							
							
							
							
						</tr>
						<!-- endloop -->
		  				
		  				
						</tbody>
					</table>
				</div>
				<!--翻页-->
				<div class="demandPage">
					<ul class="pagination fL">
	  							<!-- if {{page.previous}}==0 -->
								<li><a href="javascript:void(0)" title="上一页">&lt;</a></li>
								<!-- else -->
								<li><a href="/invoiceAggregateStaffDetail/{{page.previous}}{{get}}" title="上一页">&lt;</a></li>
								<!-- endif -->	
								
	  							<!-- if {{page.on_page}}>=3 -->
	  							<li><a href="/invoiceAggregateStaffDetail/1{{get}}" title="上一页">1</a></li>
	  							<li class="point"><span>...</span></li>
	  							<!-- endif -->
	  							{{page.page}}
	  							<!-- if {{page.on_page}}<3 && {{page.total_page}}>5 -->
	  							<li><a href="/invoiceAggregateStaffDetail/4{{get}}" >4</a></li>
	  							<li><a href="/invoiceAggregateStaffDetail/5{{get}}" >5</a></li>
	  							<!-- endif -->
	  							
	  							<!-- if {{page.total_page}}>3&&{{page.total_page}}!={{page.on_page}} -->
	  							<li class="point"><span>...</span></li>
			  					<!-- endif -->
			  					
			  					<!-- if {{page.next}}=={{page.on_page}} -->
								<li><a href="javascript:void(0)" title="下一页">&gt;</a></li>
								<!-- else -->
								<li><a href="/invoiceAggregateStaffDetail/{{page.next}}{{get}}" title="下一页">&gt;</a></li>
								<!-- endif -->
			  					
			  		</ul>
			  	</div>	
			</div>
		</div>
	</div>
	
	
	<div loading-msg='true' style="position:absolute;  left:50%;  top:50%;  "></div>
	
	<div class="modal  fade" id="invdetail">
		
		<div id="nc"></div>
	</div>
	<div class="modal  fade" id="billing">
		<div id="nr"></div>
	</div>
	
<script type="text/javascript">autoFlashHeight();</script>
</body>
