profoundjs 7.26.0 → 7.27.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3,7 +3,7 @@ pui.is_quirksmode="BackCompat"==document.compatMode;pui.is_ios=-1!=Ca.indexOf("i
3
3
  pui.defaultDateFormat="MM/DD/YY";pui.is_touch="ontouchstart"in window;pui.touchDevice=pui.is_touch;pui.is_mouse_capable=!1;pui.designer={};pui.designer["initial keywords"]=[];pui.designer.currentDisplay={};pui.ide={};pui.cloud={};pui.cloud.views={};pui.social={};pui.cnv={};pui.cnv.tA={};pui.Re={};pui.toolbox={};pui.toolbox.add=function(){};pui["field exit key"]=107;pui["field exit minus key"]=109;pui["disable prefix on field exit"]=!1;pui["no connection status"]=!1;pui["client side timeout"]=!0;
4
4
  pui.Mq={"*ISO":1,"*USA":2,"*EUR":3,"*JIS":4,"*MDY":5,"*DMY":6,"*YMD":7,"*JUL":8,"*JOB":10};pui.Nq={"/":1,"-":2,".":3,",":4," ":5,"*BLANK":5,"*JOB":7};pui.Oq={"*ISO":1,"*USA":2,"*EUR":3,"*JIS":4,"*HMS":9};pui.Pq={".":3,",":4," ":5,"*BLANK":5,":":6,"*JOB":7};pui.XA="abstract arguments await boolean break byte case catch char class const continue debugger default delete do double else enum eval export extends false final finally float for function goto if implements import in instanceof int interface let long native new null package private protected public return short static super switch synchronized this throw throws transient true try typeof var void volatile while with yield".split(" ");
5
5
  pui.pa=!1;pui.jA=null;pui["function key pattern"]="^(F|CA|CF|CK|CMD)([0-9]{1,2})([=:-])(.*)$";pui["special key pattern"]="^(Enter|PageUp|PageDown|Rollup|RollDown|RollDn|PgUp|PgDn|Help|Print)([=-])(.*)$";pui.om=0;pui["session timeout retries"]=0;pui.dA=0;pui.pj=!1;pui.Yz="profoundjs.com";pui.Nz="http://www.w3.org/2000/svg";pui.Kp={};pui["text file name pattern"]=/.+\.(css|js|json|html|htm|xml|txt|csv|sh|md|sql|scn|lst|xml|conf|php|log|ts|less|scss|cpp|ejs|vue|ts|jsx)$/i;
6
- pui["always allow field exit"]=!1;pui.dup={};pui.dup["char"]="\u25cf";pui.dup.keyCode=45;pui.dup.shift=!0;pui.dup.ctrl=!1;pui.dup.alt=!1;pui.wf={QA:{},cB:{},plugins:{},addPlugin:function(b){var a=pui.wf.plugins,c=b.category;a[c]||(a[c]={});a[c][b.name]=b}};pui["add combo style properties to choice list"]=!0;pui.viewdesigner=!1;pui.nodedesigner=!1;if(window.pui_cloud_designer)pui.nodedesigner=!0;else if(location.pathname.match(/^\/ide/i))pui.nodedesigner=!0;else{var Va=location.pathname.match(/\/([^/]+)\/?$/i);Va&&"viewdesigner"===Va[1].toLowerCase()?pui.viewdesigner=!0:Va&&"nodedesigner"===Va[1].toLowerCase()&&(pui.nodedesigner=!0)}pui.$n=!1;window.pui||(window.pui={});window.pui.baseVersion="6";window.pui.fixPackVersion="35.0";window.pui.version=window.pui.baseVersion+"."+window.pui.fixPackVersion;function fb(b){if(null!=b.touches&&1==b.touches.length)return b.touches[0].target;b=b.target;3==b.nodeType&&(b=b.parentNode);return b}function Db(b){b.preventDefault();b.stopPropagation()}pui.Te=function(b){Db(b)};function Eb(b){for(var a=Array(256),c=0;255>=c;c++)a[c]=c;Fb(a,b)}
6
+ pui["always allow field exit"]=!1;pui.dup={};pui.dup["char"]="\u25cf";pui.dup.keyCode=45;pui.dup.shift=!0;pui.dup.ctrl=!1;pui.dup.alt=!1;pui.wf={QA:{},cB:{},plugins:{},addPlugin:function(b){var a=pui.wf.plugins,c=b.category;a[c]||(a[c]={});a[c][b.name]=b}};pui["add combo style properties to choice list"]=!0;pui.viewdesigner=!1;pui.nodedesigner=!1;if(window.pui_cloud_designer)pui.nodedesigner=!0;else if(location.pathname.match(/^\/ide/i)||location.pathname.match(/^\/tasks\/[^/]+\/app\/\d+\/ide/i))pui.nodedesigner=!0;else{var Va=location.pathname.match(/\/([^/]+)\/?$/i);Va&&"viewdesigner"===Va[1].toLowerCase()?pui.viewdesigner=!0:Va&&"nodedesigner"===Va[1].toLowerCase()&&(pui.nodedesigner=!0)}pui.$n=!1;window.pui||(window.pui={});window.pui.baseVersion="6";window.pui.fixPackVersion="35.0";window.pui.version=window.pui.baseVersion+"."+window.pui.fixPackVersion;function fb(b){if(null!=b.touches&&1==b.touches.length)return b.touches[0].target;b=b.target;3==b.nodeType&&(b=b.parentNode);return b}function Db(b){b.preventDefault();b.stopPropagation()}pui.Te=function(b){Db(b)};function Eb(b){for(var a=Array(256),c=0;255>=c;c++)a[c]=c;Fb(a,b)}
7
7
  function Jb(b){"string"==typeof b&&(b=Kb(b));if(null==b||"INPUT"!=b.tagName||!pui.hj(b))return-1;if(null!=document.selection){null==b&&(b=document.activeElement);var a=document.selection.createRange()}var c=0;if(null!=b&&null!=a&&null!=b.createTextRange)try{var e=b.createTextRange();if(e){for(;0<a.compareEndPoints("StartToStart",e);)e.moveStart("character",1),c++;return c}}catch(f){}else if(null!=b)try{if(null!=b.selectionStart)return b.selectionStart}catch(f){}return-1}
8
8
  function Lb(){return pui.ide&&pui.ide.designerId?!0:null==Mb||null==Mb.designer?!1:!0}function Ob(b,a){var c="",e="",f=!1;if(200!=b.Lf()){var g="HTTP "+b.Lf();c=b.Ns()+"."}else if(f=-1!=b.Kc().indexOf("<?xml"),0==f)try{var h=eval("("+b.Kc()+")");1!=h.success&&(g=h.errorId,c=h.errorText,e=h.errorText2)}catch(n){g="CPF9897",c="The server response is missing or invalid."}return null!=g?(va.push({Pl:a,id:g,text:c,Dm:e}),!1):1==f?b.Kc():h.response}
9
9
  pui.buildLabel=function(b,a,c){function e(g,h){var n=Pb(b.style[g]),l=n.lastIndexOf(")");-1!=l&&(n=n.substr(0,l),c.style[g]=n+(h+"px)"))}var f=!0;null==c&&(f=!1,c=document.createElement("div"),c.style.position="absolute",c.style.borderStyle="none",c.style.backgroundColor="transparent");c.innerHTML='<label title="'+b.title+'" for="'+b.id+'">'+a+"</label>";c.className="label-for";a=Pb(b.className.split(" ")[0]);""!=a&&pui.ca(c,"label-for-"+a);c.style.zIndex=b.currentStyle?b.currentStyle.zIndex:window.getComputedStyle?
@@ -332,29 +332,30 @@ function Kc(b,a,c,e,f,g,h,n){var l;if("genie"===Q&&c.id.match(/^subfile-scrollba
332
332
  v)return m;m=v.tag;var y=v.inputType;f&&(g.Xl=null,g.UA());switch(q){case "select box":if(!f&&c.readOnly&&"INPUT"==c.tagName)switch(pui.S.config.protectedSelectBox){case "disable":c.disabled=!0;break;default:m="input",y=c.type}f&&pui.is_old_ie&&6==pui.ie_mode&&(""==String(g.properties["select box height"])||"1"==String(g.properties["select box height"])||"undefined"==String(g.properties["select box height"]))&&(m="input",y="text")}var A=l=!1;var z=c.tagName.toLowerCase()!=m;z||"input"!=c.tagName.toLowerCase()||
333
333
  c.type==y||(z=!0,"number"==c.type&&"text"==y&&(z=!1));if(z||c.qp){l=!0;if(c.qp){z=c;if("input"==m||"button"==m)z.type=y;delete c.qp}else{z=document.createElement(m);if("input"==m||"button"==m)z.type=y;null!=c.parentNode&&c.parentNode.replaceChild(z,c)}z.style.left=c.style.left;z.style.top=c.style.top;z.style.width=c.style.width;z.style.height=c.style.height;z.style.position=c.style.position;z.style.cursor=c.style.cursor;z.style.visibility=c.style.visibility;(y=c.getAttribute("puiwdgt"))&&z.setAttribute("puiwdgt",
334
334
  y);z.id=c.id;"string"==typeof c.name&&(z.name=c.name);"dspf"==Q&&(null==z.pui&&(z.pui={}),null!=c.xc&&(z.xc=c.xc,z.pui.formatName=c.xc),null!=c.gd&&(z.gd=c.gd,z.pui.fieldName=c.gd));"genie"==Q&&(z.P=c.P,pui.S.ha==c&&(pui.S.ha=z),A=!0);-1!=c.className.indexOf("hide")&&(z.className="hide",f&&(z.style.visibility="visible",z.style.filter="alpha(opacity=30)",z.style.opacity=.3));null!=c.getAttribute("maxlength")&&z.setAttribute("maxlength",c.getAttribute("maxlength"));z.disabled=c.disabled;null!=c.hb&&
335
- (z.hb=c.hb);null!=c.pb&&(z.pb=c.pb);c.Ro&&(z.Ro=!0);"genie"==Q&&attachInputEvents(z);f&&(g.dom=z,null!=h&&h.Uz(g),g.designer.Tz(z,g));c.readOnly&&("input"==m?"checkbox"!=z.type&&"radio"!=z.type||"genie"!=Q||S(z,"click",disableInputControl):"textarea"==m&&(z.readOnly=!0))}else if(z=c,"div"==m&&"tab panel"!=q&&(z.tabPanel=null),f||"chart"==q||"radio button"==q)l=!0;if(l)for(m=Fc(),l=0;l<m.length;l++){y=m[l].name;var I=a[y];if(null!=I&&""!=I){var L=null!=m[l].H;"overflow x"!=y&&"overflow y"!=y||"layout"!=
336
- a["field type"]||(L=!1);if(L)if("visibility"==m[l].H&&f)"hidden"==I?(z.style.filter="alpha(opacity=30)",z.style.opacity=.3):(z.style.filter="",z.style.opacity="");else try{var C=pui.Is(m[l].H,I);z.style[m[l].H]=C;f&&pui.Nk(z,m[l].H,C)}catch(N){}if(null!=m[l].ga){"boolean"==m[l].type&&"true"==I&&(I=!0);"boolean"==m[l].type&&"false"==I&&(I=!1);"disabled"==m[l].ga&&f&&(I=!1);try{if(0==I)null!=z.getAttribute(m[l].ga)&&z.removeAttribute(m[l].ga);else{var E=evalPropertyValue(I,t,z);"src"==m[l].ga&&(E=pui.normalizeURL(E,
337
- !0));"style"!==m[l].ga&&z.setAttribute(m[l].ga,E);"class"==m[l].ga&&(z.className=I)}}catch(N){}}}}if("dspf"==Q){l=[];l.push(a["css class"]);y=2;for(I=a["css class "+y];null!=I;)l.push(I),y++,I=a["css class "+y];y=a["display attribute field"];I=!1;null==y||pui.F(y)||""==y||" "==y||(l=l.concat(pui.Hr(y)),I=!0);Lc(z,l,I)}m=z;v.resizable||(m.style.width="",m.style.height="")}else if(v=pui.widgets[a["field type"]],null==v)return m;null==m.pui&&(m.pui={});null==m.pui.properties&&(m.pui.properties={});m.pui.properties[u]=
338
- q;"value"!=u||"script: value"==e||f||"genie"!=Q||null==m.P||null==m.P.idx||"INPUT"==m.tagName&&"radio"==m.type&&1!=m.checked||(pui.response[m.P.idx]=m);f&&"screen identifier"==u&&"genie"==Q&&(l="red",l="true"==e||1==e?"red":"#cccccc","dotted"==m.style.borderLeftStyle&&(m.style.borderLeftColor=l),"dotted"==m.style.borderRightStyle&&(m.style.borderRightColor=l),"dotted"==m.style.borderTopStyle&&(m.style.borderTopColor=l),"dotted"==m.style.borderBottomStyle&&(m.style.borderBottomColor=l));l=v.Mf;y=v.propertySetters;
339
- I=null;null!=y&&(I=y[u]);if(null!=I||null!=l)var K=new pui.SetterParms(e,q,f,a,t,m,c,u,g,h);if(null==l||0!=l(K))if(null==I||0!=I(K)){A&&(null!=z.comboBoxWidget?(A=z.comboBoxWidget.getBox(),pui.Fr(A),A.P=z.P,attachInputEvents(A),z.comboBoxWidget.iq(c.maxLength)):null!=z.A?(A=z.A.getBox(),pui.Fr(A),A.P=z.P,attachInputEvents(A),z.A.iq(c.maxLength)):pui.Fr(z));if("id"==u&&f){z=g.designer;A=z.selection;if(g.dom.id!=e&&null!=document.getElementById(e)&&(!pui.is_old_ie||g.dom.id.toUpperCase()!=e.toUpperCase()))return pui.alert('The widget id "'+
340
- e+'" is already in use.'),z.zb.refresh(),m;for(l=0;l<A.ee.length;l++)if("true"==g.properties.newitem&&Cc[z.Ya.Fb]&&Cc[z.Ya.Fb].items)for(y=Cc[z.Ya.Fb].items,I=0;I<y.length;I++)y[I].id==g.properties.id&&(y[I].id=e);if("tab panel"==a["field type"])for(l=0;l<z.items.length;l++)z.items[l].properties["parent tab panel"]==g.dom.id&&(z.items[l].properties["parent tab panel"]=e,z.items[l].dom.hb=e,z.items[l].Ab["parent tab panel"]=!0,z.zb.Vh("parent tab panel"));1==A.ee.length&&z.zb.gB("Properties - "+q)}"parent tab panel"!=
341
- u||!f&&"hidden"==a.visibility||(c.hb=q);"parent tab"==u&&(c.pb=q);"top"!=u&&"left"!=u&&"right"!=u&&"bottom"!=u||pui.ky(c);"empty text"!=u||f||pui.bz(c,q);z=null;"js:"==String(e).substr(0,3).toLowerCase()&&(z=e.substr(3));"javascript:"==String(e).substr(0,11).toLowerCase()&&(z=e.substr(11));"script:"==String(e).substr(0,7).toLowerCase()&&(z=e.substr(7));if(null!=b.H){if("visibility"==b.H&&f)"hidden"==q?(c.style.filter="alpha(opacity=30)",c.style.opacity=.3):(c.style.filter="",c.style.opacity="",c.style.visibility=
342
- q);else if("backgroundColor"==b.H&&null!=c.tabPanel)c.tabPanel.Tc=q?q:"#eeeeff",("genie"==Q||f)&&c.tabPanel.O();else{try{C=pui.Is(b.H,q);if("textTransform"==b.H&&"uppercase"==q)if("INPUT"==c.tagName&&"text"==c.type||"TEXTAREA"==c.tagName)c.value=pui.Ye(c.value,!1),c.addEventListener("input",pui.yp);else if(null!=c.comboBoxWidget){var F=c.comboBoxWidget.getBox();F.value=pui.Ye(F.value,!1);F.addEventListener("input",pui.yp)}else if(null!=c.A){var P=c.A.getBox();P.value=pui.Ye(P.value,!1);P.addEventListener("input",
343
- pui.yp)}c.style[b.H]=C;f&&(null===q||0==q.length?pui.Np(c,b.H):pui.Nk(c,b.H,C))}catch(N){null==z&&f&&(C="'"+e+"' is not a valid value for "+u+".",Mb.Jh&&(F=Mb.designer.eq[Mb.designer.Ya.Fb]["record format name"],null!=a.grid&&(P=Kb(a.grid),null!=P&&null!=P.grid&&(F=P.grid.ib)),C=C+("\n\n\nRecord Format: "+F)+("\n\nElement Id: "+a.id),C+="\n\nElement Type: "+a["field type"]),pui.alert(C))}null==c.tabPanel||"color"!=b.H&&"fontFamily"!=b.H&&"fontSize"!=b.H&&"height"!=b.H&&"width"!=b.H||"genie"!=Q&&!f||
344
- c.tabPanel.O()}"spinner"!=a["field type"]||f||"width"!=b.H&&"top"!=b.H&&"left"!=b.H&&"height"!=b.H||!c.Qc||c.Qc.Gp();"visibility"!=b.H||"hidden"!=q||f||"date field"!=a["field type"]||setTimeout(function(){c.calimg&&"hidden"==c.style.visibility&&(c.calimg.style.visibility="hidden")},1);"visibility"!=b.H||"hidden"!=q||f||"spinner"!=a["field type"]||setTimeout(function(){c.Qc&&"hidden"==c.style.visibility&&c.Qc.hide()},1);"visibility"!=b.H||"hidden"!=q||f||"textbox"!=a["field type"]||setTimeout(function(){c.Qh&&
345
- "hidden"==c.style.visibility&&(c.Qh.style.visibility="hidden")},1);"color"==b.H&&null!=c.firstChild&&"A"==c.firstChild.tagName?c.firstChild.style.color=q:"color"==b.H&&null!=c.firstChild&&null!=c.firstChild.nextSibling&&"A"==c.firstChild.nextSibling.tagName&&(c.firstChild.nextSibling.style.color=q);"textDecoration"==b.H&&null!=c.firstChild&&"A"==c.firstChild.tagName?c.firstChild.style.textDecoration=q:"textDecoration"==b.H&&null!=c.firstChild&&null!=c.firstChild.nextSibling&&"A"==c.firstChild.nextSibling.tagName&&
346
- (c.firstChild.nextSibling.style.textDecoration=q);"width"!=b.H||v.resizable||(c.style.width="");"height"!=b.H||v.resizable||(c.style.height="")}if(null!=b.ga)if(""==q)try{"style"===b.ga?pui.Hy(c):c.removeAttribute(b.ga),"class"==b.ga&&(c.className="")}catch(N){null==z&&f&&pui.alert(N.message)}else try{E=q,"boolean"==b.type&&"true"==E&&(E=!0,"disabled"==b.ga&&f&&(E=!1)),"boolean"==b.type&&"false"==E&&(E=!1),0==E?null!=c.getAttribute(b.ga)&&c.removeAttribute(b.ga):("src"==b.ga&&(E=pui.normalizeURL(E,
347
- !0)),"style"===b.ga?pui.rr(c,E,"layout"===a["field type"]):c.setAttribute(b.ga,E),"class"==b.ga&&(c.className=E))}catch(N){null==z&&f&&(C="'"+e+"' is not a valid value for "+u+".",Mb.Jh&&(F=Mb.designer.eq[Mb.designer.Ya.Fb]["record format name"],null!=a.grid&&(P=Kb(a.grid),null!=P&&null!=P.grid&&(F=P.grid.ib)),C=C+("\n\n\nRecord Format: "+F)+("\n\nElement Id: "+a.id),C+="\n\nElement Type: "+a["field type"]),pui.alert(C))}if("dspf"==Q&&("css class"==u.substr(0,9)||"display attribute field"==u)){if("display attribute field"==
348
- u&&"combo box"==a["field type"])l=c.className.split(" ");else for(l=[],l.push(a["css class"]),y=2,I=a["css class "+y];null!=I;)l.push(I),y++,I=a["css class "+y];E=Number(u.substr(10));if(isNaN(E)||1>E||99<E)E=1;"display attribute field"!=u&&(l[E-1]=q);y=a["display attribute field"];I=!1;null==y||pui.F(y)||""==y||" "==y||(l=l.concat(pui.Hr(y)),I=!0);Lc(c,l,I)}"js"==b.type&&(E=null,pui.oc(e)?E=function(N){c.Wa||"true"!=c.T&&"send data"!=c.T||(pui.T=c.T);pui.runLogic(e.routine,c.D,c.gk);N||(N=window.event);
349
- N&&N.stopPropagation&&N.stopPropagation()}:"ontabclick"==u?E=function(){eval("var tab = arguments[0];");try{return eval(e)}catch(N){pui.Ra(N,u.substr(0,1).toUpperCase()+u.substr(1)+" Error:\n")}}:"onoptionclick"==u?E=function(){eval("var value = arguments[0];");eval("var text = arguments[1];");try{eval(e)}catch(N){pui.Ra(N,u.substr(0,1).toUpperCase()+u.substr(1)+" Error:\n")}}:"onprompt"==u?E=function(){eval("var value = arguments[0];");try{eval(e)}catch(N){pui.Ra(N,u.substr(0,1).toUpperCase()+u.substr(1)+
350
- " Error:\n")}}:"onspin"==u?E=function(){eval("var value = arguments[0];");eval("var increment = arguments[1];");eval("var spinner = arguments[2];");eval("var newValue = arguments[3];");eval("var row;");null!=n&&eval("row = "+n+";");eval("var rrn;");null!=n&&eval("rrn = "+n+";");eval("var rowNumber;");null!=c.jc&&eval("rowNumber = "+(c.jc+1)+";");try{return eval(e)}catch(N){pui.Ra(N,u.substr(0,1).toUpperCase()+u.substr(1)+" Error:\n")}}:"onchartclick"==u?E=function(N){eval("var name = arguments[0];");
351
- "object"==typeof name&&(eval("var category = name.category"),eval("var name = name.name"));try{var X=eval(e);"function"==typeof X&&X(N)}catch(ia){pui.Ra(ia,u.substr(0,1).toUpperCase()+u.substr(1)+" Error:\n")}}:"onoptiondisplay"==u?E=function(){1<=arguments.length&&eval("var row = "+arguments[0]+";");2<=arguments.length&&eval("var rrn = "+arguments[1]+";");3<=arguments.length&&eval("var rowNumber = "+arguments[2]+";");4<=arguments.length&&eval("var column = "+arguments[3]+";");5<=arguments.length&&
352
- (pui.temp_value=arguments[4],eval("var grid = pui.temp_value;"));eval("var choices;");null!=c.comboBoxWidget&&null!=c.comboBoxWidget.choices&&(pui.temp_value=c.comboBoxWidget.choices,eval("choices = pui.temp_value.slice(0);"));null!=c.J&&null!=c.J.choices&&(pui.temp_value=c.J.choices,eval("choices = pui.temp_value.slice(0);"));eval("var values;");null!=c.comboBoxWidget&&null!=c.comboBoxWidget["choice values"]&&(pui.temp_value=c.comboBoxWidget["choice values"],eval("values = pui.temp_value.slice(0);"));
353
- null!=c.J&&null!=c.J.Be&&(pui.temp_value=c.J.Be,eval("values = pui.temp_value.slice(0);"));try{var N=eval(e);"function"==typeof N&&N()}catch(X){pui.Ra(X,u.substr(0,1).toUpperCase()+u.substr(1)+" Error:\n")}null!=c.comboBoxWidget&&null!=c.comboBoxWidget.choices&&(eval("pui.temp_value = choices;"),c.comboBoxWidget.choices=pui.temp_value.slice(0));null!=c.J&&null!=c.J.choices&&(eval("pui.temp_value = choices;"),c.J.choices=pui.temp_value.slice(0));null!=c.comboBoxWidget&&null!=c.comboBoxWidget["choice values"]&&
354
- (eval("pui.temp_value = values;"),c.comboBoxWidget["choice values"]=pui.temp_value.slice(0));null!=c.J&&null!=c.J.Be&&(eval("pui.temp_value = values;"),c.J.Be=pui.temp_value.slice(0))}:"onselect"!=u&&"ondragstart"!=u&&(E=function(N){if(null==pui.rj&&!(null!=c.getAttribute&&"true"==c.getAttribute("disabled")||null!=c.disabled&&1==c.disabled)){"true"!=c.T&&"send data"!=c.T||"onchange"!=b&&"onblur"!=b&&"onselect"!=b&&"oninput"!=b||null==c.T||(pui.T=c.T);eval("var row;");null!=n&&eval("row = "+n+";");
355
- eval("var rrn;");null!=n&&eval("rrn = "+n+";");eval("var rowNumber;");null!=c.jc&&eval("rowNumber = "+(c.jc+1)+";");pui.temp_event=N;eval("var event = pui.temp_event;");try{var X=eval(e);"function"==typeof X&&(N||(N=window.event),X(N,this))}catch(ia){pui.Ra(ia,u.substr(0,1).toUpperCase()+u.substr(1)+" Error:\n")}}}),f||null==E||(c[u]=E,null!=c.comboBoxWidget&&"onselect"!=u&&"onoptiondisplay"!=u&&c.comboBoxWidget.Jn(u,E),null!=c.A&&"onselect"!=u&&"onoptiondisplay"!=u&&c.A.Jn(u,E)));if(f){if(""!=e||
356
- null!=a[u])a[u]=e;g.Ab[u]=!0;"field type"!=u&&"left"!=u&&"right"!=u&&"top"!=u&&"bottom"!=u&&"z index"!=u&&"visibility"!=u&&"height"!=u&&"width"!=u&&"label"!=u&&"color"!=u&&"font family"!=u&&"font size"!=u&&"font style"!=u&&"font weight"!=u||g.wh();g.Og();null!=h&&h.Ej();"dspf"==Q&&("id"==u&&(pui.ide.RA(),pui.ide.SA()),"id"!=u&&"field type"!=u&&"value"!=u||pui.ide.Zt(),g.Rf||(g.designer.pp(),pui.ide.refreshRibbon()))}l=v.Bc;y=v.Sv;I=null;null!=y&&(I=y[u]);if(null!=I||null!=l)K=new pui.SetterParms(e,
357
- q,f,a,t,m,c,u,g,h);null!=l&&l(K);null!=I&&I(K);return m}}pui.SetterParms=function(b,a,c,e,f,g,h,n,l,m){this.newValue=b;this.value=a;this.design=c;this.properties=e;this.originalValue=f;this.dom=g;this.Ka=h;this.propertyName=n;this.j=l;this.resizer=m};pui.SetterParms.prototype.evalProperty=function(b){return evalPropertyValue(this.properties[b],this.originalValue,this.dom)};
335
+ (z.hb=c.hb);null!=c.pb&&(z.pb=c.pb);c.Ro&&(z.Ro=!0);"genie"==Q&&attachInputEvents(z);f&&(g.dom=z,null!=h&&h.Uz(g),g.designer.Tz(z,g));c.readOnly&&("input"==m?"checkbox"!=z.type&&"radio"!=z.type||"genie"!=Q||S(z,"click",disableInputControl):"textarea"==m&&(z.readOnly=!0))}else if(z=c,"div"==m&&"tab panel"!=q&&(z.tabPanel=null),f||"chart"==q||"radio button"==q)l=!0;if(l)for(m=Fc(),l=0;l<m.length;l++){y=m[l].name;var I=a[y];if(("choices"==m[l].name||"choices values"==m[l].name)&&"select"==z.nodeName.toLowerCase())if(null!=
336
+ a[y]&&""!=a[y]){if(null!=pui.appJob&&("I"==pui.appJob.decimalFormat||"J"==pui.appJob.decimalFormat)){var L=I.match(/(?<=^|\.)([A-Za-z0-9_]+)(?=\.|$)/g);null!=L&&1<L.length&&(I=L,I=I.join(","),a[y]=I)}}else I=a[y];if(null!=I&&""!=I){L=null!=m[l].H;"overflow x"!=y&&"overflow y"!=y||"layout"!=a["field type"]||(L=!1);if(L)if("visibility"==m[l].H&&f)"hidden"==I?(z.style.filter="alpha(opacity=30)",z.style.opacity=.3):(z.style.filter="",z.style.opacity="");else try{var C=pui.Is(m[l].H,I);z.style[m[l].H]=
337
+ C;f&&pui.Nk(z,m[l].H,C)}catch(N){}if(null!=m[l].ga){"boolean"==m[l].type&&"true"==I&&(I=!0);"boolean"==m[l].type&&"false"==I&&(I=!1);"disabled"==m[l].ga&&f&&(I=!1);try{if(0==I)null!=z.getAttribute(m[l].ga)&&z.removeAttribute(m[l].ga);else{var E=evalPropertyValue(I,t,z);"src"==m[l].ga&&(E=pui.normalizeURL(E,!0));"style"!==m[l].ga&&z.setAttribute(m[l].ga,E);"class"==m[l].ga&&(z.className=I)}}catch(N){}}}}if("dspf"==Q){l=[];l.push(a["css class"]);y=2;for(I=a["css class "+y];null!=I;)l.push(I),y++,I=
338
+ a["css class "+y];y=a["display attribute field"];I=!1;null==y||pui.F(y)||""==y||" "==y||(l=l.concat(pui.Hr(y)),I=!0);Lc(z,l,I)}m=z;v.resizable||(m.style.width="",m.style.height="")}else if(v=pui.widgets[a["field type"]],null==v)return m;null==m.pui&&(m.pui={});null==m.pui.properties&&(m.pui.properties={});m.pui.properties[u]=q;"value"!=u||"script: value"==e||f||"genie"!=Q||null==m.P||null==m.P.idx||"INPUT"==m.tagName&&"radio"==m.type&&1!=m.checked||(pui.response[m.P.idx]=m);f&&"screen identifier"==
339
+ u&&"genie"==Q&&(l="red",l="true"==e||1==e?"red":"#cccccc","dotted"==m.style.borderLeftStyle&&(m.style.borderLeftColor=l),"dotted"==m.style.borderRightStyle&&(m.style.borderRightColor=l),"dotted"==m.style.borderTopStyle&&(m.style.borderTopColor=l),"dotted"==m.style.borderBottomStyle&&(m.style.borderBottomColor=l));l=v.Mf;y=v.propertySetters;I=null;null!=y&&(I=y[u]);if(null!=I||null!=l)var K=new pui.SetterParms(e,q,f,a,t,m,c,u,g,h);if(null==l||0!=l(K))if(null==I||0!=I(K)){A&&(null!=z.comboBoxWidget?
340
+ (A=z.comboBoxWidget.getBox(),pui.Fr(A),A.P=z.P,attachInputEvents(A),z.comboBoxWidget.iq(c.maxLength)):null!=z.A?(A=z.A.getBox(),pui.Fr(A),A.P=z.P,attachInputEvents(A),z.A.iq(c.maxLength)):pui.Fr(z));if("id"==u&&f){z=g.designer;A=z.selection;if(g.dom.id!=e&&null!=document.getElementById(e)&&(!pui.is_old_ie||g.dom.id.toUpperCase()!=e.toUpperCase()))return pui.alert('The widget id "'+e+'" is already in use.'),z.zb.refresh(),m;for(l=0;l<A.ee.length;l++)if("true"==g.properties.newitem&&Cc[z.Ya.Fb]&&Cc[z.Ya.Fb].items)for(y=
341
+ Cc[z.Ya.Fb].items,I=0;I<y.length;I++)y[I].id==g.properties.id&&(y[I].id=e);if("tab panel"==a["field type"])for(l=0;l<z.items.length;l++)z.items[l].properties["parent tab panel"]==g.dom.id&&(z.items[l].properties["parent tab panel"]=e,z.items[l].dom.hb=e,z.items[l].Ab["parent tab panel"]=!0,z.zb.Vh("parent tab panel"));1==A.ee.length&&z.zb.gB("Properties - "+q)}"parent tab panel"!=u||!f&&"hidden"==a.visibility||(c.hb=q);"parent tab"==u&&(c.pb=q);"top"!=u&&"left"!=u&&"right"!=u&&"bottom"!=u||pui.ky(c);
342
+ "empty text"!=u||f||pui.bz(c,q);z=null;"js:"==String(e).substr(0,3).toLowerCase()&&(z=e.substr(3));"javascript:"==String(e).substr(0,11).toLowerCase()&&(z=e.substr(11));"script:"==String(e).substr(0,7).toLowerCase()&&(z=e.substr(7));if(null!=b.H){if("visibility"==b.H&&f)"hidden"==q?(c.style.filter="alpha(opacity=30)",c.style.opacity=.3):(c.style.filter="",c.style.opacity="",c.style.visibility=q);else if("backgroundColor"==b.H&&null!=c.tabPanel)c.tabPanel.Tc=q?q:"#eeeeff",("genie"==Q||f)&&c.tabPanel.O();
343
+ else{try{C=pui.Is(b.H,q);if("textTransform"==b.H&&"uppercase"==q)if("INPUT"==c.tagName&&"text"==c.type||"TEXTAREA"==c.tagName)c.value=pui.Ye(c.value,!1),c.addEventListener("input",pui.yp);else if(null!=c.comboBoxWidget){var F=c.comboBoxWidget.getBox();F.value=pui.Ye(F.value,!1);F.addEventListener("input",pui.yp)}else if(null!=c.A){var P=c.A.getBox();P.value=pui.Ye(P.value,!1);P.addEventListener("input",pui.yp)}c.style[b.H]=C;f&&(null===q||0==q.length?pui.Np(c,b.H):pui.Nk(c,b.H,C))}catch(N){null==
344
+ z&&f&&(C="'"+e+"' is not a valid value for "+u+".",Mb.Jh&&(F=Mb.designer.eq[Mb.designer.Ya.Fb]["record format name"],null!=a.grid&&(P=Kb(a.grid),null!=P&&null!=P.grid&&(F=P.grid.ib)),C=C+("\n\n\nRecord Format: "+F)+("\n\nElement Id: "+a.id),C+="\n\nElement Type: "+a["field type"]),pui.alert(C))}null==c.tabPanel||"color"!=b.H&&"fontFamily"!=b.H&&"fontSize"!=b.H&&"height"!=b.H&&"width"!=b.H||"genie"!=Q&&!f||c.tabPanel.O()}"spinner"!=a["field type"]||f||"width"!=b.H&&"top"!=b.H&&"left"!=b.H&&"height"!=
345
+ b.H||!c.Qc||c.Qc.Gp();"visibility"!=b.H||"hidden"!=q||f||"date field"!=a["field type"]||setTimeout(function(){c.calimg&&"hidden"==c.style.visibility&&(c.calimg.style.visibility="hidden")},1);"visibility"!=b.H||"hidden"!=q||f||"spinner"!=a["field type"]||setTimeout(function(){c.Qc&&"hidden"==c.style.visibility&&c.Qc.hide()},1);"visibility"!=b.H||"hidden"!=q||f||"textbox"!=a["field type"]||setTimeout(function(){c.Qh&&"hidden"==c.style.visibility&&(c.Qh.style.visibility="hidden")},1);"color"==b.H&&null!=
346
+ c.firstChild&&"A"==c.firstChild.tagName?c.firstChild.style.color=q:"color"==b.H&&null!=c.firstChild&&null!=c.firstChild.nextSibling&&"A"==c.firstChild.nextSibling.tagName&&(c.firstChild.nextSibling.style.color=q);"textDecoration"==b.H&&null!=c.firstChild&&"A"==c.firstChild.tagName?c.firstChild.style.textDecoration=q:"textDecoration"==b.H&&null!=c.firstChild&&null!=c.firstChild.nextSibling&&"A"==c.firstChild.nextSibling.tagName&&(c.firstChild.nextSibling.style.textDecoration=q);"width"!=b.H||v.resizable||
347
+ (c.style.width="");"height"!=b.H||v.resizable||(c.style.height="")}if(null!=b.ga)if(""==q)try{"style"===b.ga?pui.Hy(c):c.removeAttribute(b.ga),"class"==b.ga&&(c.className="")}catch(N){null==z&&f&&pui.alert(N.message)}else try{E=q,"boolean"==b.type&&"true"==E&&(E=!0,"disabled"==b.ga&&f&&(E=!1)),"boolean"==b.type&&"false"==E&&(E=!1),0==E?null!=c.getAttribute(b.ga)&&c.removeAttribute(b.ga):("src"==b.ga&&(E=pui.normalizeURL(E,!0)),"style"===b.ga?pui.rr(c,E,"layout"===a["field type"]):c.setAttribute(b.ga,
348
+ E),"class"==b.ga&&(c.className=E))}catch(N){null==z&&f&&(C="'"+e+"' is not a valid value for "+u+".",Mb.Jh&&(F=Mb.designer.eq[Mb.designer.Ya.Fb]["record format name"],null!=a.grid&&(P=Kb(a.grid),null!=P&&null!=P.grid&&(F=P.grid.ib)),C=C+("\n\n\nRecord Format: "+F)+("\n\nElement Id: "+a.id),C+="\n\nElement Type: "+a["field type"]),pui.alert(C))}if("dspf"==Q&&("css class"==u.substr(0,9)||"display attribute field"==u)){if("display attribute field"==u&&"combo box"==a["field type"])l=c.className.split(" ");
349
+ else for(l=[],l.push(a["css class"]),y=2,I=a["css class "+y];null!=I;)l.push(I),y++,I=a["css class "+y];E=Number(u.substr(10));if(isNaN(E)||1>E||99<E)E=1;"display attribute field"!=u&&(l[E-1]=q);y=a["display attribute field"];I=!1;null==y||pui.F(y)||""==y||" "==y||(l=l.concat(pui.Hr(y)),I=!0);Lc(c,l,I)}"js"==b.type&&(E=null,pui.oc(e)?E=function(N){c.Wa||"true"!=c.T&&"send data"!=c.T||(pui.T=c.T);pui.runLogic(e.routine,c.D,c.gk);N||(N=window.event);N&&N.stopPropagation&&N.stopPropagation()}:"ontabclick"==
350
+ u?E=function(){eval("var tab = arguments[0];");try{return eval(e)}catch(N){pui.Ra(N,u.substr(0,1).toUpperCase()+u.substr(1)+" Error:\n")}}:"onoptionclick"==u?E=function(){eval("var value = arguments[0];");eval("var text = arguments[1];");try{eval(e)}catch(N){pui.Ra(N,u.substr(0,1).toUpperCase()+u.substr(1)+" Error:\n")}}:"onprompt"==u?E=function(){eval("var value = arguments[0];");try{eval(e)}catch(N){pui.Ra(N,u.substr(0,1).toUpperCase()+u.substr(1)+" Error:\n")}}:"onspin"==u?E=function(){eval("var value = arguments[0];");
351
+ eval("var increment = arguments[1];");eval("var spinner = arguments[2];");eval("var newValue = arguments[3];");eval("var row;");null!=n&&eval("row = "+n+";");eval("var rrn;");null!=n&&eval("rrn = "+n+";");eval("var rowNumber;");null!=c.jc&&eval("rowNumber = "+(c.jc+1)+";");try{return eval(e)}catch(N){pui.Ra(N,u.substr(0,1).toUpperCase()+u.substr(1)+" Error:\n")}}:"onchartclick"==u?E=function(N){eval("var name = arguments[0];");"object"==typeof name&&(eval("var category = name.category"),eval("var name = name.name"));
352
+ try{var X=eval(e);"function"==typeof X&&X(N)}catch(ia){pui.Ra(ia,u.substr(0,1).toUpperCase()+u.substr(1)+" Error:\n")}}:"onoptiondisplay"==u?E=function(){1<=arguments.length&&eval("var row = "+arguments[0]+";");2<=arguments.length&&eval("var rrn = "+arguments[1]+";");3<=arguments.length&&eval("var rowNumber = "+arguments[2]+";");4<=arguments.length&&eval("var column = "+arguments[3]+";");5<=arguments.length&&(pui.temp_value=arguments[4],eval("var grid = pui.temp_value;"));eval("var choices;");null!=
353
+ c.comboBoxWidget&&null!=c.comboBoxWidget.choices&&(pui.temp_value=c.comboBoxWidget.choices,eval("choices = pui.temp_value.slice(0);"));null!=c.J&&null!=c.J.choices&&(pui.temp_value=c.J.choices,eval("choices = pui.temp_value.slice(0);"));eval("var values;");null!=c.comboBoxWidget&&null!=c.comboBoxWidget["choice values"]&&(pui.temp_value=c.comboBoxWidget["choice values"],eval("values = pui.temp_value.slice(0);"));null!=c.J&&null!=c.J.Be&&(pui.temp_value=c.J.Be,eval("values = pui.temp_value.slice(0);"));
354
+ try{var N=eval(e);"function"==typeof N&&N()}catch(X){pui.Ra(X,u.substr(0,1).toUpperCase()+u.substr(1)+" Error:\n")}null!=c.comboBoxWidget&&null!=c.comboBoxWidget.choices&&(eval("pui.temp_value = choices;"),c.comboBoxWidget.choices=pui.temp_value.slice(0));null!=c.J&&null!=c.J.choices&&(eval("pui.temp_value = choices;"),c.J.choices=pui.temp_value.slice(0));null!=c.comboBoxWidget&&null!=c.comboBoxWidget["choice values"]&&(eval("pui.temp_value = values;"),c.comboBoxWidget["choice values"]=pui.temp_value.slice(0));
355
+ null!=c.J&&null!=c.J.Be&&(eval("pui.temp_value = values;"),c.J.Be=pui.temp_value.slice(0))}:"onselect"!=u&&"ondragstart"!=u&&(E=function(N){if(null==pui.rj&&!(null!=c.getAttribute&&"true"==c.getAttribute("disabled")||null!=c.disabled&&1==c.disabled)){"true"!=c.T&&"send data"!=c.T||"onchange"!=b&&"onblur"!=b&&"onselect"!=b&&"oninput"!=b||null==c.T||(pui.T=c.T);eval("var row;");null!=n&&eval("row = "+n+";");eval("var rrn;");null!=n&&eval("rrn = "+n+";");eval("var rowNumber;");null!=c.jc&&eval("rowNumber = "+
356
+ (c.jc+1)+";");pui.temp_event=N;eval("var event = pui.temp_event;");try{var X=eval(e);"function"==typeof X&&(N||(N=window.event),X(N,this))}catch(ia){pui.Ra(ia,u.substr(0,1).toUpperCase()+u.substr(1)+" Error:\n")}}}),f||null==E||(c[u]=E,null!=c.comboBoxWidget&&"onselect"!=u&&"onoptiondisplay"!=u&&c.comboBoxWidget.Jn(u,E),null!=c.A&&"onselect"!=u&&"onoptiondisplay"!=u&&c.A.Jn(u,E)));if(f){if(""!=e||null!=a[u])a[u]=e;g.Ab[u]=!0;"field type"!=u&&"left"!=u&&"right"!=u&&"top"!=u&&"bottom"!=u&&"z index"!=
357
+ u&&"visibility"!=u&&"height"!=u&&"width"!=u&&"label"!=u&&"color"!=u&&"font family"!=u&&"font size"!=u&&"font style"!=u&&"font weight"!=u||g.wh();g.Og();null!=h&&h.Ej();"dspf"==Q&&("id"==u&&(pui.ide.RA(),pui.ide.SA()),"id"!=u&&"field type"!=u&&"value"!=u||pui.ide.Zt(),g.Rf||(g.designer.pp(),pui.ide.refreshRibbon()))}l=v.Bc;y=v.Sv;I=null;null!=y&&(I=y[u]);if(null!=I||null!=l)K=new pui.SetterParms(e,q,f,a,t,m,c,u,g,h);null!=l&&l(K);null!=I&&I(K);return m}}
358
+ pui.SetterParms=function(b,a,c,e,f,g,h,n,l,m){this.newValue=b;this.value=a;this.design=c;this.properties=e;this.originalValue=f;this.dom=g;this.Ka=h;this.propertyName=n;this.j=l;this.resizer=m};pui.SetterParms.prototype.evalProperty=function(b){return evalPropertyValue(this.properties[b],this.originalValue,this.dom)};
358
359
  function Lc(b,a,c){function e(u){return"BLU"==u||"GRN"==u||"PNK"==u||"RED"==u||"TRQ"==u||"WHT"==u||"YLW"==u}var f,g=[],h=!1,n=[],l=!1,m=null;for(f=0;f<a.length;f++){var t=!1;c&&f==a.length-1&&(t=!0);var q=a[f];if(null!=q&&""!=q){if(e(q)){if(l&&!t)continue;if(!l)l=!0,m=g.length;else if(t&&null!=m){g[m]=q;continue}}g.push(q);if("PR"==q||"PR-UL"==q)b.readOnly=!0,b.tabIndex="-1","SELECT"!=b.tagName||Lb()||(b.disabled=!0),null!=b.comboBoxWidget&&(t=b.comboBoxWidget.getBox(),t.readOnly=!0,Lb()||(t.disabled=
359
360
  !0),t.tabIndex="-1"),null!=b.A&&(t=b.A.getBox(),t.readOnly=!0,t.disabled=!0,t.tabIndex="-1");"RI"==q&&(h=!0);(e(q)||"HI"==q)&&n.push(q)}}if(h)for(f=0;f<n.length;f++)g.push("RI-"+n[f]);a=g.join(" ");b.setAttribute("class",a);b.className=a}
