181 lines
7.3 KiB
Plaintext
181 lines
7.3 KiB
Plaintext
@using WX.CRM.WebHelper;
|
||
@using WX.CRM.Model.Entity;
|
||
@{
|
||
ViewBag.Title = "退款订单";
|
||
Layout = "~/Views/Shared/_Index_Layout2.cshtml";
|
||
}
|
||
<div class="mvctool">
|
||
@Html.ToolButton("btnQuery", "icon-search", "查询", true)
|
||
@Html.ToolButton("btnExport", "icon-export", "导出", "Export_Click", true)
|
||
</div>
|
||
<div class="bas_datagrid">
|
||
<div id="tb" style="padding:5px;height:auto" class="grid_toolbar">
|
||
<ul class="toolBar_ul">
|
||
<li>
|
||
年:<select id="SltYear">
|
||
<option>2016</option>
|
||
<option>2017</option>
|
||
<option>2018</option>
|
||
<option>2019</option>
|
||
<option>2020</option>
|
||
<option>2021</option>
|
||
<option>2022</option>
|
||
<option>2023</option>
|
||
<option>2024</option>
|
||
<option>2025</option>
|
||
<option>2026</option>
|
||
<option>2027</option>
|
||
<option>2028</option>
|
||
<option>2029</option>
|
||
<option>2030</option>
|
||
</select>
|
||
月:<select id="SltMonth">
|
||
<option>01</option>
|
||
<option>02</option>
|
||
<option>03</option>
|
||
<option>04</option>
|
||
<option>05</option>
|
||
<option>06</option>
|
||
<option>07</option>
|
||
<option>08</option>
|
||
<option>09</option>
|
||
<option>10</option>
|
||
<option>11</option>
|
||
<option>12</option>
|
||
</select>
|
||
</li>
|
||
<li>
|
||
@*@Html.Action("UserComBoxByRole", "Control", new { controlName = "nb1", onLoadSucced = "onLoadSucced()", roleCodes = ViewBag.roleCodes, saledeptid = "", salegroupid = ViewBag.userGroupId, iseid = "0", inneruserid = ViewBag.inneruserid, currentRight = WX.CRM.WebHelper.InitRights.CONST_订单退款 })*@
|
||
@Html.Action("UserSSOComBox", "Control", new { currentRight = WX.CRM.WebHelper.InitRights.CONST_订单退款 })
|
||
</li>
|
||
<li>订单ID:<input type="text" name="txt_OrderId" style="width:150px" /></li>
|
||
<li>类型:<select id="lxType"><option value="">全部</option><option value="0">个人</option><option value="1">经理</option><option value="2">订金</option></select></li>
|
||
<li>是否开通退款:<select id="isOpen"><option value="">全部</option><option value="1">是</option><option value="0">否</option></select></li>
|
||
<li>去除当月数据:<input type="checkbox" id="curMonth" /></li>
|
||
<li>
|
||
退款类型:
|
||
<select name="slt_isacturalrefund">
|
||
<option value="">全部</option>
|
||
<option value="1">需要实际退款</option>
|
||
<option value="0" title="不需要实际退款">退回可用余额</option>
|
||
</select>
|
||
</li>
|
||
</ul>
|
||
</div>
|
||
@Html.Raw(ViewBag.gridTable)
|
||
</div>
|
||
<script type="text/javascript">
|
||
function Appendzero(obj) {
|
||
if (obj < 10) return "0" + "" + obj;
|
||
else return obj;
|
||
}
|
||
function string2date(str){
|
||
return new Date(Date.parse(str.replace(/-/g, "/")));
|
||
}
|
||
$(function () {
|
||
var m = string2date("@ViewBag.Month");
|
||
$("#SltYear").val(m.getFullYear());
|
||
$("#SltMonth").val(Appendzero(m.getMonth() + 1));
|
||
|
||
$('#tablist').tablegrid({
|
||
url: '/WeiXin/SzzyOrderRefund/Detail',
|
||
height: $(window).height() - 110,
|
||
loadNow: true,
|
||
data: GetControlValue,
|
||
onLoadError: function () {
|
||
$.messager.alert("警告", "信息加载失败!", "error");
|
||
}
|
||
});
|
||
|
||
$(window).resize(function () {//自动适应大小
|
||
$('#tablist').tablegrid('resize', {
|
||
height: $(window).height() - 110
|
||
});
|
||
});
|
||
|
||
$("#btnQuery").click(function () {
|
||
$('#tablist').tablegrid("Search");
|
||
});
|
||
});
|
||
function frameReturnByClose() {
|
||
$("#modalwindow").window('close');
|
||
}
|
||
function frameReturnByReload(flag) {
|
||
$("#tablist").tablegrid("Load");
|
||
}
|
||
function frameReturnByMes(mes) {
|
||
$.messageBox5s('提示', mes);
|
||
}
|
||
|
||
//function loadtablegrid() {
|
||
// $('#tablist').tablegrid({
|
||
// url: '/WeiXin/SzzyOrderRefund/Detail',
|
||
// height: $(window).height() - 110,
|
||
// loadNow: true,
|
||
// data: GetControlValue,
|
||
// onLoadError: function () {
|
||
// $.messager.alert("警告", "信息加载失败!", "error");
|
||
// }
|
||
// });
|
||
//}
|
||
function GetControlValue() {
|
||
var year = $("#SltYear").val();
|
||
var mon = $("#SltMonth").val();
|
||
var yearmonth = year + "-" + mon + "-01";
|
||
var lxType = $("#lxType").val();
|
||
var isOpen = $("#isOpen").val();
|
||
var curMonth = 0;
|
||
var chkMonth = $("#curMonth").prop("checked");
|
||
if (chkMonth) {
|
||
curMonth = 1;
|
||
}
|
||
return { month: yearmonth, lxType: lxType, isOpen: isOpen, curMonth: curMonth, saleDeptId: $("#nb1_uc_org_depts").val(), groupId: $("#nb1_uc_org_groups").val(), userId: $("#nb1_uc_org_ids").val() };
|
||
}
|
||
function onLoadSucced() {
|
||
$('#tablist').tablegrid("Search");
|
||
}
|
||
|
||
function GetRefundInfo(orderId) {
|
||
if (orderId != undefined && orderId.length != 0 && orderId != 0) {
|
||
$("#modalwindow").html(GetIframeHtml("/WeiXin/SzzyOrderRefund/Info?orderId=" + orderId + "&Ieguid=" + GetGuid()));
|
||
$("#modalwindow").window({ title: '退款信息', width: 830, height: 550, iconCls: 'icon-edit' }).window('open');
|
||
} else { $.messageBox5s('提示', '@Suggestion.PlaseChooseToOperatingRecords'); }
|
||
}
|
||
|
||
</script>
|
||
@*ToolBar事件处理*@
|
||
<script type="text/javascript">
|
||
function GetIframeHtml(src) {
|
||
return "<iframe width='100%' height='98%' scrolling='no' frameborder='0'' src='" + src + "'></iframe>";
|
||
}
|
||
//获取datagrid头部及字段
|
||
function getDataGridHeader() {
|
||
var columns = $('#tablist').tablegrid("getAllHead");
|
||
return columns;
|
||
}
|
||
function Export_Click() {
|
||
var year = $("#SltYear").val();
|
||
var mon = $("#SltMonth").val();
|
||
var yearmonth = year + "-" + mon + "-01";
|
||
var lxType = $("#lxType").val();
|
||
var curMonth = 0;
|
||
var chkMonth = $("#curMonth").prop("checked");
|
||
if (chkMonth) {
|
||
curMonth = 1;
|
||
}
|
||
var para = GetQueryStr();
|
||
if (para != null || para != "" || para != undefined) {
|
||
para += "&";
|
||
}
|
||
para += "month=" + yearmonth;
|
||
para += "&lxType=" + lxType;
|
||
para += "&curMonth=" + curMonth;
|
||
para += "&saleDeptId=" + $("#nb1_uc_org_depts").val();
|
||
para += "&groupId=" + $("#nb1_uc_org_groups").val();
|
||
para += "&userId=" + $("#nb1_uc_org_ids").val();
|
||
|
||
$("#modalwindow").html(GetIframeHtml("/Control/ExcelExport?Query=" + encodeURIComponent("/WeiXin/SzzyOrderRefund/DetailExport?" + para)));
|
||
$("#modalwindow").window({ title: '导出', width: 480, height: 300, iconCls: 'icon-export' }).window('open');
|
||
}
|
||
</script>
|