2018-06-10 19:49:40 +02:00
|
|
|
package v1
|
|
|
|
|
|
|
|
import (
|
|
|
|
"github.com/labstack/echo"
|
|
|
|
"net/http"
|
|
|
|
)
|
|
|
|
|
2018-07-10 14:02:23 +02:00
|
|
|
// AddListItem ...
|
2018-06-12 19:44:47 +02:00
|
|
|
func AddListItem(c echo.Context) error {
|
2018-06-13 13:45:22 +02:00
|
|
|
// swagger:operation PUT /lists/{listID} lists addListItem
|
|
|
|
// ---
|
|
|
|
// summary: Adds an item to a list
|
|
|
|
// consumes:
|
|
|
|
// - application/json
|
|
|
|
// produces:
|
|
|
|
// - application/json
|
|
|
|
// parameters:
|
|
|
|
// - name: listID
|
|
|
|
// in: path
|
|
|
|
// description: ID of the list to use
|
|
|
|
// type: string
|
|
|
|
// required: true
|
|
|
|
// - name: body
|
|
|
|
// in: body
|
|
|
|
// schema:
|
|
|
|
// "$ref": "#/definitions/ListItem"
|
|
|
|
// responses:
|
|
|
|
// "200":
|
|
|
|
// "$ref": "#/responses/ListItem"
|
|
|
|
// "400":
|
|
|
|
// "$ref": "#/responses/Message"
|
|
|
|
// "500":
|
|
|
|
// "$ref": "#/responses/Message"
|
|
|
|
|
2018-07-11 02:39:55 +02:00
|
|
|
return echo.NewHTTPError(http.StatusNotImplemented)
|
2018-06-12 19:44:47 +02:00
|
|
|
}
|
|
|
|
|
2018-07-10 14:02:23 +02:00
|
|
|
// UpdateListItem ...
|
2018-06-12 19:44:47 +02:00
|
|
|
func UpdateListItem(c echo.Context) error {
|
2018-06-13 13:45:22 +02:00
|
|
|
// swagger:operation PUT /item/{itemID} lists updateListItem
|
|
|
|
// ---
|
|
|
|
// summary: Updates a list item
|
|
|
|
// consumes:
|
|
|
|
// - application/json
|
|
|
|
// produces:
|
|
|
|
// - application/json
|
|
|
|
// parameters:
|
|
|
|
// - name: itemID
|
|
|
|
// in: path
|
|
|
|
// description: ID of the item to update
|
|
|
|
// type: string
|
|
|
|
// required: true
|
|
|
|
// - name: body
|
|
|
|
// in: body
|
|
|
|
// schema:
|
|
|
|
// "$ref": "#/definitions/ListItem"
|
|
|
|
// responses:
|
|
|
|
// "200":
|
|
|
|
// "$ref": "#/responses/ListItem"
|
|
|
|
// "400":
|
|
|
|
// "$ref": "#/responses/Message"
|
|
|
|
// "500":
|
|
|
|
// "$ref": "#/responses/Message"
|
|
|
|
|
2018-07-11 02:39:55 +02:00
|
|
|
return echo.NewHTTPError(http.StatusNotImplemented)
|
2018-07-11 02:40:29 +02:00
|
|
|
}
|