mirror of
https://github.com/TheAnachronism/docspell.git
synced 2025-06-22 10:28:27 +00:00
Allow tag ids or tag names when replacing tags
This commit is contained in:
@ -1783,12 +1783,12 @@ itemDetail flags id receive =
|
||||
}
|
||||
|
||||
|
||||
setTags : Flags -> String -> ReferenceList -> (Result Http.Error BasicResult -> msg) -> Cmd msg
|
||||
setTags : Flags -> String -> StringList -> (Result Http.Error BasicResult -> msg) -> Cmd msg
|
||||
setTags flags item tags receive =
|
||||
Http2.authPut
|
||||
{ url = flags.config.baseUrl ++ "/api/v1/sec/item/" ++ item ++ "/tags"
|
||||
, account = getAccount flags
|
||||
, body = Http.jsonBody (Api.Model.ReferenceList.encode tags)
|
||||
, body = Http.jsonBody (Api.Model.StringList.encode tags)
|
||||
, expect = Http.expectJson receive Api.Model.BasicResult.decoder
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user