class CreateHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self):
# Must be admin
if not self.current_user.is_admin():
self.render("builders/create.html")
- @tornado.web.authenticated
+ @base.authenticated
async def post(self):
# Must be admin
if not self.current_user.is_admin():
class EditHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
async def get(self, hostname):
builder = await self.backend.builders.get_by_name(hostname)
if not builder:
self.render("builders/edit.html", builder=builder)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, hostname):
builder = self.backend.builders.get_by_name(hostname)
if not builder:
class DeleteHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self, name):
builder = self.backend.builders.get_by_name(name)
if not builder:
self.render("builders/delete.html", builder=builder)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, hostname):
builder = self.backend.builders.get_by_name(hostname)
if not builder:
class StartHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
async def get(self, name):
builder = self.backend.builders.get_by_name(name)
if not builder:
self.render("builders/start.html", builder=builder)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, name):
builder = self.backend.builders.get_by_name(name)
if not builder:
class StopHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self, name):
builder = self.backend.builders.get_by_name(name)
if not builder:
self.render("builders/stop.html", builder=builder)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, name):
builder = self.backend.builders.get_by_name(name)
if not builder:
class ApproveHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self, uuid):
build = self.backend.builds.get_by_uuid(uuid)
if not build:
self.render("builds/approve.html", build=build)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, uuid):
build = self.backend.builds.get_by_uuid(uuid)
if not build:
class CloneHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self, uuid):
build = self.backend.builds.get_by_uuid(uuid)
if not build:
self.render("builds/clone.html", build=build, repos=repos)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, uuid):
build = self.backend.builds.get_by_uuid(uuid)
if not build:
class DeleteHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self, uuid):
build = self.backend.builds.get_by_uuid(uuid)
if not build:
self.render("builds/delete.html", build=build)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, uuid):
build = self.backend.builds.get_by_uuid(uuid)
if not build:
class WatchHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def post(self, uuid):
build = self.backend.builds.get_by_uuid(uuid)
if not build:
class UnwatchHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def post(self, uuid):
build = self.backend.builds.get_by_uuid(uuid)
if not build:
class CommentHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, uuid):
build = self.backend.builds.get_by_uuid(uuid)
if not build:
class BugHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
async def get(self, uuid):
build = self.backend.builds.get_by_uuid(uuid)
if not build:
self.render("builds/bug.html", build=build, fields=fields)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, uuid):
build = self.backend.builds.get_by_uuid(uuid)
if not build:
class ReposAddHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self, uuid):
build = self.backend.builds.get_by_uuid(uuid)
if not build:
self.render("builds/repos/add.html", build=build, repos=repos)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, uuid):
build = self.backend.builds.get_by_uuid(uuid)
if not build:
class ReposRemoveHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self, uuid):
build = self.backend.builds.get_by_uuid(uuid)
if not build:
self.render("builds/repos/remove.html", build=build)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, uuid):
build = self.backend.builds.get_by_uuid(uuid)
if not build:
class EditHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
async def get(self, slug):
distro = await self.backend.distros.get_by_slug(slug)
if not distro:
self.render("distros/edit.html", distro=distro, bugzilla_products=bugzilla_products)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, slug):
distro = await self.backend.distros.get_by_slug(slug)
if not distro:
class ReleasesCreateHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
async def get(self, distro_slug):
distro = await self.backend.distros.get_by_slug(distro_slug)
if not distro:
self.render("distros/releases/edit.html", release=None, distro=distro)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, distro_slug):
distro = await self.backend.distros.get_by_slug(distro_slug)
if not distro:
class ReleasesEditHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self, distro_slug, release_slug):
distro = self.backend.distros.get_by_slug(distro_slug)
if not distro:
self.render("distros/releases/edit.html", release=release, distro=distro)
- @tornado.web.authenticated
+ @base.authenticated
def post(self, distro_slug, release_slug):
distro = self.backend.distros.get_by_slug(distro_slug)
if not distro:
class ReleasesDeleteHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self, distro_slug, release_slug):
distro = self.backend.distros.get_by_slug(distro_slug)
if not distro:
self.render("distros/releases/delete.html", release=release, distro=distro)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, distro_slug, release_slug):
distro = self.backend.distros.get_by_slug(distro_slug)
if not distro:
class ReleasesPublishHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self, distro_slug, release_slug):
distro = self.backend.distros.get_by_slug(distro_slug)
if not distro:
self.render("distros/releases/publish.html", release=release, distro=distro)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, distro_slug, release_slug):
distro = self.backend.distros.get_by_slug(distro_slug)
if not distro:
class AbortHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
async def get(self, uuid):
job = await self.backend.jobs.get_by_uuid(uuid)
if not job:
self.render("jobs/abort.html", job=job)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, uuid):
job = await self.backend.jobs.get_by_uuid(uuid)
if not job:
class RetryHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
async def get(self, uuid):
job = await self.backend.jobs.get_by_uuid(uuid)
if not job:
self.render("jobs/retry.html", job=job)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, uuid):
job = await self.backend.jobs.get_by_uuid(uuid)
if not job:
class CheckHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, hostname):
mirror = self.backend.mirrors.get_by_hostname(hostname)
if not mirror:
if not self.current_user.is_admin():
raise tornado.web.HTTPError(403)
- @tornado.web.authenticated
+ @base.authenticated
def get(self):
self.render("mirrors/edit.html", mirror=None)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self):
# Fetch all values
hostname = self.get_argument("hostname")
class EditHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self, hostname):
mirror = self.backend.mirrors.get_by_hostname(hostname)
if not mirror:
self.render("mirrors/edit.html", mirror=mirror)
- @tornado.web.authenticated
+ @base.authenticated
def post(self, hostname):
mirror = self.backend.mirrors.get_by_hostname(hostname)
if not mirror:
class DeleteHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self, hostname):
mirror = self.backend.mirrors.get_by_hostname(hostname)
if not mirror:
self.render("mirrors/delete.html", mirror=mirror)
- @tornado.web.authenticated
+ @base.authenticated
def post(self, hostname):
mirror = self.backend.mirrors.get_by_hostname(hostname)
if not mirror:
class CreateHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
async def get(self, slug, name):
# Fetch the distribution
distro = self.backend.distros.get_by_slug(slug)
self.render("monitorings/edit.html", monitoring=None, distro=distro, name=name,
projects=projects)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, slug, name):
# Fetch the distribution
distro = self.backend.distros.get_by_slug(slug)
class EditHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self, slug, name):
# Fetch the distribution
distro = self.backend.distros.get_by_slug(slug)
self.render("monitorings/edit.html", monitoring=monitoring, distro=distro, name=name)
- @tornado.web.authenticated
+ @base.authenticated
def post(self, slug, name):
# Fetch the distribution
distro = self.backend.distros.get_by_slug(slug)
class DeleteHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self, slug, name):
# Fetch the distribution
distro = self.backend.distros.get_by_slug(slug)
self.render("monitorings/delete.html", monitoring=monitoring)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, slug, name):
# Fetch the distribution
distro = self.backend.distros.get_by_slug(slug)
class CheckHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, slug, name):
# Fetch the distribution
distro = self.backend.distros.get_by_slug(slug)
class CreateCustomHandler(BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self, user_slug):
user = self.backend.users.get_by_name(user_slug)
if not user:
self.render("repos/create-custom.html", user=user, distros=self.backend.distros)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, user_slug):
user = self.backend.users.get_by_name(user_slug)
if not user:
class EditHandler(BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self, **kwargs):
# Fetch the repository
repo = self._get_repo(**kwargs)
self.render("repos/edit.html", repo=repo)
- @tornado.web.authenticated
+ @base.authenticated
def post(self, **kwargs):
# Fetch the repository
repo = self._get_repo(**kwargs)
class DeleteHandler(BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self, **kwargs):
# Fetch the repository
repo = self._get_repo(**kwargs)
self.render("repos/delete.html", repo=repo)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, **kwargs):
# Fetch the repository
repo = self._get_repo(**kwargs)
class DeleteHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self, name):
user = self.backend.users.get_by_name(name)
if not user:
self.render("users/delete.html", user=user)
- @tornado.web.authenticated
+ @base.authenticated
def post(self, name):
user = self.backend.users.get_by_name(name)
if not user:
class EditHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self, name):
user = self.backend.users.get_by_name(name)
if not user:
self.render("users/edit.html", user=user)
- @tornado.web.authenticated
+ @base.authenticated
async def post(self, name):
user = self.backend.users.get_by_name(name)
if not user:
class PushSubscribeHandler(base.BaseHandler):
- @tornado.web.authenticated
+ @base.authenticated
def get(self):
self.render("users/subscribe.html")
- @tornado.web.authenticated
+ @base.authenticated
async def post(self):
# The request body must be JSON
if not self.request.headers.get("Content-Type") == "application/json":