<!-- include 'header' -->
<link rel=stylesheet href="<?= WEB_SITE_GLOBAL ?>css/jquery.validator.css">
<script type="text/javascript" src="<?= WEB_SITE_GLOBAL ?>js/jquery.validator.min.js"></script>
<script type="text/javascript" src="<?= WEB_SITE_GLOBAL ?>js/zh-CN.js"></script>
<script src="<?= WEB_SITE_GLOBAL ?>js/invoice.validator.js"></script>
<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">
					<!-- include 'invoiceMenu' -->
				</div>
			</div>
			<div class="adminContent autoHeight">
				<legend>
					发票管理 <a href="/invoiceReceivablesAS">收款管理</a>
				</legend>
				<div class="demandCate">
				<form action="/invoiceAS/1/{{status}}" id="iras" method="get">
					<ul class="cateList">
	  					<li>  
	  					<a <!-- if {{status}}=='All' --> class="now" <!-- endif -->  href="/invoiceAS">所有</a>
	  					<a <!-- if {{status}}=='UNRECORD' --> class="now" <!-- endif --> href="/invoiceAS/1/UNRECORD" title="未入账">未入账</a>
	  					<a <!-- if {{status}}=='RECORD' --> class="now" <!-- endif --> href="/invoiceAS/1/RECORD" title="已入账">已入账</a>
	  					<a <!-- if {{status}}=='BOUNCED' --> class="now" <!-- endif --> href="/invoiceAS/1/BOUNCED" title="已退票">已退票</a>
	  					<a <!-- if {{status}}=='PARTRECORD' --> class="now" <!-- endif --> href="/invoiceAS/1/PARTRECORD" title="部分入账">部分入账</a>
	  					</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>
						<th>状态</th>
						<th>操作</th></tr>
						<!-- loop list -->
						<tr>
							<td>
							<a href="#invdetail" node-invoice='INFO' data-isKey="{{list' value.iidKeyK}}" data-toggle="modal">
							{{list' value.invoiceSerial}}</a>
							<!-- if {{list' value.untreadStatus}}==2  -->
								（退票）
							<!-- endif -->
							</td>
							<td>
								<!-- if !empty({{list' value.invoiceType}}) -->
	                        	<b>￥{{list' value.invoicePrice}}</b><sup>专</sup>
	                          <!-- else -->
	                          <b>￥{{list' value.invoicePrice}}</b>
	                          <!-- endif -->
							</td>
							
							<td>
							<!-- if {{list' value.settlementType}}==1  -->
								培训班（<a href="/invoiceTrainingDetail/{{list' value.trainIdKey}}.html" target="_blank">查看</a>）
							<!-- else -->
								软件销售
							<!-- 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>{{invoiceList' value.invoiceNo}}</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>
							
							<td>
							<!-- if {{list' value.untreadStatus}}==2 -->
	                                  	已退票
	                        <!-- elseif {{list' value.untreadStatus}}==1 -->
	                                  	正在退票
	                        <!-- endif -->
							</td>
							
							<td>
							<!-- if ({{list' value.sumPrice}}<{{list' value.invoicePrice}}||{{list' value.sumPrice}}==0)&& {{list' value.untreadStatus}}==0 && {{list' value.status}}==2 && {{list' value.printStatus}}==1 -->
							<a href="#recorded" node-invoiceReceivables='INFO' data-isKey="{{list' value.iidKeyK}}" data-toggle="modal">入账</a>
							<!-- 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="/invoiceAS/{{page.previous}}{{get}}" title="上一页">&lt;</a></li>
								<!-- endif -->	
								
	  							<!-- if {{page.on_page}}>=3 -->
	  							<li><a href="/invoiceAS/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="/invoiceAS/4{{get}}" >4</a></li>
	  							<li><a href="/invoiceAS/5{{get}}" >5</a></li>
	  							<!-- endif -->
	  							
	  							<!-- if {{page.total_page}}>3 -->
	  							<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="/invoiceAS/{{page.next}}{{get}}" title="下一页">&gt;</a></li>
								<!-- endif -->
			  					
			  		</ul>
			  	</div>		
			  	
			  	
			  	
			</div>
		</div>
	</div>
	<!--弹出（发票入账）-->
	<div class="modal hide fade" id="recorded">
	<div class="modal-dialog modal-lg">
		<div class="modal-content">
		
		<form action="/invoiceCompareClaimPrice" method="post" name="receivablesInvoice">
			<input type="hidden" name="iidKey" id="inKey" value="">
			<div class="modal-header">
				<h3>发票入账</h3>
			</div>
			<div class="modal-body saeaList">
			
				<table class="table table-bordered table-condensed">
					<tbody>
					<tr>
						<th class="taC" colspan="4">收款信息填写</th>
					</tr>
					<tr>
						<th class="taC">收款金额</th><td><input checkInvoicePrice=true  name="receivablesPrice" placeholder="输入开票金额" pattern="[0-9]" min="0" step="0.01" type="number">
						<span class="colRed colTip"><span style="position:absolute;z-index=1;width:150px;top:-12px"  checkInvoicePrice=msg></span></span></td>
					</tr>
					<tr>
						<th class="taC">收款信息</th><td><input type="text" name="receivablesMessage"  ></td>
					</tr>
					<tr>
						<th class="taC">收款银行</th><td>
						<select name="receivablesBank">
								<option value="纵横广发">纵横广发</option>
									<option value="纵横工行">纵横工行</option>
									<option value="华润银行">华润银行</option>
									<option value="个人广发">个人广发</option>
							</select>
							</td>
					</tr>
					<tr>
						<th class="taC">银行到账时间</th><td><input name="receivablesDate"  type="date"></td>
					</tr>
					</tbody>
				</table>
				
				<div id="irtc"></div>
			</div>
			<div class="modal-footer">
				<input type="submit" class="button"  value="确认入账">
				
				<a href="#" class="button btn-gray" data-dismiss="modal" aria-hidden="true">关闭</a>
			</div>
		</form>
		</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>
