Exemplo n.º 1
0
func (p *Proxy) writeStores(w http.ResponseWriter, profileIP string, prof *profile.Profile) {
	t, err := template.ParseFiles("template/stores.tmpl")
	list := formatStoreListData(prof.ListStored(), profileIP)
	err = t.Execute(w, storeListData{profileIP, list})
	if err != nil {
		fmt.Fprintln(w, "内部错误:", err)
	}
}