Implement change order endpoint
This commit is contained in:
@@ -16,12 +16,18 @@ func (a *Ajax) Cur(r *http.Request) (string, string, []string) {
|
||||
listID := form.Get(r, "list")
|
||||
taskID := form.Get(r, "id")
|
||||
if listID == "" {
|
||||
a.storageGet(path.Join("task", taskID, "map"), &listID)
|
||||
listID, _ = a.taskIDToListID(taskID)
|
||||
}
|
||||
tags, _ := r.URL.Query()["t"]
|
||||
return listID, taskID, tags
|
||||
}
|
||||
|
||||
func (a *Ajax) taskIDToListID(taskID string) (string, error) {
|
||||
var listID string
|
||||
err := a.storageGet(path.Join("task", taskID, "map"), &listID)
|
||||
return listID, err
|
||||
}
|
||||
|
||||
func (a *Ajax) storageListLists(filters ...func(t *list.List) bool) ([]*list.List, error) {
|
||||
results, err := a.DB.List(nil, path.Join("list"), path.Join("list", "}"))
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user