+ MPDF 6.1

This commit is contained in:
2020-08-11 18:04:59 +06:00
parent 11d3f0fc7a
commit c2e133debe
714 changed files with 120510 additions and 93145 deletions

View File

@ -406,7 +406,7 @@ class EdtRec
if(vt=="i4")
{
//alert("prop name = "+nodeProp.getAttribute("n"));
//alert2(_('Alert'),"prop name = "+nodeProp.getAttribute("n"));
//If there is a node "list" with the elements "CheckBox" then create them.
var opt=findNode(nodeProp, "options");
@ -789,7 +789,7 @@ class EdtRec
button.className='button-secondary';
button.style.cssText="margin:0px;";
button.setAttribute("value",_('Cancel'));
//button.onclick=function f_exit(this) { alert(this.win.div); }
//button.onclick=function f_exit(this) { alert2(_('Alert'),this.win.div); }
button.onclick=function(thiz){ return function(){thiz.win.Close();};}(this);
td.appendChild( button );
tr.appendChild(td);
@ -798,13 +798,13 @@ class EdtRec
//Height adjust the height of the page
//this.win.div.style.width="400px"
//this.win.div.style.height="100px"
//alert(document.documentElement.scrollTop)
//alert(document.documentElement.clientHeight)
//alert2(_('Alert'),document.documentElement.scrollTop)
//alert2(_('Alert'),document.documentElement.clientHeight)
this.win.setHeight(eTable.offsetHeight+40); //this.win.div.style.height=(eTable.offsetHeight+40)+"px";
//alert(this.win.div.style.width)
//alert(this.win.div.style.height)
//alert2(_('Alert'),this.win.div.style.width)
//alert2(_('Alert'),this.win.div.style.height)
this.win.setCenter();
@ -1115,7 +1115,7 @@ class EdtRec
nodeProp=nodeProp.nextSibling;
}
if(count==0) alert(_("No_results_were_found_for_your_search"));
if(count==0) alert2(_('Alert'),_("No_results_were_found_for_your_search"));
else
if(count==1) //1 item has been selected, fill in the field.
{
@ -1161,10 +1161,10 @@ class EdtRec
};
applyReq(req,fn,node,xmldoc,win)
{ //alert("erec XML=\n"+getXMLNodeSerialisation(node));
{ //alert2(_('Alert'),"erec XML=\n"+getXMLNodeSerialisation(node));
if (fn==-1)
{
alert(findFirstNode(node,'#cdata-section').nodeValue);
alert2(_('Alert'),findFirstNode(node,'#cdata-section').nodeValue);
//this.pBarCnt=0;
this.hideProgressBar();
}else
@ -1204,7 +1204,7 @@ class EdtRec
this.setData(node);
}else
{
alert("Unknown function! fn=\""+fn+"\"" );
alert2(_('Alert'),"Unknown function! fn=\""+fn+"\"" );
this.hideProgressBar();
}
};
@ -1230,7 +1230,7 @@ class EdtRec
}
}else
{
alert('Field "'+prop_id+'" not find!');
alert2(_('Alert'),'Field "'+prop_id+'" not find!');
}
};
@ -1242,7 +1242,7 @@ class EdtRec
//filterName - filter name
callFilterVal(typeName,name,value,htmlid,filterName)
{
//alert(" typeName="+typeName+" name="+name+" value="+value+" htmlid="+htmlid);
//alert2(_('Alert')," typeName="+typeName+" name="+name+" value="+value+" htmlid="+htmlid);
if(value!="")
{
var xml='<?xml version="1.0" encoding="utf-8"?><metadata fn="6"><type n="'+typeName+'" c="'+name+'" pn="'+htmlid+'"><objects-list><filter>';
@ -1274,8 +1274,8 @@ class EdtRec
{
var nProps1=findFirstNode(node, 'properties')
var nProps2=findFirstNode(this.nodeMetadata, 'properties') //Since the values came in abbreviated XML
if(nProps1==null){ alert('Error, node='+getXMLNodeSerialisation(node)); return; }
if(nProps2==null){ alert('Error, nodeMetadata='+getXMLNodeSerialisation(this.nodeMetadata)); return; }
if(nProps1==null){ alert2(_('Alert'),'Error, node='+getXMLNodeSerialisation(node)); return; }
if(nProps2==null){ alert2(_('Alert'),'Error, nodeMetadata='+getXMLNodeSerialisation(this.nodeMetadata)); return; }
var nProp1=nProps1.firstChild
while(nProp1!=null)
{
@ -1406,7 +1406,7 @@ class EdtRec
//Проверяю тип дпнных и заполненость полей
if (!this.checkData(value,nodeProp.getAttribute("vt"),nodeProp.getAttribute("maybenull")))
{
alert(_("The_field_data_is_incorrect")+" \""+nodeProp.getAttribute("d")+"\"=\""+value+"\"!");
alert2(_('Alert'),_("The_field_data_is_incorrect")+" \""+nodeProp.getAttribute("d")+"\"=\""+value+"\"!");
return;
}
s+=' <prop n="'+nodeProp.getAttribute("n")+'"><![CDATA['+value+']]></prop>\n';
@ -1416,7 +1416,7 @@ class EdtRec
s+=' </properties>\n';
s+='</type>\n';
s+='</metadata>';
//alert(s);
//alert2(_('Alert'),s);
if(this.request.callServer(ScriptName,s,true))
{
this.showProgressBar();
@ -1451,7 +1451,7 @@ class EdtRec
//inserting the selected record
setPropVal(id,caption,prop_id)
{
//alert("id="+id+" caption="+caption+" prop_id="+prop_id)
//alert2(_('Alert'),"id="+id+" caption="+caption+" prop_id="+prop_id)
var prop=document.getElementById("prop_"+this.uid+"_"+prop_id);
var propvis=document.getElementById("prop_"+this.uid+"_"+prop_id+"_visible");
if ((prop!=null)&&(propvis!=null))
@ -1464,9 +1464,9 @@ class EdtRec
//The data was successfully added to the parent now so that he added 1 entry to the end of his list.
insertRows(node)
{ //Update the parent
var typeNode=findFirstNode(node,"type");
var typeName=typeNode.getAttribute("n");
var id=typeNode.getAttribute("id");
let typeNode=findFirstNode(node,"type");
let typeName=typeNode.getAttribute("n");
let id=typeNode.getAttribute("id");
if (this.opener!=null)
{
if(this.opener.f_TypeName==typeName) //It would be better to make an array of open windows then check for all and not just for the parent.
@ -1475,10 +1475,13 @@ class EdtRec
}
}
var readd=document.getElementById("readd_"+this.uid);
if(readd!==null && readd.checked)
{
if(!confirm(_("Successfully_added_data")+".\n"+_("Add_more")+"?")) this.win.Close();
let readd=document.getElementById("readd_"+this.uid);
if(readd!==null && readd.checked){
//if(!confirm(_("Successfully_added_data")+".\n"+_("Add_more")+"?")) this.win.Close();
confirm2(_('Warning'),_("Successfully_added_data")+"<br>"+_("Add_more")+"?",null,function(thiz){return function(){thiz.win.Close();};}(this));
}else
{
this.win.Close();