This commit is contained in:
Ajay Sivan 2024-07-24 13:40:02 +05:30
parent 3cbc7c1730
commit c939412b8e
No known key found for this signature in database
GPG Key ID: 5F9AC120AE59597A
1 changed files with 11 additions and 10 deletions

View File

@ -20,7 +20,8 @@
[:dispatch [:dispatch
[:wallet.swap/select-asset-to-pay [:wallet.swap/select-asset-to-pay
{:token token {:token token
:network (when (= count token-networks) (first token-networks))}]]]}))) :network (when (= count token-networks)
(first token-networks))}]]]})))
(rf/reg-event-fx :wallet.swap/select-asset-to-pay (rf/reg-event-fx :wallet.swap/select-asset-to-pay
(fn [{:keys [db]} [{:keys [token network]}]] (fn [{:keys [db]} [{:keys [token network]}]]
@ -34,15 +35,15 @@
[:show-bottom-sheet [:show-bottom-sheet
{:content (fn [] {:content (fn []
[network-selection/view [network-selection/view
{:token-symbol (:symbol token) {:token-symbol (:symbol token)
:on-select-network :on-select-network (fn [network]
(fn [network] (rf/dispatch [:hide-bottom-sheet])
(rf/dispatch [:hide-bottom-sheet]) (rf/dispatch
(rf/dispatch [:wallet.swap/select-asset-to-pay
[:wallet.swap/select-asset-to-pay {:token token
{:token token :network network
:network network :stack-id
:stack-id :screen/wallet.swap-select-asset-to-pay}]))}])}]]])})) :screen/wallet.swap-select-asset-to-pay}]))}])}]]])}))
(rf/reg-event-fx :wallet.swap/clean-asset-to-pay (rf/reg-event-fx :wallet.swap/clean-asset-to-pay
(fn [{:keys [db]}] (fn [{:keys [db]}]