MCPcopy Create free account
hub / github.com/APIParkLab/APIPark / genTime

Function genTime

controller/strategy/iml.go:215–225  ·  view source on GitHub ↗
(t string, defaultValue time.Time)

Source from the content-addressed store, hash-verified

213}
214
215func genTime(t string, defaultValue time.Time) (time.Time, error) {
216 if t == "" {
217 return defaultValue, nil
218 }
219
220 s, err := strconv.ParseInt(t, 10, 64)
221 if err != nil {
222 return time.Time{}, err
223 }
224 return time.Unix(s, 0), nil
225}
226
227func (i *imlStrategyController) GetStrategyLogs(ctx *gin.Context, keyword string, strategyId string, start string, end string, limit string, offset string) ([]*strategy_dto.LogItem, int64, error) {
228 now := time.Now()

Callers 1

GetStrategyLogsMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected