1. 13 9月, 2013 2 次提交
    • A
      support template · 943fe971
      astaxie 提交于
      943fe971
    • A
      fix #153 · 9d84969b
      astaxie 提交于
      已经支持了任意定义变量的路由形式,具体的使用请参考:
      
      func TestManyRoute(t *testing.T) {
      
      	r, _ := http.NewRequest("GET", "/beego32-12.html", nil)
      	w := httptest.NewRecorder()
      
      	handler := NewControllerRegistor()
      	handler.Add("/beego:id([0-9]+)-:page([0-9]+).html", &TestController{})
      	handler.ServeHTTP(w, r)
      
      	id := r.URL.Query().Get(":id")
      	page := r.URL.Query().Get(":page")
      
      	if id != "32" {
      		t.Errorf("url param set to [%s]; want [%s]", id, "32")
      	}
      	if page != "12" {
      		t.Errorf("url param set to [%s]; want [%s]", page, "12")
      	}
      }
      9d84969b
  2. 12 9月, 2013 6 次提交
  3. 11 9月, 2013 7 次提交
  4. 10 9月, 2013 13 次提交
  5. 09 9月, 2013 1 次提交
  6. 06 9月, 2013 1 次提交
  7. 30 8月, 2013 2 次提交
  8. 28 8月, 2013 6 次提交
  9. 27 8月, 2013 2 次提交