360
361
  function evalPropertyValue(b){var a="";if(pui.F(b)||pui.Zb(b)||pui.oc(b))return null!=b.designValue&&(a=b.designValue),a;null==b&&(b="");var c=null;"js:"==String(b).substr(0,3).toLowerCase()&&(c=b.substr(3));"javascript:"==String(b).substr(0,11).toLowerCase()&&(c=b.substr(11));"script:"==String(b).substr(0,7).toLowerCase()&&(c=b.substr(7));if(null==c||""==Pb(c))a=b;else{eval("var value = arguments[1];");eval("var obj = arguments[2];");try{a="void"===c.trim().toLowerCase()||"void(0)"===c.trim().toLowerCase()?
@@ -385,9 +386,10 @@ pui.Fq={uf:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",e
385
386
  var f=this.uf.indexOf(b.charAt(c++));var g=this.uf.indexOf(b.charAt(c++));var h=this.uf.indexOf(b.charAt(c++));e=e<<2|f>>4;f=(f&15)<<4|g>>2;var n=(g&3)<<6|h;a+=String.fromCharCode(e);64!=g&&(a+=String.fromCharCode(f));64!=h&&(a+=String.fromCharCode(n))}return a=pui.ri.decode(a)}};
386
387
  pui.downloadJSON=function(){if(pui.recordTest)pui.saveRecording();else if(null==pui.savedJSON)pui.alert("JSON is not available.");else{var b=pui.savedJSON;if("object"===typeof JSON&&"function"===typeof JSON.parse&&"function"===typeof JSON.stringify)try{b=JSON.stringify(JSON.parse(pui.savedJSON),null," ")}catch(a){}pui.Zk("text/plain","json.txt",b)}};
387
388
  pui.saveRecording=function(b){for(var a=null,c=0;c<pui.Oc.payloads.length;c++)!a&&pui.Oc.responses[c].appJob&&(a=pui.Oc.responses[c].appJob.user),pui.Oc.payloads[c].response=pui.Oc.responses[c];var e=Yc().testid;(c=e)||(c=prompt("Enter recording name"));if(c)if(pui.pjsServer)0===pui.Oc.payloads.length?pui.alert("No recording to save."):(a={id:e,appuser:a,payloads:pui.Oc.payloads},c={"Content-Type":"application/json"},sessionStorage["atrium-token"]&&(c.Authorization="Basic "+sessionStorage["atrium-token"]),
388
- fetch("/auto-testing/save-recording",{method:"POST",headers:c,body:JSON.stringify(a)}).then(function(g){g.ok?(window.parent&&window.parent.Atrium&&window.parent.Atrium.api&&"function"===typeof window.parent.Atrium.api.reloadNavParent&&window.parent.Atrium.api.reloadNavParent("test-"+e),pui.Oc={payloads:[],responses:[]},"function"===typeof b?b():pui.alert("Recording saved.")):pui.alert("Failed to save recording.")})["catch"](function(g){pui.alert("Error: Unable to save recording.");console.error("Fetch error:",
389
- g)}));else{a=JSON.stringify({user:a,payloads:pui.Oc.payloads});var f=c;f.endsWith(".json")||(f+=".json");pui["recording path"]?(c=[],c.push({name:"path",value:pui["recording path"]+f}),c.push({name:"text",value:"1"}),c.push({name:"replace",value:"Y"}),c.push({name:"json",value:a,fileName:f}),a=new pui.Lq,a.ur(c),c=cc("PUI0001109.pgm"),c=c.replace("/auth",""),a.send(c,function(g){var h;200!=g.Lf()&&(h=g.$i());h||(g=eval("("+g.Kc()+")"),g.success||(h=g.errorText));h?pui.alert(h):(pui.alert("Recording saved."),
390
- pui.Oc={payloads:[],responses:[]})})):pui.Zk("text/plain",f,a)}};pui.clearRecording=function(b){var a=Yc().testid;if(pui.pjsServer){a={id:a};var c={"Content-Type":"application/json"};sessionStorage["atrium-token"]&&(c.Authorization="Basic "+sessionStorage["atrium-token"]);fetch("/auto-testing/clear-recording",{method:"POST",headers:c,body:JSON.stringify(a)}).then(function(e){"function"===typeof b&&b(e)})["catch"](function(e){"function"===typeof b&&b(null,e)})}else"function"===typeof b&&b()};
389
+ fetch((pui.serverURL||"")+"/auto-testing/save-recording",{method:"POST",headers:c,body:JSON.stringify(a)}).then(function(g){g.ok?(window.parent&&window.parent.Atrium&&window.parent.Atrium.api&&"function"===typeof window.parent.Atrium.api.reloadNavParent&&window.parent.Atrium.api.reloadNavParent("test-"+e),pui.Oc={payloads:[],responses:[]},"function"===typeof b?b():pui.alert("Recording saved.")):pui.alert("Failed to save recording.")})["catch"](function(g){pui.alert("Error: Unable to save recording.");
390
+ console.error("Fetch error:",g)}));else{a=JSON.stringify({user:a,payloads:pui.Oc.payloads});var f=c;f.endsWith(".json")||(f+=".json");pui["recording path"]?(c=[],c.push({name:"path",value:pui["recording path"]+f}),c.push({name:"text",value:"1"}),c.push({name:"replace",value:"Y"}),c.push({name:"json",value:a,fileName:f}),a=new pui.Lq,a.ur(c),c=cc("PUI0001109.pgm"),c=c.replace("/auth",""),a.send(c,function(g){var h;200!=g.Lf()&&(h=g.$i());h||(g=eval("("+g.Kc()+")"),g.success||(h=g.errorText));h?pui.alert(h):
391
+ (pui.alert("Recording saved."),pui.Oc={payloads:[],responses:[]})})):pui.Zk("text/plain",f,a)}};
392
+ pui.clearRecording=function(b){var a=Yc().testid;if(pui.pjsServer){a={id:a};var c={"Content-Type":"application/json"};sessionStorage["atrium-token"]&&(c.Authorization="Basic "+sessionStorage["atrium-token"]);fetch((pui.serverURL||"")+"/auto-testing/clear-recording",{method:"POST",headers:c,body:JSON.stringify(a)}).then(function(e){"function"===typeof b&&b(e)})["catch"](function(e){"function"===typeof b&&b(null,e)})}else"function"===typeof b&&b()};
391
393
  pui.keepAlive=function(){if("genie"!=Q||1!=pui.S.Ud){if("dspf"==Q)var b=null==pui.S?cc("PUI0001200.pgm"):cc("PUI0002110.pgm");else if("genie"==Q)b=window.DOCUMENT_URI;else return!1;null!=pui.psid&&""!=pui.psid&&(b+="/"+pui.psid);if(null!=pui.overrideSubmitUrl&&"function"==typeof pui.overrideSubmitUrl)try{b=pui.overrideSubmitUrl(b)}catch(c){}"genie"==Q&&pui.hk(pui.S.Ud=!0);"dspf"==Q&&(pui.ac=!1);pui.cf();var a={keepalive:"1"};pui.isCloud&&(a.workspace_id=pui.cloud.ws.id);dc({url:pui.sg(b),method:"post",
392
394
  params:a,sendAsBinary:!1,suppressAlert:!0,handler:function(){pui.nc();"genie"==Q&&pui.hk(pui.S.Ud=!1);"dspf"==Q&&(pui.ac=!0);for(var c=0;c<pui.nb.length;c++)pui.nb[c].unMask()},onfail:function(c){null!=pui.onoffline||pui["suppress comm errors"]||pui.alert(pui.Wi(c));pui.nc();"genie"==Q&&pui.hk(pui.S.Ud=!1);"dspf"==Q&&(pui.ac=!0);for(c=0;c<pui.nb.length;c++)pui.nb[c].unMask();if(null!=pui.onoffline)pui.onoffline()}});return!0}};
