fix: cleanResp — strip sub-item responsible persons from main event row
This commit is contained in:
parent
c0c25d38d6
commit
7b0b0c65d5
10
index.html
10
index.html
@ -985,6 +985,12 @@ function cleanTitle(e){
|
||||
var t=e.t;var idx=t.indexOf("\na)");if(idx<0)idx=t.indexOf("\n\u0430)");if(idx<0)idx=t.indexOf("\na\u0029");if(idx<0)idx=t.indexOf(":"+String.fromCharCode(10)+"a");
|
||||
return idx>0?t.substring(0,idx).trim():t
|
||||
}
|
||||
function cleanResp(e){
|
||||
if(!e||!e.r)return"";
|
||||
if(!e.sub||!e.sub.length)return e.r;
|
||||
var r=e.r;var idx=r.indexOf("\n"+String.fromCharCode(10));if(idx<0){var m=r.match(/\n[a-zа-я]+\)/);if(m)idx=r.indexOf(m[0])}
|
||||
return idx>0?r.substring(0,idx).trim():r
|
||||
}
|
||||
function esc(s){
|
||||
return String(s).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""")
|
||||
}
|
||||
@ -1162,7 +1168,7 @@ function renderEv(){
|
||||
h+="<tr class='"+rowCl+"'>";
|
||||
h+="<td style='font-weight:700;font-size:12px'>"+e.id+"</td>";
|
||||
h+="<td><div style='font-size:12px;line-height:1.3'>"+esc(e.t)+"</div><div style='font-size:10px;color:#64748B;margin-top:2px'>"+esc(e.dname)+"</div></td>";
|
||||
h+="<td style='font-size:11px'>"+esc(nl2c(e.r))+"</td>";
|
||||
h+="<td style='font-size:11px'>"+esc(nl2c(cleanResp(e)))+"</td>";
|
||||
h+="<td style='font-size:12px;white-space:nowrap'>"+e.due+" <span style='font-size:10px;color:#64748B'>("+drText+")</span></td>";
|
||||
if(hasSub){h+="<td></td><td></td>"}
|
||||
else{
|
||||
@ -1815,6 +1821,6 @@ function dlAnalyticsWord(){
|
||||
var a=document.createElement("a");a.href=URL.createObjectURL(blob);a.download="analytics.doc";a.click()
|
||||
}
|
||||
|
||||
</script></script></script></script></script></script></script></script></script>
|
||||
</script></script></script></script></script></script></script></script></script></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user