<!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">
<meta http-equiv="Content-Type" content="text/html; charset=gb2312"/>
<link rel="stylesheet" type="text/css" href="{$vd['sc']}css/main.css"/>
</head>
<body>
<!--$item = $vd['order']['item'];-->  
<div id="titleDiv">
<div style="float:left"><a href="index.php?a=home"><img src="{$vd['sc']}images/home.png" style="vertical-align:middle" border="0"/></a></div><div style="float:left;padding-top:8px;padding-left:3px;"><a href="index.php?a=home" title="回到后台首页"><font color="#000">桌面</font></a> <span style="font-size:7px;">>></span> <a href="index.php?m=mod_b2b&c=order&a=index" title="订单列表"><font color="#000">订单列表</font></a> <span style="font-size:7px;">>></span> <span style="font-size:12px;">订单详细信息</span></div>
<div style="float:right;"><a href="index.php" onFocus="this.blur()" title="查看订单相关帮助"><img src="{$vd['sc']}images/help.gif" style="vertical-align:middle" border="0"/></a></div>
<div>
    <form action="index.php?m=mod_b2b&c=order&a=check&ubzordno={$item['ordno']}" method="post">
      <table id="checktable" style="display:none" width="100%" style="border-collapse: collapse;">
        <!--if($item['ptype'] == 4 || $item['ptype'] == 5 ){-->
        <tr>
          <td class="tablelt" style="background:#F3F3F3"><input type="radio" value="2" name="ordstate" class="checkbox" checked />交易成功：</td>
          <td class="tablert" style="background:#F3F3F3">
            表示充值成功，请将交易记录凭证复制入下边方框
          </td>
        </tr>
        <tr>
          <td class="tablelt" style="background:#F3F3F3"><input type="radio" value="-1" name="ordstate" class="checkbox" onclick="setrollback()"/>取消交易：</td>
          <td class="tablert" style="background:#F3F3F3">
            <div style="height:22px;"><input type="radio" value="没有库存了，取消交易" name="failreason" class="checkbox" />没有库存了，取消交易</div>
            <div style="height:22px;"><input type="radio" value="由于厂商或者一些不可控因素，无法交易，请重新提交订单" name="failreason" class="checkbox" />由于厂商或者一些不可控因素，无法交易，请重新提交订单</div>
            <div style="height:35px;"><input type="radio" value="" name="failreason" class="checkbox" id="custom"/>自行输入
            <input type="text" value="一般错误" size="30" onkeyup="set(this)" onmouseup="set(this)"/></div>
            <div style="height:22px;"><input type="checkbox" id="rollback" value="1" name="rollback" class="checkbox" id="custom"/><font color="#ff0000">取消订单后时候恢复记录(如一卡通恢复原来余额！客户恢复余额)，同时选择取消充单才生效</font></div>
          </td>
        </tr>
        <tr>
          <td class="tablelt" style="background:#F3F3F3">交易记录凭证：</td>
          <td class="tablert" style="background:#F3F3F3">
            <textarea rows="5" name="factoryreturn" cols="50"></textarea>
          </td>
        </tr>
        <!--}else if($item['ptype'] == 6){-->
        <tr>
          <td class="tablelt" style="background:#F3F3F3"><input type="radio" value="2" name="ordstate" class="checkbox" checked />代练完成：</td>
          <td class="tablert" style="background:#F3F3F3">
            表示充值成功，请将代练完成凭证复制入下边方框
          </td>
        </tr>
        <tr>
          <td class="tablelt" style="background:#F3F3F3"><input type="radio" value="-1" name="ordstate" class="checkbox" onclick="setrollback()"/>取消代练：</td>
          <td class="tablert" style="background:#F3F3F3">
            <div style="height:22px;"><input type="radio" value="人员不足，无法代练" name="failreason" class="checkbox" />人员不足，无法代练</div>
            <div style="height:22px;"><input type="radio" value="由于一些不可控因素，无法代练，请重新提交订单" name="failreason" class="checkbox" />由于一些不可控因素，无法代练，请重新提交订单</div>
            <div style="height:35px;"><input type="radio" value="" name="failreason" class="checkbox" id="custom"/>自行输入
            <input type="text" value="一般错误" size="30" onkeyup="set(this)" onmouseup="set(this)"/></div>
            <div style="height:22px;"><input type="checkbox" id="rollback" value="1" name="rollback" class="checkbox" id="custom"/><font color="#ff0000">取消订单后时候恢复记录(如一卡通恢复原来余额！客户恢复余额)，同时选择取消充单才生效</font></div>
          </td>
        </tr>
        <tr>
          <td class="tablelt" style="background:#F3F3F3">代练记录凭证：</td>
          <td class="tablert" style="background:#F3F3F3">
            <textarea rows="5" name="factoryreturn" cols="50"></textarea>
          </td>
        </tr>
        <!--}else{-->
        <tr>
          <td class="tablelt" style="background:#F3F3F3"><input type="radio" value="2" name="ordstate" class="checkbox" checked />充值成功：</td>
          <td class="tablert" style="background:#F3F3F3">
            表示充值成功，请将厂家的充值记录复制入下边方框
          </td>
        </tr>
        <tr>
          <td class="tablelt" style="background:#F3F3F3"><input type="radio" value="-1" name="ordstate" class="checkbox" onclick="setrollback()"/>取消充值：</td>
          <td class="tablert" style="background:#F3F3F3">
            <div style="height:22px;">
            <input type="radio" value="厂商系统出错或维护，无法充值，请稍后重新购买" name="failreason" class="checkbox" />厂商系统出错或维护，无法充值，请稍后重新购买</div>
            <div style="height:22px;"><input type="radio" value="充值帐户不符，无法充值，请重新下单购买" name="failreason" class="checkbox" />充值帐户不符，无法充值，请重新下单购买</div>
            <div style="height:22px;"><input type="radio" value="充值区域不符，无法充值，请重新下单购买" name="failreason" class="checkbox" />充值区域不符，无法充值，请重新下单购买</div>
            <div style="height:22px;"><input type="radio" value="商品库存不足，请待我们补充库存后再购买" name="failreason" class="checkbox" />商品库存不足，请待我们补充库存后再购买</div>
            <div style="height:22px;"><input type="radio" value="由于厂商或者一些不可控因素，无法充值，请重新提交订单" name="failreason" class="checkbox" />由于厂商或者一些不可控因素，无法充值，请重新提交订单</div>
            <div style="height:35px;"><input type="radio" value="" name="failreason" class="checkbox" id="custom"/>自行输入
            <input type="text" value="一般错误" size="30" onkeyup="set(this)" onmouseup="set(this)"/></div>
            <div style="height:22px;"><input type="checkbox" id="rollback" value="1" name="rollback" class="checkbox" id="custom"/><font color="#ff0000">取消订单后时候恢复记录(如一卡通恢复原来余额！客户恢复余额)，同时选择取消充单才生效</font></div>
          </td>
        </tr>
        <tr>
          <td class="tablelt" style="background:#F3F3F3">厂商充值记录：</td>
          <td class="tablert" style="background:#F3F3F3">
            <textarea rows="5" name="factoryreturn" cols="50"></textarea>
          </td>
        </tr>
        <!--}-->
        <tr>
          <td class="tablelt" style="background:#F3F3F3;height:50px;"></td>
          <td class="tablert" style="background:#F3F3F3"><input type="submit" value="保存充值结果" class="btn" onclick="return confirm('确认更新订单状态么？如果取消订单，请确认是否需要补回余额')"/> <input type="reset" value="重置" class="btn"/> <input type="button" value="取消" class="btn" onclick="viewaction()"/></td>
        </tr>
      </table>
      </form>
  </div>
