You've already forked qlg.tsgz.moe
Init Repo
This commit is contained in:
166
hyhproject/home/view/default/shops/settlements/list.html
Executable file
166
hyhproject/home/view/default/shops/settlements/list.html
Executable file
@ -0,0 +1,166 @@
|
||||
{extend name="default/shops/base" /}
|
||||
{block name="title"}订单结算 - 卖家中心{__block__}{/block}
|
||||
{block name="css"}
|
||||
{/block}
|
||||
{block name="content"}
|
||||
<div id='tab' class="wst-tab-box">
|
||||
<ul class="wst-tab-nav">
|
||||
<li id="wst-msg-li-0">结算信息<span style="display:none;"></span></li>
|
||||
<li id="wst-msg-li-1">未结算订单<span style="display:none;"></span></li>
|
||||
<li id="wst-msg-li-2">已结算订单<span style="display:none;"></span></li>
|
||||
</ul>
|
||||
<div class="wst-tab-content" style='width:98%;'>
|
||||
<div class='wst-tab-item'>
|
||||
<div>
|
||||
结算单号:<input type="text" id="settlementNo_0" style='width:120px;' autocomplete="off"/>
|
||||
结算状态:<select id='isFinish_0' autocomplete="off">
|
||||
<option value='-1'>全部</option>
|
||||
<option value='0'>未结算</option>
|
||||
<option value='1'>已结算</option>
|
||||
</select>
|
||||
<a class='s-btn' onclick="getQueryPage(0)">查询</a>
|
||||
</div>
|
||||
<table class='wst-list' style="font-size:13px;">
|
||||
<thead>
|
||||
<tr>
|
||||
<th width='20'> </th>
|
||||
<th width='100'>结算单号</th>
|
||||
<th width='40'>类型</th>
|
||||
<th width='60'>结算金额</th>
|
||||
<th width='80'>结算佣金</th>
|
||||
<th width='80'>返还金额</th>
|
||||
<th width='130'>创建时间</th>
|
||||
<th width='60'>结算状态</th>
|
||||
<th width='130'>结算时间</th>
|
||||
<th width='*'>备注</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<script id="tblist0" type="text/html">
|
||||
{{# for(var i = 0; i < d.length; i++){ }}
|
||||
<tr>
|
||||
<td>{{i+1}}</td>
|
||||
<td><a style='color:blue' href='javascript:view("{{d[i].settlementId}}")'>{{d[i].settlementNo}}</a></td>
|
||||
<td>{{# if(d[i].settlementType==1){ }}定时{{# }else{ }}手动{{# } }}</td>
|
||||
<td>¥{{d[i].settlementMoney}}</td>
|
||||
<td>¥{{d[i].commissionFee}}</td>
|
||||
<td>¥{{d[i].backMoney}}</td>
|
||||
<td>{{d[i].createTime}}</td>
|
||||
<td>{{# if(d[i].settlementStatus==1){ }}已结算{{# }else{ }}未结算{{# } }}</td>
|
||||
<td>{{WST.blank(d[i].settlementTime,'-')}}</td>
|
||||
<td style='line-height:20px;'>{{WST.blank(d[i].remarks)}}</td>
|
||||
</tr>
|
||||
{{# } }}
|
||||
</script>
|
||||
<tbody id="tbody0"></tbody>
|
||||
<tfoot>
|
||||
<tr>
|
||||
<td colspan='10' align='center' id="pager_0"></td>
|
||||
</tr>
|
||||
</tfoot>
|
||||
</table>
|
||||
</div>
|
||||
{/** 待结算订单 **/}
|
||||
<div class='wst-tab-item hide'>
|
||||
<div>
|
||||
订单号:<input type="text" id="orderNo_1" style='width:120px;' autocomplete="off"/>
|
||||
<a class='s-btn' onclick="getUnSettledOrderPage(0)">查询</a>
|
||||
<!-- <a class='s-btn' style='width:110px;' onclick="settlement()">申请结算</a> -->
|
||||
</div>
|
||||
<table class='wst-list' style="font-size:13px;">
|
||||
<thead>
|
||||
<tr>
|
||||
<!-- <th width='20'><input type='checkbox' onclick='WST.checkChks(this,".chk_1")'/></th> -->
|
||||
<th width='100'>订单号</th>
|
||||
<th width='130'>下单时间</th>
|
||||
<th width='80'>支付方式</th>
|
||||
<th width='80'>商品总金额</th>
|
||||
<th width='70'>运费</th>
|
||||
<th width='90'>订单总金额</th>
|
||||
<th width='90'>实付金额</th>
|
||||
<th width='70'>应付佣金</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<script id="tblist1" type="text/html">
|
||||
{{# for(var i = 0; i < d.length; i++){ }}
|
||||
<tr>
|
||||
<!-- <td><input type='checkbox' class='chk_1' value='{{d[i].orderId}}'/></td> -->
|
||||
<td>{{d[i].orderNo}}</td>
|
||||
<td>{{d[i].createTime}}</td>
|
||||
<td>{{d[i].payTypeNames}}</td>
|
||||
<td>¥{{d[i].goodsMoney}}</td>
|
||||
<td>¥{{d[i].deliverMoney}}</td>
|
||||
<td>¥{{d[i].totalMoney}}</td>
|
||||
<td>¥{{d[i].realTotalMoney}}</td>
|
||||
<td>¥{{d[i].commissionFee}}</td>
|
||||
</tr>
|
||||
{{# } }}
|
||||
</script>
|
||||
<tbody id="tbody1">
|
||||
</tbody>
|
||||
<tfoot>
|
||||
<tr>
|
||||
<td colspan='7' align='center' id="pager_1"></td>
|
||||
</tr>
|
||||
</tfoot>
|
||||
</table>
|
||||
|
||||
</div>
|
||||
<div class='wst-tab-item hide'>
|
||||
<div>
|
||||
结算单号:<input type="text" id="settlementNo_2" style='width:120px;' class="s-ipt" autocomplete="off"/>
|
||||
订单号:<input type="text" id="orderNo_2" style='width:120px;' class="s-ipt" autocomplete="off"/>
|
||||
结算状态:<select id='isFinish_2' class="s-ipt" autocomplete="off">
|
||||
<option value='-1'>全部</option>
|
||||
<option value='0'>未结算</option>
|
||||
<option value='1'>已结算</option>
|
||||
</select>
|
||||
<a class='s-btn' onclick="getSettleOrderPage(0)">查询</a>
|
||||
<a class="s-btn" style='margin-top:0px;line-height:15px;height:16px;float: right;' onclick="javascript:toExport(0)">导出</a>
|
||||
</div>
|
||||
<table class='wst-list' style="font-size:13px;">
|
||||
<thead>
|
||||
<tr>
|
||||
<th width='20'> </th>
|
||||
<th width='100'>订单号</th>
|
||||
<th width='80'>支付方式</th>
|
||||
<th width='70'>商品总金额</th>
|
||||
<th width='70'>运费</th>
|
||||
<th width='70'>订单总金额</th>
|
||||
<th width='70'>实付金额</th>
|
||||
<th width='70'>应付佣金</th>
|
||||
<th width='70'>结算方式</th>
|
||||
<th width='130'>结算单号</th>
|
||||
<th width='130'>结算时间</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<script id="tblist2" type="text/html">
|
||||
{{# for(var i = 0; i < d.length; i++){ }}
|
||||
<tr>
|
||||
<td>{{i+1}}</td>
|
||||
<td>{{d[i].orderNo}}</td>
|
||||
<td>{{d[i].payTypeNames}}</td>
|
||||
<td>¥{{d[i].goodsMoney}}</td>
|
||||
<td>¥{{d[i].deliverMoney}}</td>
|
||||
<td>¥{{d[i].totalMoney}}</td>
|
||||
<td>¥{{d[i].realTotalMoney}}</td>
|
||||
<td>¥{{d[i].commissionFee}}</td>
|
||||
<td>{{d[i].payName}}</td>
|
||||
<td>{{d[i].settlementNo}}</td>
|
||||
<td>{{WST.blank(d[i].settlementTime,'-')}}</td>
|
||||
</tr>
|
||||
{{# } }}
|
||||
</script>
|
||||
<tbody id="tbody2"></tbody>
|
||||
<tfoot>
|
||||
<tr>
|
||||
<td colspan='9' align='center' id="pager_2"></td>
|
||||
</tr>
|
||||
</tfoot>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
{/block}
|
||||
{block name="js"}
|
||||
<script type='text/javascript' src='__STYLE__/shops/settlements/settlements.js?v={$v}'></script>
|
||||
|
||||
{/block}
|
134
hyhproject/home/view/default/shops/settlements/settlements.js
Executable file
134
hyhproject/home/view/default/shops/settlements/settlements.js
Executable file
@ -0,0 +1,134 @@
|
||||
$(function(){
|
||||
$('#tab').TabPanel({tab:0,callback:function(tab){
|
||||
switch(tab){
|
||||
case 0:getQueryPage(0);break;
|
||||
case 1:getUnSettledOrderPage(0);break;
|
||||
case 2:getSettleOrderPage(0);break;
|
||||
}
|
||||
}});
|
||||
});
|
||||
function view(val){
|
||||
location.href=WST.U('home/settlements/view','id='+val);
|
||||
}
|
||||
function getQueryPage(p){
|
||||
var params = {};
|
||||
params.page = p;
|
||||
params.settlementNo = $.trim($('#settlementNo_0').val());
|
||||
params.isFinish = $('#isFinish_0').val();
|
||||
$.post(WST.U('home/settlements/pageQuery'),params,function(data,textStatus){
|
||||
var json = WST.toJson(data);
|
||||
if(json.status==1){
|
||||
var json = json.data;
|
||||
var gettpl = document.getElementById('tblist0').innerHTML;
|
||||
laytpl(gettpl).render(json.Rows, function(html){
|
||||
$('#tbody0').html(html);
|
||||
});
|
||||
laypage({
|
||||
cont: 'pager_0',
|
||||
pages:json.TotalPage,
|
||||
curr: json.CurrentPage,
|
||||
skin: '#e23e3d',
|
||||
groups: 3,
|
||||
jump: function(e, first){
|
||||
if(!first){
|
||||
getQueryPage(e.curr);
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
function settlement(){
|
||||
var ids = WST.getChks('.chk_1');
|
||||
if(ids.length==0){
|
||||
WST.msg('请选择要结算的订单!',{icon:2});
|
||||
return;
|
||||
}
|
||||
var load = WST.load({msg:'正在提交申请,请稍后...'});
|
||||
WST.confirm({content:'您确定要申请结算这些订单吗?',yes:function(){
|
||||
$.post(WST.U('home/settlements/settlement'),{ids:ids.join(',')},function(data,textStatus){
|
||||
layer.close(load);
|
||||
var json = WST.toJson(data);
|
||||
if(json.status==1){
|
||||
WST.msg(json.msg,{icon:1},function(){
|
||||
getUnSettledOrderPage(WSTCurrPage);
|
||||
});
|
||||
}else{
|
||||
WST.msg(json.msg);
|
||||
}
|
||||
});
|
||||
}});
|
||||
}
|
||||
function getUnSettledOrderPage(p){
|
||||
var params = {};
|
||||
params.page = p;
|
||||
params.orderNo = $.trim($('#orderNo_1').val());
|
||||
$('#pager_1').empty();
|
||||
$.post(WST.U('home/settlements/pageUnSettledQuery'),params,function(data,textStatus){
|
||||
var json = WST.toJson(data);
|
||||
if(json.status==1){
|
||||
var json = json.data;
|
||||
if(params.page>json.TotalPage && json.TotalPage >0){
|
||||
getUnSettledOrderPage(json.TotalPage);
|
||||
return;
|
||||
}
|
||||
var gettpl = document.getElementById('tblist1').innerHTML;
|
||||
laytpl(gettpl).render(json.Rows, function(html){
|
||||
$('#tbody1').html(html);
|
||||
});
|
||||
laypage({
|
||||
cont: 'pager_1',
|
||||
pages:json.TotalPage,
|
||||
curr: json.CurrentPage,
|
||||
skin: '#e23e3d',
|
||||
groups: 3,
|
||||
jump: function(e, first){
|
||||
if(!first){
|
||||
getUnSettledOrderPage(e.curr);
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
function getSettleOrderPage(p){
|
||||
var params = {};
|
||||
params.page = p;
|
||||
params.orderNo = $.trim($('#orderNo_2').val());
|
||||
params.settlementNo = $.trim($('#settlementNo_2').val());
|
||||
params.isFinish = $.trim($('#isFinish_2').val());
|
||||
$('#pager_2').empty();
|
||||
$.post(WST.U('home/settlements/pageSettledQuery'),params,function(data,textStatus){
|
||||
var json = WST.toJson(data);
|
||||
if(json.status==1){
|
||||
json = json.data;
|
||||
var gettpl = document.getElementById('tblist2').innerHTML;
|
||||
laytpl(gettpl).render(json.Rows, function(html){
|
||||
$('#tbody2').html(html);
|
||||
});
|
||||
laypage({
|
||||
cont: 'pager_2',
|
||||
pages:json.TotalPage,
|
||||
curr: json.CurrentPage,
|
||||
skin: '#e23e3d',
|
||||
groups: 3,
|
||||
jump: function(e, first){
|
||||
if(!first){
|
||||
getSettleOrderPage(e.curr);
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
//导出订单
|
||||
function toExport(){
|
||||
var params = {};
|
||||
params.orderNo = $.trim($('#orderNo_2').val());
|
||||
params.settlementNo = $.trim($('#settlementNo_2').val());
|
||||
params.isFinish = $.trim($('#isFinish_2').val());
|
||||
var box = WST.confirm({content:"您确定要导出订单吗?",yes:function(){
|
||||
layer.close(box);
|
||||
location.href=WST.U('home/settlements/toExport',params);
|
||||
}});
|
||||
}
|
91
hyhproject/home/view/default/shops/settlements/view.html
Executable file
91
hyhproject/home/view/default/shops/settlements/view.html
Executable file
@ -0,0 +1,91 @@
|
||||
{extend name="default/shops/base" /}
|
||||
{block name="title"}结算详情-卖家中心{__block__}{/block}
|
||||
{block name="content"}
|
||||
<div class="wst-shop-head"><span>结算详情</span><a href="<?=url('home/settlements/index');?>">返回</a></div>
|
||||
<div class="wst-clear"></div>
|
||||
<div class="wst-body">
|
||||
<form id='editform' autocomplete='off'>
|
||||
<div class="wst-tab-item" style="position: relative;">
|
||||
<table class='wst-form'>
|
||||
<tr>
|
||||
<td class='head-ititle' colspan='2'>结算信息</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th width='120'>结算单号:</th>
|
||||
<td>{$object['settlementNo']}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>结算金额:</th>
|
||||
<td>¥{$object['settlementMoney']}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>结算佣金:</th>
|
||||
<td>¥{$object['commissionFee']}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>返还金额:</th>
|
||||
<td>¥{$object['backMoney']}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>申请时间:</th>
|
||||
<td>{$object['createTime']}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>结算状态:</th>
|
||||
<td>
|
||||
{if $object['settlementStatus']==1}
|
||||
已结算
|
||||
{else}
|
||||
待结算
|
||||
{/if}
|
||||
</td>
|
||||
</tr>
|
||||
{if $object['settlementStatus']==1}
|
||||
<tr>
|
||||
<th>结算时间:</th>
|
||||
<td>{$object['settlementTime']}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>结算备注:</th>
|
||||
<td>{$object['remarks']}</td>
|
||||
</tr>
|
||||
{/if}
|
||||
<tr>
|
||||
<td colspan='2' align="center">
|
||||
<table class='wst-list' style='margin-left:5px;'>
|
||||
<thead>
|
||||
<tr>
|
||||
<th>序号</th>
|
||||
<th>订单号</th>
|
||||
<th>支付方式</th>
|
||||
<th>商品金额</th>
|
||||
<th>运费</th>
|
||||
<th>订单总金额</th>
|
||||
<th>积分抵扣</th>
|
||||
<th>实付金额</th>
|
||||
<th>佣金</th>
|
||||
<th>下单时间</th>
|
||||
</tr>
|
||||
</thead>
|
||||
{volist name='$object["list"]' id='vo'}
|
||||
<tr>
|
||||
<td>{$key+1}</td>
|
||||
<td>{$vo['orderNo']}</td>
|
||||
<td>{:WSTLangPayType($vo['payType'])}</td>
|
||||
<td>¥{$vo['goodsMoney']}</td>
|
||||
<td>¥{$vo['deliverMoney']}</td>
|
||||
<td>¥{$vo['totalMoney']}</td>
|
||||
<td>¥{$vo['scoreMoney']}</td>
|
||||
<td>¥{$vo['realTotalMoney']}</td>
|
||||
<td>¥{$vo['commissionFee']}</td>
|
||||
<td>{$vo['createTime']}</td>
|
||||
</tr>
|
||||
{/volist}
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
{/block}
|
Reference in New Issue
Block a user