393
395
  pui.getWindowSize=function(){if(document.body&&document.body.offsetWidth){var b=document.body.offsetWidth;var a=document.body.offsetHeight}"CSS1Compat"==document.compatMode&&document.documentElement&&document.documentElement.offsetWidth&&(b=document.documentElement.offsetWidth,a=document.documentElement.offsetHeight);window.innerWidth&&window.innerHeight&&(b=window.innerWidth,a=window.innerHeight);window.visualViewport&&window.visualViewport.width&&window.visualViewport.height&&(b=window.visualViewport.width,
@@ -687,16 +689,16 @@ a&&null!=pui.Yd&&("Enter"==a||"PageUp"==a||"PageDown"==a||null!=pui.keyMap[pui.Y
687
689
  pui.runtimeContainer.focus();Db(b);if(pui.is_old_ie)try{b.keyCode=0}catch(m){}return!1}if(n){Db(b);if(pui.is_old_ie)try{b.keyCode=0}catch(m){}return!1}c=!0}"Enter"!=a||pui.uo||(c=!0);if(c){pui.Eb=a;for(c=0;c<e.length;c++){e[c].ea="1";if("true"==e[c].T||"send data"==e[c].T)pui.T=e[c].T;e[c].Wa&&(pui.Wa=e[c].Wa,pui.$c=e[c].D,pui.Zc=e[c].gk)}if(0==pui.respond()){for(c=0;c<e.length;c++)e[c].ea="0";pui.T="false";pui.Wa=null;pui.$c=null;pui.Zc=null}Db(b);if(pui.is_old_ie)try{b.keyCode=0}catch(m){}return!1}}if(null!=
688
690
  a&&("PageUp"!=a&&"PageDown"!=a||pui.Pn)){Db(b);if(pui.is_old_ie)try{b.keyCode=0}catch(m){}return!1}}}};pui.Qo=function(b){return pui.Ch(b,"F1")};
