String returns tp as a pretty string.
()
| 45 | |
| 46 | // String returns tp as a pretty string. |
| 47 | func (tp TimePeriod) String() string { |
| 48 | return fmt.Sprintf("%s-%s", tp.From.Format(Kitchen24), tp.To.Format(Kitchen24)) |
| 49 | } |
| 50 | |
| 51 | // ParseWeekdays takes a comma-separated list of abbreviated weekdays (e.g. sat,sun) and turns them |
| 52 | // into a slice of time.Weekday. It ignores any whitespace and any invalid weekdays. |
no outgoing calls