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

Side by Side Diff: milo/frontend/console/html.go

Issue 2949783002: [milo] appengine/* -> * (Closed)
Patch Set: rebase Created 3 years, 6 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
« no previous file with comments | « milo/frontend/console/console.go ('k') | milo/frontend/console/html_data.go » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The LUCI Authors. All rights reserved. 1 // Copyright 2016 The LUCI Authors. All rights reserved.
2 // Use of this source code is governed under the Apache License, Version 2.0 2 // Use of this source code is governed under the Apache License, Version 2.0
3 // that can be found in the LICENSE file. 3 // that can be found in the LICENSE file.
4 4
5 package console 5 package console
6 6
7 import ( 7 import (
8 "net/http" 8 "net/http"
9 9
10 » "github.com/luci/luci-go/milo/appengine/common" 10 » "github.com/luci/luci-go/milo/common"
11 "github.com/luci/luci-go/server/router" 11 "github.com/luci/luci-go/server/router"
12 "github.com/luci/luci-go/server/templates" 12 "github.com/luci/luci-go/server/templates"
13 ) 13 )
14 14
15 // ConsoleHandler renders the console page. 15 // ConsoleHandler renders the console page.
16 func ConsoleHandler(c *router.Context) { 16 func ConsoleHandler(c *router.Context) {
17 project := c.Params.ByName("project") 17 project := c.Params.ByName("project")
18 if project == "" { 18 if project == "" {
19 common.ErrorPage(c, http.StatusBadRequest, "Missing Project") 19 common.ErrorPage(c, http.StatusBadRequest, "Missing Project")
20 return 20 return
21 } 21 }
22 name := c.Params.ByName("name") 22 name := c.Params.ByName("name")
23 23
24 result, err := console(c.Context, project, name) 24 result, err := console(c.Context, project, name)
25 if err != nil { 25 if err != nil {
26 common.ErrorPage(c, http.StatusInternalServerError, err.Error()) 26 common.ErrorPage(c, http.StatusInternalServerError, err.Error())
27 return 27 return
28 } 28 }
29 29
30 templates.MustRender(c.Context, c.Writer, "pages/console.html", template s.Args{ 30 templates.MustRender(c.Context, c.Writer, "pages/console.html", template s.Args{
31 "Console": result, 31 "Console": result,
32 }) 32 })
33 } 33 }
OLDNEW
« no previous file with comments | « milo/frontend/console/console.go ('k') | milo/frontend/console/html_data.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698