| ... |
... |
@@ -40,8 +40,9 @@ |
| 40 |
40 |
} |
| 41 |
41 |
|
| 42 |
42 |
const filterInputs = document.querySelectorAll('input[data-role-filter]'); |
| 43 |
|
- |
|
43 |
+ console.log(filterInputs); |
| 44 |
44 |
filterInputs.forEach(function(filterIpt) { |
|
45 |
+ console.log(filterIpt); |
| 45 |
45 |
filterIpt.addEventListener('click', function() { |
| 46 |
46 |
const role = this.getAttribute('data-role-filter'); |
| 47 |
47 |
if(this.checked) { |
| ... |
... |
@@ -49,15 +49,10 @@ |
| 49 |
49 |
} else { |
| 50 |
50 |
removeRole(role); |
| 51 |
51 |
} |
| 52 |
|
- runFilteredRequest(); |
|
53 |
+ console.log(filters); |
| 53 |
53 |
}) |
| 54 |
54 |
}); |
| 55 |
55 |
|
| 56 |
|
- function runFilteredRequest() { |
| 57 |
|
- for(filter in filters) { |
| 58 |
|
- console.log(filter); |
| 59 |
|
- } |
| 60 |
|
- } |
| 61 |
61 |
// https://wiki-dev.ebrains.eu/rest/v1/collabs?search=&offset=0&orderField=title&order=asc&favorite=false&roles=administrator |
| 62 |
62 |
const contextSearchType = document.getElementById("context-search-type"); |
| 63 |
63 |
const contextSearchText = document.getElementById("context-search-text"); |
| ... |
... |
@@ -74,7 +74,7 @@ |
| 74 |
74 |
handleXWikiSearch('bougaultx'); |
| 75 |
75 |
break |
| 76 |
76 |
default: |
| 77 |
|
- handleXWikiSearch('') |
|
73 |
+ handleXWikiSearch('', applyAdministratorFilter) |
| 78 |
78 |
} |
| 79 |
79 |
|
| 80 |
80 |
}); |