Change "empty trash" settings for a collective and submit the job

This commit is contained in:
eikek
2021-08-14 18:06:48 +02:00
parent 828e5cf703
commit 4901276c66
14 changed files with 505 additions and 19 deletions

View File

@ -130,6 +130,7 @@ module Api exposing
, setTagsMultiple
, setUnconfirmed
, startClassifier
, startEmptyTrash
, startOnceNotifyDueItems
, startOnceScanMailbox
, startReIndex
@ -996,6 +997,19 @@ startClassifier flags receive =
}
startEmptyTrash :
Flags
-> (Result Http.Error BasicResult -> msg)
-> Cmd msg
startEmptyTrash flags receive =
Http2.authPost
{ url = flags.config.baseUrl ++ "/api/v1/sec/collective/emptytrash/startonce"
, account = getAccount flags
, body = Http.emptyBody
, expect = Http.expectJson receive Api.Model.BasicResult.decoder
}
getTagCloud : Flags -> (Result Http.Error TagCloud -> msg) -> Cmd msg
getTagCloud flags receive =
Http2.authGet