</div>

<div id="content" class="cwarpper">
<div class="cbodyHead"></div>
<div class="cwarpper1">
<div class="ctitle">基本信息 订单号：{$item['ordno']} ({#OrderState($item['ordstate'], $item['ptype'])})</div>
<div>
<table border="1" id="ctable1" class="ctable" bordercolor="#86B9D6">
  <tr>
    <td class="tablelt" height="50px">商品名称：</td>
    <td class="tablert"><b>{$item['pname']}</b></td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">订购数量：</td>
    <td class="tablert">{$item['qty']}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">商品单价：</td>
    <td class="tablert">{$item['cprice']} 元</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">订购总金额：</td>
    <td class="tablert">{$item['dollars']} 元</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">订购日期：</td>
    <td class="tablert">{$item['orddate']}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">供货来源：</td>
    <td class="tablert"><font color="#0000ff"><b><!--if($item['sup'] == 0) {-->本地供货<!--}else{-->联售系统供货<!--}--></b></font></td>
  </tr>
  <!--if($item['ordstate'] != 2 && isset($vd['suporder']['item']['ubzerrcontent'])){-->
  <tr>
    <td class="tablelt" height="50px">联售系统反馈：</td>
    <td class="tablert"><font color="#0000ff"><b>{$vd['suporder']['item']['ubzerrcontent']}</b></font></td>
  </tr>
  <!--}-->
  <!--if($item['ptype'] == 4 || $item['ptype'] == 5){-->
  <tr>
    <td class="tablelt">交易方式：</td>
    <td class="tablert"><textarea name="ubzabst" wrap="VIRTUAL" cols="50" rows="5" scrolling="yes" style="padding:5px">{$item['tradeterm']}</textarea></td>
  </tr>
  <!--}-->
  <!--if($item['ptype'] == 1 || $item['ptype'] == 2) {-->
  <tr>
    <td class="tablelt" height="50px">游戏用户名：</td>
    <td class="tablert">{$item['czaccount']}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">充值区域：</td>
    <td class="tablert">{#CzText($item['czarea1'])}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">充值服务器：</td>
    <td class="tablert">{#CzText($item['czarea2'])}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">计费方式：</td>
    <td class="tablert">{#CzText($item['cztype'])}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">帐号类型：</td>
    <td class="tablert">{#CzText($item['czother'])}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">处理时间：</td>
    <td class="tablert">{$item['dealdate']}</td>
  </tr>
  <!--if($item['ordstate'] == -1) {-->
  <tr>
    <td class="tablelt" height="50px">失败原因：</td>
    <td class="tablert"><font color="#ff0000"><!--if($item['rollback'] == 1){-->[<b>已经退款</b>]<!--}-->{$item['failreason']}</font></td>
  </tr>
  <!--}-->
  <tr>
    <td class="tablelt" height="50px">厂家反馈：</td>
    <td class="tablert"><textarea rows="5" cols="50">{$item['factoryreturn']}</textarea></td>
  </tr>
  <!--}-->
</table>
</div>
</div>


<!--if($item['ptype'] == 6) {-->
<div class="cwarpper1">
<div class="ctitle">代练进度</div>
<form action="index.php?m=mod_b2b&c=order&a=powerlvsave&ordno={$item['ordno']}" method="post"> 
<div>
<table border="1" id="ctable2" class="ctable" bordercolor="#86B9D6">
  <tr>
    <td style="width:15%;background:#F8FAFC;font-weight:bold;padding-left:5px;">录入员</td>
    <td style="width:55%;background:#F8FAFC;font-weight:bold;padding-left:5px;">进度</td>
    <td style="width:30%;background:#F8FAFC;font-weight:bold;padding-left:5px;">录入时间</td>
  </tr>
  <!--foreach($vd['order']['powerlv'] as $powerlv) {-->
  <tr>
    <td style="width:15%;padding-left:5px;">{$powerlv['inputer']}</td>
    <td style="width:55%;padding-left:5px;">{$powerlv['schedule']}</td>
    <td style="width:30%;padding-left:5px;">{$powerlv['createdate']}</td>
  </tr>
  <!--}-->
  <tr>
    <td style="width:15%;padding-left:5px;"><input type="text" name="inputer" style="width:98%"/></td>
    <td style="width:55%;padding-left:5px;"><input type="text" name="schedule" style="width:98%"/></td>
    <td style="width:30%;padding-left:5px;"><input type="submit" value="添加进度" class="btn" /></td>
  </tr>
</table>

</div>
</form>
</div>
<div class="cwarpper1">
<div class="ctitle">代练信息</div>
<div>
<table border="1" id="ctable3" class="ctable" bordercolor="#86B9D6">
  <tr>
    <td class="tablelt" height="50px">代练帐号：</td>
    <td class="tablert">{$item['czaccount']}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">登录密码：</td>
    <td class="tablert">{$item['acountpwd']}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">代练角色：</td>
    <td class="tablert">{$item['rolename']}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">所在区域：</td>
    <td class="tablert">{#CzText($item['czarea1'])}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">所在服务器：</td>
    <td class="tablert">{#CzText($item['czarea2'])}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">计费方式：</td>
    <td class="tablert">{#CzText($item['cztype'])}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">帐号类型：</td>
    <td class="tablert">{#CzText($item['czother'])}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">处理时间：</td>
    <td class="tablert">{$item['dealdate']}</td>
  </tr>
  <!--if($item['ordstate'] == -1) {-->
  <tr>
    <td class="tablelt" height="50px">失败原因：</td>
    <td class="tablert"><font color="#ff0000"><!--if($item['rollback'] == 1){-->[<b>已经退款</b>]<!--}-->{$item['failreason']}</font></td>
  </tr>
  <!--}-->
  <tr>
    <td class="tablelt" height="50px">厂家反馈：</td>
    <td class="tablert"><textarea rows="5" cols="50">{$item['factoryreturn']}</textarea></td>
  </tr>
</table>
</div>
</div>
<!--}-->
  
<!--if($item['ptype'] == 4 || $item['ptype'] == 5) {-->
<div class="cwarpper1">
<div class="ctitle">购买者帐号相关信息</div>
<div>
<table border="1" id="ctable2" class="ctable" bordercolor="#86B9D6">
  <tr>
    <td class="tablelt" height="50px">游戏角色名：</td>
    <td class="tablert">{$item['czaccount']}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">所在区域：</td>
    <td class="tablert">{#CzText($item['czarea1'])}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">所在服务器：</td>
    <td class="tablert">{#CzText($item['czarea2'])}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">计费方式：</td>
    <td class="tablert">{#CzText($item['cztype'])}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">帐号类型：</td>
    <td class="tablert">{#CzText($item['czother'])}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">处理时间：</td>
    <td class="tablert">{$item['dealdate']}</td>
  </tr>
  <!--if($item['ordstate'] == -1) {-->
  <tr>
    <td class="tablelt" height="50px">失败原因：</td>
    <td class="tablert"><font color="#ff0000"><!--if($item['rollback'] == 1){-->[<b>已经退款</b>]<!--}-->{$item['failreason']}</font></td>
  </tr>
  <!--}-->
  <tr>
    <td class="tablelt" height="50px">厂家反馈：</td>
    <td class="tablert"><textarea rows="5" cols="50">{$item['factoryreturn']}</textarea></td>
  </tr>
</table>
</div>
</div>
<!--}-->
  
<!--if($item['ptype'] == 0 || $item['ptype'] > 99 || $item['ptype'] == 3) {-->
<!--if(count($vd['order']['carditem']) > 0){-->
<div class="cwarpper1">
<div class="ctitle">卡密详细信息：</div>
<div>
<table border="1" id="ctable2" class="ctable" bordercolor="#86B9D6">
  <tr>
    <td style="width:50%;background:#F8FAFC;font-weight:bold;padding-left:5px;">
      <!--if($item['ptype'] == 3){-->
      号码
      <!--}else{-->
      卡号
      <!--}-->
    </td>
    <td style="width:50%;background:#F8FAFC;font-weight:bold;padding-left:5px;">密码</td>
  </tr>
  <!--foreach($vd['order']['carditem'] as $card) {-->
  <tr>
    <td style="width:50%;padding-left:5px;">{$card['cardnumber']}</td>
    <td style="width:50%;padding-left:5px;">{$card['cardpwd']}</td>
  </tr>
  <!--}-->
</table>
</div>
</div>
<!--}-->
<!--}-->

<div class="cwarpper1">
<div class="ctitle">买家信息：</div>
<div>
<table border="1" id="ctable3" class="ctable" bordercolor="#86B9D6">
  <tr>
    <td class="tablelt" height="50px">电话：</td>
    <td class="tablert">{$item['ctel']}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">邮箱：</td>
    <td class="tablert">{$item['cmail']}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">姓名：</td>
    <td class="tablert">{$item['crealname']}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">来源IP：</td>
    <td class="tablert">{$item['cip']}</td>
  </tr>
</table>
</div>
</div>

<div class="cwarpper1">
<div class="ctitle">支付信息：</div>
<div>
<table border="1" id="ctable4" class="ctable" bordercolor="#86B9D6">
  <tr>
    <td class="tablelt" height="50px">支付方式：</td>
    <td class="tablert">{#GetPayment($item['payment'],$item['ordno'])}</td>
  </tr>
  <tr>
    <td class="tablelt" height="50px">支付状态：</td>
    <td class="tablert"><b>{#OrderState($item['ordstate'], $item['ptype'])}</b></td>
  </tr>
</table>
<input type="hidden" value="{$item['cid']}" name="ubzcid" id="ubzcid"/>
</table>
</div>
</div>

<div class="cbodyFoot"></div>
</div>

<div id="opcontent">
  
  <div class="optxt">
    <!--if($item['ptype'] > 0 && $item['ptype'] < 99 && $item['ptype'] != 3) {--><input type="button" onclick="viewaction()" value="处理此订单" class="btn"/><!--}-->
    <input type="button" onclick="window.location='index.php?m=mod_b2b&c=order&a=del&ubzordno={$item['ordno']}'" value="删除此订单" class="btn"/>
    <input type="button" onclick="window.location='index.php?m=mod_b2b&c=order&a=reorder&ordno={$item['ordno']}'" value="订单补单" class="btn"/>
  </div>
</div>
<script type="text/javascript">
  var ctablenum = 4;
</script>
<script src="{$vd['sc']}js/content.js" type="text/javascript"></script>
<script type="text/javascript">
  var disp = 0;
  function viewaction()
  {
    if(disp == 0)
    {
      $("checktable").style.display = "";
      disp = 1;
    }
    else
    {
      $("checktable").style.display = "none";
      disp = 0;
    }
  }
  
  function set(obj)
  {
    $("custom").value = obj.value;
    $("custom").checked = true;
  }
  
  function setrollback()
  {
    $("rollback").checked = true;
  }
  
</script>
</body>
</html>
