Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Attachment ¶ added in v0.2.4
func Attachment(w http.ResponseWriter, filename string, data []byte)
Attachment attachment application/octet-stream;charset=utf-8
func JSONCustom ¶
func JSONCustom(w http.ResponseWriter, code Code, opts ...Option)
JSONCustom http.StatusBadRequest式应答,自定义code,提供给前端
func JSONDetail ¶
func JSONDetail(w http.ResponseWriter, err error, opts ...Option)
JSONDetail http.StatusBadRequest式应答,含detail字段,用于debug
Types ¶
Click to show internal directories.
Click to hide internal directories.