<?php include_once(mvc::$cfg['PATH_TPL'].'public/headBase.php');?>
<div class="marauto" style="margin :6px auto;width: 80%;font-size: 14px;">
	<div class="">
		<div class="main_middle">
			<form method="post" id="checkTiXian-form">
				<input type="hidden" name="tmt_id" value="<?php echo $txArr['tmt_id'];?>">
				<table class="table table-bordered">
					<tbody>
						<tr>
							<th width="100px" class="right">提现人</th>
							<td><?php echo $txArr['tg_mobile'];?></td>
						</tr>
						<tr>
							<th width="100px" class="right">提现人微信</th>
							<td><?php echo $txArr['tmt_tg_weixin'];?></td>
						</tr>
						<tr>
							<th width="100px" class="right">当前状态</th>
							<td>
								<label class="status-label">
									<input  type="radio" <?php if($txArr['tmt_status']==-1){?> checked <?php }?> <?php if($txArr['tmt_status']!=0){?> disabled <?php }?> name="tmt_status" value="-1">已取消
								</label>
								<label class="status-label">
									<input type="radio" name="tmt_status" disabled <?php if($txArr['tmt_status']==0){?> checked <?php }?> value="0">处理中
								</label>
								<label class="status-label">
									<input type="radio" name="tmt_status" <?php if($txArr['tmt_status']!=0){?> disabled <?php }?> <?php if($txArr['tmt_status']==1){?> checked <?php }?> value="1">转账完成
								</label>
							</td>
						</tr>
						<tr>
							<th width="100px" class="right">申请时间</th>
							<td><?php echo date('Y-m-d H:i:s',$txArr['tmt_atime']);?></td>
						</tr>
						<?php if($txArr['tmt_status'] !=-1 ){?>
						<tr>
							<th width="100px" class="right">到账时间</th>
							<td><input class="form-control" <?php if($txArr['tmt_status']==1){?> disabled <?php }?> type="text" id="comTime" name="tmt_pay_time" value="<?php echo $txArr['tmt_pay_time']?date('Y-m-d H:i:s',$txArr['tmt_pay_time']):'';?>"></td>
						</tr>
						<?php }?>
						<?php if(!empty($txArr['tmt_close_time'])){?>
						<tr>
							<th width="100px" class="right">关闭时间</th>
							<td><?php echo $txArr['tmt_close_time']?date('Y-m-d H:i:s',$txArr['tmt_close_time']):'';?></td>
						</tr>
						<?php }?>
						<tr>
							<th width="100px" class="right">提现金额</th>
							<td><?php echo sprintf('%.2f',$txArr['tmt_moeny']);?></td>
						</tr>
						<?php if(!empty($txArr['tmt_check'])){?>
						<tr>
							<th width="100px" class="right">审核人</th>
							<td><?php echo $txArr['tmt_check'];?></td>
						</tr>
						<?php }?>
						<tr>
							<th width="100px" class="right">凭证/备注</th>
							<td>
								<?php if($txArr['tmt_status'] == 0){?>
								<script id="ctr_remark" name="tmt_txt" type="text/plain"><?php echo $txArr['tmt_txt'];?></script>
								<script type="text/javascript">
									var ue = UE.getEditor('ctr_remark', { initialFrameWidth:1200, initialFrameHeight: 460});
									UE.Editor.prototype._bkGetActionUrl = UE.Editor.prototype.getActionUrl;  
								    UE.Editor.prototype.getActionUrl = function(action) 
								    {  
								        if (action == 'uploadimage') 
								        {
								        	//跳转到后来的上传action  
								            return "<?php echo mvc::$cfg['ADMIN_URI'];?>article/uploadImg?isAjax=1&cate=purchase&site=pjl";  
								        }else 
								        {  
								            return this._bkGetActionUrl.call(this, action);  
								        }  
								    } 
								</script>
								<?php }else{?>
								<?php echo $txArr['tmt_txt'];?>
								<?php }?>
							</td>
						</tr>
					</tbody>
				</table>
			</form>
			<?php if($txArr['tmt_status']==0){?>
			<div class="center confirm-btn"  style="width: 100%;">
				<input type="submit" id="checkTiXian-btn" class="btn btn-danger" value="确认审核">
			</div>
			<?php }?>
		</div>
		<div class="clear"></div>
	</div>
</div>
<script type="text/javascript">
	$(document).ready(function(){
		$('#checkTiXian-btn').click(function(){
			var isEmpty=UE.getEditor('ctr_remark').hasContents()
			if(!isEmpty){
				MESSAGE.alert('凭证/备注不能为空');
				return false;
			}
			$('#checkTiXian-form').submit();
		});
		laydate.render({ 
	      elem: '#comTime',
	      type:'datetime'
	    });
	});
</script>
<?php include_once(mvc::$cfg['PATH_TPL'].'public/footBase.php');?>