mirror of
git://git.yoctoproject.org/yocto-autobuilder2.git
synced 2025-07-19 12:49:03 +02:00

Our plugin is based on upstream buildbot's console plugin. Upstream moved away from coffescript and made a number of other fixes and improvements. Run decaffeinate on the coffeescript to translate to angularjs and then convert to the new build environment and standards. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
23 lines
685 B
JavaScript
23 lines
685 B
JavaScript
/*
|
|
* decaffeinate suggestions:
|
|
* DS102: Remove unnecessary code created because of implicit returns
|
|
* Full docs: https://github.com/decaffeinate/decaffeinate/blob/master/docs/suggestions.md
|
|
*/
|
|
class ConsoleModal {
|
|
constructor($scope, $uibModalInstance, selectedBuild) {
|
|
this.$uibModalInstance = $uibModalInstance;
|
|
this.selectedBuild = selectedBuild;
|
|
$scope.$on('$stateChangeStart', () => {
|
|
return this.close();
|
|
});
|
|
}
|
|
|
|
close() {
|
|
return this.$uibModalInstance.close();
|
|
}
|
|
}
|
|
|
|
|
|
angular.module('yocto_console_view')
|
|
.controller('consoleModalController', ['$scope', '$uibModalInstance', 'selectedBuild', ConsoleModal]);
|