689
691
  pui.run=function(b){var a=!0===b.mobile,c=!0===b.screenshot,e=b.parameter,f=b.program;null==f&&(f="");var g=b.container,h=b.workstnid;null==h&&(h="");h=h.toUpperCase();var n=b.debug,l=b.log;null==n&&(n="0");null==l&&(l="0");pui.em=!0===b.renderLog;var m="*LIBL",t=f.split("/");2==t.length&&(m=t[0],f=t[1]);null==g&&(g="pui");"string"==typeof g&&(g=document.getElementById(g));S(document.body,"keydown",pui.Ch);S(document.body,"help",pui.Qo);S(document.body,"mousedown",pui.Yr);null==b.jsonURL&&null==b.replay&&
690
- "preview"!=b.mode&&pui.Gr();g.setAttribute("tabindex","0");pui.runtimeContainer=g;pui.cf();t="post";var q=cc("PUI0001200.pgm"),u=b.jsonURL;b.replay&&(u="/profoundui/userdata/automated-testing/tests/"+b.replay,u.endsWith(".json")||(u+=".json"));null!=u&&(q=u+"?r="+Math.floor(1E9*Math.random()+1),t="get");f={program:f.toUpperCase(),library:m.toUpperCase(),init:"1",pathname:location.pathname,debug:n,log:l,workstnid:h};null!=b.lang&&""!=b.lang&&(f.lang=b.lang);pui.isCloud&&(f.workspace_id=pui.cloud.ws.id,
691
- f.workspace_url=location.href,c&&(f.screenshot="1"));"1"==b.suffixid&&(f.suffixid="1");"1"==b.duplicateid&&(f.duplicateid="1");a&&(f.mobile="1",null==e&&(e=""),f.p1=e,f.l1="250");f.screen_width=screen.width;pui.yf&&(f.screen_width=pui.yf.split("x")[0]);c=b.params;if(null!=c)for(var v in c)f[v]=c[v];if("preview"==b.mode){t=null;window.opener&&window.opener.pui&&"function"===typeof window.opener.pui.generatePreview&&(t=window.opener.pui.generatePreview);window.parent&&window.parent!=window&&pui.ii()&&
692
- window.parent.noderun&&"function"===typeof window.parent.noderun.generatePreview&&(t=window.parent.noderun.generatePreview);var y;t&&(y=t(b.previewTab));y?(y.container=g,pui.sl=!0,t=!1,window.opener&&window.opener.pui&&window.opener.pui.viewdesigner&&(t=!0),window.opener&&window.opener.pui&&window.opener.pui.nodedesigner&&(t=!0),window.parent&&window.parent!=window&&pui.ii()&&window.parent.noderun&&(t=!0),pui.handler=t?function(A){ic({url:"/profoundui/dummy_submit",method:"post",params:A,sendAsBinary:!1,
693
- suppressAlert:!0,handler:function(){document.body.innerHTML="<br/><br/>Preview screen submitted."},onfail:function(){document.body.innerHTML="<br/><br/>Preview screen submitted."}})}:null,pui.zl(y,function(){pui.render(y)})):(pui.wa(g),pui.alert("Preview data is no longer available. You can rebuild the preview in the Visual Designer."))}else v=pui.getCookie("puiRefreshId"),null!=v&&(pui.deleteCookie("puiRefreshId","/",null,null,"Strict"),f={refresh:"1"},q+="/"+v),pui.recordTest&&pui.Oc.payloads.push({url:q,
694
- data:f}),ic({url:pui.sg(q),method:t,sendAsBinary:!1,params:f,saveResponse:!0,suppressAlert:!0,handler:function(A){function z(){if(Array.isArray(A.payloads)){pui.Tp=A;pui.Qg=Number(b.step);if(!pui.Qg||isNaN(pui.Qg))pui.Qg=1;var I=A.container;A=A.payloads[pui.Qg-1].response;A=JSON.parse(JSON.stringify(A));A.container=I;A.version=pui.version;pui.xw()}pui.render(A)}A.container=g;pui.zl(A,function(){pui.Kx(a,z)})},onfail:function(A){pui.nc();setTimeout(function(){if(null==pui.onoffline)pui["suppress comm errors"]||
695
- pui.alert(pui.Wi(A)),pui.is_touch&&setTimeout(function(){null!=navigator.app&&null!=navigator.app.exitApp&&navigator.app.exitApp()},500);else pui.onoffline()},500)}})};
692
+ "preview"!=b.mode&&pui.Gr();g.setAttribute("tabindex","0");pui.runtimeContainer=g;pui.cf();t="post";var q=cc("PUI0001200.pgm"),u=b.jsonURL;b.replay&&(u="/profoundui/userdata/automated-testing/tests/"+b.replay,u.endsWith(".json")||(u+=".json"));null!=u&&(q=u+"?r="+Math.floor(1E9*Math.random()+1),t="get");u=location.pathname;pui.coder&&pui.coder.baseUrl&&u.startsWith(pui.coder.baseUrl)&&(u=u.substring(pui.coder.baseUrl.length));f={program:f.toUpperCase(),library:m.toUpperCase(),init:"1",pathname:u,
693
+ debug:n,log:l,workstnid:h};null!=b.lang&&""!=b.lang&&(f.lang=b.lang);pui.isCloud&&(f.workspace_id=pui.cloud.ws.id,f.workspace_url=location.href,c&&(f.screenshot="1"));"1"==b.suffixid&&(f.suffixid="1");"1"==b.duplicateid&&(f.duplicateid="1");a&&(f.mobile="1",null==e&&(e=""),f.p1=e,f.l1="250");f.screen_width=screen.width;pui.yf&&(f.screen_width=pui.yf.split("x")[0]);c=b.params;if(null!=c)for(var v in c)f[v]=c[v];if("preview"==b.mode){t=null;window.opener&&window.opener.pui&&"function"===typeof window.opener.pui.generatePreview&&
694
+ (t=window.opener.pui.generatePreview);window.parent&&window.parent!=window&&pui.ii()&&window.parent.noderun&&"function"===typeof window.parent.noderun.generatePreview&&(t=window.parent.noderun.generatePreview);var y;t&&(y=t(b.previewTab));y?(y.container=g,pui.sl=!0,t=!1,window.opener&&window.opener.pui&&window.opener.pui.viewdesigner&&(t=!0),window.opener&&window.opener.pui&&window.opener.pui.nodedesigner&&(t=!0),window.parent&&window.parent!=window&&pui.ii()&&window.parent.noderun&&(t=!0),pui.handler=
695
+ t?function(A){ic({url:"/profoundui/dummy_submit",method:"post",params:A,sendAsBinary:!1,suppressAlert:!0,handler:function(){document.body.innerHTML="<br/><br/>Preview screen submitted."},onfail:function(){document.body.innerHTML="<br/><br/>Preview screen submitted."}})}:null,pui.zl(y,function(){pui.render(y)})):(pui.wa(g),pui.alert("Preview data is no longer available. You can rebuild the preview in the Visual Designer."))}else v=pui.getCookie("puiRefreshId"),null!=v&&(pui.deleteCookie("puiRefreshId",
696
+ "/",null,null,"Strict"),f={refresh:"1"},q+="/"+v),pui.recordTest&&pui.Oc.payloads.push({url:q,data:f}),ic({url:pui.sg(q),method:t,sendAsBinary:!1,params:f,saveResponse:!0,suppressAlert:!0,handler:function(A){function z(){if(Array.isArray(A.payloads)){pui.Tp=A;pui.Qg=Number(b.step);if(!pui.Qg||isNaN(pui.Qg))pui.Qg=1;var I=A.container;A=A.payloads[pui.Qg-1].response;A=JSON.parse(JSON.stringify(A));A.container=I;A.version=pui.version;pui.xw()}pui.render(A)}A.container=g;pui.zl(A,function(){pui.Kx(a,
697
+ z)})},onfail:function(A){pui.nc();setTimeout(function(){if(null==pui.onoffline)pui["suppress comm errors"]||pui.alert(pui.Wi(A)),pui.is_touch&&setTimeout(function(){null!=navigator.app&&null!=navigator.app.exitApp&&navigator.app.exitApp()},500);else pui.onoffline()},500)}})};
696
698
  pui.signon=function(b){var a=!0===b.mobile,c=!0===b.screenshot,e=b.container,f=b.debug,g=b.workstnid,h=b.atrium_item;null==h&&(h="");null==g&&(g="");g=g.toUpperCase();var n=b.log,l=b.plog,m=b.autotest;pui.em=!0===b.renderLog;null==e&&(e="pui");null==f&&(f="0");null==n&&(n="0");null==l&&(l="0");null==m&&(m="0");"string"==typeof e&&(e=document.getElementById(e));S(document.body,"keydown",pui.Ch);S(document.body,"help",pui.Qo);pui.Gr();e.setAttribute("tabindex","0");pui.runtimeContainer=e;null==pui.rj&&
697
- pui.cf();var t=cc("PUI0001200.pgm"),q="",u="";if("undefined"!=typeof b.program){u="*LIBL";var v=b.program.split("/");2==v.length&&(u=v[0],q=v[1])}f={signon:"1",program:q.toUpperCase(),library:u.toUpperCase(),init:"1",pathname:location.pathname,debug:f,log:n,plog:l,autotest:m,workstnid:g,atrium_item:h};null!=b.lang&&""!=b.lang&&(f.lang=b.lang);pui.isCloud&&(f.workspace_id=pui.cloud.ws.id,f.workspace_url=location.href,c&&(f.screenshot="1"));"1"==b.suffixid&&(f.suffixid="1");"1"==b.duplicateid&&(f.duplicateid=
698
- "1");a&&(f.mobile="1");f.screen_width=screen.width;pui.yf&&(f.screen_width=pui.yf.split("x")[0]);b=b.params;if(null!=b)for(var y in b)f[y]=b[y];y=pui.getCookie("puiRefreshId");null!=y&&(pui.deleteCookie("puiRefreshId","/",null,null,"Strict"),f={refresh:"1"},t+="/"+y);null==pui.rj&&(pui.recordTest&&pui.Oc.payloads.push({url:t,data:f}),ic({url:pui.sg(t),method:"post",sendAsBinary:!1,params:f,saveResponse:!0,suppressAlert:!0,handler:function(A){A.container=e;pui.zl(A,function(){pui.render(A)})},onfail:function(A){pui.nc();
699
- setTimeout(function(){if(null==pui.onoffline)pui["suppress comm errors"]||pui.alert(pui.Wi(A)),pui.is_touch&&setTimeout(function(){null!=navigator.app&&null!=navigator.app.exitApp&&navigator.app.exitApp()},500);else pui.onoffline()},500)}}))};
699
+ pui.cf();var t=cc("PUI0001200.pgm"),q="",u="";if("undefined"!=typeof b.program){u="*LIBL";var v=b.program.split("/");2==v.length&&(u=v[0],q=v[1])}v=location.pathname;pui.coder&&pui.coder.baseUrl&&v.startsWith(pui.coder.baseUrl)&&(v=v.substring(pui.coder.baseUrl.length));f={signon:"1",program:q.toUpperCase(),library:u.toUpperCase(),init:"1",pathname:v,debug:f,log:n,plog:l,autotest:m,workstnid:g,atrium_item:h};null!=b.lang&&""!=b.lang&&(f.lang=b.lang);pui.isCloud&&(f.workspace_id=pui.cloud.ws.id,f.workspace_url=
700
+ location.href,c&&(f.screenshot="1"));"1"==b.suffixid&&(f.suffixid="1");"1"==b.duplicateid&&(f.duplicateid="1");a&&(f.mobile="1");f.screen_width=screen.width;pui.yf&&(f.screen_width=pui.yf.split("x")[0]);b=b.params;if(null!=b)for(var y in b)f[y]=b[y];y=pui.getCookie("puiRefreshId");null!=y&&(pui.deleteCookie("puiRefreshId","/",null,null,"Strict"),f={refresh:"1"},t+="/"+y);null==pui.rj&&(pui.recordTest&&pui.Oc.payloads.push({url:t,data:f}),ic({url:pui.sg(t),method:"post",sendAsBinary:!1,params:f,saveResponse:!0,
701
+ suppressAlert:!0,handler:function(A){A.container=e;pui.zl(A,function(){pui.render(A)})},onfail:function(A){pui.nc();setTimeout(function(){if(null==pui.onoffline)pui["suppress comm errors"]||pui.alert(pui.Wi(A)),pui.is_touch&&setTimeout(function(){null!=navigator.app&&null!=navigator.app.exitApp&&navigator.app.exitApp()},500);else pui.onoffline()},500)}}))};
700
702
  pui.bq=function(b){b.profoundui="1";ic({url:pui.normalizeURL(pui.controller),method:"post",params:b,sendAsBinary:!1,saveResponse:!0,suppressAlert:!0,handler:function(a){if(null==a)pui.wa(document.body),document.body.innerHTML='<div id="close-browser-msg" style="font-family: Trebuchet MS; width: 95%; text-align: center; font-size: 200%;"><br/>'+pui.getLanguageText("runtimeMsg","session ended text")+"<br/><br/>"+pui.getLanguageText("runtimeMsg","close browser text")+"</div>",pui.closeSession();else{a.container=
701
703
  pui.runtimeContainer;var c=a.data;null==c&&(c={});null!=a.view&&(pui.view=a.view);if(null!=a.redirect)location.href=a.redirect;else if(null!=a.controller)pui.controller=a.controller,pui.bq({});else if(null!=a.html)pui.wa(pui.runtimeContainer),pui.runtimeContainer.innerHTML=a.html;else{var e=a.format;null==e&&(e=a.screen);var f=a.formats;null==f&&(f=a.screens);a=a.appJob||{};pui.show({path:pui.normalizeURL(pui.view),data:c,format:e,formats:f,appJob:a,handler:function(g){pui.bq(g)}})}}},onfail:function(a){null!=
702
704
  pui.onoffline||pui["suppress comm errors"]||pui.alert(pui.Wi(a));pui.nc();pui.fm();if(null!=pui.onoffline)pui.onoffline()}})};
