[#10239] Remove "Fetch last 24 hours" option
This commit is contained in:
parent
473c5135b2
commit
35381a55c0
|
@ -248,11 +248,6 @@
|
|||
(fn [cofx _]
|
||||
(mailserver/check-connection cofx)))
|
||||
|
||||
(handlers/register-handler-fx
|
||||
:mailserver/fetch-history
|
||||
(fn [cofx [_ chat-id from-timestamp]]
|
||||
(mailserver/fetch-history cofx chat-id {:from from-timestamp})))
|
||||
|
||||
(handlers/register-handler-fx
|
||||
:mailserver.callback/generate-mailserver-symkey-success
|
||||
(fn [cofx [_ mailserver sym-key-id]]
|
||||
|
@ -381,28 +376,6 @@
|
|||
(re-frame/dispatch [:bottom-sheet/hide])
|
||||
(re-frame/dispatch [:chat.ui/clear-history chat-id]))}}))
|
||||
|
||||
(handlers/register-handler-fx
|
||||
:chat.ui/fetch-history-pressed
|
||||
(fn [{:keys [now] :as cofx} [_ chat-id]]
|
||||
(mailserver/fetch-history cofx chat-id
|
||||
{:from (- (quot now 1000) mailserver.constants/one-day)})))
|
||||
|
||||
(handlers/register-handler-fx
|
||||
:chat.ui/fetch-history-pressed48-60
|
||||
(fn [{:keys [now] :as cofx} [_ chat-id]]
|
||||
(let [now (quot now 1000)]
|
||||
(mailserver/fetch-history cofx chat-id
|
||||
{:from (- now (* 2.5 mailserver.constants/one-day))
|
||||
:to (- now (* 2 mailserver.constants/one-day))}))))
|
||||
|
||||
(handlers/register-handler-fx
|
||||
:chat.ui/fetch-history-pressed84-96
|
||||
(fn [{:keys [now] :as cofx} [_ chat-id]]
|
||||
(let [now (quot now 1000)]
|
||||
(mailserver/fetch-history cofx chat-id
|
||||
{:from (- now (* 4 mailserver.constants/one-day))
|
||||
:to (- now (* 3.5 mailserver.constants/one-day))}))))
|
||||
|
||||
(handlers/register-handler-fx
|
||||
:chat.ui/fill-gaps
|
||||
(fn [{:keys [db] :as cofx} [_ gap-ids]]
|
||||
|
|
|
@ -429,7 +429,6 @@
|
|||
:export-account
|
||||
:failed
|
||||
:faq
|
||||
:fetch-history
|
||||
:fetch-messages
|
||||
:find
|
||||
:finish
|
||||
|
|
|
@ -7,7 +7,6 @@
|
|||
[status-im.ethereum.json-rpc :as json-rpc]
|
||||
[status-im.i18n :as i18n]
|
||||
[status-im.mailserver.constants :as constants]
|
||||
[status-im.mailserver.topics :as mailserver.topics]
|
||||
[status-im.multiaccounts.model :as multiaccounts.model]
|
||||
[status-im.multiaccounts.update.core :as multiaccounts.update]
|
||||
[status-im.native-module.core :as status]
|
||||
|
@ -910,26 +909,6 @@
|
|||
:on-accept #(re-frame/dispatch [:mailserver.ui/retry-request-pressed])
|
||||
:confirm-button-text (i18n/label :t/mailserver-request-retry)}}))
|
||||
|
||||
(fx/defn fetch-history
|
||||
"Retrive a list of topics given a chat id, set them to the specified
|
||||
time interval and start a mailserver request"
|
||||
[{:keys [db] :as cofx} chat-id {:keys [from to]}]
|
||||
(let [topics (mailserver.topics/topics-for-chat
|
||||
db
|
||||
chat-id)]
|
||||
(log/debug "fetch-history" "chat-id:" chat-id "from-timestamp:"
|
||||
from "topics:" topics)
|
||||
(fx/merge cofx
|
||||
{:db (reduce
|
||||
(fn [db topic]
|
||||
(cond-> (assoc-in db [:mailserver/requests-from topic] from)
|
||||
|
||||
to
|
||||
(assoc-in [:mailserver/requests-to topic] to)))
|
||||
db
|
||||
topics)}
|
||||
(process-next-messages-request))))
|
||||
|
||||
(fx/defn fill-the-gap
|
||||
[{:keys [db] :as cofx} {:keys [gaps topics chat-id]}]
|
||||
(let [mailserver (get-mailserver-when-ready cofx)
|
||||
|
|
|
@ -37,12 +37,6 @@
|
|||
:accessibility-label :clear-history-button
|
||||
:icon :main-icons/close
|
||||
:on-press #(re-frame/dispatch [:chat.ui/clear-history-pressed chat-id])}]
|
||||
[quo/list-item
|
||||
{:theme :accent
|
||||
:title (i18n/label :t/fetch-history)
|
||||
:accessibility-label :fetch-history-button
|
||||
:icon :main-icons/arrow-down
|
||||
:on-press #(hide-sheet-and-dispatch [:chat.ui/fetch-history-pressed chat-id])}]
|
||||
[quo/list-item
|
||||
{:theme :negative
|
||||
:title (i18n/label :t/delete-chat)
|
||||
|
@ -77,12 +71,6 @@
|
|||
:accessibility-label :clear-history-button
|
||||
:icon :main-icons/close
|
||||
:on-press #(re-frame/dispatch [:chat.ui/clear-history-pressed chat-id])}]
|
||||
[quo/list-item
|
||||
{:theme :accent
|
||||
:title (i18n/label :t/fetch-history)
|
||||
:accessibility-label :fetch-history-button
|
||||
:icon :main-icons/arrow-down
|
||||
:on-press #(hide-sheet-and-dispatch [:chat.ui/fetch-history-pressed chat-id])}]
|
||||
[quo/list-item
|
||||
{:theme :negative
|
||||
:title (i18n/label :t/delete-chat)
|
||||
|
@ -121,12 +109,6 @@
|
|||
:accessibility-label :clear-history-button
|
||||
:icon :main-icons/close
|
||||
:on-press #(re-frame/dispatch [:chat.ui/clear-history-pressed chat-id])}]
|
||||
[quo/list-item
|
||||
{:theme :accent
|
||||
:title (i18n/label :t/fetch-history)
|
||||
:accessibility-label :fetch-history-button
|
||||
:icon :main-icons/arrow-down
|
||||
:on-press #(hide-sheet-and-dispatch [:chat.ui/fetch-history-pressed chat-id])}]
|
||||
(when joined?
|
||||
[quo/list-item
|
||||
{:theme :negative
|
||||
|
|
|
@ -520,7 +520,6 @@
|
|||
"faq": "الاسئله المتداولة",
|
||||
"favourites": "المفضلة",
|
||||
"favourites-empty": "ستظهر العناوين التي تمت إضافتها إلى المفضلة هنا",
|
||||
"fetch-history": "إحضار آخر ٢٤ ساعة",
|
||||
"fetch-messages": "↓ جلب الرسائل",
|
||||
"find": "العثور",
|
||||
"finish": "إنهاء",
|
||||
|
|
|
@ -495,7 +495,6 @@
|
|||
"faq": "Häufig gestellte Fragen",
|
||||
"favourites": "Favoriten",
|
||||
"favourites-empty": "Favorisierte Adressen werden hier angezeigt",
|
||||
"fetch-history": "Letzten 24 Stunden abrufen",
|
||||
"fetch-messages": "↓ Nachrichten abrufen",
|
||||
"find": "Finden",
|
||||
"finish": "Fertig",
|
||||
|
|
|
@ -468,7 +468,6 @@
|
|||
"export-account": "Export account",
|
||||
"failed": "Failed",
|
||||
"faq": "Frequently asked questions",
|
||||
"fetch-history": "Fetch last 24 hours",
|
||||
"fetch-messages": "↓ Fetch messages",
|
||||
"find": "Find",
|
||||
"finish": "Finish",
|
||||
|
|
|
@ -496,7 +496,6 @@
|
|||
"faq": "Preguntas frecuentes",
|
||||
"favourites": "Favoritos",
|
||||
"favourites-empty": "Las direcciones agregadas a favoritos aparecerán aquí",
|
||||
"fetch-history": "Obtener las últimas 24 horas",
|
||||
"fetch-messages": "↓ Recuperar mensajes",
|
||||
"find": "Encontrar",
|
||||
"finish": "Finalizar",
|
||||
|
|
|
@ -496,7 +496,6 @@
|
|||
"faq": "Preguntas frecuentes",
|
||||
"favourites": "Favoritos",
|
||||
"favourites-empty": "Las direcciones agregadas a favoritos aparecerán aquí",
|
||||
"fetch-history": "Obtener las últimas 24 horas",
|
||||
"fetch-messages": "↓ Recuperar mensajes",
|
||||
"find": "Encontrar",
|
||||
"finish": "Finalizar",
|
||||
|
|
|
@ -520,7 +520,6 @@
|
|||
"faq": "Mga madalas na tinatanong",
|
||||
"favourites": "Mga paborito",
|
||||
"favourites-empty": "Lilitaw dito ang mga address na idinagdag sa mga paborito",
|
||||
"fetch-history": "Ang Fetch ay tatagal hanggang 24 na oras",
|
||||
"fetch-messages": "↓ Kumuha ng mga mensahe",
|
||||
"find": "Maghanap",
|
||||
"finish": "Tapos na",
|
||||
|
|
|
@ -496,7 +496,6 @@
|
|||
"faq": "Foire aux questions",
|
||||
"favourites": "Favoris",
|
||||
"favourites-empty": "Les adresses ajoutées aux favoris apparaîtront ici",
|
||||
"fetch-history": "Récupérer les dernières 24 heures",
|
||||
"fetch-messages": "↓ Récupérer les messages",
|
||||
"find": "Trouver",
|
||||
"finish": "Finir",
|
||||
|
|
|
@ -490,7 +490,6 @@
|
|||
"faq": "Pertanyaan yang sering diajukan",
|
||||
"favourites": "Favorit",
|
||||
"favourites-empty": "Alamat yang ditambahkan ke favorit akan muncul di sini",
|
||||
"fetch-history": "Ambil 24 jam terakhir",
|
||||
"fetch-messages": "↓ Mengambil pesan",
|
||||
"find": "Temukan",
|
||||
"finish": "Selesai",
|
||||
|
|
|
@ -496,7 +496,6 @@
|
|||
"faq": "Domande frequenti",
|
||||
"favourites": "Preferiti",
|
||||
"favourites-empty": "Gli indirizzi aggiunti ai preferiti verranno visualizzati qui",
|
||||
"fetch-history": "Recupera le ultime 24 ore",
|
||||
"fetch-messages": "↓ Recupera messaggi",
|
||||
"find": "Trova",
|
||||
"finish": "Finito",
|
||||
|
|
|
@ -382,7 +382,6 @@
|
|||
"export-account": "アカウントをエクスポート",
|
||||
"failed": "失敗しました",
|
||||
"faq": "よくある質問",
|
||||
"fetch-history": "過去24時間の取得",
|
||||
"fetch-messages": "↓メッセージを取得する",
|
||||
"find": "見つける",
|
||||
"finish": "完了",
|
||||
|
|
|
@ -490,7 +490,6 @@
|
|||
"faq": "자주 묻는 질문",
|
||||
"favourites": "즐겨 찾기",
|
||||
"favourites-empty": "즐겨찾기에 추가 된 주소가 여기에 표시됩니다.",
|
||||
"fetch-history": "지난 24시간 내역 불러오기",
|
||||
"fetch-messages": "↓ 메시지 가져 오기",
|
||||
"find": "찾기",
|
||||
"finish": "완료",
|
||||
|
|
|
@ -496,7 +496,6 @@
|
|||
"faq": "Perguntas frequentes",
|
||||
"favourites": "Favoritos",
|
||||
"favourites-empty": "Os endereços adicionados aos favoritos aparecerão aqui",
|
||||
"fetch-history": "Buscar últimas 24 horas",
|
||||
"fetch-messages": "↓ Buscar mensagens",
|
||||
"find": "Encontrar",
|
||||
"finish": "Terminar",
|
||||
|
|
|
@ -496,7 +496,6 @@
|
|||
"faq": "Perguntas frequentes",
|
||||
"favourites": "Favoritos",
|
||||
"favourites-empty": "Os endereços adicionados aos favoritos aparecerão aqui",
|
||||
"fetch-history": "Buscar últimas 24 horas",
|
||||
"fetch-messages": "↓ Buscar mensagens",
|
||||
"find": "Encontrar",
|
||||
"finish": "Terminar",
|
||||
|
|
|
@ -514,7 +514,6 @@
|
|||
"faq": "Часто задаваемые вопросы",
|
||||
"favourites": "Избранное",
|
||||
"favourites-empty": "Здесь будут отображены адреса, добавленные в избранное.",
|
||||
"fetch-history": "Получить сообщения за последние 24 часа",
|
||||
"fetch-messages": "↓ Открыть сообщения",
|
||||
"find": "Найти",
|
||||
"finish": "Закончить",
|
||||
|
|
|
@ -496,7 +496,6 @@
|
|||
"faq": "Sıkça Sorulan Sorular",
|
||||
"favourites": "Favoriler",
|
||||
"favourites-empty": "Sık kullanılanlara eklenen adresler burada görünecek",
|
||||
"fetch-history": "Son 24 saati getir",
|
||||
"fetch-messages": "Mesajları getir",
|
||||
"find": "Bul",
|
||||
"finish": "Bitti",
|
||||
|
|
|
@ -490,7 +490,6 @@
|
|||
"faq": "常见问题",
|
||||
"favourites": "收藏夹",
|
||||
"favourites-empty": "添加到收藏夹的地址将显示在这里",
|
||||
"fetch-history": "获取最近24小时的消息",
|
||||
"fetch-messages": "↓获取消息",
|
||||
"find": "查找",
|
||||
"finish": "完成",
|
||||
|
|
|
@ -392,7 +392,6 @@
|
|||
"export-account": "导出帐户",
|
||||
"failed": "失败",
|
||||
"faq": "常见问题",
|
||||
"fetch-history": "获取最近24小时",
|
||||
"fetch-messages": "↓获取消息",
|
||||
"find": "查找",
|
||||
"finish": "完成",
|
||||
|
|
|
@ -490,7 +490,6 @@
|
|||
"faq": "常見問題",
|
||||
"favourites": "收藏夾",
|
||||
"favourites-empty": "添加到收藏夾的地址將顯示在此處",
|
||||
"fetch-history": "過去24小時中",
|
||||
"fetch-messages": "↓取得訊息",
|
||||
"find": "搜尋",
|
||||
"finish": "完成",
|
||||
|
|
|
@ -367,7 +367,6 @@
|
|||
"export-account": "导出帐户",
|
||||
"failed": "失败",
|
||||
"faq": "常见问题",
|
||||
"fetch-history": "获取最近24小时",
|
||||
"fetch-messages": "↓获取消息",
|
||||
"find": "查找",
|
||||
"finishing-card-setup": "卡片设置完成",
|
||||
|
|
Loading…
Reference in New Issue