You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
FZ/lis-module-print-web/src/main/webapp/print/LPrtTemDownloadInput.js

83 lines
1.9 KiB

var turnPage = new turnPageClass();
var showInfo;
window.onfocus = myonfocus;
function myonfocus()
{
if (showInfo != null)
{
try
{
showInfo.focus();
}
catch (ex)
{
showInfo = null;
}
}
}
function easyQueryClick()
{
if (document.all("TempleteName").value == "")
{
alert("请输入打印名称!")
return;
}
if (document.all("TempleteName").value != "")
{
try
{
var sqlId1 = "LPrtTemDownloadInputSql1";
// var mySql1 = new SqlClass();
// mySql1.setModule("print");
// mySql1.setResourceName("print.LPrtTemDownloadInputSql");
// mySql1.setSqlId(sqlId1);
// mySql1.addSubPara(document.all("TempleteName").value);
// mySql1.addSubPara(document.all("TempleteType").value);
// mySql1.addSubPara(document.all("Language").value);
var param = [
document.all("TempleteName").value,
document.all("TempleteType").value,
document.all("Language").value
];
var mySql1 = wrapSql("print.LPrtTemDownloadInputSql", "LPrtTemDownloadInputSql1", param, "print");
turnPage.queryModal(mySql1, LPrtTempleteGrid);
}
catch (ex)
{
alert(ex.message);
}
}
}
// 下载事件
function downloadClick()
{
var tSel = LPrtTempleteGrid.getSelNo();
if (tSel == 0 || tSel == null)
{
i18nAlert("请选择一条记录,再下载模板!", "LIS-04038");
}
else
{
document.all("FilePath").value = LPrtTempleteGrid.getRowColData(tSel - 1,6);
document.all("OutputTypeName").value = LPrtTempleteGrid.getRowColData(tSel - 1,5);
try
{
fm.action = "../API/print/print/LPrtTemDownloadSave/DOWNLOAD";
document.getElementById("fm").submit();
// ajaxSubmit2(document.getElementById("fm"),afterSubmit2);
}
catch (ex)
{
ex.message;
}
}
}
function afterSubmit2(info){
if(info.Content!=null&&info.Content!=""){
info=JSON.parse(info);
alert(info.Content);
}
}