File tree Expand file tree Collapse file tree 2 files changed +13
-7
lines changed
Expand file tree Collapse file tree 2 files changed +13
-7
lines changed Original file line number Diff line number Diff line change 3030 </ main >
3131 </ body >
3232 < script >
33- var public_key = '9c79f14df986a1ec693c'
34- var api_root = null // 'http://localhost:8000'
33+ var public_key = '9c79f14df986a1ec693c' // '61e9d8d03109e44d7c67'
34+ var api_root = null // 'https://socket-beta.tutorcruncher.com' ' http://localhost:8000'
3535 var socket1 = socket ( public_key , {
3636 element : '#socket1' ,
3737 router_mode : 'history' ,
3838 api_root : api_root ,
3939 mode : 'grid' ,
40- // contractor_filter: {
41- // labels: ['foo', 'bar'],
42- // label_exclude: ['whatever']
43- // },
40+ labels_include : [ ] ,
41+ labels_exclude : [ ] ,
4442 event_callback : function ( name , v ) {
4543 console . log ( name , v )
4644 }
Original file line number Diff line number Diff line change @@ -97,7 +97,15 @@ window.socket = function (public_key, config) {
9797 config . element = '#socket'
9898 }
9999
100- config . contractor_filter = config . contractor_filter || { }
100+ config . contractor_filter = { }
101+ if ( config . labels_include ) {
102+ config . contractor_filter . label = config . labels_include
103+ delete config . labels_include
104+ }
105+ if ( config . labels_exclude ) {
106+ config . contractor_filter . label_exclude = config . labels_exclude
107+ delete config . labels_exclude
108+ }
101109
102110 if ( config . subject_filter === undefined ) {
103111 config . subject_filter = true
You can’t perform that action at this time.
0 commit comments