@@ -1,17 +1,17 @@
1
1
  function B(a){this.onready=this.onfail=this.onsuccess=this.cacheBuster=this.suppressAlert=this.password=this.user=this.async=this.url=this.reqData=this.postData=this.method=null;this.headers={};this.params=null;this.sendAsBinary=!0;var b=this.overrideMimeType=null,c=null,e=null,d=null,g="undefined"!=typeof pui&&"undefined"!=typeof pui.alert?pui.alert:alert,f=this;B.defaultHeaders&&(this.headers=B.defaultHeaders);if("object"==typeof a)for(var k in a)"undefined"!=typeof this[k]&&(this[k]=a[k]);else this.url=
2
2
  a;if(window.XMLHttpRequest)b=new XMLHttpRequest;else if(window.ActiveXObject)b=new ActiveXObject("Microsoft.XMLHTTP");else{g("Ajax request error: Unsupported browser.");return}this.send=this.send=function(){function h(){if(4==b.readyState){c=0===b.status?z?"Request aborted.":"Request failed. Check the browser console for more details.":b.status+" - "+b.statusText;if(null!=f.onready)f.onready(f);if(200==b.status){if(e=!0,null!=f.onsuccess)f.onsuccess(f)}else if(e=!1,1!=f.suppressAlert&&g(c),null!=
3
- f.onfail)f.onfail(f);d=!1}}var m,n=null,q=null,t=null;if(null==f.method)n="GET";else if("string"==typeof f.method||"GET"==f.method.toUpperCase()&&"POST"==f.method.toUpperCase()&&"PUT"==f.method.toUpperCase()&&"DELETE"==f.method.toUpperCase())n=f.method.toUpperCase();else{g('Invalid value for property: "method".');return}if("POST"==n||"PUT"==n||"DELETE"==n)if(null!=f.reqData?t=f.reqData:null!=f.postData&&(t=f.postData),null!=t){if("string"!=typeof t){g('Invalid value for property: "postData".');return}}else t=
3
+ f.onfail)f.onfail(f);d=!1}}var n,m=null,q=null,t=null;if(null==f.method)m="GET";else if("string"==typeof f.method||"GET"==f.method.toUpperCase()&&"POST"==f.method.toUpperCase()&&"PUT"==f.method.toUpperCase()&&"DELETE"==f.method.toUpperCase())m=f.method.toUpperCase();else{g('Invalid value for property: "method".');return}if("POST"==m||"PUT"==m||"DELETE"==m)if(null!=f.reqData?t=f.reqData:null!=f.postData&&(t=f.postData),null!=t){if("string"!=typeof t){g('Invalid value for property: "postData".');return}}else t=
4
4
  "";if(null==f.async)q=!0;else{if(1!=f.async&&0!=f.async){g('Invalid value for property: "async".');return}q=f.async}if("string"!=typeof f.url)g('Invalid value for property: "url".');else if(null!=f.user&&"string"!=typeof f.user)g('Invalid value for property: "user".');else if(null!=f.password&&"string"!=typeof f.password)g('Invalid value for property: "password".');else if(null!=f.onsuccess&&"function"!=typeof f.onsuccess)g('Invalid value for event: "onsuccess".');else if(null!=f.onfail&&"function"!=
5
- typeof f.onfail)g('Invalid value for event: "onfail".');else if(null!=f.onready&&"function"!=typeof f.onready)g('Invalid value for event: "onready".');else{var u=!0;if(null!=t)for(m in f.headers)"CONTENT-TYPE"==m.toUpperCase()&&-1==f.headers[m].toLowerCase().indexOf("www-form-urlencoded")&&(u=!1);var p=f.url,w=f.params;if("object"==typeof w){var l="";for(m in w){var r=w[m],v=[];"object"==typeof r?null!=r.length&&0<r.length&&(v=r):v.push(r);for(r=0;r<v.length;r++)""!=l&&(l+="&"),l+=encodeURIComponent(m)+
6
- "="+encodeURIComponent(v[r])}""!=l&&(!u||"POST"!=n&&"PUT"!=n&&"DELETE"!=n?(u=p.split("?"),p=2==u.length&&""!=u[1]?u[0]+"?"+u[1]+"&"+l:p+("?"+l)):t=(null!=t&&""!=t?t+"&":"")+l)}"GET"!==n||null!==f.cacheBuster&&!0!==f.cacheBuster||(p=pui.addUrlCacheBuster(p));try{"string"==typeof f.user&&"string"==typeof f.password?b.open(n,p,q,f.user,f.password):b.open(n,p,q);p=!1;var y=f.headers;for(m in y)b.setRequestHeader(m,y[m]),"CONTENT-TYPE"==m.toUpperCase()&&(p=!0);if("POST"==n||"PUT"==n||"DELETE"==n)p||b.setRequestHeader("Content-type",
5
+ typeof f.onfail)g('Invalid value for event: "onfail".');else if(null!=f.onready&&"function"!=typeof f.onready)g('Invalid value for event: "onready".');else{var u=!0;if(null!=t)for(n in f.headers)"CONTENT-TYPE"==n.toUpperCase()&&-1==f.headers[n].toLowerCase().indexOf("www-form-urlencoded")&&(u=!1);var p=f.url,w=f.params;if("object"==typeof w){var l="";for(n in w){var r=w[n],v=[];"object"==typeof r?null!=r.length&&0<r.length&&(v=r):v.push(r);for(r=0;r<v.length;r++)""!=l&&(l+="&"),l+=encodeURIComponent(n)+
6
+ "="+encodeURIComponent(v[r])}""!=l&&(!u||"POST"!=m&&"PUT"!=m&&"DELETE"!=m?(u=p.split("?"),p=2==u.length&&""!=u[1]?u[0]+"?"+u[1]+"&"+l:p+("?"+l)):t=(null!=t&&""!=t?t+"&":"")+l)}"GET"!==m||null!==f.cacheBuster&&!0!==f.cacheBuster||(p=pui.addUrlCacheBuster(p));try{"string"==typeof f.user&&"string"==typeof f.password?b.open(m,p,q,f.user,f.password):b.open(m,p,q);p=!1;var y=f.headers;for(n in y)b.setRequestHeader(n,y[n]),"CONTENT-TYPE"==n.toUpperCase()&&(p=!0);if("POST"==m||"PUT"==m||"DELETE"==m)p||b.setRequestHeader("Content-type",
7
7
  "application/x-www-form-urlencoded");"string"==typeof f.overrideMimeType&&"function"==typeof b.overrideMimeType&&b.overrideMimeType(f.overrideMimeType)}catch(D){g(D);return}d=!0;var z=!1;1==q&&(b.onload=h,b.onerror=h,b.onabort=function(){z=!0;h()});if(1==f.sendAsBinary)try{b.sendAsBinary(t)}catch(D){b.send(t)}else b.send(t);1!=q&&h()}};this.ok=this.ok=function(){return null!=e?e:!1};this.getResponseText=this.j=function(){return b.responseText};this.getResponseXML=this.K=function(){return b.responseXML};
8
- this.getStatus=this.l=function(){return b.status};this.getStatusText=this.C=function(){return b.statusText};this.getStatusMessage=this.B=function(){return c};this.getAllResponseHeaders=this.getAllResponseHeaders=function(){if(e)try{return b.getAllResponseHeaders()}catch(h){g(h)}};this.getResponseHeader=this.getResponseHeader=function(h){if(e)try{return b.getResponseHeader(h)}catch(m){g(m)}};this.setRequestHeader=this.setRequestHeader=function(h,m){f.headers[h]=m};this.abort=this.abort=function(){if(!0===
8
+ this.getStatus=this.l=function(){return b.status};this.getStatusText=this.C=function(){return b.statusText};this.getStatusMessage=this.B=function(){return c};this.getAllResponseHeaders=this.getAllResponseHeaders=function(){if(e)try{return b.getAllResponseHeaders()}catch(h){g(h)}};this.getResponseHeader=this.getResponseHeader=function(h){if(e)try{return b.getResponseHeader(h)}catch(n){g(n)}};this.setRequestHeader=this.setRequestHeader=function(h,n){f.headers[h]=n};this.abort=this.abort=function(){if(!0===
9
9
  d)try{b.abort()}catch(h){g(h)}}}function C(a,b){var c="";if(1==arguments.length&&"object"==typeof arguments[0]){var e=arguments[0];e.async=null;e.onsuccess=null;if("function"==typeof e.handler){var d=!0;var g=e.handler}else d=!1}else null!=b&&"function"==typeof b?(d=!0,g=b):d=!1;e=new B(arguments[0]);e.async=d;e.onsuccess=function(f){c+=f.j();1==d&&g(c)};e.send();if(0==d)return c}
10
10
  function F(a,b){var c=null,e=!1;if(1==arguments.length&&"object"==typeof arguments[0]){var d=arguments[0];d.async=null;d.onsuccess=null;1==d.saveResponse&&(e=!0);if("function"==typeof d.handler){var g=!0;var f=d.handler}else g=!1}else null!=b&&"function"==typeof b?(g=!0,f=b):g=!1;d=new B(arguments[0]);d.async=g;d.onsuccess=function(k){k=k.j();e&&"object"==typeof pui&&(pui.savedJSON=k);try{c=eval("("+k+")")}catch(h){f(null,h);return}1==g&&f(c)};d.send();if(0==g)return c}
11
11
  "undefined"==typeof window.pui&&(window.pui={});window.RPGspRequest=B;window.pui.Ajax=B;window.pui.AjaxRequest=B;window.ajax=C;
12
12
  window.ajaxXML=function(a,b){var c=null;if(1==arguments.length&&"object"==typeof arguments[0]){var e=arguments[0];e.async=null;e.onsuccess=null;e.onfail=null;e.onsuccess=null;if("function"==typeof e.handler){var d=!0;var g=e.handler}else d=!1}else null!=b&&"function"==typeof b?(d=!0,g=b):d=!1;e=new B(arguments[0]);e.async=d;e.onsuccess=function(f){c=f.K();1==d&&g(c)};e.send();if(0==d)return c};window.ajaxJSON=F;
13
13
  window.ajaxSubmit=function(a,b){var c="",e="undefined"!=typeof pui&&"undefined"!=typeof pui.alert?pui.alert:alert;if("object"==typeof a)var d=a;else d=document.getElementById(a),null==d&&(d=document.forms[a]);if(null!=d)var g=d.tagName;if(null==d||null==g||"FORM"!=g.toUpperCase())return e("Ajax request error: Invalid form object."),"";if(""==a.action)return e("Ajax request error: Invalid form action."),"";for(a=0;a<d.elements.length;a++)if(e=d.elements[a],null!=e.name&&""!=e.name){g=!1;if("INPUT"==
14
- e.tagName){var f=e.type;f=f.toLowerCase();"hidden"==f&&(g=!0);"password"==f&&(g=!0);"text"==f&&(g=!0);pui.Aa(f)&&(g=!0);""==f&&(g=!0);("checkbox"==f||"radio"==f)&&e.checked&&(g=!0)}"TEXTAREA"==e.tagName&&(g=!0);"SELECT"==e.tagName&&(g=!0);g&&(""!=c&&(c+="&"),c+=e.name+"="+encodeURIComponent(e.value))}d=new B(d.action);d.method="POST";d.postData=c;var k="";if(null!=b&&"function"==typeof b)var h=!0;else h=!1,d.async=!1;d.onsuccess=function(m){k+=m.j();1==h&&b(k)};d.send();if(0==h)return k};function G(a){a=null!=a&&"object"==typeof a?a:document.getElementById(a);if(null==a)return"";var b="";"div"==a.tagName.toLowerCase()&&(b=a.firstChild,b=null!=b&&null!=b.tagName&&"A"==b.tagName?b.innerHTML:a.innerHTML);if("INPUT"==a.tagName&&"checkbox"==a.type)return!0===a.indeterminate?a.indeterminateValue:a.checked&&null!=a.checkedValue?a.checkedValue:a.checked||null==a.uncheckedValue?a.checked:a.uncheckedValue;if("INPUT"==a.tagName&&"radio"==a.type)return a.checked;"TEXTAREA"==a.tagName?b=a.value:
14
+ e.tagName){var f=e.type;f=f.toLowerCase();"hidden"==f&&(g=!0);"password"==f&&(g=!0);"text"==f&&(g=!0);pui.Aa(f)&&(g=!0);""==f&&(g=!0);("checkbox"==f||"radio"==f)&&e.checked&&(g=!0)}"TEXTAREA"==e.tagName&&(g=!0);"SELECT"==e.tagName&&(g=!0);g&&(""!=c&&(c+="&"),c+=e.name+"="+encodeURIComponent(e.value))}d=new B(d.action);d.method="POST";d.postData=c;var k="";if(null!=b&&"function"==typeof b)var h=!0;else h=!1,d.async=!1;d.onsuccess=function(n){k+=n.j();1==h&&b(k)};d.send();if(0==h)return k};function G(a){a=null!=a&&"object"==typeof a?a:document.getElementById(a);if(null==a)return"";var b="";"div"==a.tagName.toLowerCase()&&(b=a.firstChild,b=null!=b&&null!=b.tagName&&"A"==b.tagName?b.innerHTML:a.innerHTML);if("INPUT"==a.tagName&&"checkbox"==a.type)return!0===a.indeterminate?a.indeterminateValue:a.checked&&null!=a.checkedValue?a.checkedValue:a.checked||null==a.uncheckedValue?a.checked:a.uncheckedValue;if("INPUT"==a.tagName&&"radio"==a.type)return a.checked;"TEXTAREA"==a.tagName?b=a.value:
15
15
  "INPUT"==a.tagName?b=a.value:"SELECT"==a.tagName&&(b=a.selectedIndex,b=0<=b?a.options[b].value:a.pui&&a.pui.properties&&a.pui.properties.value?a.pui.properties.value:a.value);null!=a.comboBoxWidget&&(b=a.comboBoxWidget.getValue());null!=a.s&&(b=a.s.getValue());null!=a.signaturePad&&(b=a.signaturePad.getValue());null!=a.M&&(b=String(a.value));null!=a.o&&(b="",a.o.X&&null!=a.o.aa?b=a.o.aa:a.o.X||null==a.o.Z||(b=a.o.Z));a.pui&&a.pui.widget&&"function"===typeof a.pui.widget.getPropertyValue&&(b=a.pui.widget.getPropertyValue("value"));
16
16
  for(b=b.replace(/&nbsp;/g," ");-1!=b.indexOf(String.fromCharCode(160));)b=b.replace(String.fromCharCode(160)," ");b==a.ta&&(b="");return b}function J(a){if("string"!==typeof a)return a;for(;" "==a.charAt(0);)a=a.replace(a.charAt(0),"");return a}function M(a){return"string"!==typeof a?a:a.replace(/^\s*|\s*$/g,"")}pui.detachCalendar=function(a){"string"==typeof a&&(a=document.getElementById(a));null!=a&&pui.Ea(a)};
17
17
  function N(a,b,c){var e=!1,d=location.href;d=d.split("?")[0];d=d.split("/");2<d.length&&"auth"==d[d.length-2].toLowerCase()&&(e=!0);d="/profoundui/";var g="PUI0009101.PGM PUI0009102.PGM PUI0009103.PGM PUI0009104.PGM PUI0009107.PGM PUI0009109.PGM PUI0009110.PGM PUI0009119.PGM".split(" ");"string"===typeof pui.widgetURLPrefix&&-1!=g.indexOf(a.toUpperCase())&&(d=pui.widgetURLPrefix,"/"!=d.substr(d.length-1)&&(d+="/"));if(1==e||1==c)d+="auth/";d+=a;null!=b&&1==b&&(d+="/"+PSID);null!=pui.serverURL&&(d=
@@ -24,9 +24,10 @@ pui.ia={i:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",en
24
24
  var d=this.i.indexOf(a.charAt(c++));var g=this.i.indexOf(a.charAt(c++));var f=this.i.indexOf(a.charAt(c++));e=e<<2|d>>4;d=(d&15)<<4|g>>2;var k=(g&3)<<6|f;b+=String.fromCharCode(e);64!=g&&(b+=String.fromCharCode(d));64!=f&&(b+=String.fromCharCode(k))}return b=pui.H.decode(b)}};
25
25
  pui.downloadJSON=function(){if(pui.recordTest)pui.saveRecording();else if(null==pui.savedJSON)pui.alert("JSON is not available.");else{var a=pui.savedJSON;if("object"===typeof JSON&&"function"===typeof JSON.parse&&"function"===typeof JSON.stringify)try{a=JSON.stringify(JSON.parse(pui.savedJSON),null," ")}catch(b){}pui.S("text/plain","json.txt",a)}};
26
26
  pui.saveRecording=function(a){for(var b=null,c=0;c<pui.h.payloads.length;c++)!b&&pui.h.responses[c].appJob&&(b=pui.h.responses[c].appJob.user),pui.h.payloads[c].response=pui.h.responses[c];var e=O().testid;(c=e)||(c=prompt("Enter recording name"));if(c)if(pui.pjsServer)0===pui.h.payloads.length?pui.alert("No recording to save."):(b={id:e,appuser:b,payloads:pui.h.payloads},c={"Content-Type":"application/json"},sessionStorage["atrium-token"]&&(c.Authorization="Basic "+sessionStorage["atrium-token"]),
27
- fetch("/auto-testing/save-recording",{method:"POST",headers:c,body:JSON.stringify(b)}).then(function(g){g.ok?(window.parent&&window.parent.Atrium&&window.parent.Atrium.api&&"function"===typeof window.parent.Atrium.api.reloadNavParent&&window.parent.Atrium.api.reloadNavParent("test-"+e),pui.h={payloads:[],responses:[]},"function"===typeof a?a():pui.alert("Recording saved.")):pui.alert("Failed to save recording.")})["catch"](function(g){pui.alert("Error: Unable to save recording.");console.error("Fetch error:",
28
- g)}));else{b=JSON.stringify({user:b,payloads:pui.h.payloads});var d=c;d.endsWith(".json")||(d+=".json");pui["recording path"]?(c=[],c.push({name:"path",value:pui["recording path"]+d}),c.push({name:"text",value:"1"}),c.push({name:"replace",value:"Y"}),c.push({name:"json",value:b,fileName:d}),b=new pui.ja,b.ka(c),c=N("PUI0001109.pgm"),c=c.replace("/auth",""),b.send(c,function(g){var f;200!=g.l()&&(f=g.B());f||(g=eval("("+g.j()+")"),g.success||(f=g.errorText));f?pui.alert(f):(pui.alert("Recording saved."),
29
- pui.h={payloads:[],responses:[]})})):pui.S("text/plain",d,b)}};pui.clearRecording=function(a){var b=O().testid;if(pui.pjsServer){b={id:b};var c={"Content-Type":"application/json"};sessionStorage["atrium-token"]&&(c.Authorization="Basic "+sessionStorage["atrium-token"]);fetch("/auto-testing/clear-recording",{method:"POST",headers:c,body:JSON.stringify(b)}).then(function(e){"function"===typeof a&&a(e)})["catch"](function(e){"function"===typeof a&&a(null,e)})}else"function"===typeof a&&a()};
27
+ fetch((pui.serverURL||"")+"/auto-testing/save-recording",{method:"POST",headers:c,body:JSON.stringify(b)}).then(function(g){g.ok?(window.parent&&window.parent.Atrium&&window.parent.Atrium.api&&"function"===typeof window.parent.Atrium.api.reloadNavParent&&window.parent.Atrium.api.reloadNavParent("test-"+e),pui.h={payloads:[],responses:[]},"function"===typeof a?a():pui.alert("Recording saved.")):pui.alert("Failed to save recording.")})["catch"](function(g){pui.alert("Error: Unable to save recording.");
28
+ console.error("Fetch error:",g)}));else{b=JSON.stringify({user:b,payloads:pui.h.payloads});var d=c;d.endsWith(".json")||(d+=".json");pui["recording path"]?(c=[],c.push({name:"path",value:pui["recording path"]+d}),c.push({name:"text",value:"1"}),c.push({name:"replace",value:"Y"}),c.push({name:"json",value:b,fileName:d}),b=new pui.ja,b.ka(c),c=N("PUI0001109.pgm"),c=c.replace("/auth",""),b.send(c,function(g){var f;200!=g.l()&&(f=g.B());f||(g=eval("("+g.j()+")"),g.success||(f=g.errorText));f?pui.alert(f):
29
+ (pui.alert("Recording saved."),pui.h={payloads:[],responses:[]})})):pui.S("text/plain",d,b)}};
30
+ pui.clearRecording=function(a){var b=O().testid;if(pui.pjsServer){b={id:b};var c={"Content-Type":"application/json"};sessionStorage["atrium-token"]&&(c.Authorization="Basic "+sessionStorage["atrium-token"]);fetch((pui.serverURL||"")+"/auto-testing/clear-recording",{method:"POST",headers:c,body:JSON.stringify(b)}).then(function(e){"function"===typeof a&&a(e)})["catch"](function(e){"function"===typeof a&&a(null,e)})}else"function"===typeof a&&a()};
30
31
  pui.keepAlive=function(){if("genie"!=context||1!=pui.m.u){if("dspf"==context)var a=null==pui.m?N("PUI0001200.pgm"):N("PUI0002110.pgm");else if("genie"==context)a=window.DOCUMENT_URI;else return!1;null!=pui.psid&&""!=pui.psid&&(a+="/"+pui.psid);if(null!=pui.overrideSubmitUrl&&"function"==typeof pui.overrideSubmitUrl)try{a=pui.overrideSubmitUrl(a)}catch(c){}"genie"==context&&pui.N(pui.m.u=!0);"dspf"==context&&(pui.G=!1);pui.Ha();var b={keepalive:"1"};pui.isCloud&&(b.workspace_id=pui.cloud.ws.id);C({url:pui.la(a),
31
32
  method:"post",params:b,sendAsBinary:!1,suppressAlert:!0,handler:function(){pui.V();"genie"==context&&pui.N(pui.m.u=!1);"dspf"==context&&(pui.G=!0);for(var c=0;c<pui.D.length;c++)pui.D[c].unMask()},onfail:function(c){null!=pui.onoffline||pui["suppress comm errors"]||pui.alert(pui.xa(c));pui.V();"genie"==context&&pui.N(pui.m.u=!1);"dspf"==context&&(pui.G=!0);for(c=0;c<pui.D.length;c++)pui.D[c].unMask();if(null!=pui.onoffline)pui.onoffline()}});return!0}};
