Changeset - 30cef362bf70
[Not reviewed]
default
0 1 0
drewp@bigasterisk.com - 6 years ago 2019-06-08 19:14:41
drewp@bigasterisk.com
support for hiding a dev from live view
Ignore-this: feda54533430f85d451cd824985f3594
1 file changed with 2 insertions and 0 deletions:
0 comments (0 inline, 0 general)
light9/web/live/live.coffee
Show inline comments
 
@@ -465,12 +465,14 @@ coffeeElementSetup(class Light9LiveContr
 
  update: ->
 
    U = (x) => @graph.Uri(x)
 

	
 
    newDevs = []
 
    for dc in @graph.sortedUris(@graph.subjects(U('rdf:type'), U(':DeviceClass')))
 
      for dev in @graph.sortedUris(@graph.subjects(U('rdf:type'), dc))
 
        if @graph.contains(dev, U(':hideInLiveUi'), null)
 
          continue
 
        newDevs.push({uri: dev})
 

	
 
    #log("controls update now has #{newDevs.length} devices")
 
    syncArray(@, 'devices', newDevs, (a, b) -> a.uri.value == b.uri.value)
 

	
 
    return
0 comments (0 inline, 0 general)