forked from free-lancers/electricity_bill_calc_service
feat(report):完成获取公示用数据接口的功能。
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
package exceptions
|
||||
|
||||
import "fmt"
|
||||
|
||||
type NotFoundError struct {
|
||||
Message string
|
||||
}
|
||||
@@ -8,6 +10,10 @@ func NewNotFoundError(msg string) *NotFoundError {
|
||||
return &NotFoundError{Message: msg}
|
||||
}
|
||||
|
||||
func NewNotFoundErrorFromError(msg string, err error) *NotFoundError {
|
||||
return &NotFoundError{Message: fmt.Sprintf("%s,%v", msg, err)}
|
||||
}
|
||||
|
||||
func (e NotFoundError) Error() string {
|
||||
return e.Message
|
||||
}
|
||||
|
Reference in New Issue
Block a user