32
33
  pui.getWindowSize=function(){if(document.body&&document.body.offsetWidth){var a=document.body.offsetWidth;var b=document.body.offsetHeight}"CSS1Compat"==document.compatMode&&document.documentElement&&document.documentElement.offsetWidth&&(a=document.documentElement.offsetWidth,b=document.documentElement.offsetHeight);window.innerWidth&&window.innerHeight&&(a=window.innerWidth,b=window.innerHeight);window.visualViewport&&window.visualViewport.width&&window.visualViewport.height&&(a=window.visualViewport.width,
@@ -34,27 +35,27 @@ b=window.visualViewport.height);document.documentElement&&document.documentEleme
34
35
  pui.normalizeURL=function(a,b){return null==a||"string"!=typeof a?"":1==b&&null==window.puiMobileClient||"http:"==a.substr(0,5).toLowerCase()||"https:"==a.substr(0,6).toLowerCase()||"data:"==a.substr(0,5).toLowerCase()?a:null!=pui.serverURL?pui.serverURL+a:window.cordova&&"/"==a.substr(0,1)?a.substr(1):a};
35
36
  pui.animate=function(a){var b=a.element;"string"==typeof b&&(b=document.getElementById(b));if(null!=b){var c=a.effect;if("fly in left"==c||"fly in right"==c||"fly out left"==c||"fly out right"==c)var e="left";else if("fly in up"==c||"fly in down"==c||"fly out up"==c||"fly out down"==c)e="top";else if("fade in"==c||"fade out"==c)e="opacity";else if(e=a.properties,null==e&&(e=a.property,null==e))return;"string"==typeof e&&(e=[e]);var d=a.duration;null==d&&(d="500ms");"s"!=d.substr(d.length-1,1)&&(d+=
36
37
  "s");var g=1E3*parseInt(d);2<d.length&&"ms"==d.substr(d.length-2,2)&&(g=parseInt(d));var f=a.type;null==f&&(f="ease");var k=a.from,h=a.to;switch(c){case "fly in right":k=-b.offsetWidth;k+="px";h="0px";break;case "fly in left":k=b.offsetWidth;k+="px";h="0px";break;case "fly out left":h=-b.offsetWidth;h+="px";k="0px";break;case "fly out right":h=b.offsetWidth;h+="px";k="0px";break;case "fly out down":h=b.offsetHeight;h+="px";k="0px";break;case "fly out up":h=-b.offsetHeight;h+="px";k="0px";break;case "fly in up":k=
37
- b.offsetHeight;k+="px";h="0px";break;case "fly in down":k=-b.offsetHeight;k+="px";h="0px";break;case "fade in":k="0";h="100";break;case "fade out":k="100",h="0"}if(null!=h){var m="";for(c=0;c<e.length;c++){var n=e[c];""!=m&&(m+=", ");m+=n+" "+d+" "+f}var q=["transition","MozTransition","WebkitTransition","msTransition","OTransition"];if(null!=k){if("string"==typeof k||"number"==typeof k)k=[k];for(c=0;c<e.length;c++)n=e[c],b.style[n]=k[c]}setTimeout(function(){for(var t=0;t<q.length;t++)b.style[q[t]]=
38
- m;setTimeout(function(){if("string"==typeof h||"number"==typeof h)h=[h];for(var u=0;u<e.length;u++)b.style[e[u]]=h[u];setTimeout(function(){for(var p=0;p<q.length;p++)b.style[q[p]]="";if(null!=a.oncomplete)a.oncomplete()},g)},1)},1)}}};pui.getActiveElement=function(){return"genie"==context?lastActiveElement:pui.activeElement};pui.fieldExit=function(a){var b=pui.getActiveElement();if(null!=b){var c=!1;null!=a&&(c=!0);"genie"==context?fieldExit(b,c):pui.ra(b)}};pui.gotoNextElement=function(a){R(a,!0)};
38
+ b.offsetHeight;k+="px";h="0px";break;case "fly in down":k=-b.offsetHeight;k+="px";h="0px";break;case "fade in":k="0";h="100";break;case "fade out":k="100",h="0"}if(null!=h){var n="";for(c=0;c<e.length;c++){var m=e[c];""!=n&&(n+=", ");n+=m+" "+d+" "+f}var q=["transition","MozTransition","WebkitTransition","msTransition","OTransition"];if(null!=k){if("string"==typeof k||"number"==typeof k)k=[k];for(c=0;c<e.length;c++)m=e[c],b.style[m]=k[c]}setTimeout(function(){for(var t=0;t<q.length;t++)b.style[q[t]]=
39
+ n;setTimeout(function(){if("string"==typeof h||"number"==typeof h)h=[h];for(var u=0;u<e.length;u++)b.style[e[u]]=h[u];setTimeout(function(){for(var p=0;p<q.length;p++)b.style[q[p]]="";if(null!=a.oncomplete)a.oncomplete()},g)},1)},1)}}};pui.getActiveElement=function(){return"genie"==context?lastActiveElement:pui.activeElement};pui.fieldExit=function(a){var b=pui.getActiveElement();if(null!=b){var c=!1;null!=a&&(c=!0);"genie"==context?fieldExit(b,c):pui.ra(b)}};pui.gotoNextElement=function(a){R(a,!0)};
39
40
  pui.gotoPreviousElement=function(a){R(a,!1)};
40
41
  function R(a,b){b=b?1:-1;var c=document.querySelectorAll("INPUT,SELECT,TEXTAREA"),e=c.length;if(!(2>e)){a=Array.prototype.indexOf.call(c,a);for(var d=a+b,g;d!==a;)if(d===e)d=0;else if(-1===d)d=e-1;else{var f=g=c[d];null!=g&&null!=g.comboBoxWidget&&(f=g.comboBoxWidget.T());null!=g&&null!=g.s&&(f=g.s.T());if(f.readOnly||f.disabled||"hidden"===f.style.visibility||"-1"===f.tabIndex||!f.clientHeight||!f.clientWidth)d+=b;else{try{f.focus();if(document.activeElement!=f){d+=b;continue}setTimeout(function(){pui["highlight on focus"]&&
41
42
  "function"==typeof f.select&&f.select();pui.Ga(null,f)},0)}catch(k){}break}}}}pui.showCalendar=function(a){var b=a;"string"==typeof a&&(b=document.getElementById(a));if(null!=b&&"object"==typeof b){var c=b.calimg;null!=c&&(null!=c.click&&"function"==typeof c.click?c.click():null!=c.onclick&&"function"==typeof c.onclick&&setTimeout(function(){c.onclick()},250))}};pui.getComputedStyle=function(a){var b=null;window.getComputedStyle?b=window.getComputedStyle(a):a.currentStyle&&(b=a.currentStyle);return b};
