Bug 1184748 - Link to compare view from resultset view for talos jobs

This commit is contained in:
Tiramisu 1993 2015-08-11 20:09:18 +08:00
Родитель 9a2497df86
Коммит e8f23db660
3 изменённых файлов: 10 добавлений и 4 удалений

Просмотреть файл

@ -249,7 +249,7 @@ treeherder.directive('thCloneJobs', [
return jobsShown;
};
var jobMouseDown = function(ev){
var jobMouseDown = function(resultset, ev){
var el = $(ev.target);
var key = el.attr(jobKeyAttr);
@ -258,6 +258,7 @@ treeherder.directive('thCloneJobs', [
var job = this.job_map[key].job_obj;
job.revision = resultset.revision;
//NOTE: scope is set to "this" by _.bind
switch (ev.which) {
case 1:
@ -739,7 +740,7 @@ treeherder.directive('thCloneJobs', [
element.off();
//Register events callback
element.on('mousedown', _.bind(jobMouseDown, scope));
element.on('mousedown', _.bind(jobMouseDown, scope, scope.resultset));
registerCustomEventCallbacks(scope, element);

Просмотреть файл

@ -10,14 +10,14 @@ treeherder.controller('PluginCtrl', [
'numberFilter', 'ThBugJobMapModel', 'thResultStatus', 'thJobFilters',
'ThResultSetModel', 'ThLog', '$q', 'thPinboard', 'ThJobArtifactModel',
'thBuildApi', 'thNotify', 'ThJobLogUrlModel', 'ThModelErrors', 'thTabs',
'$timeout', 'thJobSearchStr', 'thReftestStatus',
'$timeout', 'thJobSearchStr', 'thReftestStatus', 'ThResultSetStore',
function PluginCtrl(
$scope, $rootScope, $location, thUrl, ThJobClassificationModel,
thClassificationTypes, ThJobModel, thEvents, dateFilter, thDateFormat,
numberFilter, ThBugJobMapModel, thResultStatus, thJobFilters,
ThResultSetModel, ThLog, $q, thPinboard, ThJobArtifactModel,
thBuildApi, thNotify, ThJobLogUrlModel, ThModelErrors, thTabs,
$timeout, thJobSearchStr, thReftestStatus) {
$timeout, thJobSearchStr, thReftestStatus, ThResultSetStore) {
var $log = new ThLog("PluginCtrl");
@ -96,6 +96,7 @@ treeherder.controller('PluginCtrl', [
$scope.eta = $scope.job.get_current_eta();
$scope.eta_abs = Math.abs($scope.job.get_current_eta());
$scope.typical_eta = $scope.job.get_typical_eta();
$scope.jobRevision = ThResultSetStore.getSelectedJob($scope.repoName).job.revision
// During save or delete classification we reselect the same
// job to update correct tab contents and job state, but we

Просмотреть файл

@ -17,6 +17,10 @@
<a href="http://people.mozilla.com/~bgirard/cleopatra/?zippedProfile={{line.url}}"
target="_blank">Open {{line.value}} in Cleopatra</a>
</li>
<li>
<a href="https://treeherder.mozilla.org/perf.html#/comparechooser?newProject={{repoName}}&newRevision={{jobRevision}}">
Compare result against another revision with Perfherder</a>
</li>
</ul>
</div>