Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(83)

Side by Side Diff: gm/rebaseline_server/static/view.html

Issue 376623002: rebaseline_server: allow JSON to control column filtering (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Ravi suggestions Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 2
3 <html ng-app="Loader" ng-controller="Loader.Controller"> 3 <html ng-app="Loader" ng-controller="Loader.Controller">
4 4
5 <head> 5 <head>
6 <title ng-bind="windowTitle"></title> 6 <title ng-bind="windowTitle"></title>
7 <script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.1.5/angular.js" ></script> 7 <script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.1.5/angular.js" ></script>
8 <script src="constants.js"></script> 8 <script src="constants.js"></script>
9 <script src="loader.js"></script> 9 <script src="loader.js"></script>
10 <link rel="stylesheet" href="view.css"> 10 <link rel="stylesheet" href="view.css">
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 <table ng-show="viewingTab == defaultTab" border="1"> 67 <table ng-show="viewingTab == defaultTab" border="1">
68 <tr> 68 <tr>
69 <th colspan="4"> 69 <th colspan="4">
70 Filters 70 Filters
71 </th> 71 </th>
72 <th> 72 <th>
73 Settings 73 Settings
74 </th> 74 </th>
75 </tr> 75 </tr>
76 <tr valign="top"> 76 <tr valign="top">
77 <td> 77
78 resultType<br> 78 <!-- filters -->
79 <label ng-repeat="valueAndCount in extraColumnHeaders[constants.KEY__EXT RACOLUMNS__RESULT_TYPE][constants.KEY__EXTRACOLUMNHEADERS__VALUES_AND_COUNTS]"> 79 <td ng-repeat="columnName in orderedColumnNames">
80 <input type="checkbox" 80
81 name="resultTypes" 81 <!-- Only display filterable columns here... -->
82 value="{{valueAndCount[0]}}" 82 <div ng-if="extraColumnHeaders[columnName][constants.KEY__EXTRACOLUMNHEA DERS__IS_FILTERABLE]">
83 ng-checked="isValueInSet(valueAndCount[0], showingColumnValues[ constants.KEY__EXTRACOLUMNS__RESULT_TYPE])" 83 {{extraColumnHeaders[columnName][constants.KEY__EXTRACOLUMNHEADERS__HE ADER_TEXT]}}<br>
84 ng-click="toggleValueInSet(valueAndCount[0], showingColumnValue s[constants.KEY__EXTRACOLUMNS__RESULT_TYPE]); setUpdatesPending(true)"> 84
85 {{valueAndCount[0]}} ({{valueAndCount[1]}})<br> 85 <!-- If we filter this column using free-form text match... -->
86 </label> 86 <div ng-if="extraColumnHeaders[columnName][constants.KEY__EXTRACOLUMNH EADERS__USE_FREEFORM_FILTER]">
87 <button ng-click="showingColumnValues[constants.KEY__EXTRACOLUMNS__RESUL T_TYPE] = {}; toggleValuesInSet(allColumnValues[constants.KEY__EXTRACOLUMNS__RES ULT_TYPE], showingColumnValues[constants.KEY__EXTRACOLUMNS__RESULT_TYPE]); updat eResults()" 87 <input type="text"
88 ng-disabled="!readyToDisplay || allColumnValues[constants.KEY__E XTRACOLUMNS__RESULT_TYPE].length == setSize(showingColumnValues[constants.KEY__E XTRACOLUMNS__RESULT_TYPE])"> 88 ng-model="columnStringMatch[columnName]"
89 all 89 ng-change="setUpdatesPending(true)"/>
90 </button> 90 <br>
91 <button ng-click="showingColumnValues[constants.KEY__EXTRACOLUMNS__RESUL T_TYPE] = {}; updateResults()" 91 <button ng-click="setColumnStringMatch(columnName, '')"
92 ng-disabled="!readyToDisplay || 0 == setSize(showingColumnValues [constants.KEY__EXTRACOLUMNS__RESULT_TYPE])"> 92 ng-disabled="('' == columnStringMatch[columnName])">
93 none 93 clear (show all)
94 </button> 94 </button>
95 <button ng-click="toggleValuesInSet(allColumnValues[constants.KEY__EXTRA COLUMNS__RESULT_TYPE], showingColumnValues[constants.KEY__EXTRACOLUMNS__RESULT_T YPE]); updateResults()"> 95 </div>
96 toggle 96
97 </button> 97 <!-- If we filter this column using checkboxes... -->
98 <div ng-if="!extraColumnHeaders[columnName][constants.KEY__EXTRACOLUMN HEADERS__USE_FREEFORM_FILTER]">
99 <label ng-repeat="valueAndCount in extraColumnHeaders[columnName][co nstants.KEY__EXTRACOLUMNHEADERS__VALUES_AND_COUNTS]">
100 <input type="checkbox"
101 name="resultTypes"
102 value="{{valueAndCount[0]}}"
103 ng-checked="isValueInSet(valueAndCount[0], showingColumnVal ues[columnName])"
104 ng-click="toggleValueInSet(valueAndCount[0], showingColumnV alues[columnName]); setUpdatesPending(true)">
105 {{valueAndCount[0]}} ({{valueAndCount[1]}})<br>
106 </label>
107 <button ng-click="showingColumnValues[columnName] = {}; toggleValues InSet(allColumnValues[columnName], showingColumnValues[columnName]); updateResul ts()"
108 ng-disabled="!readyToDisplay || allColumnValues[columnName]. length == setSize(showingColumnValues[columnName])">
109 all
110 </button>
111 <button ng-click="showingColumnValues[columnName] = {}; updateResult s()"
112 ng-disabled="!readyToDisplay || 0 == setSize(showingColumnVa lues[columnName])">
113 none
114 </button>
115 <button ng-click="toggleValuesInSet(allColumnValues[columnName], sho wingColumnValues[columnName]); updateResults()">
116 toggle
117 </button>
118 </div>
119
120 </div>
98 </td> 121 </td>
99 <td ng-repeat="category in [constants.KEY__EXTRACOLUMNS__BUILDER, constant s.KEY__EXTRACOLUMNS__TEST]"> 122
100 {{category}} 123 <!-- settings -->
101 <br>
102 <input type="text"
103 ng-model="categoryValueMatch[category]"
104 ng-change="setUpdatesPending(true)"/>
105 <br>
106 <button ng-click="setCategoryValueMatch(category, '')"
107 ng-disabled="('' == categoryValueMatch[category])">
108 clear (show all)
109 </button>
110 </td>
111 <td>
112 config<br>
113 <label ng-repeat="valueAndCount in extraColumnHeaders[constants.KEY__EXT RACOLUMNS__CONFIG][constants.KEY__EXTRACOLUMNHEADERS__VALUES_AND_COUNTS]">
114 <input type="checkbox"
115 name="configs"
116 value="{{valueAndCount[0]}}"
117 ng-checked="isValueInSet(valueAndCount[0], showingColumnValues[ constants.KEY__EXTRACOLUMNS__CONFIG])"
118 ng-click="toggleValueInSet(valueAndCount[0], showingColumnValue s[constants.KEY__EXTRACOLUMNS__CONFIG]); setUpdatesPending(true)">
119 {{valueAndCount[0]}} ({{valueAndCount[1]}})<br>
120 </label>
121 <button ng-click="showingColumnValues[constants.KEY__EXTRACOLUMNS__CONFI G] = {}; toggleValuesInSet(allColumnValues[constants.KEY__EXTRACOLUMNS__CONFIG], showingColumnValues[constants.KEY__EXTRACOLUMNS__CONFIG]); updateResults()"
122 ng-disabled="!readyToDisplay || allColumnValues[constants.KEY__E XTRACOLUMNS__CONFIG].length == setSize(showingColumnValues[constants.KEY__EXTRAC OLUMNS__CONFIG])">
123 all
124 </button>
125 <button ng-click="showingColumnValues[constants.KEY__EXTRACOLUMNS__CONFI G] = {}; updateResults()"
126 ng-disabled="!readyToDisplay || 0 == setSize(showingColumnValues [constants.KEY__EXTRACOLUMNS__CONFIG])">
127 none
128 </button>
129 <button ng-click="toggleValuesInSet(allColumnValues[constants.KEY__EXTRA COLUMNS__CONFIG], showingColumnValues[constants.KEY__EXTRACOLUMNS__CONFIG]); upd ateResults()">
130 toggle
131 </button>
132 </td>
133 <td><table> 124 <td><table>
134 <tr><td> 125 <tr><td>
135 <input type="checkbox" ng-model="showThumbnailsPending" 126 <input type="checkbox" ng-model="showThumbnailsPending"
136 ng-init="showThumbnailsPending = true" 127 ng-init="showThumbnailsPending = true"
137 ng-change="areUpdatesPending = true"/> 128 ng-change="areUpdatesPending = true"/>
138 Show thumbnails 129 Show thumbnails
139 </td></tr> 130 </td></tr>
140 <tr><td> 131 <tr><td>
141 <input type="checkbox" ng-model="mergeIdenticalRowsPending" 132 <input type="checkbox" ng-model="mergeIdenticalRowsPending"
142 ng-init="mergeIdenticalRowsPending = true" 133 ng-init="mergeIdenticalRowsPending = true"
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after
241 move {{selectedImagePairs.length}} selected tests to {{otherTab} } tab 232 move {{selectedImagePairs.length}} selected tests to {{otherTab} } tab
242 </button> 233 </button>
243 </div> 234 </div>
244 </td> 235 </td>
245 </tr> 236 </tr>
246 </table> <!-- results header --> 237 </table> <!-- results header -->
247 </td></tr><tr><td> 238 </td></tr><tr><td>
248 <table border="1" ng-app="diff_viewer"> <!-- results --> 239 <table border="1" ng-app="diff_viewer"> <!-- results -->
249 <tr> 240 <tr>
250 <!-- Most column headers are displayed in a common fashion... --> 241 <!-- Most column headers are displayed in a common fashion... -->
251 <th ng-repeat="categoryName in [constants.KEY__EXTRACOLUMNS__RESULT_TY PE, constants.KEY__EXTRACOLUMNS__BUILDER, constants.KEY__EXTRACOLUMNS__TEST, con stants.KEY__EXTRACOLUMNS__CONFIG]"> 242 <th ng-repeat="columnName in orderedColumnNames">
252 <input type="radio" 243 <input type="radio"
253 name="sortColumnRadio" 244 name="sortColumnRadio"
254 value="{{categoryName}}" 245 value="{{columnName}}"
255 ng-checked="(sortColumnKey == categoryName)" 246 ng-checked="(sortColumnKey == columnName)"
256 ng-click="sortResultsBy(constants.KEY__IMAGEPAIRS__EXTRACOLUM NS, categoryName)"> 247 ng-click="sortResultsBy(constants.KEY__IMAGEPAIRS__EXTRACOLUM NS, columnName)">
257 {{categoryName}} 248 {{extraColumnHeaders[columnName][constants.KEY__EXTRACOLUMNHEADERS__ HEADER_TEXT]}}
258 </th> 249 </th>
259 <!-- ... but there are a few columns where we display things different ly. --> 250 <!-- ... but there are a few columns where we display things different ly. -->
260 <th> 251 <th>
261 <input type="radio" 252 <input type="radio"
262 name="sortColumnRadio" 253 name="sortColumnRadio"
263 value="bugs" 254 value="bugs"
264 ng-checked="(sortColumnKey == constants.KEY__EXPECTATIONS__BU GS)" 255 ng-checked="(sortColumnKey == constants.KEY__EXPECTATIONS__BU GS)"
265 ng-click="sortResultsBy(constants.KEY__IMAGEPAIRS__EXPECTATIO NS, constants.KEY__EXPECTATIONS__BUGS)"> 256 ng-click="sortResultsBy(constants.KEY__IMAGEPAIRS__EXPECTATIO NS, constants.KEY__EXPECTATIONS__BUGS)">
266 bugs 257 bugs
267 </th> 258 </th>
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
304 min="0" max="255"/> 295 min="0" max="255"/>
305 </th> 296 </th>
306 <th> 297 <th>
307 <!-- imagepair-selection checkbox column --> 298 <!-- imagepair-selection checkbox column -->
308 </th> 299 </th>
309 </tr> 300 </tr>
310 301
311 <tr ng-repeat="imagePair in limitedImagePairs" valign="top" 302 <tr ng-repeat="imagePair in limitedImagePairs" valign="top"
312 ng-class-odd="'results-odd'" ng-class-even="'results-even'" 303 ng-class-odd="'results-odd'" ng-class-even="'results-even'"
313 results-updated-callback-directive> 304 results-updated-callback-directive>
314 <td> 305
315 {{imagePair[constants.KEY__IMAGEPAIRS__EXTRACOLUMNS][constants.KEY__ EXTRACOLUMNS__RESULT_TYPE]}} 306 <td ng-repeat="columnName in orderedColumnNames">
307 {{imagePair[constants.KEY__IMAGEPAIRS__EXTRACOLUMNS][columnName]}}
316 <br> 308 <br>
317 <button class="show-only-button" 309 <button class="show-only-button"
318 ng-show="viewingTab == defaultTab" 310 ng-show="viewingTab == defaultTab"
319 ng-disabled="1 == setSize(showingColumnValues[constants.KEY_ _EXTRACOLUMNS__RESULT_TYPE])" 311 ng-disabled="1 == setSize(showingColumnValues[columnName])"
320 ng-click="showOnlyColumnValue(constants.KEY__EXTRACOLUMNS__R ESULT_TYPE, imagePair[constants.KEY__IMAGEPAIRS__EXTRACOLUMNS][constants.KEY__EX TRACOLUMNS__RESULT_TYPE])" 312 ng-click="showOnlyColumnValue(columnName, imagePair[constant s.KEY__IMAGEPAIRS__EXTRACOLUMNS][columnName])"
321 title="show only results of type {{imagePair[constants.KEY__ IMAGEPAIRS__EXTRACOLUMNS][constants.KEY__EXTRACOLUMNS__RESULT_TYPE]}}"> 313 title="show only results of {{extraColumnHeaders[columnName] [constants.KEY__EXTRACOLUMNHEADERS__HEADER_TEXT]}} {{imagePair[constants.KEY__IM AGEPAIRS__EXTRACOLUMNS][columnName]}}">
322 show only 314 show only
323 </button> 315 </button>
324 <br> 316 <br>
325 <button class="show-all-button" 317 <button class="show-all-button"
326 ng-show="viewingTab == defaultTab" 318 ng-show="viewingTab == defaultTab"
327 ng-disabled="allColumnValues[constants.KEY__EXTRACOLUMNS__RE SULT_TYPE].length == setSize(showingColumnValues[constants.KEY__EXTRACOLUMNS__RE SULT_TYPE])" 319 ng-disabled="allColumnValues[columnName].length == setSize(s howingColumnValues[columnName])"
328 ng-click="showAllColumnValues(constants.KEY__EXTRACOLUMNS__R ESULT_TYPE)" 320 ng-click="showAllColumnValues(columnName)"
329 title="show results of all types"> 321 title="show results of all {{extraColumnHeaders[columnName][ constants.KEY__EXTRACOLUMNHEADERS__HEADER_TEXT]}}s">
330 show all 322 show all
331 </button> 323 </button>
332 </td> 324 </td>
333 <td ng-repeat="categoryName in [constants.KEY__EXTRACOLUMNS__BUILDER, constants.KEY__EXTRACOLUMNS__TEST]"> 325
334 {{imagePair[constants.KEY__IMAGEPAIRS__EXTRACOLUMNS][categoryName]}} 326 <!-- bugs -->
335 <br>
336 <button class="show-only-button"
337 ng-show="viewingTab == defaultTab"
338 ng-disabled="imagePair[constants.KEY__IMAGEPAIRS__EXTRACOLUM NS][categoryName] == categoryValueMatch[categoryName]"
339 ng-click="setCategoryValueMatch(categoryName, imagePair[cons tants.KEY__IMAGEPAIRS__EXTRACOLUMNS][categoryName])"
340 title="show only results of {{categoryName}} {{imagePair[con stants.KEY__IMAGEPAIRS__EXTRACOLUMNS][categoryName]}}">
341 show only
342 </button>
343 <br>
344 <button class="show-all-button"
345 ng-show="viewingTab == defaultTab"
346 ng-disabled="'' == categoryValueMatch[categoryName]"
347 ng-click="setCategoryValueMatch(categoryName, '')"
348 title="show results of all {{categoryName}}s">
349 show all
350 </button>
351 </td>
352 <td>
353 {{imagePair[constants.KEY__IMAGEPAIRS__EXTRACOLUMNS][constants.KEY__ EXTRACOLUMNS__CONFIG]}}
354 <br>
355 <button class="show-only-button"
356 ng-show="viewingTab == defaultTab"
357 ng-disabled="1 == setSize(showingColumnValues[constants.KEY_ _EXTRACOLUMNS__CONFIG])"
358 ng-click="showOnlyColumnValue(constants.KEY__EXTRACOLUMNS__C ONFIG, imagePair[constants.KEY__IMAGEPAIRS__EXTRACOLUMNS][constants.KEY__EXTRACO LUMNS__CONFIG])"
359 title="show only results of config {{imagePair[constants.KEY __IMAGEPAIRS__EXTRACOLUMNS][constants.KEY__EXTRACOLUMNS__CONFIG]}}">
360 show only
361 </button>
362 <br>
363 <button class="show-all-button"
364 ng-show="viewingTab == defaultTab"
365 ng-disabled="allColumnValues[constants.KEY__EXTRACOLUMNS__CO NFIG].length == setSize(showingColumnValues[constants.KEY__EXTRACOLUMNS__CONFIG] )"
366 ng-click="showAllColumnValues(constants.KEY__EXTRACOLUMNS__C ONFIG)"
367 title="show results of all configs">
368 show all
369 </button>
370 </td>
371 <td> 327 <td>
372 <a ng-repeat="bug in imagePair[constants.KEY__IMAGEPAIRS__EXPECTATIO NS][constants.KEY__EXPECTATIONS__BUGS]" 328 <a ng-repeat="bug in imagePair[constants.KEY__IMAGEPAIRS__EXPECTATIO NS][constants.KEY__EXPECTATIONS__BUGS]"
373 href="https://code.google.com/p/skia/issues/detail?id={{bug}}" 329 href="https://code.google.com/p/skia/issues/detail?id={{bug}}"
374 target="_blank"> 330 target="_blank">
375 {{bug}} 331 {{bug}}
376 </a> 332 </a>
377 </td> 333 </td>
378 334
379 <!-- image A --> 335 <!-- image A -->
380 <td width="{{imageSize}}" ng-if="imagePair[constants.KEY__IMAGEPAIRS__ ROWSPAN] > 0" rowspan="{{imagePair[constants.KEY__IMAGEPAIRS__ROWSPAN]}}"> 336 <td width="{{imageSize}}" ng-if="imagePair[constants.KEY__IMAGEPAIRS__ ROWSPAN] > 0" rowspan="{{imagePair[constants.KEY__IMAGEPAIRS__ROWSPAN]}}">
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
452 ng-click="toggleSomeImagePairs($index, imagePair[constants.KE Y__IMAGEPAIRS__ROWSPAN])"> 408 ng-click="toggleSomeImagePairs($index, imagePair[constants.KE Y__IMAGEPAIRS__ROWSPAN])">
453 </tr> 409 </tr>
454 </table> <!-- imagePairs --> 410 </table> <!-- imagePairs -->
455 </td></tr></table> <!-- table holding results header + imagePairs table --> 411 </td></tr></table> <!-- table holding results header + imagePairs table -->
456 412
457 </div><!-- main display area of selected tab --> 413 </div><!-- main display area of selected tab -->
458 </div><!-- everything: hide until readyToDisplay --> 414 </div><!-- everything: hide until readyToDisplay -->
459 415
460 </body> 416 </body>
461 </html> 417 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698