mirror of
https://github.com/TheAnachronism/docspell.git
synced 2025-06-22 10:28:27 +00:00
Use search stats to populate search menu
This commit is contained in:
@ -9,6 +9,7 @@ module Page.Share.Data exposing (Mode(..), Model, Msg(..), PageError(..), init)
|
||||
|
||||
import Api
|
||||
import Api.Model.ItemLightList exposing (ItemLightList)
|
||||
import Api.Model.SearchStats exposing (SearchStats)
|
||||
import Api.Model.ShareSecret exposing (ShareSecret)
|
||||
import Api.Model.ShareVerifyResult exposing (ShareVerifyResult)
|
||||
import Comp.ItemCardList
|
||||
@ -41,7 +42,6 @@ type alias Model =
|
||||
, verifyResult : ShareVerifyResult
|
||||
, passwordModel : PasswordModel
|
||||
, pageError : PageError
|
||||
, items : ItemLightList
|
||||
, searchMenuModel : Comp.SearchMenu.Model
|
||||
, powerSearchInput : Comp.PowerSearchInput.Model
|
||||
, searchInProgress : Bool
|
||||
@ -58,7 +58,6 @@ emptyModel flags =
|
||||
, passwordFailed = False
|
||||
}
|
||||
, pageError = PageErrorNone
|
||||
, items = Api.Model.ItemLightList.empty
|
||||
, searchMenuModel = Comp.SearchMenu.init flags
|
||||
, powerSearchInput = Comp.PowerSearchInput.init
|
||||
, searchInProgress = False
|
||||
@ -79,6 +78,7 @@ init shareId flags =
|
||||
type Msg
|
||||
= VerifyResp (Result Http.Error ShareVerifyResult)
|
||||
| SearchResp (Result Http.Error ItemLightList)
|
||||
| StatsResp (Result Http.Error SearchStats)
|
||||
| SetPassword String
|
||||
| SubmitPassword
|
||||
| SearchMenuMsg Comp.SearchMenu.Msg
|
||||
|
Reference in New Issue
Block a user