批量下载OA用印文件功能
This commit is contained in:
@@ -85,6 +85,7 @@
|
||||
@MyControls.Btn("批量下载交易确认书", "BatchDownLoadDoc()")
|
||||
<button class="btn btn-primary" id="batchSendEmail" style="margin-left:16px;">批量发送邮件</button>
|
||||
<button class="btn btn-primary" id="batchSendOA" style="margin-left:16px;">批量发送OA</button>
|
||||
<button class="btn btn-primary" id="batchDownloadOA" style="margin-left:16px;">批量下载OA文件</button>
|
||||
@if (PS.GetErpConfig().IsAutoSealAndUploadFiles && !PS.GetErpConfig().IsAutoSealAfterGeneratedBook)
|
||||
{
|
||||
@MyControls.Btn("批量确认书用印", "BatchSealContracts()")
|
||||
|
||||
@@ -561,6 +561,10 @@ $(function () {
|
||||
ContractTypeCtrl = new ContractTypeCtrl(document.getElementById('ContractTypeCtrl'));
|
||||
SendEmailHub();
|
||||
SendOAHub();
|
||||
|
||||
$("#batchDownloadOA").click(function () {
|
||||
BatchDownloadOAFiles();
|
||||
});
|
||||
});
|
||||
|
||||
function gridComplete() {
|
||||
@@ -656,6 +660,23 @@ function isExistFile(url) {
|
||||
return result;
|
||||
}
|
||||
|
||||
//批量下载OA用印文件
|
||||
function BatchDownloadOAFiles() {
|
||||
var jgrid = jQuery('#listGrid');
|
||||
var tradeIdList = main.GetGridIds(jgrid);
|
||||
if (tradeIdList.length == 0) {
|
||||
main.alert("请至少选择一笔交易"); return;
|
||||
}
|
||||
|
||||
var confirmBookPostData = {
|
||||
tradeIds: tradeIdList,
|
||||
docpdf: ["DOC", "PDF"],
|
||||
IsSeal: true,
|
||||
DocType: "交易确认书"
|
||||
};
|
||||
openWindowWithPost("/trade/BatchDownLoadDoc/", confirmBookPostData);
|
||||
}
|
||||
|
||||
//批量下载交易确认书
|
||||
function BatchDownLoadDoc() {
|
||||
var startDate = $("#DateFromTradeDate").val();
|
||||
@@ -677,9 +698,6 @@ function BatchDownLoadDoc() {
|
||||
'<label class="col-sm-5 control-label">文档类型</label>' +
|
||||
'<label class="btn btn-sm btn-primary" style="border:none"><input type="checkbox" checked name="docType" value="DOC"> DOC</label>' +
|
||||
'<label class="btn btn-sm btn-primary" style="border:none"><input type="checkbox" checked name="docType" value="PDF"> PDF</label>';
|
||||
|
||||
htmlContent += '<br/><label class="col-sm-5 control-label">下载用印文件</label>' +
|
||||
'<select id="Seal" style="margin-top:5px;"><option>是</option><option>否</option></select>';
|
||||
|
||||
|
||||
main.open2("批量下载交易确认书",
|
||||
@@ -693,8 +711,7 @@ function BatchDownLoadDoc() {
|
||||
docpdf.push($(this).val())
|
||||
})
|
||||
|
||||
var isSeal = $("#Seal").val() == '是' ? true : false;
|
||||
var confirmBookPostData = { TradeDateStart: startDate, TradeDateEnd: endDate, ClientIds: clientIds, TradeIds: tradeIdList, TradeCashIds: null, DocType: "交易确认书", docpdf: docpdf, IsSeal: isSeal };
|
||||
var confirmBookPostData = { TradeDateStart: startDate, TradeDateEnd: endDate, ClientIds: clientIds, TradeIds: tradeIdList, TradeCashIds: null, DocType: "交易确认书", docpdf: docpdf, IsSeal: false };
|
||||
if (page.IsAutoSealAndUploadFiles) {
|
||||
confirmBookPostData.SealResults = $("#SealResults").val();
|
||||
//confirmBookPostData.SealDateStart = $("#DateFromSealDate").val();
|
||||
|
||||
Reference in New Issue
Block a user