42
- pui.upload=function(a,b){var c,e=a.dir,d=!0===a.overwrite,g;"number"==typeof a.slimit&&(g=a.slimit);var f;"number"==typeof a.flimit&&(f=a.flimit);var k="";"string"==typeof a.altname&&(k=a.altname);var h;typeof a.allowedTypes&&a.allowedTypes instanceof Array&&(h=a.allowedTypes);null==f&&(f=a.files.length);if(null==g||null==h){var m=[];for(c=0;c<a.files.length;c++){var n=a.files[c];var q="undefined"!=typeof n.type&&""!=n.type?n.type:"application/octet-stream";-1==pui.na(m,q)&&m.push(q);n=n.data&&n.data instanceof
43
- ArrayBuffer?n.data.byteLength:n.size;n=Math.ceil(n/1048576);if(null==t||n>t)var t=n}null==g&&(g=t);null==h&&(h=m)}t=N("PUI0009109.PGM");t+="?AUTH="+encodeURIComponent(pui.F?pui.F:pui.appJob.auth);"widget"!==a.mode&&(t+="&mode=ajax");a.id&&(t+="&id="+encodeURIComponent(a.id));t+="&r="+Math.floor(1E9*Math.random());pui.isCloud&&(t+="&workspace_id="+pui.cloud.ws.id);m=new FormData;m.append("dir",e);m.append("overwrite",d?"1":"0");m.append("flimit",f);m.append("slimit",g);m.append("altname",k);"string"==
44
- typeof a.generateNames&&m.append("generateNames",a.generateNames);for(c=0;c<h.length;c++)m.append("type",h[c]);for(c=0;c<a.files.length;c++){n=a.files[c];if(n.data&&n.data instanceof ArrayBuffer){try{var u=new Blob([n.data])}catch(w){e=new window.WebKitBlobBuilder,e.append(n.data),u=e.getBlob()}m.append("file",u)}else m.append("file",n);m.append("filename",n.name)}var p=new XMLHttpRequest;p.open("POST",t,!0);p.onreadystatechange=function(){if(4==p.readyState){var w=!0;if(200==p.status){try{var l=
43
+ pui.upload=function(a,b){var c,e=a.dir,d=!0===a.overwrite,g;"number"==typeof a.slimit&&(g=a.slimit);var f;"number"==typeof a.flimit&&(f=a.flimit);var k="";"string"==typeof a.altname&&(k=a.altname);var h;typeof a.allowedTypes&&a.allowedTypes instanceof Array&&(h=a.allowedTypes);null==f&&(f=a.files.length);if(null==g||null==h){var n=[];for(c=0;c<a.files.length;c++){var m=a.files[c];var q="undefined"!=typeof m.type&&""!=m.type?m.type:"application/octet-stream";-1==pui.na(n,q)&&n.push(q);m=m.data&&m.data instanceof
44
+ ArrayBuffer?m.data.byteLength:m.size;m=Math.ceil(m/1048576);if(null==t||m>t)var t=m}null==g&&(g=t);null==h&&(h=n)}t=N("PUI0009109.PGM");t+="?AUTH="+encodeURIComponent(pui.F?pui.F:pui.appJob.auth);"widget"!==a.mode&&(t+="&mode=ajax");a.id&&(t+="&id="+encodeURIComponent(a.id));t+="&r="+Math.floor(1E9*Math.random());pui.isCloud&&(t+="&workspace_id="+pui.cloud.ws.id);n=new FormData;n.append("dir",e);n.append("overwrite",d?"1":"0");n.append("flimit",f);n.append("slimit",g);n.append("altname",k);"string"==
45
+ typeof a.generateNames&&n.append("generateNames",a.generateNames);for(c=0;c<h.length;c++)n.append("type",h[c]);for(c=0;c<a.files.length;c++){m=a.files[c];if(m.data&&m.data instanceof ArrayBuffer){try{var u=new Blob([m.data])}catch(w){e=new window.WebKitBlobBuilder,e.append(m.data),u=e.getBlob()}n.append("file",u)}else n.append("file",m);n.append("filename",m.name)}var p=new XMLHttpRequest;p.open("POST",t,!0);p.onreadystatechange=function(){if(4==p.readyState){var w=!0;if(200==p.status){try{var l=
45
46
  eval("("+p.responseText+")")}catch(v){w=!1;var r="Server response missing or invalid."}l&&(w=l.success,w||(l.key?(r=pui.getLanguageText("runtimeMsg","upload "+l.key),"file limit"==l.key&&(r=r.replace("&1",f)),"size limit"==l.key&&(r=r.replace("&1",g))):r=l.error))}else w=!1,r=p.status+" - "+p.statusText+".",0==p.status&&""==p.statusText&&(r="The FILE could not be found in the system.");"function"==typeof b&&b(w,r)}};"function"==typeof a.onabort&&(p.onabort=a.onabort);"function"==typeof a.onprogress&&
46
- "upload"in p&&(p.upload.onprogress=a.onprogress);"function"==typeof a.onload&&(p.onload=a.onload);p.send(m);return p};pui.getCookie=function(a){var b=document.cookie.split(";"),c="",e;for(e=0;e<b.length;e++){var d=b[e].split("=");var g=d[0].replace(/^\s+|\s+$/g,"");if(g==a)return 1<d.length&&(c=unescape(d[1].replace(/^\s+|\s+$/g,""))),c}return null};
47
+ "upload"in p&&(p.upload.onprogress=a.onprogress);"function"==typeof a.onload&&(p.onload=a.onload);p.send(n);return p};pui.getCookie=function(a){var b=document.cookie.split(";"),c="",e;for(e=0;e<b.length;e++){var d=b[e].split("=");var g=d[0].replace(/^\s+|\s+$/g,"");if(g==a)return 1<d.length&&(c=unescape(d[1].replace(/^\s+|\s+$/g,""))),c}return null};
47
48
  pui.setCookie=function(a,b,c,e,d,g,f){var k=new Date;k.setTime(k.getTime());c&&(c*=864E5);k=new Date(k.getTime()+c);document.cookie=a+"="+escape(b)+(c?";expires="+k.toGMTString():"")+(e?";path="+e:"")+(d?";domain="+d:"")+(g?";secure":"")+(f?";SameSite="+f:"")};pui.deleteCookie=function(a,b,c,e,d){pui.getCookie(a)&&(document.cookie=a+"="+(b?";path="+b:"")+(c?";domain="+c:"")+";expires=Thu, 01-Jan-1970 00:00:01 GMT"+(e?";Secure":"")+(d?";SameSite="+d:""))};
48
49
  pui.refresh=function(a){null==a&&(a={});var b=a.url;a=a.skin;pui.setCookie("puiRefreshId",pui.psid,null,"/",null,null,"Strict");pui.skipConfirm=!0;pui.shutdownOnClose=!1;pui.confirmOnClose=!1;if(null!=a){a="skin="+encodeURIComponent(a);b=window.location.href;var c=b.split("?");b=c[0];c=c[1];null==c&&(c="");c=c.split("&");for(var e=!1,d=0;d<c.length;d++)5<=c[d].length&&"skin="==c[d].substr(0,5).toLowerCase()&&(c[d]=a,e=!0);e||(1==c.length&&""==c[0]?c[0]=a:c.push(a));c=c.join("&");b=b+"?"+c}null!=b?
49
50
  window.location.href=b:window.location.reload()};
50
51
  pui.downloadURL=function(a){if(null==pui||null==pui.appJob||null==pui.appJob.auth||""==pui.appJob.auth)return pui.is_ie?"":"data:text/html,<!DOCTYPE html><html><body><p>To download, please connect to a Profound UI session.</p></body></html>";var b=!0===a.inline;if(null==a.id)return"";var c=N("PUI0009110.PGM");c+="?id="+encodeURIComponent(a.id);null!=a.contentType&&(c+="&type="+encodeURIComponent(a.contentType));b&&(c+="&inline=1");c=c+"&usehttprc=0&AUTH="+encodeURIComponent(pui.F?pui.F:pui.appJob.auth);
51
52
  return c+="&r="+Math.floor(1E9*Math.random())};pui.download=function(a){var b=pui.downloadURL(a);a=!0===a.inline;if(null==pui||null==pui.appJob||null==pui.appJob.auth||""==pui.appJob.auth)a=!0;a?pui.openURL(b):pui.link(b)};
52
- pui.downloadFile=function(a){if("undefined"===typeof a||null==a||"string"!==typeof a.id||1>a.id.length)pui.alert("Error downloading file. \n\n No file path given",null,"Error","Close");else{var b=pui.downloadURL(a),c=a.id,e=new XMLHttpRequest;e.responseType="blob";e.open("GET",b,!0);e.send();var d=null,g=null,f=null,k=null;e.onprogress=function(h){var m=pui.extractFileNameFromContentDisposition(e.getResponseHeader("Content-Disposition"));if(c.split("/").pop()==m||"error.txt"!=m)"undefined"===typeof e.onprogress.diaglogShown&&
53
+ pui.downloadFile=function(a){if("undefined"===typeof a||null==a||"string"!==typeof a.id||1>a.id.length)pui.alert("Error downloading file. \n\n No file path given",null,"Error","Close");else{var b=pui.downloadURL(a),c=a.id,e=new XMLHttpRequest;e.responseType="blob";e.open("GET",b,!0);e.send();var d=null,g=null,f=null,k=null;e.onprogress=function(h){var n=pui.extractFileNameFromContentDisposition(e.getResponseHeader("Content-Disposition"));if(c.split("/").pop()==n||"error.txt"!=n)"undefined"===typeof e.onprogress.diaglogShown&&
53
54
  (e.onprogress.diaglogShown=!0,d=document.createElement("dialog"),document.body.appendChild(d),g=document.createElement("p"),d.appendChild(g),f=document.createElement("button"),f.innerHTML="OK",f.onclick=function(){d.close();d.remove()},k=document.createElement("button"),k.innerHTML="Cancel",k.id="cancelButton",k.onclick=function(){e.abort();d.close();d.remove()},d.appendChild(k),g.innerHTML="Downloading file: "+c+"<br> Starting download...",d.showModal(),e.onprogress.lastTime=Date.now()),Date.now()>
54
55
  e.onprogress.lastTime+2E3&&(g.innerHTML="Downloading file: "+c+"<br>"+h.type+" "+(h.loaded/1048576).toFixed(4)+" mb loaded",e.onprogress.lastTime=Date.now())};e.onloadend=function(){null!=d&&(d.querySelector("button[id='cancelButton']").remove(),d.appendChild(f),g.innerHTML="File "+c+" downloaded successfully.")};e.onreadystatechange=function(){if(4==e.readyState&&200==e.status){var h=pui.extractFileNameFromContentDisposition(e.getResponseHeader("Content-Disposition"));if(c.split("/").pop()!=h&&"error.txt"==
55
- h){var m=new FileReader;m.onload=function(){pui.alert("Error downloading file: "+c+"\n\n"+m.result,null,"Error","Close");console.log(m.result)};m.readAsText(e.response)}else{var n=null;if("string"===typeof a.contentType&&0<a.contentType.length)n=a.contentType;else if(n=e.getResponseHeader("Content-Type").split(";")[0],"string"===typeof n&&"application/octet-stream"==n){var q=h.split(".").pop();if("string"===typeof q)switch(q.toLowerCase()){case "pdf":n="application/pdf";break;case "txt":n="text/plain";
56
- break;case "csv":n="text/csv";break;case "json":n="application/json";break;case "xml":n="application/xml";break;case "html":n="text/html";break;case "htm":n="text/html";break;case "jpg":n="image/jpeg";break;case "jpeg":n="image/jpeg";break;case "png":n="image/png";break;case "gif":n="image/gif"}}q="application/pdf text/plain text/csv application/json application/xml text/html image/jpeg image/png image/gif".split(" ");var t=new File([e.response],h,{type:n});t=URL.createObjectURL(t);var u=document.createElement("a");
57
- "boolean"===typeof a.inline&&a.inline&&q.includes(n)?u.target="_blank":u.download=h;u.name=h;u.href=t;document.body.appendChild(u);u.dispatchEvent(new MouseEvent("click",{bubbles:!0,cancelable:!0,view:window}));document.body.removeChild(u)}}}}};pui.extractFileNameFromContentDisposition=function(a){a=/filename[^;=\n]*=((['"]).*?\2|[^;\n]*)/.exec(a);return null!=a&&a[1]?a[1].replace(/['"]/g,""):null};
56
+ h){var n=new FileReader;n.onload=function(){pui.alert("Error downloading file: "+c+"\n\n"+n.result,null,"Error","Close");console.log(n.result)};n.readAsText(e.response)}else{var m=null;if("string"===typeof a.contentType&&0<a.contentType.length)m=a.contentType;else if(m=e.getResponseHeader("Content-Type").split(";")[0],"string"===typeof m&&"application/octet-stream"==m){var q=h.split(".").pop();if("string"===typeof q)switch(q.toLowerCase()){case "pdf":m="application/pdf";break;case "txt":m="text/plain";
57
+ break;case "csv":m="text/csv";break;case "json":m="application/json";break;case "xml":m="application/xml";break;case "html":m="text/html";break;case "htm":m="text/html";break;case "jpg":m="image/jpeg";break;case "jpeg":m="image/jpeg";break;case "png":m="image/png";break;case "gif":m="image/gif"}}q="application/pdf text/plain text/csv application/json application/xml text/html image/jpeg image/png image/gif".split(" ");var t=new File([e.response],h,{type:m});t=URL.createObjectURL(t);var u=document.createElement("a");
58
+ "boolean"===typeof a.inline&&a.inline&&q.includes(m)?u.target="_blank":u.download=h;u.name=h;u.href=t;document.body.appendChild(u);u.dispatchEvent(new MouseEvent("click",{bubbles:!0,cancelable:!0,view:window}));document.body.removeChild(u)}}}}};pui.extractFileNameFromContentDisposition=function(a){a=/filename[^;=\n]*=((['"]).*?\2|[^;\n]*)/.exec(a);return null!=a&&a[1]?a[1].replace(/['"]/g,""):null};
58
59
  pui.focusOnContainer=function(){window.parent!=window&&pui.ha(window.parent)&&window.parent.noderun||setTimeout(function(){null==pui.g&&(pui.g=document.createElement("input"),pui.g.type=pui.is_touch?"button":"text",pui.g.readOnly=!0,pui.g.style.position="absolute",pui.g.style.left="-999px",pui.g.style.top="-999px",pui.g.style.width="10px",pui.g.style.borderStyle="none",pui.g.style.backgroundColor="transparent",pui.runtimeContainer&&pui.runtimeContainer.appendChild(pui.g));pui.W=!0;pui.g.focus();setTimeout(function(){pui.W=
59
60
  !1},0)},1)};pui.addCSS=function(a){var b=document.getElementsByTagName("head")[0],c=document.createElement("style");c.type="text/css";pui.is_old_ie?c.styleSheet.cssText=a:c.innerHTML=a;b.appendChild(c)};pui.loadCSS=function(a){if(null!=pui.U(a))return!1;var b=document.getElementsByTagName("head")[0],c=document.createElement("link");c.setAttribute("rel","stylesheet");c.setAttribute("type","text/css");c.setAttribute("media","screen");c.setAttribute("href",pui.normalizeURL(a));b.appendChild(c);return!0};
60
61
  pui.removeCSS=function(a){var b=document.getElementsByTagName("head")[0],c=pui.U(a);if(null==c){c=b.getElementsByTagName("style");for(var e=0;e<c.length;e++){var d=c[e];if(d.innerHTML==a||null!=d.styleSheet&&d.styleSheet.cssText==a)return b.removeChild(d),!0}return!1}b.removeChild(c);return!0};
@@ -67,36 +68,36 @@ pui.ha(window.parent)&&window.parent.noderun?console.log("Suppressed alert: "+a)
67
68
  pui.set=function(a,b){a="object"==typeof a?a:document.getElementById(a);if(null!=a){if("DIV"==a.tagName)null!=a.M?a.M.setValue(b):null!=a.comboBoxWidget?a.comboBoxWidget.setValue(b):null!=a.s?a.s.setValue(b):a.button&&a.button.fa?a.button.fa.innerHTML=b:a.pui&&a.pui.widget?applyProperty(a,"value",b):a.innerHTML=b;else if("INPUT"==a.tagName||"SELECT"==a.tagName||"TEXTAREA"==a.tagName)"INPUT"==a.tagName&&"checkbox"==a.type?a.checked="boolean"==typeof b?b:null!=a.checkedValue&&b==a.checkedValue?!0:!1:
68
69
  ("genie"==context&&b!=a.value&&pui.m.Ca(a),a.value=b,null!=a.O&&(a.O.value=b));if("dspf"==context||pui.ga&&null==a.A){a.modified=!0;pui.Ja(a);var c=a.Ka;null!=a.id&&-1==a.id.indexOf(".")&&null!=a.R&&(pui.qa[a.R]=!0);null!=c&&(c.za(),c.sa=!0,pui.Fa(a,c.ua()))}"genie"==context&&null!=a.A&&null!=a.A.idx&&(pui.response[a.A.idx]=a);pui.oa(a);a.pui&&a.pui.properties&&(a.pui.properties.value=b)}};
69
70
  pui.getActiveContainer=function(){if("genie"==context){for(var a=1,b=document.getElementById("window"+a);b;){var c=document.getElementById("window"+ ++a);if(c)b=c;else break}if(b)return b}else if("dspf"==context&&pui.Y)return pui.Y;return pui.runtimeContainer};pui.getDisplayType=function(){return pui.ga?"5250-handler":"dspf"==context?"rdf":"5250"};
70
- function S(a){function b(){if(!(n>=m.length)){u=m[n].command;p=m[n].wait;n+=1;if("function"==typeof pui.onPCCommand)try{var l=pui.onPCCommand(u,p);if(null==l||1==l){setTimeout(b,0);return}}catch(v){showFailureMessage(u)}t="?cmd="+encodeURIComponent(u)+"&wait="+(p?"1":"0");if(1==f||2==f)k?(w.params.cmd=u,w.params.sign=1,w.params.hashalg="string"===typeof pui["pccmd hash sign algorithm"]?pui["pccmd hash sign algorithm"].toUpperCase():"SHA-512",w.handler=d,F(w)):c("");else if(3==f)w.params.cmd=u,w.handler=
71
- e,F(w);else{if(0==n&&0<m.length){l=[];for(var r=0;r<m.length;r++)l.push("("+m[r].pa+")");u=l.join(" && ")}try{h.runCommand(u)}catch(v){l='Unable to execute "'+u+'".\n\n',null!=v&&(l+=v.name+":\n\n"+v.message+"."),alert(l)}}}}function c(l){if(2==f){var r=new Image;r.onload=b;r.onerror=function(){console.log("PC Command Listener image mode failure.");g(u)};r.src=q+t+"&type=image&rnd="+String(Math.random())+String((new Date).getTime())+l}else{l=new pui.Ajax(q+t+l);l.method="GET";l.async=p?!1:!0;l.suppressAlert=
71
+ function S(a){function b(){if(!(m>=n.length)){u=n[m].command;p=n[m].wait;m+=1;if("function"==typeof pui.onPCCommand)try{var l=pui.onPCCommand(u,p);if(null==l||1==l){setTimeout(b,0);return}}catch(v){showFailureMessage(u)}t="?cmd="+encodeURIComponent(u)+"&wait="+(p?"1":"0");if(1==f||2==f)k?(w.params.cmd=u,w.params.sign=1,w.params.hashalg="string"===typeof pui["pccmd hash sign algorithm"]?pui["pccmd hash sign algorithm"].toUpperCase():"SHA-512",w.handler=d,F(w)):c("");else if(3==f)w.params.cmd=u,w.handler=
72
+ e,F(w);else{if(0==m&&0<n.length){l=[];for(var r=0;r<n.length;r++)l.push("("+n[r].pa+")");u=l.join(" && ")}try{h.runCommand(u)}catch(v){l='Unable to execute "'+u+'".\n\n',null!=v&&(l+=v.name+":\n\n"+v.message+"."),alert(l)}}}}function c(l){if(2==f){var r=new Image;r.onload=b;r.onerror=function(){console.log("PC Command Listener image mode failure.");g(u)};r.src=q+t+"&type=image&rnd="+String(Math.random())+String((new Date).getTime())+l}else{l=new pui.Ajax(q+t+l);l.method="GET";l.async=p?!1:!0;l.suppressAlert=
72
73
  !0;l.onfail=function(v){200!=v.l()&&(console.log("PC Command Listener comm. failure: "+v.B()),g(u))};l.onsuccess=function(v){try{var y=JSON.parse(v.j());if(!y.success&&"string"===typeof y.error){console.log("PC Command Listener failure.",y.error);g(u);return}}catch(z){}b()};try{l.send()}catch(v){console.log("PC Command Listener failure.",v),g(u)}}}function e(l,r){try{if(r)throw r;if(null==l)throw Error("Empty response from PCCMD crypt program.");if(null!=l.error||"string"===typeof l.error&&0<l.error.length)throw Error("PCCMD crypt error: "+
73
74
  String(l.error));if("string"!==typeof l.cmd||0==l.cmd.length)throw Error("PCCMD crypt response was missing a command.");var v="puilaunch:"+encodeURIComponent(l.cmd),y=document.createElement("iframe");y.style.display="none";y.src=v;document.body.appendChild(y);setTimeout(function(){null!=y&&null!=y.parentNode&&document.body.removeChild(y);y=null;b()},5E3)}catch(z){console.log(z)}}function d(l,r){try{if(r)throw r;if("object"!==typeof l||null===l)throw Error("Empty response");if(!0!==l.success)throw"string"===
74
75
  typeof l.error&&0<l.error.length?l.error:"Unknown error";r="";"string"===typeof l.sig&&0<l.sig.length&&(r="&sig="+encodeURIComponent(l.sig));c(r)}catch(v){console.log(v),g(u)}}function g(l){console.log("Command: "+l);l=pui.getLanguageText("runtimeMsg","pccommand error");!1!==pui["alert pccommand errors"]?alert(l):console.log(l);console.log("Visit https://docs.profoundlogic.com/x/aQFK for more information on supporting STRPCCMD.")}var f=1,k=!1;pui["use pc listener"]&&(f=1);null!=window.HTTPS&&"ON"==
75
76
  window.HTTPS&&1==f&&(f=2);pui["pc listener mode"]&&(f=parseInt(pui["pc listener mode"]));if("string"==typeof pui["pc command mode"])switch(pui["pc command mode"]){case "applet":f=0;break;case "listener":case "listener_m1":f=1;break;case "listener_m1s":f=1;k=!0;break;case "listener_m2":f=2;break;case "listener_m2s":f=2;k=!0;break;case "launcher":f=3;break;default:f=1,console.log("Unsupported pc command mode:",pui["pc command mode"])}if(0==f){var h=document.getElementById("PCCommandApplet");if(!h){pui.I=
76
- a;loadPCCommandApplet("runCommandCb");return}}var m=[],n=0;m="string"==typeof a?[{command:a,wait:!1}]:a;a=parseInt(pui["pc listener port"],10);isNaN(a)&&(a="80");var q="http://localhost:"+a+"/",t="",u,p,w={url:N("PUI0009117.pgm"),method:"post",params:{auth:pui.appJob&&pui.appJob.auth?pui.appJob.auth:""},async:!0};b()}window.runCommandCb=function(){S(pui.I);pui.I=null};pui.runPCCommand=S;
77
+ a;loadPCCommandApplet("runCommandCb");return}}var n=[],m=0;n="string"==typeof a?[{command:a,wait:!1}]:a;a=parseInt(pui["pc listener port"],10);isNaN(a)&&(a="80");var q="http://localhost:"+a+"/",t="",u,p,w={url:N("PUI0009117.pgm"),method:"post",params:{auth:pui.appJob&&pui.appJob.auth?pui.appJob.auth:""},async:!0};b()}window.runCommandCb=function(){S(pui.I);pui.I=null};pui.runPCCommand=S;
77
78
  pui.isServerBusy=function(){if("undefined"==typeof context)return!1;if("dspf"==context&&!1===pui.G||"genie"==context&&!0===pui.m.u)return!0;for(var a=document.getElementsByTagName("iframe"),b=0;b<a.length;b++){var c=a[b].contentWindow;if(null!=c){var e=null;try{e=c.pui}catch(d){}if(null!=e&&"object"===typeof e&&"function"===typeof e.isServerBusy&&e.isServerBusy())return!0}}return!1};
78
79
  pui.showLastError=function(){if(0==errors.length)alert("No errors have been reported.");else{var a=errors.length-1;alert("Operation: "+errors[a].Da+"\nId: "+errors[a].id+"\n\nMessage: "+errors[a].text+"\n"+errors[a].Ia)}};
79
80
  pui.editCode=function(a,b){function c(x,A){var E=" nn/n nn/nn nn/nn/n nn/nn/nn nnn/nn/nn nn/nn/nnnn nnn/nn/nnnn".split(" ");"*ymd"===k.dateEdit&&(E[8]="nnnn/nn/nn",E[9]="nnnnn/nn/nn");E=E[z];x=String(x);x=x.replace(".","");x=x.replace(",","");x=x.replace("-","");x="0000000000"+x;x=x.substr(x.length-A);A="/";null!=k.dateEditSeparator&&(A=k.dateEditSeparator);for(var K=!1,P=0,Q="",I=0;I<E.length;I++){var H=E.substr(I,1),T=E.substr(I+1,1);if("/"===H||"/"===T)K=!0;"/"===H?H=A:(H=x.substr(P,1),P+=1,
80
- "0"===H?K||(H=" "):K=!0);Q+=H}return Q}function e(x,A,E){for(x+="";x.length<A;)x+=E;return x}var d=null,g=0,f=null,k={},h=2;"number"===typeof arguments[h]&&(d=arguments[h],h++,"number"===typeof arguments[h]&&(g=arguments[h],h++));"string"===typeof arguments[h]&&(f=arguments[h],h++);"object"===typeof arguments[h]&&(k=arguments[h],h++);var m=!1;"*astfill"===f&&(m=!0,f=null);var n=!1,q=null,t=!1,u=h=!1;h=" ";pui.appJob&&"string"===typeof pui.appJob.decimalFormat&&(h=pui.appJob.decimalFormat);var p="I"===
81
- h||"J"===h,w="J"===h;null!=k.decimalEdit&&(p=","===k.decimalEdit||"0,"===k.decimalEdit,w="0."===k.decimalEdit||"0,"===k.decimalEdit);"1"<=b&&"4">=b&&(q="999.00");"A"<=b&&"D">=b&&(q="999.00CR");"J"<=b&&"M">=b&&(q="999.00-");"N"<=b&&"Q">=b&&(q="-999.00");if("1"==b||"A"==b||"J"==b||"N"==b||"2"==b||"B"==b||"K"==b||"O"==b)t=!0;h="1"==b||"A"==b||"J"==b||"N"==b||"3"==b||"C"==b||"L"==b||"P"==b?!0:!1;"Z"==b&&(q="999.00");if("X"===b||"Z"===b)u=!0;"X"===b&&(n=!0);"5"<=b&&"9">=b&&pui.alert("User-defined edit code not supported: "+
81
+ "0"===H?K||(H=" "):K=!0);Q+=H}return Q}function e(x,A,E){for(x+="";x.length<A;)x+=E;return x}var d=null,g=0,f=null,k={},h=2;"number"===typeof arguments[h]&&(d=arguments[h],h++,"number"===typeof arguments[h]&&(g=arguments[h],h++));"string"===typeof arguments[h]&&(f=arguments[h],h++);"object"===typeof arguments[h]&&(k=arguments[h],h++);var n=!1;"*astfill"===f&&(n=!0,f=null);var m=!1,q=null,t=!1,u=h=!1;h=" ";pui.appJob&&"string"===typeof pui.appJob.decimalFormat&&(h=pui.appJob.decimalFormat);var p="I"===
82
+ h||"J"===h,w="J"===h;null!=k.decimalEdit&&(p=","===k.decimalEdit||"0,"===k.decimalEdit,w="0."===k.decimalEdit||"0,"===k.decimalEdit);"1"<=b&&"4">=b&&(q="999.00");"A"<=b&&"D">=b&&(q="999.00CR");"J"<=b&&"M">=b&&(q="999.00-");"N"<=b&&"Q">=b&&(q="-999.00");if("1"==b||"A"==b||"J"==b||"N"==b||"2"==b||"B"==b||"K"==b||"O"==b)t=!0;h="1"==b||"A"==b||"J"==b||"N"==b||"3"==b||"C"==b||"L"==b||"P"==b?!0:!1;"Z"==b&&(q="999.00");if("X"===b||"Z"===b)u=!0;"X"===b&&(m=!0);"5"<=b&&"9">=b&&pui.alert("User-defined edit code not supported: "+
82
83
  b+".");"1"<=b&&"9">=b||"A"<=b&&"D">=b||"J"<=b&&"Q">=b||"X"<=b&&"Z">=b||pui.alert("Invalid edit code: "+b+".");var l=(a||0)+"",r=parseFloat(l,10)||0;var v=l.replace(/\..*/,"");"-0"===v&&(v="-");""!=v&&"-"!=v||!w||(v="0");var y=l;-1==y.indexOf(".")&&(y+=".");y=y.replace(/.*\./,"");var z=v.length;3>z&&(z=3);var D=y.length;"number"===typeof d&&(z=d);"number"===typeof g&&(D=g);if("Y"==b)return(3>z||9<z)&&pui.alert("Length not valid for edit code Y."),c(r,z);d=".";p&&(d=",");u&&(d="");0<D&&(y=e(y,D,"0"),
83
- "0"!==v||w||(v=""),l=v+d+y);var L=" ";n&&(L="0");m&&(L="*");if(t){for(g=/(\d+)(\d{3})/;g.test(v);)v=v.replace(g,"$1"+(p?".":",")+"$2");l=v+(0<D?d+y:"")}p=0>r;l=l.replace(/-/g,"");"(999.00)"===q?p&&(l="("+l+")"):"999.00-"===q?l=p?l+"-":l+" ":"999.00CR"===q?l=p?l+"CR":l+" ":"-999.00"===q&&p&&(l="-"+l);f&&(l="EUR"==f?l+" EUR":"$"==f?"-"==l.substr(0,1)?"-"+f+l.substr(1):f+l:f+l);h||0===r&&(l="");(function(){var x=z;x+=D&&!u?1:0;t&&(x+=parseInt((z-D-1)/3));"999.00CR"===q&&(x+=2);"999.00-"===q&&(x+=1);
84
+ "0"!==v||w||(v=""),l=v+d+y);var L=" ";m&&(L="0");n&&(L="*");if(t){for(g=/(\d+)(\d{3})/;g.test(v);)v=v.replace(g,"$1"+(p?".":",")+"$2");l=v+(0<D?d+y:"")}p=0>r;l=l.replace(/-/g,"");"(999.00)"===q?p&&(l="("+l+")"):"999.00-"===q?l=p?l+"-":l+" ":"999.00CR"===q?l=p?l+"CR":l+" ":"-999.00"===q&&p&&(l="-"+l);f&&(l="EUR"==f?l+" EUR":"$"==f?"-"==l.substr(0,1)?"-"+f+l.substr(1):f+l:f+l);h||0===r&&(l="");(function(){var x=z;x+=D&&!u?1:0;t&&(x+=parseInt((z-D-1)/3));"999.00CR"===q&&(x+=2);"999.00-"===q&&(x+=1);
84
85
  "-999.00"===q&&(x+=1);"string"===typeof f&&(x+=f.length);var A=l;for(A+="";A.length<x;)A=L+A;l=A})();return l};
85
- pui.editWord=function(a,b,c){function e(){if(0<w.length){var v=w.substr(w.length-1,1);w=w.substr(0,w.length-1);"0"==v&&0==w.length&&r&&(v=l?"*":" ")}else v="0",r&&(v=" "),l&&(v="*");return v}var d;a=String(a);var g={};"object"===typeof c&&(g=c);c="$";null!=g.currencySymbol&&(c=g.currencySymbol);var f=b.indexOf("0")+1,k=b.indexOf("*")+1;if(0==f||0!=k&&k<f)f=k;var h=-1;for(d=b.length-1;0<=d;--d)if(d+1==f||" "==b.substr(d,1)){h=d;break}k=b.substr(0,h+1);var m="",n="",q=!1,t=!1,u=0<=b.substr(h+1).indexOf("-")||
86
- 0<=b.substr(h+1).indexOf("CR");for(d=h+1;d<b.length;d++){var p=b.substr(d,1);if("CR"==b.substr(d,2))t=!0,d++;else if("-"==p)t=!0;else if("&"!=p&&("*"!=p||t))if("A"<=p.toUpperCase()&&"Z">=p.toUpperCase()&&u&&!t)b=b.substr(0,d)+" "+b.substr(d+1);else{m=b.substring(h+1,d);n=b.substr(d);q=!0;break}}q||(m=b.substr(h+1));p=".";d=" ";pui.appJob&&"string"===typeof pui.appJob.decimalFormat&&(d=pui.appJob.decimalFormat);"string"===typeof g.decimalFormat&&(d=g.decimalFormat);if("I"===d||"J"===d)p=",";d=0;p=
86
+ pui.editWord=function(a,b,c){function e(){if(0<w.length){var v=w.substr(w.length-1,1);w=w.substr(0,w.length-1);"0"==v&&0==w.length&&r&&(v=l?"*":" ")}else v="0",r&&(v=" "),l&&(v="*");return v}var d;a=String(a);var g={};"object"===typeof c&&(g=c);c="$";null!=g.currencySymbol&&(c=g.currencySymbol);var f=b.indexOf("0")+1,k=b.indexOf("*")+1;if(0==f||0!=k&&k<f)f=k;var h=-1;for(d=b.length-1;0<=d;--d)if(d+1==f||" "==b.substr(d,1)){h=d;break}k=b.substr(0,h+1);var n="",m="",q=!1,t=!1,u=0<=b.substr(h+1).indexOf("-")||
87
+ 0<=b.substr(h+1).indexOf("CR");for(d=h+1;d<b.length;d++){var p=b.substr(d,1);if("CR"==b.substr(d,2))t=!0,d++;else if("-"==p)t=!0;else if("&"!=p&&("*"!=p||t))if("A"<=p.toUpperCase()&&"Z">=p.toUpperCase()&&u&&!t)b=b.substr(0,d)+" "+b.substr(d+1);else{n=b.substring(h+1,d);m=b.substr(d);q=!0;break}}q||(n=b.substr(h+1));p=".";d=" ";pui.appJob&&"string"===typeof pui.appJob.decimalFormat&&(d=pui.appJob.decimalFormat);"string"===typeof g.decimalFormat&&(d=g.decimalFormat);if("I"===d||"J"===d)p=",";d=0;p=
87
88
  k.split(p);1<p.length&&(d=p[1].replace(/[^ ]/g,"").length);var w=isNaN(Number(a))?"0":String(a);w=w.replace("-","");p=w.split(".");g=p[0];b="";h=null;1<p.length&&(b=p[1]);if(null==h||isNaN(h))h=d;for(;b.length>h;)b=b.substr(0,b.length-1);for(;h>b.length;)b+="0";for(w=g+b;"0"==w.substr(0,1);)w=w.substr(1);g="";var l=h=!1,r=b=!1;0==f&&(r=!0);for(d=k.length-1;0<=d;--d)q=p=k.substr(d,1)," "==p?q=e():"&"==p?q=" ":"0"==p&&d+1==f?q=e():"*"==p?(l=!0,q=e()):p==c?d+2==f&&(q=e(),b=!0):h&&(q=" ",l&&(q="*")),
88
- g=q+g,d<=f&&(r=!0),r&&0==w.length&&(h=!0);m=m.replace(/&/g," ");m=m.replace(/\*/g," ");0<=a&&(m=m.replace("CR"," "),m=m.replace("-"," "));g=g+m+n;a=g.length-1;g=J(g);l&&"*"!=g.substr(0,1)&&(g="*"+g);for(b&&(g=c+g);g.length<=a;)g=" "+g;return g};
89
+ g=q+g,d<=f&&(r=!0),r&&0==w.length&&(h=!0);n=n.replace(/&/g," ");n=n.replace(/\*/g," ");0<=a&&(n=n.replace("CR"," "),n=n.replace("-"," "));g=g+n+m;a=g.length-1;g=J(g);l&&"*"!=g.substr(0,1)&&(g="*"+g);for(b&&(g=c+g);g.length<=a;)g=" "+g;return g};
89
90
  pui.getRadioGroupValue=function(a){if("string"!==typeof a||"object"!==typeof pui.L)return null;for(var b=null,c=pui.currentFormatNames,e=c.length-1;0<=e;e--){var d=c[e].toUpperCase()+"."+a.toUpperCase();if("undefined"!==typeof pui.L[d]){b=pui.L[d];break}}if(null==b)return null;a=null;for(c=0;c<b.length;c++)if(e=b[c],e.checked&&null!=e.radioValue){a=e.radioValue;break}return a};pui.ea=function(){for(var a=document.getElementById("auth-form"),b=document.cookie.split("; "),c=!1,e=0;e<b.length;e++){var d=b[e].split("=");if(unescape(d[0])=="pui-signon-"+a.action&&"1"==unescape(d[1])){c=!0;break}}if("undefined"!=typeof Storage){b=O();if(b.workstnid)sessionStorage["atrium-params-workstnid"]=b.workstnid;else try{delete sessionStorage["atrium-params-workstnid"]}catch(g){}if(b.suffixid)sessionStorage["atrium-params-suffixid"]=b.suffixid;else try{delete sessionStorage["atrium-params-suffixid"]}catch(g){}if(b.duplicateid)sessionStorage["atrium-params-duplicateid"]=
90
- b.duplicateid;else try{delete sessionStorage["atrium-params-duplicateid"]}catch(g){}}if(c)location.href=a.action;else{if(c=document.getElementById("auth-box"))c.style.display="";a.elements["auth-user"].focus()}};
91
+ b.duplicateid;else try{delete sessionStorage["atrium-params-duplicateid"]}catch(g){}}if(c)location.href=a.getAttribute("action")||a.action;else{if(c=document.getElementById("auth-box"))c.style.display="";a.elements["auth-user"].focus()}};
91
92
  pui.da=function(){var a=document.getElementById("auth-form"),b=a.elements["auth-user"].value,c=a.elements["auth-password"].value,e=document.getElementById("auth-message"),d={"server unavailable":"The server could not be reached at {connectorURL}.<br>Please check your network connection and try again.","error authenticating":"An error occurred while authenticating the user."},g="";e.innerHTML="";if(""==M(b))return e.innerHTML=authMessages["user required"],a.elements["auth-user"].focus(),!1;if(""==
92
- M(c))return e.innerHTML=authMessages["password required"],a.elements["auth-password"].focus(),!1;if(pui.pjsServer){var f="Basic "+btoa(M(b)+":"+M(c));fetch("/profoundui/atrium/authenticate",{method:"POST",headers:{Authorization:f}}).then(function(k){k.ok?(document.cookie=escape("pui-signon-"+a.action)+"=1; path=/",sessionStorage.setItem("atrium-token",btoa(M(b)+":"+M(c))),location.href=a.action):401===k.status?(e.innerHTML=authMessages["invalid credentials"],a.elements["auth-user"].focus()):503===
93
- k.status?k.json().then(function(h){g=authMessages["server unavailable"]||d["server unavailable"];e.innerHTML=g.replace(/{connectorURL}/,h.system);a.elements["auth-user"].focus()}):(g=authMessages["error authenticating"]||d["error authenticating"],e.innerHTML=g,a.elements["auth-user"].focus())})["catch"](function(k){g=authMessages["error authenticating"]||d["error authenticating"];e.innerHTML=g;a.elements["auth-user"].focus();console.error("Error during Atrium authentication:",k)});return!1}pui.v(function(){localStorage["pui-http-auth-invalid"]&&
94
- delete localStorage["pui-http-auth-invalid"];var k=new pui.Ajax("/profoundui/pui0005010.pgm");k.async=!0;k.method="POST";pui.setReqAuth(k,b,c);k.suppressAlert=!0;k.onready=function(h){if(200==h.l()){var m=eval("("+h.j()+")");h=m.days;var n=!1;1==m.warn&&(0==h?(m=authMessages["password expired"],pui.alert(m),n=!0):(m=authMessages["password pending expiration"],m=m.replace(/{DAYS}/g,h),n=confirm(m)));n?(h="/profoundui/changepass?user="+encodeURIComponent(b),h+="&next="+encodeURIComponent(a.action),
95
- h+="&back="+encodeURIComponent(location.href),location.href=h):(document.cookie=escape("pui-signon-"+a.action)+"=1; path=/",location.href=a.action)}else e.innerHTML=authMessages["invalid credentials"],a.elements["auth-user"].focus()};k.send()});return!1};
93
+ M(c))return e.innerHTML=authMessages["password required"],a.elements["auth-password"].focus(),!1;if(pui.pjsServer){var f="Basic "+btoa(M(b)+":"+M(c));fetch((pui.serverURL||"")+"/profoundui/atrium/authenticate",{method:"POST",headers:{Authorization:f}}).then(function(k){k.ok?(k=a.getAttribute("action")||a.action,document.cookie=escape("pui-signon-"+k)+"=1; path=/",sessionStorage.setItem("atrium-token",btoa(M(b)+":"+M(c))),location.href=k):401===k.status?(e.innerHTML=authMessages["invalid credentials"],
94
+ a.elements["auth-user"].focus()):503===k.status?k.json().then(function(h){g=authMessages["server unavailable"]||d["server unavailable"];e.innerHTML=g.replace(/{connectorURL}/,h.system);a.elements["auth-user"].focus()}):(g=authMessages["error authenticating"]||d["error authenticating"],e.innerHTML=g,a.elements["auth-user"].focus())})["catch"](function(k){g=authMessages["error authenticating"]||d["error authenticating"];e.innerHTML=g;a.elements["auth-user"].focus();console.error("Error during Atrium authentication:",
95
+ k)});return!1}pui.v(function(){localStorage["pui-http-auth-invalid"]&&delete localStorage["pui-http-auth-invalid"];var k=new pui.Ajax("/profoundui/pui0005010.pgm");k.async=!0;k.method="POST";pui.setReqAuth(k,b,c);k.suppressAlert=!0;k.onready=function(h){if(200==h.l()){var n=eval("("+h.j()+")");h=n.days;var m=!1;1==n.warn&&(0==h?(m=authMessages["password expired"],pui.alert(m),m=!0):(m=authMessages["password pending expiration"],m=m.replace(/{DAYS}/g,h),m=confirm(m)));h=a.getAttribute("action")||a.action;
96
+ m?(m="/profoundui/changepass?user="+encodeURIComponent(b),m+="&next="+encodeURIComponent(h),m+="&back="+encodeURIComponent(location.href),location.href=m):(document.cookie=escape("pui-signon-"+h)+"=1; path=/",location.href=h)}else e.innerHTML=authMessages["invalid credentials"],a.elements["auth-user"].focus()};k.send()});return!1};
96
97
  pui.v=function(a){if("undefined"!==typeof Atrium&&Atrium.pjsServer)sessionStorage.removeItem("atrium-token"),a();else{var b=new pui.Ajax("/profoundui/pui0005010.pgm");b.async="function"===typeof a?!0:!1;b.method="POST";pui.setReqAuth(b,"PUI_SIGNOFF_USER","PUI_SIGNOFF_USER");b.suppressAlert=!0;"function"===typeof a&&(b.onready=function(){"function"==typeof a&&a()});b.send()}};window.pui.signOn=pui.da;window.pui.clearCredentials=pui.v;window.pui.signOnInit=pui.ea;
97
98
  pui.ca=function(){var a=O(),b=document.getElementById("change-user"),c=document.getElementById("change-current"),e=b,d=document.getElementById("change-cancel");"undefined"!=typeof a.user&&(b.value=a.user.toUpperCase(),b.readOnly=!0,b.className+=" read-only",e=c);"undefined"==typeof a.back&&(d.style.display="none");document.getElementById("change-box").style.display="block";e.focus()};pui.ba=function(){var a=O();"undefined"!=typeof a.back&&(location.href=a.back)};
98
99
  pui.P=function(){if("undefined"===typeof Atrium||!Atrium.pjsServer){var a=O(),b=document.getElementById("change-form"),c=b.elements["change-user"].value,e=b.elements["change-current"].value,d=b.elements["change-new"].value,g=b.elements["change-confirm"].value,f=document.getElementById("change-message");f.innerHTML="";if(""==M(c))return f.innerHTML=passMessages["user required"],b.elements["change-user"].focus(),!1;if(""==M(e))return f.innerHTML=passMessages["current required"],b.elements["change-current"].focus(),
99
100
  !1;if(""==M(d))return f.innerHTML=passMessages["new required"],b.elements["change-new"].focus(),!1;if(""==M(g))return f.innerHTML=passMessages["confirm required"],b.elements["change-confirm"].focus(),!1;if(d!=g)return f.innerHTML=passMessages["must match"],b.elements["change-new"].focus(),!1;g=new pui.Ajax("/profoundui/pui0005011.pgm");g.async=!0;g.method="POST";g.params={};g.params.user=c;g.params.current=e;g.params["new"]=d;g.suppressAlert=!0;g.onready=function(k){if(200!=k.l())f.innerHTML="HTTP "+
100
- k.l()+" - "+k.C()+".",b.elements["change-user"].focus();else{try{var h=eval("("+k.j()+")");if("boolean"!=typeof h.success)throw Error("Invalid response format: 'success' is not a boolean.");if(!h.success&&"string"!=typeof h.error)throw Error("Invalid response format: 'error' is not a string.");}catch(m){h={success:!1,error:"The server response is missing or invalid."}}0==h.success?(f.innerHTML=h.error,b.elements["change-user"].focus()):(pui.alert(passMessages.success),pui.v(function(){var m=new pui.Ajax("/profoundui/pui0005010.pgm");
101
- m.async=!0;m.method="POST";pui.setReqAuth(m,c,d);m.suppressAlert=!0;m.onready=function(n){200==n.l()?"undefined"!=typeof a.next&&(location.href=a.next):(pui.alert("HTTP "+n.l()+" - "+n.C()+"."),b.elements["change-user"].focus())};m.send()}))}};g.send();return!1}};
101
+ k.l()+" - "+k.C()+".",b.elements["change-user"].focus();else{try{var h=eval("("+k.j()+")");if("boolean"!=typeof h.success)throw Error("Invalid response format: 'success' is not a boolean.");if(!h.success&&"string"!=typeof h.error)throw Error("Invalid response format: 'error' is not a string.");}catch(n){h={success:!1,error:"The server response is missing or invalid."}}0==h.success?(f.innerHTML=h.error,b.elements["change-user"].focus()):(pui.alert(passMessages.success),pui.v(function(){var n=new pui.Ajax("/profoundui/pui0005010.pgm");
102
+ n.async=!0;n.method="POST";pui.setReqAuth(n,c,d);n.suppressAlert=!0;n.onready=function(m){200==m.l()?"undefined"!=typeof a.next&&(location.href=a.next):(pui.alert("HTTP "+m.l()+" - "+m.C()+"."),b.elements["change-user"].focus())};n.send()}))}};g.send();return!1}};
102
103
  pui.setReqAuth=function(a,b,c){var e=-1!=navigator.userAgent.indexOf("Edge"),d=!e&&-1!=navigator.userAgent.indexOf("Chrome"),g=-1!=navigator.userAgent.indexOf("Firefox");!e&&-1!=navigator.userAgent.indexOf("Safari")&&!d||d||g?(a.user=encodeURIComponent(b),a.password=encodeURIComponent(c)):(a.user=b,a.password=c)};window.pui.passInit=pui.ca;window.pui.passCancel=pui.ba;window.pui.changePass=pui.P;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "profoundjs",
3
- "version": "7.26.0",
3
+ "version": "7.27.0",
4
4
  "min-profoundui-version": "6.20.0",
5
5
  "description": "Profound.js Framework and Server",
6
6
  "keywords": [
@@ -44,7 +44,7 @@
44
44
  ],
45
45
  "dependencies": {
46
46
  "@aws-sdk/client-sesv2": "^3.835.0",
47
- "@stylistic/eslint-plugin-js": "^1.7.0",
47
+ "@stylistic/eslint-plugin": "^5.5.0",
48
48
  "acorn": "^8.6.0",
49
49
  "adm-zip": "^0.5.1",
50
50
  "agentkeepalive": "^4.1.2",
@@ -60,7 +60,7 @@
60
60
  "chokidar": "^3.4.0",
61
61
  "columnify": "^1.6.0",
62
62
  "compare-versions": "^3.5.1",
63
- "compression": "^1.7.4",
63
+ "compression": "^1.8.1",
64
64
  "cookie-parser": "^1.4.4",
65
65
  "cookie-session": "^1.3.3",
66
66
  "cors": "^2.8.5",
@@ -77,7 +77,7 @@
77
77
  "express-async-handler": "^1.2.0",
78
78
  "express-basic-auth": "^1.2.0",
79
79
  "express-http-proxy": "^1.6.0",
80
- "express-session": "^1.17.1",
80
+ "express-session": "^1.18.2",
81
81
  "express-useragent": "^1.0.15",
82
82
  "fast-sort": "^3.4.1",
83
83
  "fs-extra": "^9.0.1",
@@ -95,7 +95,7 @@
95
95
  "memorystore": "^1.6.1",
96
96
  "minimist": "^1.2.5",
97
97
  "moment": "^2.26.0",
98
- "morgan": "^1.9.1",
98
+ "morgan": "^1.10.1",
99
99
  "mssql": "^6.4.1",
100
100
  "multer": "^2.0.2",
101
101
  "mysql": "^2.17.1",
@@ -105,7 +105,7 @@
105
105
  "nocache": "^3.0.4",
106
106
  "node-machine-id": "^1.1.12",
107
107
  "node-sql-parser": "^4.6.6",
108
- "nodemailer": "^6.4.8",
108
+ "nodemailer": "^7.0.10",
109
109
  "openai": "^5.20.2",
110
110
  "opentype.js": "^1.3.4",
111
111
  "otplib": "^12.0.1",