Compare commits

..

2 Commits

Author SHA1 Message Date
15a13a254b Merge branch 'master' of https://git.mesh.kz/igor/Metadata_PHP 2026-04-25 12:18:52 +05:00
e5f9596928 Add disabled value to edit field 2026-04-25 12:18:40 +05:00

View File

@ -302,17 +302,18 @@ class EdtRec
//td2.style.width=row+"px";
}
let isDisabled = nodeProp.getAttribute("disabled") === "1";
let value=getCdata(nodeProp).nodeValue;
if(vt==="html"){
td1.innerHTML=nodeProp.getAttribute("d")+'<br><button class="button-secondary" onclick="showHTMLEditor(\''+nodeProp.getAttribute("d")+'\',\'prop_'+this.uid+'_'+nodeProp.getAttribute("n")+'\');">HTML ...</button>';
}else{
td1.innerHTML=nodeProp.getAttribute("d");
}
if (isDisabled) td1.style.color = "#888";
if (nodeProp.getAttribute("maybenull")=='0') td1.style.fontWeight = "bold";
if(nodeProp.getAttribute("t")!=null) td1.title=nodeProp.getAttribute("t");
if (nodeProp.getAttribute("maybenull")=='0') td1.style.cssText="font-weight: bold;";
let value=getCdata(nodeProp).nodeValue;
if(vt==="string" || vt==="str")
{
@ -547,6 +548,7 @@ class EdtRec
select.setAttribute("name",nodeProp.getAttribute("n"));
//select.setAttribute("value",value) does not work because when creating no values in the list
select.setAttribute("id","prop_"+this.uid+"_"+nodeProp.getAttribute("n"));
select.disabled = isDisabled;
select.onchange = function(thiz,node){ return function()
{
thiz.onComboObjectChangeHandler(node);
@ -563,6 +565,7 @@ class EdtRec
button.setAttribute("type","button");
button.setAttribute("value","...");
button.style.cssText="width:30px;font-size:9pt;margin:0px;padding:0px;height:100%;";
button.disabled = isDisabled;
button.onclick=function(thiz,val){
return function(){
thiz.SelectObjects(val);