You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
DS7/DSWebMobile/Scripts/profitInfo.js

1624 lines
103 KiB
JavaScript

3 years ago
var winWidth = 0;
var winHeight = 0;
var itemContainHeight = 0;
var u = "";
var w = "";
var pageCount = 20; //每页计数
var UrlParam = "";
var cacheKey = "";
var gid = "";
var companyid = "";
var pageTotalCount = 0;
var url = "";
var rdoAuditing = "";
var pageNum = 0;
var bsno = "";
var oplb = "";
var auditingStatusIsAll = "1";
var expenseStatusIsAll = "1";
var auditingIsAll = "";
var expenseIsAll = "";
var operateDataType = "";
var operateUserGID = "";
var operateItemGID = "";
var operateOplbValue = "";
var operateBsnoValue = "";
var operateFeeStatus = "";
var operateFeeStatusCtrl = "";
var strSelGID = "";
var drCount = 0;
var crCount = 0;
var drDisplay = false;
var crDisplay = false;
var changeFeeName = "";
var changeCustomerName = "";
var changeUnit = "";
var changeUnitPrice = "";
var changeTaxRate = "";
var changeTaxUnitPrice = "";
var changeQuantity = "";
var changeNoTaxAmount = "";
var changeAmount = "";
var changeCurrency = "";
var changeExChangerate = "";
var changeAccTaxRate = "";
var isDrAuditing = 0; //是否未审核过
var isCrAuditing = 0; //是否未审核过
var isRejectSign = false; //是否驳回
var isSettlementDrSign = false; //是否结算
var isInvoiceDrSign = false; //是否开出发票
var isOrderAmountDrSign = false; //是否申请费用
var isOrderInvoiceDrSign = false; //是否申请开票
var isSettlementCrSign = false; //是否结算
var isInvoiceCrSign = false; //是否开出发票
var isOrderAmountCrSign = false; //是否申请费用
var isOrderInvoiceCrSign = false; //是否申请开票
var _auditingDrSign = new Array; //已审核费用
var _SettlementDrSign = new Array; //已结算费用
var _InvoiceDrSign = new Array; //已开出发票费用
var _OrderAmountDrSign = new Array; //已申请费用费用
var _OrderInvoiceDrSign = new Array; //已申请开票费用
var _auditingCrSign = new Array; //已审核费用
var _SettlementCrSign = new Array; //已结算费用
var _InvoiceCrSign = new Array; //已开出发票费用
var _OrderAmountCrSign = new Array; //已申请费用费用
var _OrderInvoiceCrSign = new Array; //已申请开票费用
var _auditingDrAmount = 0 //已审核费用数量
var _settlementDrAmount = 0; //已结算费用数量
var _invoiceDrAmount = 0; //已开出发票费用数量
var _orderAmountDrAmount = 0; //已申请费用费用数量
var _orderInvoiceDrAmount = 0; //已申请开票费用数量
var _auditingCrAmount = 0 //已审核费用数量
var _settlementCrAmount = 0; //已结算费用数量
var _invoiceCrAmount = 0; //已开出发票费用数量
var _orderAmountCrAmount = 0; //已申请费用费用数量
var _orderInvoiceCrAmount = 0; //已申请开票费用数量
var isModule = 0; //判断点击的是哪个分支模块 0-利润审核1-应收利润 2-应付利润
var auditingArr = new Array();
var auditingAmount = 0;
var _rejectOpt = -1;
var searchKey = "";
$(function () {
$.ajaxSetup({ async: false });
winWidth = document.documentElement.clientWidth;
winHeight = document.documentElement.clientHeight;
itemContainHeight = winHeight / 16 - 6.55; //125 8.125
$(".itemContain").css("height", itemContainHeight + "em");
$(".itemContain").css("overflow", "auto");
$("#onlineService").css("width", winWidth * 0.75 / 16 + "em");
$("#onlineService").css("height", winHeight * 0.6 / 16 + "em");
$("#serviceConatain").css("height", (winHeight * 0.6 - 32) / 16 + "em");
var imgWidth = 398 * winWidth / 1080;
var imgHeight = imgWidth * 99 / 398;
$("#btnReturnTipConfirm").css("width", imgWidth / 16 + "em");
$("#btnReturnTipConfirm").css("height", imgHeight / 16 + "em");
$("#btnConfirm").css("width", imgWidth / 16 + "em");
$("#btnConfirm").css("height", imgHeight / 16 + "em");
$(".nav ul.navUL li.navLI").hover(
function () {
$(this).children(".drop_dwon").slideDown(100);
$(this).children(".nav ul.navUL li.navLI a").attr("id", "currlayout")
}, function () {
$(this).children(".drop_dwon").slideUp(100);
$(this).children(".nav ul.navUL li.navLI a").attr("id", "")
}
);
$("#closeModifyFloatBtn").bind("click", function () {
$("#onlineService").animate({ width: "hide", opacity: "hide" }, "normal", function () {
$("#onlineService").hide();
});
return false;
});
$("#txtReason").width($("#laybg").width() - 2);
$(".itemContain").css("height", itemContainHeight + "em");
if ($("#txtReason").val() == "请添加备注信息或者驳回原因") {
$("#txtReason").css("color", "#acacac");
}
else {
$("#txtReason").css("color", "#303030");
}
$("#maskUser").css("display", "none");
$("#laybg").css("display", "none");
$("#layInvoiceState").mouseleave(function () {
$("#layInvoiceState").css("display", "none");
});
u = UrlParm.parm("u");
w = UrlParm.parm("w");
bsno = UrlParm.parm("b");
oplb = UrlParm.parm("y");
expenseStatusIsAll = UrlParm.parm("es");
//auditingStatusIsAll = UrlParam.parm("t");
var expenseArr = expenseStatusIsAll.split("-");
auditingIsAll = expenseArr[1];
expenseIsAll = expenseArr[0];
/*if ((winWidth <= 320)) { // && (winHeight == 985)
$("#css").attr("href", "lib/css/list960.css");
}
else if ((winWidth >= 360)) { // && (winHeight == 673)
$("#css").attr("href", "lib/css/list1080.css");
}*/
$("#btnAudit").show();
$("#btnApply").hide();
fnProfitAuditingBillInfo();
fnProfitAuditingDrInfo();
fnProfitAuditingCrInfo();
fnShowProfitInfo();
$("#txtReason").focus(function () {
$("#txtReason").css("color", "#303030");
if ($("#txtReason").val() == "请添加备注信息或者驳回原因") {
$("#txtReason").val("");
}
});
$("#txtReason").blur(function () {
if ($("#txtReason").val() == "") {
$("#txtReason").val("请添加备注信息或者驳回原因");
$("#txtReason").css("color", "#acacac");
}
else {
$("#txtReason").css("color", "#303030");
}
});
});
function fnShowProfitInfo() {
isModule = 0;
$("[rel=chk]").attr("checked", false);
$(".navLI").removeClass("navLIHover");
$("#baseNav").addClass("navLIHover");
$(".navLIHoverTitle").css("display", "none");
$("#baseNavTitle").css("display", "block");
$(".navHyperlink").show();
$("#baseNavHyperlink").hide();
$(".secNavContain").css("display", "none");
$(".itemContain").css("display", "none");
$("#profitInfo").css("display", "block");
itemContainHeight = winHeight / 16 - 8.125; //125
$(".itemContain").css("height", itemContainHeight + "em");
}
function fnShowReceivableInfo() {
isDrAuditing = 0;
operateDataType = "dr";
isModule = 1;
$("#chkAll").removeAttr("checked");
drDisplay = true;
crDisplay = false;
$("#onlineService").animate({ width: "hide", opacity: "hide" }, "normal", function () {
$("#onlineService").hide();
});
$("[rel=chk]").attr("checked", false);
itemContainHeight = winHeight / 16 - 6.9 - 4.4;
$("#receivableInfo").css("height", itemContainHeight + "em");
$(".navLI").removeClass("navLIHover");
$("#drNav").addClass("navLIHover");
$(".navLIHoverTitle").css("display", "none");
$("#drNavTitle").css("display", "block");
$(".navHyperlink").show();
$("#drNavHyperlink").hide();
$(".secNavContain").css("display", "block");
$(".itemContain").css("display", "none");
$("#receivableInfo").css("display", "block");
}
function fnShowPayableInfo() {
isCrAuditing = 0;
operateDataType = "cr";
isModule = 2;
$("#chkAll").removeAttr("checked");
crDisplay = true;
drDisplay = false;
$("#onlineService").animate({ width: "hide", opacity: "hide" }, "normal", function () {
$("#onlineService").hide();
});
$("[rel=chk]").attr("checked", false);
itemContainHeight = winHeight / 16 - 6.9 - 4.4;
$("#payableInfo").css("height", itemContainHeight + "em");
$(".navLI").removeClass("navLIHover");
$("#crNav").addClass("navLIHover");
$(".navLIHoverTitle").css("display", "none");
$("#crNavTitle").css("display", "block");
$(".navHyperlink").show();
$("#crNavHyperlink").hide();
$(".secNavContain").css("display", "block");
$(".itemContain").css("display", "none");
$("#payableInfo").css("display", "block");
}
function fnItemSelect(dataType, userGID, itemGID, oplbValue, bsnoValue, feeStatus, feeStatusCtrl, title, titleHover, bill, feeid) {
operateDataType = dataType;
operateUserGID = userGID;
operateItemGID = itemGID;
operateOplbValue = oplbValue;
operateBsnoValue = bsnoValue;
operateFeeStatus = feeStatus;
operateFeeStatusCtrl = feeStatusCtrl;
$("[rel='title']").css("display", "block");
$("[rel='titleHover']").css("display", "none");
$("[rel='UL']").css("display", "none");
$("#" + title).hide();
$("#" + titleHover).show();
$("#" + bill).show();
//fnDispNewValue(feeid)();
}
function fnItemHyperlinkSelect(title, titleHover, bill, feeid) {
$("[rel='title']").css("display", "block");
$("[rel='titleHover']").css("display", "none");
$("[rel='UL']").css("display", "none");
$("#" + title).hide();
$("#" + titleHover).show();
$("#" + bill).show();
//fnDispNewValue(feeid)();
}
function fnItemUnSelect(title, titleHover, bill) {
$("#" + titleHover).hide();
$("#" + bill).hide();
$("#" + title).show();
}
function fnDrCheck(chkid, dataType, userGID, itemGID, oplbValue, bsnoValue, feeStatus, feeStatusCtrl, title, titleHover, bill, feeid) {
operateDataType = dataType;
operateUserGID = userGID;
operateItemGID = itemGID;
operateOplbValue = oplbValue;
operateBsnoValue = bsnoValue;
operateFeeStatus = feeStatus;
operateFeeStatusCtrl = feeStatusCtrl;
if ($(chkid).attr("checked") != true) { $("#chkAll").removeAttr("checked"); }
}
function fnCrCheck(chkid, dataType, userGID, itemGID, oplbValue, bsnoValue, feeStatus, feeStatusCtrl, title, titleHover, bill, feeid) {
operateDataType = dataType;
operateUserGID = userGID;
operateItemGID = itemGID;
operateOplbValue = oplbValue;
operateBsnoValue = bsnoValue;
operateFeeStatus = feeStatus;
operateFeeStatusCtrl = feeStatusCtrl;
if ($(chkid).attr("checked") != true) { $("#chkAll").removeAttr("checked"); }
}
function fnProfitAuditingBillInfo() {
$.ajaxSetup({ async: false });
var pageTotalCount = 0;
var oplbName = ""; //经营类别
var opType = ""; //更改单
var custNo = ""; //委托编号
var mblno = ""; //主提单号
var hblno = ""; //分提单号
var customNo = ""; //报关单号
var feeStatusRef = ""; //费用锁定
var customerName = ""; //委托单位
var etd = ""; //开船日期
var sale = ""; //揽货人
var accDate = ""; //会计期间
var enterp = ""; //经营单位
var op = ""; //操作
var inputBy = ""; //录入人
var portLoad = ""; //起运港
var portDischarge = ""; //目的港
var vessel = ""; //船名
var voyno = ""; //航次
var rmb = 0; //人民币
var usd = 0; //美金
var otr = 0; //其它货币
var ttl = 0; //合计
var cntrtotal = ""; //集装箱CNTRTOTAL
var opstatus = ""; //费用状态
searchKey = "BSNO='" + bsno + "'";
UrlParam = "&bf=&bt=&af=&at=&ef=&et=&isall=" + auditingIsAll + "&s=" + jsencrypt(decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs"), searchKey) + "&t=1&l=10"; //" + PageIndex + "
url = "../../Handler/Profit.ashx?action=0" + UrlParam;
$.ajax({
type: "post",
dataType: "json",
data: UrlParam,
url: url,
cache: false,
success: function (msg) {
strInfo = "";
$.each(msg, function (i, item) {
if (item.BSNO != "" && item.BSNO != undefined && item.BSNO != null) {
//bsno2 = item.BSNO;
oplbName = item.OPLBNAME; //经营类别
//opType = item.OPTYPE; //更改单 dsweb ="op_seae"
custNo = item.CUSTNO; //委托编号
mblno = item.MBLNO; //主提单号
hblno = item.HBLNO; //分提单号
customNo = item.CUSTOMNO; //报关单号
feeStatusRef = item.FEESTATUSREF; //费用锁定
$("#hidFeeStatus").val(feeStatusRef);
customerName = item.CUSTOMERNAME; //委托单位
etd = item.ETD; //开船日期
sale = item.SALE; //揽货人
accDate = item.ACCDATE; //会计期间
enterp = item.ENTERP; //经营单位
op = item.OP; //操作
inputBy = item.INPUTBY; //录入人
portLoad = item.PORTLOAD; //起运港
portDischarge = item.PORTDISCHARGE; //目的港
vessel = item.VESSEL; //船名
voyno = item.VOYNO; //航次
cntrtotal = item.CNTRTOTAL; //集装箱
opstatus = item.OPSTATUS; //费用状态
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">委托编号:" + custNo + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">主提单号:" + mblno + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">分提单号:" + hblno + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">费用状态:" + opstatus + "</span></li>";
strInfo += "<li class=\"itemLI\"><ul style=\"margin:0;padding:0;width:100%;height:100%;list-style:none;\"><li style=\"float:left;margin:0;margin-left:2%;padding:0;width:48%;height:100%;\">";
if (rmb > 0) {
strInfo += "<span id=\"profitRMB\" class=\"itemContent\">利润RMB&nbsp;<span id=\"profitRMB\">" + rmb + "</span></span>";
}
else {
strInfo += "<span class=\"itemContent\">利润RMB&nbsp;<span id=\"profitRMB\" style=\"color:#F00;\">" + rmb + "</span></span>";
}
strInfo += "</li><li style=\"float:left;margin:0;padding:0;width:50%;height:100%;\">";
if (usd > 0) {
strInfo += "<span id=\"profitUSD\" class=\"itemContent\">利润USD&nbsp;<span id=\"profitUSD\">" + usd + "</span></span>";
}
else {
strInfo += "<span class=\"itemContent\">利润USD&nbsp;<span id=\"profitUSD\" style=\"color:#F00;\">" + usd + "</span></span>";
}
strInfo += "</li></ul></li>";
strInfo += "<li class=\"itemLI\"><ul style=\"margin:0;padding:0;width:100%;height:100%;list-style:none;\"><li style=\"float:left;margin:0;margin-left:2%;padding:0;width:48%;height:100%;\">";
if (otr > 0) {
strInfo += "<span id=\"profitOT\" class=\"itemContent\">其它:&nbsp;<span id=\"profitOT\">" + otr + "</span></span>";
}
else {
strInfo += "<span class=\"itemContent\">其它:&nbsp;<span id=\"profitOT\" style=\"color:#F00;\">" + otr + "</span></span>";
}
strInfo += "</li><li style=\"float:left;margin:0;padding:0;width:50%;height:100%;\">";
if (ttl > 0) {
strInfo += "<span id=\"grossProfit\" class=\"itemContent\">毛利润:&nbsp;<span id=\"grossProfit\">" + ttl + "</span></span>";
}
else {
strInfo += "<span class=\"itemContent\">毛利润:&nbsp;<span id=\"grossProfit\" style=\"color:#F00;\">" + ttl + "</span></span>";
}
strInfo += "</li></ul></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">经营类别:" + oplbName + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">报关单号:" + customNo + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">费用锁定:" + feeStatusRef + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">委托单位:" + customerName + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">开船日期:" + etd + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">揽&nbsp;&nbsp;货&nbsp;&nbsp;人:" + sale + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">会计期间:" + accDate + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">经营单位:" + enterp + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">操&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;作:" + op + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">录&nbsp;&nbsp;入&nbsp;&nbsp;人:" + inputBy + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">起运港:" + portLoad + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">目的港:" + portDischarge + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">船&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;名:" + vessel + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">航&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;次:" + voyno + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">集&nbsp;&nbsp;装&nbsp;&nbsp;箱:" + cntrtotal + "</span></li>";
}
});
if (strInfo != "") {
$("#detailProfitInfoUL").html(strInfo);
}
}
});
$.ajax({
type: "post",
data: "bo=" + bsno,
dataType: "json",
url: "../../Handler/Profit.ashx?action=10",
cache: false,
success: function (msg) {
$.each(msg, function (i, item) {
if (i == 0) {
$("#profitRMB").html(item.PR);
}
else if (i == 1) {
$("#profitUSD").html(item.PR);
}
else if (i == 2) {
$("#profitOT").html(item.PR);
}
else if (i == 3) {
ttl = item.PR;
$("#grossProfit").html(ttl.substring(0, ttl.length - 5));
}
});
}
});
}
function fnProfitAuditingDrInfo() {
$.ajaxSetup({ async: false });
var pageTotalCount = 0;
var feeStatus = ""; //费用状态
var feeName = ""; //费用名称
var feeDescription = ""; //英文名称
var customerType = ""; //客户类别
var customerName = ""; //结算对象
var unit = ""; //单位标准
var unitPrice = ""; //单价
var taxUnitPrice = ""; //含税单价
var quantity = ""; //数量
var taxRate = ""; //税率
var noTaxAmount = ""; //不含税金额
var amount = ""; //金额
var currency = ""; //币别
var exchangeRate = ""; //汇率
var accTaxRate = ""; //进项税率
var rmark = ""; //备注
var isAdvancedpay = ""; //是否垫付
var isInvoice = ""; //不开发票
var feeFrt = ""; //FRT
var commissionRate = ""; //佣金比率
var opName = ""; //录入人
var enterDate = ""; //录入日期
var settlement = ""; //结算金额
var invoice = ""; //已开票金额
var invoiceNum = ""; //发票号码
//auditingStatusIsAll=1 checked auditingStatusIsAll=0 unchecked
//应收Dr type=1 应付Cr type=2
//cacheKey = decrypt(u, decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs")) + "|RL|DI|" + expenseStatusIsAll + "|" + LocaleYear + "|" + LocaleMonth + "|" + LocaleDate + "|" + LocaleHours + "|" + LocaleMinutes;
UrlParam = "&s=&y=" + jsencrypt(decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs"), oplb) + "&t=1&es=" + expenseIsAll + "&b=" + jsencrypt(decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs"), bsno); //" + PageIndex + "
url = "../../Handler/Profit.ashx?action=1" + UrlParam;
isSettlementDrSign = false; //是否结算
isInvoiceDrSign = false; //是否开出发票
isOrderAmountDrSign = false; //是否申请费用
isOrderInvoiceDrSign = false; //是否申请开票
$.ajax({
type: "post",
dataType: "json",
data: UrlParam,
url: url,
cache: false,
success: function (msg) {
strInfo = "";
_auditingDrAmount = 0;
_settlementDrAmount = 0; //已结算费用数量
_invoiceDrAmount = 0; //已开出发票费用数量
_orderAmountDrAmount = 0; //已申请费用费用数量
_orderInvoiceDrAmount = 0; //已申请开票费用数量
$.each(msg, function (i, item) {
if (item.GId != "" && item.GId != undefined && item.GId != null) {
drCount++;
if (item.Settlement != "0.00") {
isSettlementDrSign = true;
_SettlementDrSign[_settlementDrAmount] = item.GId + "|" + item.FeeName;
_settlementDrAmount++;
}
if (item.Invoice != "0.00") {
isInvoiceDrSign = true;
_InvoiceDrSign[_invoiceDrAmount] = item.GId + "|" + item.FeeName;
_invoiceDrAmount++;
}
if (item.OrderAmount != "0.00") {
isOrderAmountDrSign = true;
_OrderAmountDrSign[_orderAmountDrAmount] = item.GId + "|" + item.FeeName;
_orderAmountDrAmount++;
}
if (item.OrderInvoice != "0.00") {
isOrderInvoiceDrSign = true;
_OrderInvoiceDrSign[_orderInvoiceDrAmount] = item.GId + "|" + item.FeeName;
_orderInvoiceDrAmount++;
}
feeStatus = item.FeeStatus_Ref;
feeName = item.FeeName; //费用名称
feeDescription = item.FeeDescription; //英文名称
customerType = item.CustomerType; //客户类别
customerName = item.CustomerName; //结算对象
unit = item.Unit; //单位标准
unitPrice = item.UnitPrice + ".00"; //单价
taxUnitPrice = item.TaxUnitPrice + ".00"; //含税单价
quantity = item.Quantity; //数量
taxRate = item.TaxRate; //税率
noTaxAmount = item.NoTaxAmount + ".00"; //不含税金额
amount = item.Amount + ".00"; //金额
currency = item.Currency; //币别
exchangeRate = item.ExChangerate; //汇率
accTaxRate = item.AccTaxRate; //进项税率
rmark = item.Remark; //备注
feeFrt = item.FeeFrt; //FRT
//commissionRate = item.Commissionrate; //佣金比率
opName = item.OpName; //录入人
enterDate = item.EnterDate; //录入日期
enterDate = enterDate.substring(0, 8);
enterDate = enterDate.replace(/\//g, "-");
settlement = item.Settlement + ".00"; //结算金额
invoice = item.Invoice + ".00"; //已开票金额
invoiceNum = item.InvoiceNum; //发票号码
strInfo += "<li class=\"itemLIComposite\">";
strInfo += "<ul class=\"itemUL\">";
switch (item.FeeStatus) {
case 2: //提交审核
isDrAuditing = 1;
strInfo += "<li class=\"itemTitleLI_Yellow\" style=\"display:block;\" id=\"drItemTitle" + item.GId + "\" rel=\"title\" ><span class=\"itemContentLeft\"><input id=\"chkdr" + i + "\" flow=\"1\" ref=\"chk\" name=\"chkdr\" value=\"" + item.GId + "\" selparam=\"提交审核\" onclick=\"fnDrCheck('chkdr" + i + "', 'dr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '提交审核', 'drFeeStatus" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','" + item.GId + "');\" type=\"checkbox\" />&nbsp;<a href=\"javascript:fnItemSelect('dr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '提交审核', 'drFeeStatus" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','" + item.GId + "')\" class=\"normalContent\"><span cuid=\"drItemTitleCustomerName" + item.GId + "\">" + customerName + "</span>&nbsp;<span feid=\"drItemTitleFeeName" + item.GId + "\">" + feeName + "</span>&nbsp;<span amid=\"drItemTitleAmount" + item.GId + "\">" + amount + "</span>&nbsp;<span cyid=\"drItemTitleCurrency" + item.GId + "\">" + currency + "</span></a></span><span class=\"itemContentRight\"><a href=\"javascript:fnItemHyperlinkSelect('drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "');\"><img id=\"drDetailReceivableLI\" src=\"../../Images/hideDarkGray.png\" style=\"width:0.9375em;height:0.75em;border:0px #fff solid;\" /></a></span></li>";
break;
case 0: //审核通过
strInfo += "<li class=\"itemTitleLI_Green\" style=\"display:block;\" id=\"drItemTitle" + item.GId + "\" rel=\"title\"><span class=\"itemContentLeft\"><input id=\"chkdr" + i + "\" flow=\"2\" ref=\"chk\" name=\"chkdr\" value=\"" + item.GId + "\" selparam=\"审核通过\" onclick=\"fnDrCheck('chkdr" + i + "', 'dr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '审核通过', 'drFeeStatus" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','" + item.GId + "');\" type=\"checkbox\" />&nbsp;<a href=\"javascript:fnItemSelect('dr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '审核通过', 'drFeeStatus" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','" + item.GId + "')\" class=\"normalContent\"><span cuid=\"drItemTitleCustomerName" + item.GId + "\">" + customerName + "</span>&nbsp;<span feid=\"drItemTitleFeeName" + item.GId + "\">" + feeName + "</span>&nbsp;<span amid=\"drItemTitleAmount" + item.GId + "\">" + amount + "</span>&nbsp;<span cyid=\"drItemTitleCurrency" + item.GId + "\">" + currency + "</span></a></span><span class=\"itemContentRight\"><a href=\"javascript:fnItemHyperlinkSelect('drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "');\"><img id=\"drDetailReceivableLI\" src=\"../../Images/hideDarkGray.png\" style=\"width:0.9375em;height:0.75em;border:0px #fff solid;\" /></a></span></li>";
break;
case 6: //驳回提交
strInfo += "<li class=\"itemTitleLI_Brown\" style=\"display:block;\" id=\"drItemTitle" + item.GId + "\" rel=\"title\"><span class=\"itemContentLeft\"><input id=\"chkdr" + i + "\" flow=\"3\" ref=\"chk\" name=\"chkdr\" value=\"" + item.GId + "\" selparam=\"驳回提交\" onclick=\"fnDrCheck('chkdr" + i + "', 'dr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '驳回提交', 'drFeeStatus" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','" + item.GId + "');\" type=\"checkbox\" />&nbsp;<a href=\"javascript:fnItemSelect('dr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '驳回提交', 'drFeeStatus" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','" + item.GId + "')\" class=\"normalContent\"><span cuid=\"drItemTitleCustomerName" + item.GId + "\">" + customerName + "</span>&nbsp;<span feid=\"drItemTitleFeeName" + item.GId + "\">" + feeName + "</span>&nbsp;<span amid=\"drItemTitleAmount" + item.GId + "\">" + amount + "</span>&nbsp;<span cyid=\"drItemTitleCurrency" + item.GId + "\">" + currency + "</span></a></span><span class=\"itemContentRight\"><a href=\"javascript:fnItemHyperlinkSelect('drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "');\"><img id=\"drDetailReceivableLI\" src=\"../../Images/hideDarkGray.png\" style=\"width:0.9375em;height:0.75em;border:0px #fff solid;\" /></a></span></li>";
break;
case 9: //结算完毕
strInfo += "<li class=\"itemTitleLI_Blue\" style=\"display:block;\" id=\"drItemTitle" + item.GId + "\" rel=\"title\"><span class=\"itemContentLeft\"><input id=\"chkdr" + i + "\" flow=\"4\" ref=\"chk\" name=\"chkdr\" value=\"" + item.GId + "\" selparam=\"结算完毕\" onclick=\"fnDrCheck('chkdr" + i + "', 'dr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '结算完毕', 'drFeeStatus" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','" + item.GId + "');\" type=\"checkbox\" />&nbsp;<a href=\"javascript:fnItemSelect('dr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '结算完毕', 'drFeeStatus" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','" + item.GId + "')\" class=\"normalContent\"><span cuid=\"drItemTitleCustomerName" + item.GId + "\">" + customerName + "</span>&nbsp;<span feid=\"drItemTitleFeeName" + item.GId + "\">" + feeName + "</span>&nbsp;<span amid=\"drItemTitleAmount" + item.GId + "\">" + amount + "</span>&nbsp;<span cyid=\"drItemTitleCurrency" + item.GId + "\">" + currency + "</span></a></span><span class=\"itemContentRight\"><a href=\"javascript:fnItemHyperlinkSelect('drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "');\"><img id=\"drDetailReceivableLI\" src=\"../../Images/hideDarkGray.png\" style=\"width:0.9375em;height:0.75em;border:0px #fff solid;\" /></a></span></li>";
break;
case 3: //申请修改
isDrAuditing = 3;
strInfo += "<li class=\"itemTitleLI_Pink\" style=\"display:block;\" id=\"drItemTitle" + item.GId + "\" rel=\"title\"><span class=\"itemContentLeft\"><input id=\"chkdr" + i + "\" flow=\"5\" ref=\"chk\" name=\"chkdr\" value=\"" + item.GId + "\" selparam=\"申请修改\" onclick=\"fnDrCheck('chkdr" + i + "', 'dr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '申请修改', 'drFeeStatus" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','" + item.GId + "');\" type=\"checkbox\" />&nbsp;<a href=\"javascript:fnItemSelect('dr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '申请修改', 'drFeeStatus" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','" + item.GId + "')\" class=\"normalContent\"><span cuid=\"drItemTitleCustomerName" + item.GId + "\">" + customerName + "</span>&nbsp;<span feid=\"drItemTitleFeeName" + item.GId + "\">" + feeName + "</span>&nbsp;<span amid=\"drItemTitleAmount" + item.GId + "\">" + amount + "</span>&nbsp;<span cyid=\"drItemTitleCurrency" + item.GId + "\">" + currency + "</span></a></span><span class=\"itemContentRight\"><a href=\"javascript:fnItemHyperlinkSelect('drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "');\"><img id=\"drDetailReceivableLI\" src=\"../../Images/hideDarkGray.png\" style=\"width:0.9375em;height:0.75em;border:0px #fff solid;\" /></a></span></li>";
break;
case 4: //申请删除
isDrAuditing = 4;
strInfo += "<li class=\"itemTitleLI_Gray\" style=\"display:block;\" id=\"drItemTitle" + item.GId + "\" rel=\"title\"><span class=\"itemContentLeft\"><input id=\"chkdr" + i + "\" flow=\"6\" ref=\"chk\" name=\"chkdr\" value=\"" + item.GId + "\" selparam=\"申请删除\" onclick=\"fnDrCheck('chkdr" + i + "', 'dr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '申请删除', 'drFeeStatus" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','" + item.GId + "');\" type=\"checkbox\" />&nbsp;<a href=\"javascript:fnItemSelect('dr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '申请删除', 'drFeeStatus" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "','" + item.GId + "')\" class=\"normalContent\"><span cuid=\"drItemTitleCustomerName" + item.GId + "\">" + customerName + "</span>&nbsp;<span feid=\"drItemTitleFeeName" + item.GId + "\">" + feeName + "</span>&nbsp;<span amid=\"drItemTitleAmount" + item.GId + "\">" + amount + "</span>&nbsp;<span cyid=\"drItemTitleCurrency" + item.GId + "\">" + currency + "</span></a></span><span class=\"itemContentRight\"><a href=\"javascript:fnItemHyperlinkSelect('drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "');\"><img id=\"drDetailReceivableLI\" src=\"../../Images/hideDarkGray.png\" style=\"width:0.9375em;height:0.75em;border:0px #fff solid;\" /></a></span></li>";
break;
}
switch (item.FeeStatus) {
case 3: //申请修改
strInfo += "<li class=\"itemTitleLIHover\" style=\"display:none;\" id=\"drItemTitleHover" + item.GId + "\" rel=\"titleHover\"><span class=\"itemContentLeftHover\" style=\"display:inline-block;width:80%;\"><a onclick=\"fnItemUnSelect('drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "')\"><span cuid=\"drItemTitleCustomerName" + item.GId + "\">" + customerName + "</span>&nbsp;<span feid=\"drItemTitleFeeName" + item.GId + "\">" + feeName + "</span>&nbsp;<span amid=\"drItemTitleAmount" + item.GId + "\">" + amount + "</span>&nbsp;<span cyid=\"drItemTitleCurrency" + item.GId + "\">" + currency + "</span></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href=\"javascript:fnDispNewValue('" + item.GId + "')\"><img src=\"../../Images/edit.png\" style=\"width:1.75em;height:1.125em;border:0px #fff solid;\" /></a></span><span class=\"itemContentRightHover\"><a onclick=\"fnItemUnSelect('drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "')\"><img id=\"drDetailReceivableLI\" src=\"../../Images/showDarkOrange.png\" style=\"width:0.9375em;height:0.75em;border:0px #fff solid;border:0px #fff solid;\" /></a></span></li>";
break;
/*case "":
strInfo += "<li class=\"itemTitleLIHover\" style=\"display:none;\" id=\"drItemTitleHover" + item.GID + "\" rel=\"titleHover\"><span class=\"itemContentLeftHover\" style=\"display:inline-block;width:100%;\"><a onclick=\"fnItemUnSelect('drItemTitle" + item.GID + "', 'drItemTitleHover" + item.GID + "', 'drBillUL" + item.GID + "')\">" + customerName + " " + feeName + " " + amount + "</a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href=\"javascript:void(0);\"><img src=\"../../Images/edit.png\" style=\"width:1.75em;height:1.125em;border:0px #fff solid;\" /></a></span><span class=\"itemContentRightHover\">&nbsp;<img id=\"drDetailReceivableLI\" src=\"../../Images/showDarkOrange.png\" style=\"width:0.9375em;height:0.75em;border:0px #fff solid;\" />&nbsp;&nbsp;</span></li>";
break;*/
default:
strInfo += "<li class=\"itemTitleLIHover\" style=\"display:none;\" id=\"drItemTitleHover" + item.GId + "\" rel=\"titleHover\" onclick=\"fnItemUnSelect('drItemTitle" + item.GId + "', 'drItemTitleHover" + item.GId + "', 'drBillUL" + item.GId + "')\"><span class=\"itemContentLeftHover\" style=\"display:inline-block;width:80%;\"><span cuid=\"drItemTitleCustomerName" + item.GId + "\">" + customerName + "</span>&nbsp;<span feid=\"drItemTitleFeeName" + item.GId + "\">" + feeName + "</span>&nbsp;<span amid=\"drItemTitleAmount" + item.GId + "\">" + amount + "</span>&nbsp;<span cyid=\"drItemTitleCurrency" + item.GId + "\">" + currency + "</span></span><span class=\"itemContentRightHover\"><img id=\"drDetailReceivableLI\" src=\"../../Images/showDarkOrange.png\" style=\"width:0.9375em;height:0.75em;border:0px #fff solid;\" /></span></li>";
break;
}
strInfo += "</ul>";
strInfo += "<ul id=\"drBillUL" + item.GId + "\" class=\"itemUL\" style=\"display:none\" rel=\"UL\">";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">费用状态:" + "<span id='drFeeStatus" + item.GId + "'>" + feeStatus + "</span>" + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">费用名称:<span feid=\"drItemTitleAmount" + item.GId + "\">" + feeName + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">英文名称:" + feeDescription + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">客户类别:" + customerType + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">结算对象:<span cuid=\"drItemTitleCustomerName" + item.GId + "\">" + customerName + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">单位标准:<span unid=\"drItemTitleUnit" + item.GId + "\">" + unit + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">单价:<span upid=\"drItemTitleUnitPrice" + item.GId + "\">" + unitPrice + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">含税单价:<span tupid=\"drItemTitleTaxUnitPrice" + item.GId + "\">" + taxUnitPrice + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">数量:<span quid=\"drItemTitleQuantity" + item.GId + "\">" + quantity + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">税率:<span trid=\"drItemTitleTaxRate" + item.GId + "\">" + taxRate + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">无税金额:<span ntaid=\"drItemTitleNoTaxAmount" + item.GId + "\">" + noTaxAmount + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">金额:<span amid=\"drItemTitleAmount" + item.GId + "\">" + amount + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">币别:<span cuid=\"drItemTitleCurrency" + item.GId + "\">" + currency + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">汇率:<span tupid=\"drItemTitleExchangeRate" + item.GId + "\">" + exchangeRate + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">进项税率:<span atrid=\"drItemTitleAccTaxRate" + item.GId + "\">" + accTaxRate + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">备注:" + rmark + "</span></li>";
//strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">是否垫付:" + item.IsAdvancedpay + "</span></li>"; isAdvancedpay
//strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">不开发票:" + item.IsInvoice + "</span></li>"; isInvoice
if (item.IsAdvancedpay == "False") {
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">是否垫付:不垫付</span></li>"; //isAdvancedpay
}
else {
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">是否垫付:垫付</span></li>"; //isAdvancedpay
}
if (item.IsInvoice == "False") {
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">是否开发票:<span id=\"drFeeInvoice" + item.GId + "\">开发票</span></span></li>"; //isInvoice
}
else {
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">是否开发票:<span id=\"drFeeInvoice" + item.GId + "\">禁开发票</span></span></li>"; //isInvoice
}
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">FRT" + feeFrt + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">佣金比率:" + commissionRate + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">录入人:" + opName + "</span></li>";
/*strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">录入日期:" + enterDate + "</span></li>";*/
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">结算金额:" + settlement + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">已开票金额:" + invoice + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">发票号码:" + invoiceNum + "</span></li>";
strInfo += "</ul>";
strInfo += "</li>";
}
});
if (strInfo != "") {
$("#detailReceivableUL").html(strInfo);
}
}
});
//$("#detailReceivableUL").html("<li class=\"itemLI\">aaa</li>");
}
function fnProfitAuditingCrInfo() {
$.ajaxSetup({ async: false });
var pageTotalCount = 0;
var feeStatus = ""; //费用状态
var feeName = ""; //费用名称
var feeDescription = ""; //英文名称
var customerType = ""; //客户类别
var customerName = ""; //结算对象
var unit = ""; //单位标准
var unitPrice = ""; //单价
var taxUnitPrice = ""; //含税单价
var quantity = ""; //数量
var taxRate = ""; //税率
var noTaxAmount = ""; //不含税金额
var amount = ""; //金额
var currency = ""; //币别
var exchangeRate = ""; //汇率
var accTaxRate = ""; //进项税率
var rmark = ""; //备注
var isAdvancedpay = ""; //是否垫付
var isInvoice = ""; //不开发票
var feeFrt = ""; //FRT
var commissionRate = ""; //佣金比率
var opName = ""; //录入人
var enterDate = ""; //录入日期
var settlement = ""; //结算金额
var invoice = ""; //已开票金额
var invoiceNum = ""; //发票号码
//auditingStatusIsAll=1 checked auditingStatusIsAll=0 unchecked
//应收Dr type=1 应付Cr type=2
//cacheKey = decrypt(u, decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs")) + "|RL|DI|" + expenseStatusIsAll + "|" + LocaleYear + "|" + LocaleMonth + "|" + LocaleDate + "|" + LocaleHours + "|" + LocaleMinutes;
UrlParam = "&s=&y=" + jsencrypt(decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs"), oplb) + "&t=2&es=" + expenseIsAll + "&b=" + jsencrypt(decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs"), bsno); //" + PageIndex + "
url = "../../Handler/Profit.ashx?action=1" + UrlParam;
isSettlementCrSign = false; //是否结算
isInvoiceCrSign = false; //是否开出发票
isOrderAmountDrSign = false; //是否申请费用
isOrderInvoiceCrSign = false; //是否申请开票
$.ajax({
type: "post",
dataType: "json",
data: UrlParam,
url: url,
cache: false,
success: function (msg) {
strInfo = "";
_auditingCrAmount = 0;
_settlementCrAmount = 0; //已结算费用数量
_invoiceCrAmount = 0; //已开出发票费用数量
_orderAmountCrAmount = 0; //已申请费用费用数量
_orderInvoiceCrAmount = 0; //已申请开票费用数量
$.each(msg, function (i, item) {
if (item.GId != "" && item.GId != undefined && item.GId != null) {
crCount++;
if (item.Settlement != "0.00") {
isSettlementCrSign = true;
_SettlementCrSign[_settlementCrAmount] = item.GId + "|" + item.FeeName;
_settlementCrAmount++;
}
if (item.Invoice != "0.00") {
isInvoiceCrSign = true;
_InvoiceCrSign[_invoiceCrAmount] = item.GId + "|" + item.FeeName;
_invoiceCrAmount++;
}
if (item.OrderAmount != "0.00") {
isOrderAmountCrSign = true;
_OrderAmountCrSign[_orderAmountCrAmount] = item.GId + "|" + item.FeeName;
_orderAmountCrAmount++;
}
if (item.OrderInvoice != "0.00") {
isOrderInvoiceCrSign = true;
_OrderInvoiceCrSign[_orderInvoiceCrAmount] = item.GId + "|" + item.FeeName;
_orderInvoiceCrAmount++;
}
feeStatus = item.FeeStatus_Ref;
feeName = item.FeeName; //费用名称
feeDescription = item.FeeDescription; //英文名称
customerType = item.CustomerType; //客户类别
customerName = item.CustomerName; //结算对象
unit = item.Unit; //单位标准
unitPrice = item.UnitPrice+".00"; //单价
taxUnitPrice = item.TaxUnitPrice + ".00"; //含税单价
quantity = item.Quantity; //数量
taxRate = item.TaxRate; //税率
noTaxAmount = item.NoTaxAmount + ".00"; //不含税金额
amount = item.Amount + ".00"; //金额
currency = item.Currency; //币别
exchangeRate = item.ExChangerate; //汇率
accTaxRate = item.AccTaxRate; //进项税率
rmark = item.Remark; //备注
feeFrt = item.FeeFrt; //FRT
//commissionRate = item.Commissionrate; //佣金比率
opName = item.OpName; //录入人
enterDate = item.EnterDate; //录入日期
enterDate = enterDate.substring(0, 8);
enterDate = enterDate.replace(/\//g, "-");
settlement = item.Settlement + ".00"; //结算金额
invoice = item.Invoice + ".00"; //已开票金额
invoiceNum = item.InvoiceNum; //发票号码
strInfo += "<li class=\"itemLIComposite\">";
strInfo += "<ul class=\"itemUL\">";
switch (item.FeeStatus) {
case 2: //提交审核
isCrAuditing = 1;
strInfo += "<li class=\"itemTitleLI_Yellow\" style=\"display:block;\" id=\"crItemTitle" + item.GId + "\" rel=\"title\"><span class=\"itemContentLeft\"><input id=\"chkcr" + i + "\" flow=\"1\" ref=\"chk\" name=\"chkcr\" value=\"" + item.GId + "\" selparam=\"提交审核\" onclick=\"fnCrCheck('chkcr" + i + "', 'cr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '提交审核', 'crFeeStatus" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','" + item.GId + "');\" type=\"checkbox\" />&nbsp;<a href=\"javascript:fnItemSelect('cr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '提交审核', 'crFeeStatus" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','" + item.GId + "')\" class=\"normalContent\"><span cuid=\"crItemTitleCustomerName" + item.GId + "\">" + customerName + "</span>&nbsp;<span feid=\"crItemTitleFeeName" + item.GId + "\">" + feeName + "</span>&nbsp;<span amid=\"crItemTitleAmount" + item.GId + "\">" + amount + "</span>&nbsp;<span cyid=\"crItemTitleCurrency" + item.GId + "\">" + currency + "</span></a></span><span class=\"itemContentRight\"><a href=\"javascript:fnItemHyperlinkSelect('crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "');\"><img id=\"crDetailReceivableLI\" src=\"../../Images/hideDarkGray.png\" style=\"width:0.9375em;height:0.75em;border:0px #fff solid;\" /></a></span></li>";
break;
case 0: //审核通过
strInfo += "<li class=\"itemTitleLI_Green\" style=\"display:block;\" id=\"crItemTitle" + item.GId + "\" rel=\"title\"><span class=\"itemContentLeft\"><input id=\"chkcr" + i + "\" flow=\"2\" ref=\"chk\" name=\"chkcr\" value=\"" + item.GId + "\" selparam=\"审核通过\" onclick=\"fnCrCheck('chkcr" + i + "', 'cr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '审核通过', 'crFeeStatus" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','" + item.GId + "');\" type=\"checkbox\" />&nbsp;<a href=\"javascript:fnItemSelect('cr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '审核通过', 'crFeeStatus" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','" + item.GId + "')\" class=\"normalContent\"><span cuid=\"crItemTitleCustomerName" + item.GId + "\">" + customerName + "</span>&nbsp;<span feid=\"crItemTitleFeeName" + item.GId + "\">" + feeName + "</span>&nbsp;<span amid=\"crItemTitleAmount" + item.GId + "\">" + amount + "</span>&nbsp;<span cyid=\"crItemTitleCurrency" + item.GId + "\">" + currency + "</span></a></span><span class=\"itemContentRight\"><a href=\"javascript:fnItemHyperlinkSelect('crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "');\"><img id=\"crDetailReceivableLI\" src=\"../../Images/hideDarkGray.png\" style=\"width:0.9375em;height:0.75em;border:0px #fff solid;\" /></a></span></li>";
break;
case 6: //驳回提交
strInfo += "<li class=\"itemTitleLI_Brown\" style=\"display:block;\" id=\"crItemTitle" + item.GId + "\" rel=\"title\"><span class=\"itemContentLeft\"><input id=\"chkcr" + i + "\" flow=\"3\" ref=\"chk\" name=\"chkcr\" value=\"" + item.GId + "\" selparam=\"驳回提交\" onclick=\"fnCrCheck('chkcr" + i + "', 'cr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '驳回提交', 'crFeeStatus" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','" + item.GId + "');\" type=\"checkbox\" />&nbsp;<a href=\"javascript:fnItemSelect('cr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '驳回提交', 'crFeeStatus" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','" + item.GId + "')\" class=\"normalContent\"><span cuid=\"crItemTitleCustomerName" + item.GId + "\">" + customerName + "</span>&nbsp;<span feid=\"crItemTitleFeeName" + item.GId + "\">" + feeName + "</span>&nbsp;<span amid=\"crItemTitleAmount" + item.GId + "\">" + amount + "</span>&nbsp;<span cyid=\"crItemTitleCurrency" + item.GId + "\">" + currency + "</span></a></span><span class=\"itemContentRight\"><a href=\"javascript:fnItemHyperlinkSelect('crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "');\"><img id=\"crDetailReceivableLI\" src=\"../../Images/hideDarkGray.png\" style=\"width:0.9375em;height:0.75em;border:0px #fff solid;\" /></a></span></li>";
break;
case 9: //结算完毕
strInfo += "<li class=\"itemTitleLI_Blue\" style=\"display:block;\" id=\"crItemTitle" + item.GId + "\" rel=\"title\"><span class=\"itemContentLeft\"><input id=\"chkcr" + i + "\" flow=\"4\" ref=\"chk\" name=\"chkcr\" value=\"" + item.GId + "\" selparam=\"结算完毕\" onclick=\"fnCrCheck('chkcr" + i + "', 'cr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '结算完毕', 'crFeeStatus" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','" + item.GId + "');\" type=\"checkbox\" />&nbsp;<a href=\"javascript:fnItemSelect('cr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '结算完毕', 'crFeeStatus" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','" + item.GId + "')\" class=\"normalContent\"><span cuid=\"crItemTitleCustomerName" + item.GId + "\">" + customerName + "</span>&nbsp;<span feid=\"crItemTitleFeeName" + item.GId + "\">" + feeName + "</span>&nbsp;<span amid=\"crItemTitleAmount" + item.GId + "\">" + amount + "</span>&nbsp;<span cyid=\"crItemTitleCurrency" + item.GId + "\">" + currency + "</span></a></span><span class=\"itemContentRight\"><a href=\"javascript:fnItemHyperlinkSelect('crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "');\"><img id=\"crDetailReceivableLI\" src=\"../../Images/hideDarkGray.png\" style=\"width:0.9375em;height:0.75em;border:0px #fff solid;\" /></a></span></li>";
break;
case 3: //申请修改
isCrAuditing = 3;
strInfo += "<li class=\"itemTitleLI_Pink\" style=\"display:block;\" id=\"crItemTitle" + item.GId + "\" rel=\"title\"><span class=\"itemContentLeft\"><input id=\"chkcr" + i + "\" flow=\"5\" ref=\"chk\" name=\"chkcr\" value=\"" + item.GId + "\" selparam=\"申请修改\" onclick=\"fnCrCheck('chkcr" + i + "', 'cr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '申请修改', 'crFeeStatus" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','" + item.GId + "');\" type=\"checkbox\" />&nbsp;<a href=\"javascript:fnItemSelect('cr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '申请修改', 'crFeeStatus" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','" + item.GId + "')\" class=\"normalContent\"><span cuid=\"crItemTitleCustomerName" + item.GId + "\">" + customerName + "</span>&nbsp;<span feid=\"crItemTitleFeeName" + item.GId + "\">" + feeName + "</span>&nbsp;<span amid=\"crItemTitleAmount" + item.GId + "\">" + amount + "</span>&nbsp;<span cyid=\"crItemTitleCurrency" + item.GId + "\">" + currency + "</span></a></span><span class=\"itemContentRight\"><a href=\"javascript:fnItemHyperlinkSelect('crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "');\"><img id=\"crDetailReceivableLI\" src=\"../../Images/hideDarkGray.png\" style=\"width:0.9375em;height:0.75em;border:0px #fff solid;\" /></a></span></li>";
break;
case 4: //申请删除
isCrAuditing = 4;
strInfo += "<li class=\"itemTitleLI_Gray\" style=\"display:block;\" id=\"crItemTitle" + item.GId + "\" rel=\"title\"><span class=\"itemContentLeft\"><input id=\"chkcr" + i + "\" flow=\"6\" ref=\"chk\" name=\"chkcr\" value=\"" + item.GId + "\" selparam=\"申请删除\" onclick=\"fnCrCheck('chkcr" + i + "', 'cr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '申请删除', 'crFeeStatus" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','" + item.GId + "');\" type=\"checkbox\" />&nbsp;<a href=\"javascript:fnItemSelect('cr', '" + gid + "', '" + item.GId + "', '" + oplb + "', '" + bsno + "', '申请删除', 'crFeeStatus" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "','" + item.GId + "')\" class=\"normalContent\"><span cuid=\"crItemTitleCustomerName" + item.GId + "\">" + customerName + "</span>&nbsp;<span feid=\"crItemTitleFeeName" + item.GId + "\">" + feeName + "</span>&nbsp;<span amid=\"crItemTitleAmount" + item.GId + "\">" + amount + "</span>&nbsp;<span cyid=\"crItemTitleCurrency" + item.GId + "\">" + currency + "</span></a></span><span class=\"itemContentRight\"><a href=\"javascript:fnItemHyperlinkSelect('crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "');\"><img id=\"crDetailReceivableLI\" src=\"../../Images/hideDarkGray.png\" style=\"width:0.9375em;height:0.75em;border:0px #fff solid;\" /></a></span></li>";
break;
}
switch (item.FeeStatus) {
case 3: //申请修改
strInfo += "<li class=\"itemTitleLIHover\" style=\"display:none;\" id=\"crItemTitleHover" + item.GId + "\" rel=\"titleHover\"><span class=\"itemContentLeftHover\" style=\"display:inline-block;width:80%;\"><a onclick=\"fnItemUnSelect('crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "')\"><span cuid=\"crItemTitleCustomerName" + item.GId + "\">" + customerName + "</span>&nbsp;<span feid=\"crItemTitleFeeName" + item.GId + "\">" + feeName + "</span>&nbsp;<span amid=\"crItemTitleAmount" + item.GId + "\">" + amount + "</span>&nbsp;<span cyid=\"crItemTitleCurrency" + item.GId + "\">" + currency + "</span></a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href=\"javascript:fnDispNewValue('" + item.GId + "')\"><img src=\"../../Images/edit.png\" style=\"width:1.75em;height:1.125em;border:0px #fff solid;\" /></a></span><span class=\"itemContentRightHover\"><a onclick=\"fnItemUnSelect('crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "')\"><img id=\"crDetailReceivableLI\" src=\"../../Images/showDarkOrange.png\" style=\"width:0.9375em;height:0.75em;border:0px #fff solid;\" /></a></span></li>";
break;
/*case "":
strInfo += "<li class=\"itemTitleLIHover\" style=\"display:none;\" id=\"crItemTitleHover" + item.GID + "\" rel=\"titleHover\"><span class=\"itemContentLeftHover\" style=\"display:inline-block;width:100%;\"><a onclick=\"fnItemUnSelect('crItemTitle" + item.GID + "', 'crItemTitleHover" + item.GID + "', 'crBillUL" + item.GID + "')\">" + customerName + " " + feeName + " " + amount + "</a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href=\"javascript:void(0);\"><img src=\"../../Images/edit.png\" style=\"width:1.75em;height:1.125em;border:0px #fff solid;\" /></a></span><span class=\"itemContentRightHover\">&nbsp;<img id=\"crDetailReceivableLI\" src=\"../../Images/showDarkOrange.png\" style=\"width:0.9375em;height:0.75em;border:0px #fff solid;\" />&nbsp;&nbsp;</span></li>";
break;*/
default:
strInfo += "<li class=\"itemTitleLIHover\" style=\"display:none;\" id=\"crItemTitleHover" + item.GId + "\" rel=\"titleHover\" onclick=\"fnItemUnSelect('crItemTitle" + item.GId + "', 'crItemTitleHover" + item.GId + "', 'crBillUL" + item.GId + "')\"><span class=\"itemContentLeftHover\" style=\"display:inline-block;width:80%;\"><span cuid=\"crItemTitleCustomerName" + item.GId + "\">" + customerName + "</span>&nbsp;<span feid=\"crItemTitleFeeName" + item.GId + "\">" + feeName + "</span>&nbsp;<span amid=\"crItemTitleAmount" + item.GId + "\">" + amount + "</span>&nbsp;<span cyid=\"crItemTitleCurrency" + item.GId + "\">" + currency + "</span></span><span class=\"itemContentRightHover\"><img id=\"crDetailReceivableLI\" src=\"../../Images/showDarkOrange.png\" style=\"width:0.9375em;height:0.75em;border:0px #fff solid;\" /></span></li>";
break;
}
strInfo += "</ul>";
strInfo += "<ul id=\"crBillUL" + item.GId + "\" class=\"itemUL\" style=\"display:none\" rel=\"UL\">";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">费用状态:" + "<span id='crFeeStatus" + item.GId + "'>" + feeStatus + "</span>" + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">费用名称:<span feid=\"crItemTitleAmount" + item.GId + "\">" + feeName + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">英文名称:" + feeDescription + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">客户类别:" + customerType + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">结算对象:<span cuid=\"crItemTitleCustomerName" + item.GId + "\">" + customerName + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">单位标准:<span unid=\"crItemTitleUnit" + item.GId + "\">" + unit + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">单价:<span upid=\"crItemTitleUnitPrice" + item.GId + "\">" + unitPrice + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">含税单价:<span tupid=\"crItemTitleTaxUnitPrice" + item.GId + "\">" + taxUnitPrice + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">数量:<span quid=\"crItemTitleQuantity" + item.GId + "\">" + quantity + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">税率:<span trid=\"crItemTitleTaxRate" + item.GId + "\">" + taxRate + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">无税金额:<span ntaid=\"crItemTitleNoTaxAmount" + item.GId + "\">" + noTaxAmount + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">金额:<span amid=\"crItemTitleAmount" + item.GId + "\">" + amount + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">币别:<span cuid=\"crItemTitleCurrency" + item.GId + "\">" + currency + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">汇率:<span tupid=\"crItemTitleExchangeRate" + item.GId + "\">" + exchangeRate + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">进项税率:<span atrid=\"crItemTitleAccTaxRate" + item.GId + "\">" + accTaxRate + "</span></span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">备注:" + rmark + "</span></li>";
//strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">是否垫付:" + item.IsAdvancedpay + "</span></li>"; isAdvancedpay
//strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">不开发票:" + item.IsInvoice + "</span></li>"; isInvoice
if (item.IsAdvancedpay == "False") {
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">是否垫付:不垫付</span></li>"; //isAdvancedpay
}
else {
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">是否垫付:垫付</span></li>"; //isAdvancedpay
}
if (item.IsInvoice == "False") {
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">是否开发票:<span id=\"crFeeInvoice" + item.GId + "\">开发票</span></span></li>"; //isInvoice
}
else {
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">是否开发票:<span id=\"crFeeInvoice" + item.GId + "\">禁开发票</span></span></li>"; //isInvoice
}
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">FRT" + feeFrt + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">佣金比率:" + commissionRate + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">录入人:" + opName + "</span></li>";
/*strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">录入日期:" + enterDate + "</span></li>";*/
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">结算金额:" + settlement + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">已开票金额:" + invoice + "</span></li>";
strInfo += "<li class=\"itemLI\"><span class=\"itemContent\">发票号码:" + invoiceNum + "</span></li>";
strInfo += "</ul>";
strInfo += "</li>";
}
});
if (strInfo != "") {
$("#detailPayableUL").html(strInfo);
}
}
});
//$("#detailReceivableUL").html("<li class=\"itemLI\">aaa</li>");
}
function fnDispNewValue(feeid) {
var strInquire = "";
var cacheKey = "";
//应收Dr type=1 应付Cr type=2
//cacheKey = decrypt(u, decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs")) + "|FL|" + feeid + "|" + LocaleYear + "|" + LocaleMonth + "|" + LocaleDate + "|" + LocaleHours + "|" + LocaleMinutes;
$.ajax({
type: "post",
dataType: "json",
url: "../../Handler/Profit.ashx?action=9&id=" + jsencrypt(decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs"), feeid),
cache: false,
success: function (msg) {
strInquire = "";
$.each(msg, function (i, item) {
if (item.GId != "" && item.GId != undefined) {
changeFeeName = item.FeeName;
changeCustomerName = item.CustomerName;
changeUnit = item.Unit;
changeUnitPrice = parseFloat(item.UnitPrice);
changeTaxRate = parseFloat(item.TaxRate);
changeTaxUnitPrice = parseFloat(item.TaxUnitPrice);
changeQuantity = parseFloat(item.Quantity);
changeNoTaxAmount = parseFloat(item.NoTaxAmount);
changeAmount = parseFloat(item.Amount);
changeCurrency = item.Currency;
changeExChangerate = parseFloat(item.ExChangerate);
changeAccTaxRate = parseFloat(item.AccTaxRate);
strInquire += "<div class=\"serviceItem\"><span style=\"font-size:0.875em;color:#595959;font-family:'微软雅黑';\">费用名称:<span style=\"color:#00a8ff;\">" + item.FeeName + "</span></span></div>";
strInquire += "<div class=\"serviceItem\"><span style=\"font-size:0.875em;color:#595959;font-family:'微软雅黑';\">费用对象:<span style=\"color:#00a8ff;\">" + item.CustomerName + "</span></span></div>";
strInquire += "<div class=\"serviceItem\"><span style=\"font-size:0.875em;color:#595959;font-family:'微软雅黑';\">单位标准:<span style=\"color:#00a8ff;\">" + item.Unit + "</span></span></div>";
strInquire += "<div class=\"serviceItem\"><span style=\"font-size:0.875em;color:#595959;font-family:'微软雅黑';\">不含税价:<span style=\"color:#00a8ff;\">" + parseFloat(item.UnitPrice) + "</span></span></div>";
strInquire += "<div class=\"serviceItem\"><span style=\"font-size:0.875em;color:#595959;font-family:'微软雅黑';\">税&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;率:<span style=\"color:#00a8ff;\">" + parseFloat(item.TaxRate) + "</span></span></div>";
strInquire += "<div class=\"serviceItem\"><span style=\"font-size:0.875em;color:#595959;font-family:'微软雅黑';\">含税单价:<span style=\"color:#00a8ff;\">" + parseFloat(item.TaxUnitPrice) + "</span></span></div>";
strInquire += "<div class=\"serviceItem\"><span style=\"font-size:0.875em;color:#595959;font-family:'微软雅黑';\">计费数量:<span style=\"color:#00a8ff;\">" + parseFloat(item.Quantity) + "</span></span></div>";
strInquire += "<div class=\"serviceItem\"><span style=\"font-size:0.875em;color:#595959;font-family:'微软雅黑';\">不含税额:<span style=\"color:#00a8ff;\">" + parseFloat(item.NoTaxAmount) + "</span></span></div>";
strInquire += "<div class=\"serviceItem\"><span style=\"font-size:0.875em;color:#595959;font-family:'微软雅黑';\">含税金额:<span style=\"color:#00a8ff;\">" + parseFloat(item.Amount) + "</span></span></div>";
strInquire += "<div class=\"serviceItem\"><span style=\"font-size:0.875em;color:#595959;font-family:'微软雅黑';\">币&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;别:<span style=\"color:#00a8ff;\">" + item.Currency + "</span></span></div>";
strInquire += "<div class=\"serviceItem\"><span style=\"font-size:0.875em;color:#595959;font-family:'微软雅黑';\">汇&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;率:<span style=\"color:#00a8ff;\">" + parseFloat(item.ExChangerate) + "</span></span></div>";
strInquire += "<div class=\"serviceItem\"><span style=\"font-size:0.875em;color:#595959;font-family:'微软雅黑';\">财务税率:<span style=\"color:#00a8ff;\">" + parseFloat(item.AccTaxRate) + "</span></span></div>";
if (item.IsAdvancedpay == "0") {
strInquire += "<div class=\"serviceItem\"><span style=\"font-size:0.875em;color:#595959;font-family:'微软雅黑';\">是否垫付:<span style=\"color:#00a8ff;\">否</span></span></div>";
}
else {
strInquire += "<div class=\"serviceItem\"><span style=\"font-size:0.875em;color:#595959;font-family:'微软雅黑';\">是否垫付:<span style=\"color:#00a8ff;\">是</span></span></div>";
}
strInquire += "<div class=\"serviceItem\"><span style=\"font-size:0.875em;color:#595959;font-family:'微软雅黑';\">修改原因:<span style=\"color:#00a8ff;\">" + item.Reason + "</span></span></div>";
}
});
if (strInquire != "") {
$("#serviceConatain").html(strInquire);
$("#onlineService").animate({ width: "show", opacity: "show" }, "normal", function () {
$("#onlineService").show();
});
}
}
});
}
function fnProcAudit() {
if (operateFeeStatus == "提交审核") {
fnAudit();
}
else {
fnAuditShen();
}
}
function fnProcBack() {
if (operateFeeStatus == "提交审核") {
showBg("0", "", "0");
}
else if (drDisplay || crDisplay) {//!isDrAuditing || isCrAuditing
showBg("0", "", "1");
}
$("#txtReason").val("请添加备注信息或者驳回原因");
}
function fnAudit() { //, dataType
$.ajaxSetup({ async: false });
var recCount = 0;
var txtReason = $("#txtReason").val();
strSelGID = "";
if (txtReason == "请添加备注信息或者驳回原因") { txtReason = ""; }
if (drDisplay) {
for (var iCount = 0; iCount < drCount; iCount++) {
if ($("#chkdr" + iCount).attr("checked") == true) {
//查询判断$("#chkdr" + iCount).attr("value")是否是提交审核状态,是则可以审核,否则不能审核
//......
if ($("#chkdr" + iCount).attr("flow") == "1") {
strSelGID += $("#chkdr" + iCount).attr("value") + ",";
auditingArr[auditingAmount] = $("#chkdr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
}
else if (crDisplay) {
for (var iCount = 0; iCount < crCount; iCount++) {
if ($("#chkcr" + iCount).attr("checked") == true) {
//查询判断$("#chkdr" + iCount).attr("value")是否是提交审核状态,是则可以审核,否则不能审核
//......
if ($("#chkcr" + iCount).attr("flow") == "1") {
strSelGID += $("#chkcr" + iCount).attr("value") + ",";
auditingArr[auditingAmount] = $("#chkcr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
}
strSelGID = strSelGID.substring(0, strSelGID.length - 1);
$.ajax({
type: "post",
dataType: "json",
url: "../../Handler/Profit.ashx?action=3&b=" + jsencrypt(decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs"), strSelGID) + "&y=" + jsencrypt(decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs"), oplb),
cache: false,
success: function (msg) {
$("#chkAll").removeAttr("checked");
if (operateDataType == "dr") {
fnProfitAuditingDrInfo();
}
else if (operateDataType == "cr") {
fnProfitAuditingCrInfo();
}
}
});
}
function fnAuditBack() {
$.ajaxSetup({ async: false });
var _value = "";
var txtReason = $("#txtReason").val();
var auditingValue = "";
var settlementValue = "";
var invoiceValue = "";
var orderAmountValue = "";
var orderInvoiceValue = "";
var recCount = 0;
strSelGID = "";
if (txtReason == "请添加备注信息或者驳回原因") { txtReason = ""; }
if (drDisplay) {
for (var iCount = 0; iCount < drCount; iCount++) {
if ($("#chkdr" + iCount).attr("checked") == true) {
_value = $("#chkdr" + iCount).attr("value");
if (_auditingDrAmount > 0) {
for (var iAuditing = 0; iAuditing < _auditingDrAmount; iAuditing++) {
auditingValue = _auditingDrSign[iAuditing];
if (auditingValue.indexOf(_value) != -1) {
var tempArr = auditingValue.split("|");
showBg("1", tempArr[1] + "已审核无法驳回!");
}
else {
//查询判断 _value 是否是提交审核状态,是则可以审核,否则不能审核
//......
if ($("#chkdr" + iCount).attr("flow") == "1") {
strSelGID += _value + ",";
auditingArr[auditingAmount] = $("#chkdr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
}
else if (_settlementDrAmount > 0) {
for (var iSettlement = 0; iSettlement < _settlementDrAmount; iSettlement++) {
settlementValue = _SettlementDrSign[iSettlement];
if (settlementValue.indexOf(_value) != -1) {
var tempArr = settlementValue.split("|");
showBg("1", tempArr[1] + "已结算无法驳回!");
}
else {
//查询判断 _value 是否是提交审核状态,是则可以审核,否则不能审核
//......
if ($("#chkdr" + iCount).attr("flow") == "1") {
strSelGID += _value + ",";
auditingArr[auditingAmount] = $("#chkdr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
}
else if (_invoiceDrAmount > 0) {
for (var iInvoice = 0; iInvoice < _invoiceDrAmount; iInvoice++) {
invoiceValue = _InvoiceDrSign[iInvoice];
if (invoiceValue.indexOf(_value) != -1) {
var tempArr = invoiceValue.split("|");
showBg("1", tempArr[1] + "已开出发票无法驳回!");
}
else {
//查询判断 _value 是否是提交审核状态,是则可以审核,否则不能审核
//......
if ($("#chkdr" + iCount).attr("flow") == "1") {
strSelGID += _value + ",";
auditingArr[auditingAmount] = $("#chkdr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
}
else if (_orderAmountDrAmount > 0) {
for (var iOrderAmount = 0; iOrderAmount < _orderAmountDrAmount; iOrderAmount++) {
orderAmountValue = _OrderAmountDrSign[iOrderAmount];
if (orderAmountValue.indexOf(_value) != -1) {
var tempArr = orderAmountValue.split("|");
showBg("1", tempArr[1] + "已申请费用无法驳回!");
}
else {
//查询判断 _value 是否是提交审核状态,是则可以审核,否则不能审核
//......
if ($("#chkdr" + iCount).attr("flow") == "1") {
strSelGID += _value + ",";
auditingArr[auditingAmount] = $("#chkdr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
}
else if (_orderInvoiceDrAmount > 0) {
for (var iOrderInvoice = 0; iOrderInvoice < _orderInvoiceDrAmount; iOrderInvoice++) {
orderInvoiceValue = _OrderInvoiceDrSign[iOrderInvoice];
if (orderInvoiceValue.indexOf(_value) != -1) {
var tempArr = orderInvoiceValue.split("|");
showBg("1", tempArr[1] + "已申请开票费用无法驳回!");
}
else {
//查询判断 _value 是否是提交审核状态,是则可以审核,否则不能审核
//......
if ($("#chkdr" + iCount).attr("flow") == "1") {
strSelGID += _value + ",";
auditingArr[auditingAmount] = $("#chkdr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
}
else if (_settlementDrAmount == 0 && _invoiceDrAmount == 0 && _orderAmountDrAmount == 0 && _orderInvoiceDrAmount == 0) {
//查询判断 _value 是否是提交审核状态,是则可以审核,否则不能审核
//......
if ($("#chkdr" + iCount).attr("flow") == "1") {
strSelGID += _value + ",";
auditingArr[auditingAmount] = $("#chkdr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
}
}
else if (crDisplay) {
for (var iCount = 0; iCount < crCount; iCount++) {
if ($("#chkcr" + iCount).attr("checked") == true) {
_value = $("#chkcr" + iCount).attr("value");
if (_auditingCrAmount > 0) {
for (var iAuditing = 0; iAuditing < _auditingCrAmount; iAuditing++) {
auditingValue = _auditingCrSign[iAuditing];
if (auditingValue.indexOf(_value) != -1) {
var tempArr = auditingValue.split("|");
showBg("1", tempArr[1] + "已审核无法驳回!");
}
else {
//查询判断 _value 是否是提交审核状态,是则可以审核,否则不能审核
//......
if ($("#chkcr" + iCount).attr("flow") == "1") {
strSelGID += _value + ",";
auditingArr[auditingAmount] = $("#chkdr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
}
else if (_settlementCrAmount > 0) {
for (var iSettlement = 0; iSettlement < _settlementCrAmount; iSettlement++) {
settlementValue = _SettlementCrSign[iSettlement];
if (settlementValue.indexOf(_value) != -1) {
var tempArr = settlementValue.split("|");
showBg("1", tempArr[1] + "已结算无法驳回!");
}
else {
//查询判断 _value 是否是提交审核状态,是则可以审核,否则不能审核
//......
if ($("#chkcr" + iCount).attr("flow") == "1") {
strSelGID += _value + ",";
auditingArr[auditingAmount] = $("#chkdr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
}
else if (_invoiceCrAmount > 0) {
for (var iInvoice = 0; iInvoice < _invoiceCrAmount; iInvoice++) {
invoiceValue = _InvoiceCrSign[iInvoice];
if (invoiceValue.indexOf(_value) != -1) {
var tempArr = invoiceValue.split("|");
showBg("1", tempArr[1] + "已开出发票无法驳回!");
}
else {
//查询判断 _value 是否是提交审核状态,是则可以审核,否则不能审核
//......
if ($("#chkcr" + iCount).attr("flow") == "1") {
strSelGID += _value + ",";
auditingArr[auditingAmount] = $("#chkdr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
}
else if (_orderAmountCrAmount > 0) {
for (var iOrderAmount = 0; iOrderAmount < _orderAmountCrAmount; iOrderAmount++) {
orderAmountValue = _OrderAmountCrSign[iOrderAmount];
if (orderAmountValue.indexOf(_value) != -1) {
var tempArr = orderAmountValue.split("|");
showBg("1", tempArr[1] + "已申请费用无法驳回!");
}
else {
//查询判断 _value 是否是提交审核状态,是则可以审核,否则不能审核
//......
if ($("#chkcr" + iCount).attr("flow") == "1") {
strSelGID += _value + ",";
auditingArr[auditingAmount] = $("#chkdr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
}
else if (_orderInvoiceCrAmount > 0) {
for (var iOrderInvoice = 0; iOrderInvoice < _orderInvoiceCrAmount; iOrderInvoice++) {
orderInvoiceValue = _OrderInvoiceCrSign[iOrderInvoice];
if (orderInvoiceValue.indexOf(_value) != -1) {
var tempArr = orderInvoiceValue.split("|");
showBg("1", tempArr[1] + "已申请开票费用无法驳回!");
}
else {
//查询判断 _value 是否是提交审核状态,是则可以审核,否则不能审核
//......
if ($("#chkcr" + iCount).attr("flow") == "1") {
strSelGID += _value + ",";
auditingArr[auditingAmount] = $("#chkdr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
}
else if (_settlementCrAmount == 0 && _invoiceCrAmount == 0 && _orderAmountCrAmount == 0 && _orderInvoiceCrAmount == 0) {
//查询判断 _value 是否是提交审核状态,是则可以审核,否则不能审核
//......
if ($("#chkcr" + iCount).attr("flow") == "1") {
strSelGID += _value + ",";
auditingArr[auditingAmount] = $("#chkdr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
}
}
strSelGID = strSelGID.substring(0, strSelGID.length - 1);
$.ajax({
type: "post",
dataType: "json",
url: "../../Handler/Profit.ashx?action=4&es=" + expenseIsAll + "&t=" + auditingIsAll + "&r=" + jsencrypt(decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs"), txtReason) + "&b=" + jsencrypt(decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs"), strSelGID) + "&y=" + jsencrypt(decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs"), operateOplbValue),
cache: false,
success: function (msg) {
$("#chkAll").removeAttr("checked");
closeBg();
if (operateDataType == "dr") {
fnProfitAuditingDrInfo();
}
else if (operateDataType == "cr") {
fnProfitAuditingCrInfo();
}
}
});
$("#txtReason").val("请添加备注信息或者驳回原因");
}
function fnNoIvoice() {
$.ajaxSetup({ async: false });
var recCount = 0;
strSelGID = "";
if (drDisplay) {
for (var iCount = 0; iCount < drCount; iCount++) {
if ($("#chkdr" + iCount).attr("checked") == true && $("#chkdr" + iCount).attr("flow") == "2") {
strSelGID += $("#chkdr" + iCount).attr("value") + ",";
auditingArr[auditingAmount] = $("#chkdr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
else if (crDisplay) {
for (var iCount = 0; iCount < crCount; iCount++) {
if ($("#chkcr" + iCount).attr("checked") == true && $("#chkcr" + iCount).attr("flow") == "2") {
strSelGID += $("#chkcr" + iCount).attr("value") + ",";
auditingArr[auditingAmount] = $("#chkcr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
strSelGID = strSelGID.substring(0, strSelGID.length - 1);
$.ajax({
type: "post",
dataType: "json",
url: "../../Handler/Profit.ashx?action=5&b=" + jsencrypt(decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs"), strSelGID),
cache: false,
success: function (msg) {
//showBg("1", "已禁止开发票!");
if (operateDataType == "dr") {
fnProfitAuditingDrInfo();
}
else if (operateDataType == "cr") {
fnProfitAuditingCrInfo();
}
}
});
}
function fnCancelNoIvoice() {
$.ajaxSetup({ async: false });
var recCount = 0;
strSelGID = "";
if (drDisplay) {
for (var iCount = 0; iCount < drCount; iCount++) {
if ($("#chkdr" + iCount).attr("checked") == true && $("#chkdr" + iCount).attr("flow") == "2") {
strSelGID += $("#chkdr" + iCount).attr("value") + ",";
auditingArr[auditingAmount] = $("#chkdr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
else if (crDisplay) {
for (var iCount = 0; iCount < crCount; iCount++) {
if ($("#chkcr" + iCount).attr("checked") == true && $("#chkcr" + iCount).attr("flow") == "2") {
strSelGID += $("#chkcr" + iCount).attr("value") + ",";
auditingArr[auditingAmount] = $("#chkcr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
strSelGID = strSelGID.substring(0, strSelGID.length - 1);
$.ajax({
type: "post",
dataType: "json",
url: "../../Handler/Profit.ashx?action=6&b=" + jsencrypt(decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs"), strSelGID),
cache: false,
success: function (msg) {
//showBg("1", "已允许开发票!");
if (operateDataType == "dr") {
fnProfitAuditingDrInfo();
}
else if (operateDataType == "cr") {
fnProfitAuditingCrInfo();
}
}
});
}
function fnAuditShen() {
$.ajaxSetup({ async: false });
var recCount = 0;
var txtReason = $("#txtReason").val();
strSelGID = "";
if (txtReason == "请添加备注信息或者驳回原因") { txtReason = ""; }
if (drDisplay) {
for (var iCount = 0; iCount < drCount; iCount++) {
if ($("#chkdr" + iCount).attr("checked") == true && ($("#chkdr" + iCount).attr("flow") == "5" || $("#chkdr" + iCount).attr("flow") == "6")) {
//查询判断 $("#chkdr" + iCount).attr("value") 是否是提交审核状态,是则可以审核,否则不能审核
//......
strSelGID += $("#chkdr" + iCount).attr("value") + ",";
auditingArr[auditingAmount] = $("#chkdr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
else if (crDisplay) {
for (var iCount = 0; iCount < crCount; iCount++) {
if ($("#chkcr" + iCount).attr("checked") == true && ($("#chkcr" + iCount).attr("flow") == "5" || $("#chkcr" + iCount).attr("flow") == "6")) {
//查询判断 $("#chkdr" + iCount).attr("value") 是否是提交审核状态,是则可以审核,否则不能审核
//......
strSelGID += $("#chkcr" + iCount).attr("value") + ",";
auditingArr[auditingAmount] = $("#chkcr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
strSelGID = strSelGID.substring(0, strSelGID.length - 1);
switch (operateFeeStatus) {
case "申请修改":
operateFeeStatus = 3;
break;
case "申请删除":
operateFeeStatus = 4;
break;
}
$.ajax({
type: "post",
dataType: "json",
url: "../../Handler/Profit.ashx?action=7&es=" + expenseIsAll + "&t=" + auditingIsAll + "&b=" + jsencrypt(decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs"), strSelGID) + "&y=" + jsencrypt(decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs"), operateOplbValue),
cache: false,
success: function (msg) {
//showBg("1", "申请已批准!");
$("#chkAll").removeAttr("checked");
if (operateDataType == "dr") {
fnProfitAuditingDrInfo();
}
else if (operateDataType == "cr") {
fnProfitAuditingCrInfo();
}
/*$("#txtReason").val("请添加备注信息或者驳回原因");*/
}
});
$("#txtReason").val("请添加备注信息或者驳回原因");
}
function fnAuditBackShen() {
$.ajaxSetup({ async: false });
var recCount = 0;
var txtReason = $("#txtReason").val();
strSelGID = "";
if (txtReason == "请添加备注信息或者驳回原因") { txtReason = ""; }
if (drDisplay) {
for (var iCount = 0; iCount < drCount; iCount++) {
if ($("#chkdr" + iCount).attr("checked") == true && ($("#chkdr" + iCount).attr("flow") == "5" || $("#chkdr" + iCount).attr("flow") == "6")) {
//查询判断 $("#chkdr" + iCount).attr("value") 是否是提交审核状态,是则可以审核,否则不能审核
//......
strSelGID += $("#chkdr" + iCount).attr("value") + ",";
auditingArr[auditingAmount] = $("#chkdr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
else if (crDisplay) {
for (var iCount = 0; iCount < crCount; iCount++) {
if ($("#chkcr" + iCount).attr("checked") == true && ($("#chkcr" + iCount).attr("flow") == "5" || $("#chkcr" + iCount).attr("flow") == "6")) {
//查询判断 $("#chkdr" + iCount).attr("value") 是否是提交审核状态,是则可以审核,否则不能审核
//......
strSelGID += $("#chkcr" + iCount).attr("value") + ",";
auditingArr[auditingAmount] = $("#chkcr" + iCount).attr("value");
auditingAmount++;
recCount++;
}
}
}
strSelGID = strSelGID.substring(0, strSelGID.length - 1);
$.ajax({
type: "post",
dataType: "json",
url: "../../Handler/Profit.ashx?action=8&es=" + expenseIsAll + "&t=" + auditingIsAll + "&r=" + jsencrypt(decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs"), txtReason) + "&b=" + jsencrypt(decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs"), strSelGID) + "&y=" + jsencrypt(decrypt("8cdd29a091e29cc101042f65", "^id548f@^fueam##54325jfs"), operateOplbValue),
cache: false,
success: function (msg) {
//showBg("1", "申请已驳回!");
$("#chkAll").removeAttr("checked");
closeBg();
$.each(msg, function (i, item) {
if (item.Success) {
if (operateDataType == "dr") {
fnProfitAuditingDrInfo();
}
else if (operateDataType == "cr") {
fnProfitAuditingCrInfo();
}
//showBg("1", "审核已驳回!");
/*$("#txtReason").val("请添加备注信息或者驳回原因");*/
}
});
}
});
$("#txtReason").val("请添加备注信息或者驳回原因");
}
function fnReason() {
$("#txtReason").css("display", "block");
$("#historyList").css("display", "none");
}
function fnHistory() {
$("#txtReason").css("display", "none");
$("#historyList").css("display", "block");
}
function fnLayInvoiceShow() {
$("#layInvoiceState").css("display", "block");
}
function fnSelectChange() {
if ($("#chkAll").attr("checked") == true) {
fnSelectAll();
}
else {
fnUnSelectAll();
}
}
function fnSelectAll() {
if (isModule == 1) {
$("input[name='chkcr']").removeAttr("checked");
$("input[name='chkdr']").attr("checked", true);
for (var iCount = 0; iCount < drCount; iCount++) {
if ($("#chkdr" + iCount).attr("checked") == true) {
//查询判断$("#chkdr" + iCount).attr("value")是否是提交审核状态,是则可以审核,否则不能审核
//......
if ($("#chkdr" + iCount).attr("selparam") == "提交审核") {
operateFeeStatus = "提交审核";
}
else if ($("#chkdr" + iCount).attr("selparam") == "申请修改") {
operateFeeStatus = "申请修改";
}
else if ($("#chkdr" + iCount).attr("selparam") == "申请删除") {
operateFeeStatus = "申请删除";
}
}
}
}
else if (isModule == 2) {
$("input[name='chkdr']").removeAttr("checked");
$("input[name='chkcr']").attr("checked", true);
for (var iCount = 0; iCount < crCount; iCount++) {
if ($("#chkcr" + iCount).attr("checked") == true) {
//查询判断$("#chkdr" + iCount).attr("value")是否是提交审核状态,是则可以审核,否则不能审核
//......
if ($("#chkcr" + iCount).attr("selparam") == "提交审核") {
operateFeeStatus = "提交审核";
}
else if ($("#chkcr" + iCount).attr("selparam") == "申请修改") {
operateFeeStatus = "申请修改";
}
else if ($("#chkcr" + iCount).attr("selparam") == "申请删除") {
operateFeeStatus = "申请删除";
}
}
}
}
}
function fnUnSelectAll() {
if (isModule == 1) {
$("input[name='chkdr']").removeAttr("checked");
}
else if (isModule == 2) {
$("input[name='chkcr']").removeAttr("checked");
}
}
function closeBg2() {
$("#maskUser2").css("display", "none");
$("#laybg2").css("display", "none");
}
//显示灰色 jQuery 遮罩层
function showBg(param, msg, opt) {
$.ajaxSetup({ async: false });
var layTitleWidth;
var layTitleHeight;
_rejectOpt = -1;
layTitleWidth = ($("#laybg").width() + 2) / 16;
layTitleHeight = (layTitleWidth * 280) / 800;
if (param == "0") {
$("[rel='optLay']").css("display", "none");
$("#optAuditing").css("display", "block");
if (opt == "0") { _rejectOpt = 0; }
else if (opt == "1") { _rejectOpt = 1; }
}
else if (param == "1") {
$("[rel='optLay']").css("display", "none");
$("#optReturn").css("display", "block");
$(".auditingMsg").html(msg);
}
$("#laybg").css("display", "block");
$("#laybg").css("min-height", $("#laybg").height() / 16 + "em");
}
function fnRejectOption() {
if (_rejectOpt == 0) {
fnAuditBack();
isDrAuditing = null;
isCrAuditing = null;
}
else if (_rejectOpt == 1) {
fnAuditBackShen();
isDrAuditing = null;
isCrAuditing = null;
}
}
//关闭灰色 jQuery 遮罩
function closeBg() {
$("#maskUser").css("display", "none");
$("#laybg").css("display", "none");
}
function fnIndex() {
window.location.href = "/Home/Index?u=" + escape(u) + "&w=" + escape(w);
//window.location.href = "Index.aspx?u=" + escape(u) + "&w=" + escape(w); //encrypt(_mobile, _encrypt)
}
function fnReturn() {
// window.location.href = "/Profit/ProfitList?u=" + escape(u) + "&w=" + escape(w);
//window.location.href = "ProfitAuditingList.aspx?u=" + escape(u) + "&w=" + escape(w);
history.back();
}