mirror of
https://github.com/stagehacks/Cue-View.git
synced 2026-08-14 10:13:39 +00:00
fasted data updates/draws
This commit is contained in:
+12
-77
@@ -1,8 +1,13 @@
|
||||
<header>
|
||||
<h1><%= listName %></h1>
|
||||
<h2><%= data.version %></h2>
|
||||
<h2>Eos <%= data.version %></h2>
|
||||
</header>
|
||||
|
||||
<%
|
||||
const fs = require('fs');
|
||||
let cueTemplate = _.template(fs.readFileSync(`./plugins/eos/cue.ejs`));
|
||||
%>
|
||||
|
||||
|
||||
<% for(var i in data.cuelists){ %>
|
||||
<strong>List <%= i %></strong>
|
||||
@@ -28,69 +33,12 @@
|
||||
<% for(var j=0; j<cues.length; j++){ %>
|
||||
<% var q = data.cuelists[i][cues[j]] %>
|
||||
|
||||
<% for(var partNumber in q){ %>
|
||||
|
||||
<% var p = q[partNumber] %>
|
||||
|
||||
|
||||
<% if(p.scene.length>0 && partNumber==0){ %>
|
||||
<tr>
|
||||
<td></td>
|
||||
<td colspan="12" class="scene"><hr><span><%= p.scene %></span></td>
|
||||
</tr>
|
||||
<% } %>
|
||||
|
||||
<% if(cues[j]==data.activeCue+""){ %>
|
||||
<tr class="active-cue scroll-position">
|
||||
<% }else{ %>
|
||||
<tr>
|
||||
<% } %>
|
||||
|
||||
<% if(partNumber!=0){ %>
|
||||
<td class="num"> P<%= partNumber %></td>
|
||||
<% }else{ %>
|
||||
<td class="num"> <%= cues[j] %></td>
|
||||
<% } %>
|
||||
|
||||
<% if(partNumber!=0 || p.partcount==0){ %>
|
||||
|
||||
<!-- Int Up/Int Down -->
|
||||
<% if(p.uptimeduration == p.downtimeduration || p.downtimeduration==-1){ %>
|
||||
<td class="black" colspan="2"><%= prettyDuration(p.uptimedelay) || "" %><%= prettyDuration(p.uptimeduration, true) %></td>
|
||||
<% }else{ %>
|
||||
<td class="black"><%= prettyDuration(p.uptimedelay) || "" %><%= prettyDuration(p.uptimeduration, true) %></td>
|
||||
<td class="black "><%= prettyDuration(p.downtimeduration, true) %></td>
|
||||
<% } %>
|
||||
|
||||
<td class="black hide-medium"><%= prettyDuration(p.focustimeduration, true) %></td>
|
||||
<td class="black hide-medium"><%= prettyDuration(p.colortimeduration, true) %></td>
|
||||
<td class="black hide-medium"><%= prettyDuration(p.beamtimeduration, true) %></td>
|
||||
<td class="hide-small"><%= prettyDuration(p.duration) %></td>
|
||||
|
||||
<% }else{ %>
|
||||
<td class="black" colspan="2"></td>
|
||||
<td class="black hide-medium"></td>
|
||||
<td class="black hide-medium"></td>
|
||||
<td class="black hide-medium"></td>
|
||||
<td class="hide-small"></td>
|
||||
|
||||
<% } %>
|
||||
|
||||
<td class="black hide-small"><%= p.mark %></td>
|
||||
<td class="black hide-small"><%= p.block %></td>
|
||||
<td class="black hide-small"><%= p.assert %></td>
|
||||
<td class="black hide-small">
|
||||
<%= (p.follow>=0)? "F"+prettyDuration(p.follow) : "" %>
|
||||
<%= (p.hang>=0)? "H"+prettyDuration(p.hang) : "" %>
|
||||
</td>
|
||||
<td class="black" style="text-align: left">
|
||||
<%= (partNumber==0 ? "": " ") %>
|
||||
<%= p.label %>
|
||||
</td>
|
||||
<td class="black hide-medium"><%= p.extlinks %></td>
|
||||
</tr>
|
||||
|
||||
<% } %>
|
||||
<%= cueTemplate({
|
||||
q: q,
|
||||
cues: cues,
|
||||
cueNumber: cues[j],
|
||||
isActive: (cues[j]==data.activeCue+"")
|
||||
}) %>
|
||||
|
||||
<% } %>
|
||||
</table>
|
||||
@@ -98,16 +46,3 @@
|
||||
<% } %>
|
||||
|
||||
|
||||
<%
|
||||
function prettyDuration(milliseconds, box){
|
||||
if(milliseconds==-1){
|
||||
return "";
|
||||
}
|
||||
var num = Math.round(milliseconds/100)/10;
|
||||
if(box){
|
||||
return "<div class='time'>"+num+"</div>";
|
||||
}
|
||||
return num;
|
||||
|
||||
}
|
||||
%>
|
||||
Reference in New Issue
Block a user