feat: add universities and restaurants (#4)
Features: - Allow to search for individual resources by their name - Add new resources and their handler: Universities, Restaurants - Added new parameter to reverse output order Reviewed-on: #4 Co-authored-by: bdoerfchen <git@bissendorf.co> Co-committed-by: bdoerfchen <git@bissendorf.co>
This commit is contained in:
@ -55,9 +55,10 @@ type ingredient struct {
|
||||
Additionals []string
|
||||
}
|
||||
|
||||
func (d *Meal) Kind() string { return ResourceMeal }
|
||||
func (d *Meal) Name() string { return d.Title }
|
||||
func (d *Meal) Kind() string { return ResourceMeal }
|
||||
func (d *Meal) ItemName() string { return d.Title }
|
||||
|
||||
// Table output
|
||||
func (d *Meal) ColumnNames() []string { return []string{"Location", "Date", "Counter", "Price"} }
|
||||
func (d *Meal) Columns() []any {
|
||||
return []any{d.Location, d.Date.Format(time.DateOnly), d.Counter, d.Prices["Studierende"]}
|
||||
|
||||
Reference in New Issue
Block a user