diff --git a/.github/workflows/atomicdex-desktop-ci.yml b/.github/workflows/atomicdex-desktop-ci.yml index f81a703834..21706cc733 100644 --- a/.github/workflows/atomicdex-desktop-ci.yml +++ b/.github/workflows/atomicdex-desktop-ci.yml @@ -32,7 +32,7 @@ jobs: include: - name: ubuntu-qt-5-15-2 - os: ubuntu-16.04 + os: ubuntu-18.04 qt: '5.15.2' type: 'release' diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index a15c11a911..02e4592433 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -85,7 +85,7 @@ AtomicDex-linux-zip: paths: - $CI_PROJECT_DIR/atomicdex-desktop-linux-${CI_COMMIT_SHA::9}.zip when: always - expire_in: 1 week + expire_in: 3 days AtomicDex-linux-AppImage: stage: upload_linux_appimage @@ -97,7 +97,7 @@ AtomicDex-linux-AppImage: paths: - $CI_PROJECT_DIR/atomicdex-desktop-${CI_COMMIT_SHA::9}-x86_64.AppImage when: always - expire_in: 1 week + expire_in: 3 days AtomicDex-linux-tar: stage: upload_linux_tar @@ -109,4 +109,4 @@ AtomicDex-linux-tar: paths: - $CI_PROJECT_DIR/atomicdex-desktop-linux-${CI_COMMIT_SHA::9}.tar.zst when: always - expire_in: 1 week + expire_in: 3 days diff --git a/CMakeLists.txt b/CMakeLists.txt index 4af760fdc1..0b54ea1446 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -11,7 +11,7 @@ include(vcpkg_prerequisites) include(qt_prerequisites) include(cfg_hash) -project(${DEX_PROJECT_NAME} LANGUAGES CXX VERSION 0.5.0) +project(${DEX_PROJECT_NAME} LANGUAGES CXX VERSION 0.5.1) message(STATUS "${PROJECT_NAME} is version ${PROJECT_VERSION}") include(cmake_default_options) @@ -61,13 +61,13 @@ endif () ##! We fetch our dependencies if (APPLE) FetchContent_Declare(mm2 - URL https://github.com/KomodoPlatform/atomicDEX-API/releases/download/v1.1.0/mm2-41170748d-Darwin-Release.zip) + URL https://github.com/KomodoPlatform/atomicDEX-API/releases/download/beta-2.1.4270/mm2-3a3f159bf-Darwin-Release.zip) elseif (UNIX AND NOT APPLE) FetchContent_Declare(mm2 - URL https://github.com/KomodoPlatform/atomicDEX-API/releases/download/v1.1.0/mm2-41170748d-Linux-Release.zip) + URL https://github.com/KomodoPlatform/atomicDEX-API/releases/download/beta-2.1.4270/mm2-3a3f159bf-Linux-Release.zip) else () FetchContent_Declare(mm2 - URL https://github.com/KomodoPlatform/atomicDEX-API/releases/download/v1.1.0/mm2-41170748d-Windows_NT-Release.zip) + URL https://github.com/KomodoPlatform/atomicDEX-API/releases/download/beta-2.1.4270/mm2-3a3f159bf-Windows_NT-Release.zip) endif () #FetchContent_Declare(qmaterial URL https://github.com/KomodoPlatform/Qaterial/archive/last-clang-working-2.zip) diff --git a/assets/config/0.5.0-coins.json b/assets/config/0.5.1-coins.json similarity index 96% rename from assets/config/0.5.0-coins.json rename to assets/config/0.5.1-coins.json index 34e620e1c1..5a88f422fe 100644 --- a/assets/config/0.5.0-coins.json +++ b/assets/config/0.5.1-coins.json @@ -142,6 +142,40 @@ "active": false, "currently_enabled": false }, + "AXS-BEP20": { + "coin": "AXS-BEP20", + "name": "Axie Infinity", + "coinpaprika_id": "axs-axie-infinity", + "coingecko_id": "axie-infinity", + "nodes": [ + "http://bsc1.cipig.net:8655", + "http://bsc2.cipig.net:8655", + "http://bsc3.cipig.net:8655" + ], + "explorer_url": [ + "https://bscscan.com/" + ], + "type": "BEP-20", + "active": false, + "currently_enabled": false + }, + "AXS-ERC20": { + "coin": "AXS-ERC20", + "name": "Axie Infinity", + "coinpaprika_id": "axs-axie-infinity", + "coingecko_id": "axie-infinity", + "nodes": [ + "http://eth1.cipig.net:8555", + "http://eth2.cipig.net:8555", + "http://eth3.cipig.net:8555" + ], + "explorer_url": [ + "https://etherscan.io/" + ], + "type": "ERC-20", + "active": false, + "currently_enabled": false + }, "BNB": { "coin": "BNB", "name": "Binance Coin", @@ -209,22 +243,39 @@ "active": false, "currently_enabled": false }, - "ARPA": { - "coin": "ARPA", - "name": "ARPA Chain", - "coinpaprika_id": "arpa-arpa-chain", - "coingecko_id": "arpa-chain", - "nodes": [ - "http://eth1.cipig.net:8555", - "http://eth2.cipig.net:8555", - "http://eth3.cipig.net:8555" - ], - "explorer_url": [ - "https://etherscan.io/" - ], - "type": "ERC-20", - "active": false, - "currently_enabled": false + "ARPA-BEP20": { + "coin": "ARPA-BEP20", + "name": "ARPA Chain", + "coinpaprika_id": "arpa-arpa-chain", + "coingecko_id": "arpa-chain", + "nodes": [ + "http://bsc1.cipig.net:8655", + "http://bsc2.cipig.net:8655", + "http://bsc3.cipig.net:8655" + ], + "explorer_url": [ + "https://bscscan.com/" + ], + "type": "BEP-20", + "active": false, + "currently_enabled": false + }, + "ARPA-ERC20": { + "coin": "ARPA-ERC20", + "name": "ARPA Chain", + "coinpaprika_id": "arpa-arpa-chain", + "coingecko_id": "arpa-chain", + "nodes": [ + "http://eth1.cipig.net:8555", + "http://eth2.cipig.net:8555", + "http://eth3.cipig.net:8555" + ], + "explorer_url": [ + "https://etherscan.io/" + ], + "type": "ERC-20", + "active": false, + "currently_enabled": false }, "ATOM-BEP20": { "coin": "ATOM-BEP20", @@ -881,7 +932,7 @@ { "url": "woolloomooloo.ecoincore.com:34333", "protocol": "SSL", - "disable_cert_verification": false + "disable_cert_verification": true }, { "url": "lenoir.ecoincore.com:34333", @@ -1523,6 +1574,23 @@ "active": false, "currently_enabled": false }, + "FJC-BEP20": { + "coin": "FJC-BEP20", + "name": "Fujicoin", + "coinpaprika_id": "fjc-fujicoin", + "coingecko_id": "fujicoin", + "nodes": [ + "http://bsc1.cipig.net:8655", + "http://bsc2.cipig.net:8655", + "http://bsc3.cipig.net:8655" + ], + "explorer_url": [ + "https://bscscan.com/" + ], + "type": "BEP-20", + "active": false, + "currently_enabled": false + }, "STFIRO": { "coin": "STFIRO", "name": "StakedFIRO", @@ -1652,6 +1720,26 @@ "active": false, "currently_enabled": false }, + "GRMS": { + "coin": "GRMS", + "type": "Smart Chain", + "name": "GRMS", + "coingecko_id": "test-coin", + "coinpaprika_id": "grms-grms", + "electrum": [ + { + "url": "89.108.102.188:17485" + }, + { + "url": "31.31.199.13:17485" + } + ], + "explorer_url": [ + "https://explorer.grms.pw/" + ], + "active": false, + "currently_enabled": false + }, "GRS": { "coin": "GRS", "name": "Groestlcoin", @@ -1818,6 +1906,40 @@ "currently_enabled": false, "wallet_only": true }, + "KNC-BEP20": { + "coin": "KNC-BEP20", + "name": "Kyber Network", + "coinpaprika_id": "knc-kyber-network", + "coingecko_id": "kyber-network-crystal", + "nodes": [ + "http://bsc1.cipig.net:8655", + "http://bsc2.cipig.net:8655", + "http://bsc3.cipig.net:8655" + ], + "explorer_url": [ + "https://bscscan.com/" + ], + "type": "BEP-20", + "active": false, + "currently_enabled": false + }, + "KNC-ERC20": { + "coin": "KNC-ERC20", + "name": "Kyber Network", + "coinpaprika_id": "knc-kyber-network", + "coingecko_id": "kyber-network-crystal", + "nodes": [ + "http://eth1.cipig.net:8555", + "http://eth2.cipig.net:8555", + "http://eth3.cipig.net:8555" + ], + "explorer_url": [ + "https://etherscan.io/" + ], + "type": "ERC-20", + "active": false, + "currently_enabled": false + }, "KOIN": { "coin": "KOIN", "name": "Koinon", @@ -1959,6 +2081,29 @@ "active": false, "currently_enabled": false }, + "LTFN": { + "coin": "LTFN", + "name": "Litecoin Finance", + "coinpaprika_id": "test-coin", + "coingecko_id": "litecoin-finance", + "electrum": [ + { + "url": "eltfnx.scalaris.info:30001" + }, + { + "url": "eltfnx6.scalaris.info:30001" + }, + { + "url": "eltfnx7.scalaris.info:30001" + } + ], + "explorer_url": [ + "https://openchains.info/coin/ltfn/" + ], + "type": "UTXO", + "active": false, + "currently_enabled": false + }, "MATIC-BEP20": { "coin": "MATIC-BEP20", "name": "Polygon", @@ -2733,7 +2878,7 @@ "coin": "QI", "name": "QiSwap", "coingecko_id": "qiswap", - "coinpaprika_id": "test-coin", + "coinpaprika_id": "qi-qiswap", "active": false, "currently_enabled": false, "explorer_url": [ @@ -3480,7 +3625,7 @@ "TKL": { "coin": "TKL", "name": "Tokel", - "coinpaprika_id": "test-coin", + "coinpaprika_id": "tkl-tokel", "coingecko_id": "test-coin", "electrum": [ @@ -3701,6 +3846,23 @@ "active": false, "currently_enabled": false }, + "WWCN-ERC20": { + "coin": "WWCN-ERC20", + "name": "Wrapped Widecoin", + "coinpaprika_id": "wwcn-wrapped-widecoin", + "coingecko_id": "wrapped-widecoin", + "nodes": [ + "http://eth1.cipig.net:8555", + "http://eth2.cipig.net:8555", + "http://eth3.cipig.net:8555" + ], + "explorer_url": [ + "https://etherscan.io/" + ], + "type": "ERC-20", + "active": false, + "currently_enabled": false + }, "WLC": { "coin": "WLC", "name": "Wireless Coin", @@ -4016,7 +4178,7 @@ "coin": "ZET", "name": "Zetacoin", "coinpaprika_id": "zet-zetacoin", - "coingecko_id": "test-coin", + "coingecko_id": "zetacoin", "electrum": [ { "url": "failover.zet.ewmci.xyz:50002", @@ -4254,7 +4416,7 @@ "coin": "QC", "name": "Qcash", "coingecko_id": "qcash", - "coinpaprika_id": "test-coin", + "coinpaprika_id": "qc-qcash", "active": false, "currently_enabled": false, "explorer_url": [ @@ -4645,23 +4807,6 @@ "active": false, "currently_enabled": false }, - "KNC": { - "coin": "KNC", - "name": "KyberNetwork", - "coinpaprika_id": "knc-kyber-network", - "coingecko_id": "kyber-network", - "nodes": [ - "http://eth1.cipig.net:8555", - "http://eth2.cipig.net:8555", - "http://eth3.cipig.net:8555" - ], - "explorer_url": [ - "https://etherscan.io/" - ], - "type": "ERC-20", - "active": false, - "currently_enabled": false - }, "LEO": { "coin": "LEO", "name": "Bitfinex LEO Token", @@ -5138,6 +5283,30 @@ "active": false, "currently_enabled": false }, + "USBL": { + "active": false, + "coin": "USBL", + "name": "Balanced", + "coingecko_id": "balanced", + "coinpaprika_id": "balanced-balanced", + "currently_enabled": false, + "electrum": [ + { + "url": "swap.softbalanced.com:50001", + "protocol": "TCP" + }, + { + "url": "swap.softbalanced.com:50002", + "protocol": "SSL", + "disable_cert_verification": true + } + ], + "explorer_url": [ + "https://softbalanced.com:3001/insight/" + ], + "explorer_tx_url": "tx/", + "type": "UTXO" + }, "UTK": { "coin": "UTK", "name": "UTRUST", diff --git a/atomic_defi_design/assets/images/coins/axs.png b/atomic_defi_design/assets/images/coins/axs.png new file mode 100644 index 0000000000..c07db42c22 Binary files /dev/null and b/atomic_defi_design/assets/images/coins/axs.png differ diff --git a/atomic_defi_design/assets/images/coins/grms.png b/atomic_defi_design/assets/images/coins/grms.png new file mode 100644 index 0000000000..11c316c475 Binary files /dev/null and b/atomic_defi_design/assets/images/coins/grms.png differ diff --git a/atomic_defi_design/assets/images/coins/ltfn.png b/atomic_defi_design/assets/images/coins/ltfn.png new file mode 100644 index 0000000000..182dc057b1 Binary files /dev/null and b/atomic_defi_design/assets/images/coins/ltfn.png differ diff --git a/atomic_defi_design/assets/images/coins/usbl.png b/atomic_defi_design/assets/images/coins/usbl.png new file mode 100644 index 0000000000..a77d949c9a Binary files /dev/null and b/atomic_defi_design/assets/images/coins/usbl.png differ diff --git a/atomic_defi_design/assets/images/coins/wwcn.png b/atomic_defi_design/assets/images/coins/wwcn.png new file mode 100644 index 0000000000..bac60e9168 Binary files /dev/null and b/atomic_defi_design/assets/images/coins/wwcn.png differ diff --git a/atomic_defi_design/assets/images/providers/binance.png b/atomic_defi_design/assets/images/providers/binance.png new file mode 100644 index 0000000000..fd9f78dfef Binary files /dev/null and b/atomic_defi_design/assets/images/providers/binance.png differ diff --git a/atomic_defi_design/assets/images/providers/coingecko.png b/atomic_defi_design/assets/images/providers/coingecko.png new file mode 100644 index 0000000000..1ca5e43e0d Binary files /dev/null and b/atomic_defi_design/assets/images/providers/coingecko.png differ diff --git a/atomic_defi_design/assets/images/providers/coinpaprika.png b/atomic_defi_design/assets/images/providers/coinpaprika.png new file mode 100644 index 0000000000..36600af05f Binary files /dev/null and b/atomic_defi_design/assets/images/providers/coinpaprika.png differ diff --git a/atomic_defi_design/assets/languages/atomic_defi_en.ts b/atomic_defi_design/assets/languages/atomic_defi_en.ts index bc22c921c3..99c30c52dc 100644 --- a/atomic_defi_design/assets/languages/atomic_defi_en.ts +++ b/atomic_defi_design/assets/languages/atomic_defi_en.ts @@ -17,154 +17,154 @@ AddCustomCoinModal - + Get the contract address from - + Choose the asset type - + Type - + Cancel Cancel - - - + + + Next - - + + Enter the contract address - + Choose the asset ticker - + Ticker - + Enter the ticker - + Contract Address - + Get the contract address from - - - - + + + + Previous - + Choose the asset logo - + Browse - + Please choose the asset logo - + Configuration - + All configuration fields will be fetched using the contract address you provided. - + Name - + Enter the name - + Coingecko ID - + Enter the Coingecko ID - + Get the Coingecko ID - + Active - - + + Preview - + WARNING: Application will restart immidiately to apply the changes! - + Asset not found, please go back and make sure Contract Address is correct - + Config Fields - + Fetched Data - + Submit & Restart @@ -172,57 +172,57 @@ AddressBook - + Address Book - + Search a contact by name or tags - + New Contact - + Name - + Tags (first 6) - + Actions - + Edit - + Remove - + Do you want to remove this contact ? - + Yes Yes - + No @@ -230,174 +230,194 @@ AddressBookAddContactAddressModal - + Edit address entry - + Create a new address - + Selected wallet: %1 - + NONE - + Enter a name - + This key already exists. - + Enter the address - + Validate - + Cancel Cancel + + + Convert + + AddressBookEditContactModal - + Edit contact - + Contact Name - + Enter a contact name - + Address List - + Search for an address entry. - + Type - + Key - + Address - + Actions - + New Address - + Tags - + + - + Confirm - - + + Cancel Cancel - + The selected address belongs to a disabled coin, you need to enabled it before sending. - + Enable - + Cannot send to this address - + Your balance is empty - + Ok + + + Remove address ? + + + + + Yes + Yes + + + + No + + AddressBookNewContactCategoryModal - + Add a new tag - + Enter the tag name - + This contact already has this tag - + Add - + Cancel Cancel @@ -405,27 +425,27 @@ AddressBookNewContactModal - + Create a new contact - + Enter the contact name - + This contact name already exists. - + Confirm - + Cancel Cancel @@ -433,12 +453,12 @@ AddressBookSendWalletSelector - + Choose a valid - + coin @@ -446,12 +466,12 @@ AddressBookWalletTypeListModal - + Select wallet type - + Search @@ -459,7 +479,7 @@ AmountChart - + Work in progress @@ -467,7 +487,7 @@ App - + Recover Funds Result @@ -475,7 +495,7 @@ AssetPieChart - + Assets @@ -531,7 +551,7 @@ BuyBox - + Buy @@ -539,37 +559,37 @@ CamouflagePasswordModal - + Setup Camouflage Password - + Camouflage Password is a secret password for emergency situations. - + Using it to login will display your balance lower than it actually is. - + Here you enter the suffix and at login you need to enter {real_password}{suffix} - + Enter a suffix - + Cancel Cancel - + Save @@ -577,12 +597,12 @@ CandleStickChart - + Loading market data - + There is no chart data for this pair yet @@ -613,12 +633,12 @@ CexInfoModal - + Market Data - + Market data (prices, charts, etc.) marked with the ⓘ icon originates from third-party sources.<br><br>Data is sourced via <a href="https://bandprotocol.com/">Band Decentralized Oracle</a> and <a href="https://coingecko.com">CoinGecko</a>.<br><br><b>Oracle Supported Pairs:</b><br>%1<br><br><b>Last reference (Band Oracle):</b><br><a href="%2">%2</a> @@ -634,12 +654,12 @@ ClaimRewardsModal - + Failed to prepare to claim rewards - + Claim your %1 reward? TICKER @@ -746,7 +766,7 @@ Cancel - + Confirm @@ -754,24 +774,24 @@ CoinMenu - + Disable %1 TICKER - + Disable and Delete %1 TICKER - + Disable all %1 assets - + Disable all assets @@ -792,12 +812,12 @@ Combo_fiat - + Fiat - + Recommended: @@ -848,74 +868,74 @@ ConfirmTradeModal - + Confirm Exchange Details - + This swap request can not be undone and is a final event! - + This transaction can take up to 60 mins - DO NOT close this application! - + Total %1 fees: %2 (%3) - + Security configuration - + dPoW protected - + %1 confirmations for incoming %2 transactions - - + + Read more about dPoW - + Use custom protection settings for incoming %1 transactions TICKER - + Enable Komodo dPoW security - + Required Confirmations - + Warning, this atomic swap is not dPoW protected! - + Cancel Cancel - + Confirm @@ -923,7 +943,7 @@ CopyFieldButton - + Copied to Clipboard @@ -931,188 +951,188 @@ Dashboard - + The current number of enabled coins does not match your configuration specification. Your assets configuration will be reset. - - + + Content for this section will be added later. Stay tuned! - + Matching - + Order Matching - + Matched - + Order Matched - + Ongoing - + Swap Ongoing - + Successful - + Swap Successful - + Refunding - + Failed - + Swap Failed - + Unknown - + Unknown State - + Started - + Negotiated - + Taker fee sent - + Maker payment received - + Maker payment wait confirm started - + Maker payment validated and confirmed - + Taker payment sent - + Taker payment spent - + Maker payment spent - + Finished - + Start failed - + Negotiate failed - + Taker fee validate failed - + Maker payment transaction failed - + Maker payment Data send failed - + Maker payment wait confirm failed - + Taker payment validate failed - + Taker payment wait confirm failed - + Taker payment spend failed - + Maker payment wait refund started - + Maker payment refunded - + Maker payment refund failed @@ -1135,49 +1155,41 @@ - - DefaultSweetComboBox - - - Search - - - DeleteWalletModal - + Delete Wallet - + Are you sure you want to delete %1 wallet? WALLET_NAME - + If so, make sure you record your seed phrase in order to restore your wallet in the future. - + Enter your wallet password - + Wrong Password - + Cancel Cancel - + Delete @@ -1185,7 +1197,7 @@ DexAppPasswordField - + Type password @@ -1193,27 +1205,27 @@ DexKeyChecker - + At least 1 lowercase alphabetical character - + At least 1 uppercase alphabetical character - + At least 1 numeric character - + At least 1 special character (eg. !@#$%) - + At least %n character(s) @@ -1221,7 +1233,7 @@ - + Password and Confirm Password have to be same @@ -1229,7 +1241,7 @@ DexPaginator - + items per page @@ -1237,17 +1249,17 @@ DexRangeSlider - + Min - + Half - + Max @@ -1255,7 +1267,7 @@ DexSweetComboBox - + Search @@ -1263,47 +1275,47 @@ EnableCoinModal - + Enable assets - + Add a custom asset to the list - + Search - + Select all assets - + All assets are already enabled! - + You can still enable %1 assets. Selected: %2. - + Change assets limit - + Close - + Enable @@ -1311,88 +1323,50 @@ EulaModal - + Disclaimer & Terms of Service - + Accept EULA - + Accept Terms and Conditions - + Close - + Cancel Cancel - + Confirm - - - <h2>This End-User License Agreement ('EULA') is a legal agreement between you and Komodo Platform.</h2> - -<p>This EULA agreement governs your acquisition and use of our %1 software ('Software', 'Mobile Application', 'Application' or 'App') directly from Komodo Platform or indirectly through a Komodo Platform authorized entity, reseller or distributor (a 'Distributor').</p> -<p>Please read this EULA agreement carefully before completing the installation process and using the %1 software. It provides a license to use the %1 software and contains warranty information and liability disclaimers.</p> -<p>If you register for the beta program of the %1 software, this EULA agreement will also govern that trial. By clicking 'accept' or installing and/or using the %1 software, you are confirming your acceptance of the Software and agreeing to become bound by the terms of this EULA agreement.</p> -<p>If you are entering into this EULA agreement on behalf of a company or other legal entity, you represent that you have the authority to bind such entity and its affiliates to these terms and conditions. If you do not have such authority or if you do not agree with the terms and conditions of this EULA agreement, do not install or use the Software, and you must not accept this EULA agreement.</p> -<p>This EULA agreement shall apply only to the Software supplied by Komodo Platform herewith regardless of whether other software is referred to or described herein. The terms also apply to any Komodo Platform updates, supplements, Internet-based services, and support services for the Software, unless other terms accompany those items on delivery. If so, those terms apply.</p> - -<h3>License Grant</h3> -<p>Komodo Platform hereby grants you a personal, non-transferable, non-exclusive licence to use the %1 software on your devices in accordance with the terms of this EULA agreement.</p> - -<p>You are permitted to load the %1 software (for example a PC, laptop, mobile or tablet) under your control. You are responsible for ensuring your device meets the minimum security and resource requirements of the %1 software.</p> - -<p><b>You are not permitted to:</b></p> -<ul> -<li>Edit, alter, modify, adapt, translate or otherwise change the whole or any part of the Software nor permit the whole or any part of the Software to be combined with or become incorporated in any other software, nor decompile, disassemble or reverse engineer the Software or attempt to do any such things</li> -<li>Reproduce, copy, distribute, resell or otherwise use the Software for any commercial purpose</li> -<li>Use the Software in any way which breaches any applicable local, national or international law</li> -<li>Use the Software for any purpose that Komodo Platform considers is a breach of this EULA agreement</li> -</ul> - -<h3>Intellectual Property and Ownership</h3> -<p>Komodo Platform shall at all times retain ownership of the Software as originally downloaded by you and all subsequent downloads of the Software by you. The Software (and the copyright, and other intellectual property rights of whatever nature in the Software, including any modifications made thereto) are and shall remain the property of Komodo Platform.</p> - -<p>Komodo Platform reserves the right to grant licences to use the Software to third parties.</p> - -<h3>Termination</h3> -<p>This EULA agreement is effective from the date you first use the Software and shall continue until terminated. You may terminate it at any time upon written notice to Komodo Platform.</p> -<p>It will also terminate immediately if you fail to comply with any term of this EULA agreement. Upon such termination, the licenses granted by this EULA agreement will immediately terminate and you agree to stop all access and use of the Software. The provisions that by their nature continue and survive will survive any termination of this EULA agreement.</p> - -<h3>Governing Law</h3> -<p>This EULA agreement, and any dispute arising out of or in connection with this EULA agreement, shall be governed by and construed in accordance with the laws of Vietnam.</p> - -<p><b>This document was last updated on January 31st, 2020</b></p> - - FatalErrorModal - + Fatal Error - + Connection has been lost. You have been disconnected. - + Close @@ -1413,69 +1387,69 @@ FirstLaunch - + Type password - + connect - + Welcome - + New Wallet - + Import wallet - + My Wallets + - Delete - + Enter password to confirm deletion of - + wallet - + Cancel Cancel - - + + Wallet status - + wallet deleted successfully - + wallet password entered is incorrect @@ -1483,7 +1457,7 @@ General - + %n day(s) @@ -1491,7 +1465,7 @@ - + %nd day @@ -1500,7 +1474,7 @@ - + %nh hours @@ -1509,7 +1483,7 @@ - + %nm minutes @@ -1518,7 +1492,7 @@ - + %ns seconds @@ -1527,7 +1501,7 @@ - + %nms milliseconds @@ -1536,66 +1510,66 @@ - + - - + Trading Fee - + Minimum Trading Amount - + Wallet %1 already exists WALLETNAME - + %1 balance is lower than the fees amount: %2 %3 - + Tradable (after fees) %1 balance is lower than minimum trade amount - + Please fill the price field - + Please fill the volume field - - + + %1 volume is lower than minimum trade amount - - + + %1 needs to be enabled in order to use %2 - - + + %1 balance needs to be funded, a non-zero balance is required to pay the gas of %2 transactions - + Unknown Error @@ -1603,37 +1577,37 @@ Header - + You get - + You send - + Fiat Price - + CEX rate - + Price - + Quantity - + Total @@ -1649,22 +1623,22 @@ InitialLoading - + Loading, please wait - + Initializing MM2 - + Enabling assets - + Getting ready @@ -1672,7 +1646,7 @@ Languages - + Language @@ -1680,17 +1654,17 @@ LinksRow - + Join our Discord server - + Follow us on Twitter - + Go to Support Guides @@ -1698,7 +1672,7 @@ List - + Funds are recoverable @@ -1706,12 +1680,12 @@ ListDelegate - + %1 is not enabled - Do you want to enable it to be able to select %2 best orders ?<br><a href='#'>Yes</a> - <a href='#no'>No</a> - + This order require a minimum amount of %1 %2 <br>You don't have enough funds.<br> Your max balance after fees is: (%3) @@ -1737,18 +1711,18 @@ - + Connect - + Back - + Login @@ -1756,117 +1730,142 @@ Main - + + Segwit + + + + + Confirmation + + + + + Do you want to send your %1 funds to %2 wallet first? + + + + + Success + + + + + Your transaction is send, may take some time to arrive + + + + Wallet Balance - + Price - + Change 24h - + Portfolio % - + Send - + Enable %1 ? - + Yes Yes - + No - + Receive - + Swap - + Claim Rewards - + Faucet - + Loading market data - + There is no chart data for this ticker yet - + Loading - + Scanning blocks for TX History... - + Syncing TX History... - + Refreshing - + No transactions - + Fetching transactions - + Trade - + Orders - + History @@ -1874,12 +1873,12 @@ MinTradeModal - + Minimum Trading Amount - + the minimum amount of %1 coin available for the order; the min_volume must be greater than or equal to %2; it must be also less or equal than volume param; default is %3 @@ -1918,67 +1917,67 @@ NewUpdateModal - + Searching new updates... - + Please wait while the application is finding a new update... You can close this modal if you want. - + Already updated - + %1 is already up-to-date ! - + New update detected ! - + Do you want to update %1 from %2 to %3 ? - + Download - + Remind me later - + Download in progress... - + Update downloaded - + Update has been successfully downloaded. Do you want to restart the application now ? - + Restart now - + Restart later @@ -1986,12 +1985,12 @@ NewUser - + Wrong word, please check again - + Failed to create a wallet @@ -2006,12 +2005,12 @@ - + Generated Seed - + Check @@ -2021,7 +2020,7 @@ - + We recommend storing it offline. @@ -2031,32 +2030,32 @@ - + Continue - + Let's double check your seed phrase - + Copied to Clipboard - + Next - + Your seed phrase is important - that's why we like to make sure it's correct. We'll ask you three different questions about your seed phrase to make sure you'll be able to easily restore your wallet whenever you want. - + Enter the %n. word @@ -2090,146 +2089,123 @@ NotificationsModal - + Swap status updated - + You sent %1 - + You received %1 - + Your wallet balance changed - + Please check your internet connection (e.g. VPN service or firewall might block it). - + Failed to enable %1 TICKER - + Endpoint not reachable - + Could not reach to endpoint - + Mismatch at %1 custom asset configuration TICKER - + Application needs to be restarted for %1 custom asset. TICKER - + Batch %1 failed. Reason: %2 - + Show - + Restart - + Quit - + There isn't any notification - - OrderContent - - - ID - - - - - Maker Order - - - - - Taker Order - - - - - Cancel - Cancel - - OrderForm - + Price - + Cancel selected order to change price - + Volume - + Amount to sell - + Amount to receive - + Minimum volume: %1 - + Volume: %1 - + How it works ? @@ -2254,7 +2230,7 @@ Right slider: Sets the volume you want to trade. OrderLine - + Funds are recoverable @@ -2262,97 +2238,97 @@ Right slider: Sets the volume you want to trade. OrderModal - + Swap Details - + Order Details - + Maker Order - + Taker Order - + Refund State - + Your swap failed but the auto-refund process for your payment started already. Please wait and keep application opened until you receive your payment back - + Date - + ID - + Maker Payment Sent ID - + Maker Payment Spent ID - + Taker Payment Spent ID - + Taker Payment Sent ID - + Error ID - + Error Log - + Close - + Cancel Order - + Recover Funds - + Refunding... - + View on Explorer @@ -2386,38 +2362,38 @@ Right slider: Sets the volume you want to trade. OrdersPage - - + + Filter - + Date - + Export CSV - + Apply Filter - + From - + To - + Please choose the CSV export name and location @@ -2433,37 +2409,37 @@ Right slider: Sets the volume you want to trade. PasswordField - + Password - + Enter your wallet password - + At least 1 lowercase alphabetical character - + At least 1 uppercase alphabetical character - + At least 1 numeric character - + At least 1 special character (eg. !@#$%) - + At least %n character(s) @@ -2471,7 +2447,7 @@ Right slider: Sets the volume you want to trade. - + Password and Confirm Password have to be same @@ -2479,12 +2455,12 @@ Right slider: Sets the volume you want to trade. PasswordForm - + Confirm Password - + Enter the same password to confirm @@ -2492,27 +2468,27 @@ Right slider: Sets the volume you want to trade. Portfolio - + Show only coins with balance - + (%1/%2) - - Search + + Dashboard - - Portfolio + + Search - + Add asset @@ -2556,75 +2532,114 @@ Right slider: Sets the volume you want to trade. + + PriceLineSimplified + + + Set swap price for evaluation + + + + + Exchange rate + + + + + Selected + + + + + CEXchange rate + + + + + Expensive + + + + + Expedient + + + + + %1 compared to CEX + PRICE_DIFF% + + + ProView - + Failed to place the order - + Placed the order - + Chart - + Trading Information - + Exchange Rates - + Orders - + History - + Order Book - + Best Orders - + Place Order - + Buy - + Sell - + Order Selected - + Start Swap @@ -2632,18 +2647,28 @@ Right slider: Sets the volume you want to trade. ReceiveModal - + Receive - + Only send %1 to this address TICKER - + + %1 address + + + + + copied to clipboard + + + + Close @@ -2651,7 +2676,7 @@ Right slider: Sets the volume you want to trade. RecoverSeed - + Failed to Import the wallet @@ -2666,33 +2691,54 @@ Right slider: Sets the volume you want to trade. - + Wallet Name - - + + Enter seed - + BIP39 seed validation failed, try again or select 'Allow custom seed' - + + <strong>Allow custom seed</strong> + + + + + Custom seed phrases might be less secure and easier to crack than a generated BIP39 compliant seed phrase or private key (WIF).<br><br>To confirm you understand the risk and know what you are doing, type <strong>'I understand'</strong> in the box below. + + + + + + I understand + + + + + Enable + + + + Next - + Continue - + Allow custom seed @@ -2700,58 +2746,58 @@ Right slider: Sets the volume you want to trade. RecoverSeedModal - - + + View seed and private keys - + Please enter your password to view the seed. - + Wrong Password - + Cancel Cancel - + View - + Backup seed - + RPC Password - + Search a coin. - + Public Address - + Private Key - + Close @@ -2759,17 +2805,17 @@ Right slider: Sets the volume you want to trade. RestartModal - + Applying the changes... - + Restarting the application. %1 - + Restarting the application... @@ -2795,7 +2841,7 @@ Right slider: Sets the volume you want to trade. SellBox - + Sell @@ -2803,150 +2849,145 @@ Right slider: Sets the volume you want to trade. SendModal - + Failed to send - + Failed to Send - + Prepare to send - - + + Recipient's address - + Enter address of the recipient - + Address Book - + The address has to be mixed case. - + Fix - - Amount to send - - - - + Enter the amount to send - + MAX - + Enable Custom Fees - + Only use custom fees if you know what you are doing! - + Custom Fee - + Enter the custom fee - + Gas Limit - + Enter the gas limit - + Gas Price - + Enter the gas price - + Custom Fee can't be higher than the amount - + Not enough funds. - + You have %1 AMT TICKER - + Close - + Prepare - - + + Send - + Amount - + Fees - + Date - + Back @@ -2954,43 +2995,43 @@ Right slider: Sets the volume you want to trade. SendModalContactList - + Select a contact with an %1 address - + Search for contacts... - + %1 addresses - + 1 address - - + + Back - + Choose an %1 address of %2 - + Name - + Address @@ -2998,42 +3039,42 @@ Right slider: Sets the volume you want to trade. SendResult - + Transaction Complete! - + Recipient's address - + Amount - + Fees - + Date - + Transaction Hash - + Close - + View on Explorer @@ -3041,93 +3082,96 @@ Right slider: Sets the volume you want to trade. SettingModal - + Confirm Logout - + Are you sure you want to log out? - + + Yes Yes - + + Cancel Cancel - + + Settings + + + + General - - + + Language - + User Interface - + Security - - About - - - - - Version - - - - + Enable Desktop Notifications - + Maximum number of enabled coins - + Logs - + Open Folder - + + Reset assets configuration - + Reset - + + This will reset your wallet config to default + + + + Current Font - + Theme @@ -3137,12 +3181,17 @@ Right slider: Sets the volume you want to trade. - + + About & Version + + + + Apply Changes - + Ask system's password before sending coins ? (2FA) @@ -3152,48 +3201,78 @@ Right slider: Sets the volume you want to trade. - - + + Show - + Setup Camouflage Password - + Open - + Disclaimer and ToS - + Application version - + + DEX Version + + + + + DEX Version copied to clipboard. + + + + MM2 version - + + MM2 Version + + + + + MM2 Version copied to clipboard. + + + + Qt version - + + Qt Version + + + + + Qt Version copied to clipboard. + + + + Search Update - + Logout @@ -3201,80 +3280,93 @@ Right slider: Sets the volume you want to trade. Settings - + Fiat - + Recommended: - + Enable Desktop Notifications - + Use QtTextRendering Or NativeTextRendering - + Open Logs Folder - + View seed and private keys - + Disclaimer and ToS - + Setup Camouflage Password - + Reset assets configuration - + Delete Wallet - + Log out - + mm2 version + + Sidebar + + + Search coin + + + + + Add crypto + + + SidebarBottom - + Settings - + Support - + Privacy @@ -3282,43 +3374,43 @@ Right slider: Sets the volume you want to trade. SidebarCenter - - + + Dashboard - - + + Wallet - - + + DEX - + DEX features are not allowed in %1 COUNTRY - - + + Address Book - - + + Fiat - + Coming soon ! @@ -3326,12 +3418,12 @@ Right slider: Sets the volume you want to trade. SmartChartView - + Loading market data - + There is no chart data for this ticker yet @@ -3339,60 +3431,55 @@ Right slider: Sets the volume you want to trade. SubBestOrder - + Token - + Available Quantity - + Available Quantity (in %1) - + Fiat Volume - + CEX Rate - + %1 is not enabled - Do you want to enable it to be able to select %2 best orders ?<br><a href='#'>Yes</a> - <a href='#no'>No</a> - - - No best order. - - SubCoinSelector - + Token - + Balance - + Balance Fiat - + No Selectable coin. @@ -3400,72 +3487,62 @@ Right slider: Sets the volume you want to trade. SubHistory - + History - + Filter - + Date - + Close filtering options. - + Open filering options. - + Filter settings - - Base Ticker - - - - - Rel Ticker - - - - + From - + To - + Cancel Cancel - + Apply filter - + Export - + Please choose the CSV export name and location @@ -3473,63 +3550,53 @@ Right slider: Sets the volume you want to trade. SubOrders - - + + Orders - + Close filtering options. - + Filter - + Date - + Open filering options. - + Filter settings - - Base Ticker - - - - - Rel Ticker - - - - + From - + To - + Cancel Cancel - + Apply filter @@ -3537,69 +3604,69 @@ Right slider: Sets the volume you want to trade. Support - + Update available - + Up to date - + Changelog - + Open Logs Folder - + Frequently Asked Questions - + Do you store my private keys? - + No! %1 is non-custodial. We never store any sensitive data, including your private keys, seed phrases, or PIN. This data is only stored on the user’s device and never leaves it. You are in full control of your assets. - + How is trading on %1 different from trading on other DEXs? - + Other DEXs generally only allow you to trade assets that are based on a single blockchain network, use proxy tokens, and only allow placing a single order with the same funds. %1 enables you to natively trade across two different blockchain networks without proxy tokens. You can also place multiple orders with the same funds. For example, you can sell 0.1 BTC for KMD, QTUM, or VRSC — the first order that fills automatically cancels all other orders. - + How long does each atomic swap take? - + Several factors determine the processing time for each swap. The block time of the traded assets depends on each network (Bitcoin typically being the slowest) Additionally, the user can customize security preferences. For example, (you can ask %1 to consider a KMD transaction as final after just 3 confirmations which makes the swap time shorter compared to waiting for a <a href="https://komodoplatform.com/security-delayed-proof-of-work-dpow/">notarization</a>. - + Do I need to be online for the duration of the swap? - + Yes. You must remain connected to the internet and have your app running to successfully complete each atomic swap (very short breaks in connectivity are usually fine). Otherwise, there is risk of trade cancellation if you are a maker, and risk of loss of funds if you are a taker. The atomic swap protocol requires both participants to stay online and monitor the involved blockchains for the process to stay atomic. If you go offline, so will your orders, and any that are in progress will fail, leading to potential loss of trade / transaction fees, and a wait for the swap to timeout and issue a refund. It may also negatively affect your wallet's reputation score for future trade matching. @@ -3608,12 +3675,12 @@ For this reason, we recommend cancelling orders before closing %1, or reviewing - + How are the fees on %1 calculated? - + There are two fee categories to consider when trading on %1. 1. %1 charges approximately 0.13% (1/777 of trading volume but not lower than 0.0001) as the trading fee for taker orders, and maker orders have zero fees. @@ -3623,52 +3690,52 @@ Network fees can vary greatly depending on your selected trading pair. - + Do you provide user support? - + Yes! %1 offers support through the <a href="%2">%1 Discord server</a>. The team and the community are always happy to help! - + %1 is available for mobile on both <a href="%2">Android and iPhone, and for desktop on Windows, Mac, and Linux</a> operating systems. - + Who is behind %1? - + %1 is developed by the Komodo team. Komodo is one of the most established blockchain projects working on innovative solutions like atomic swaps, Delayed Proof of Work, and an interoperable multi-chain architecture. - + Is it possible to develop my own white-label exchange on %1? - + Absolutely! You can read our developer documentation for more details or contact us with your partnership inquiries. Have a specific technical question? The %1 developer community is always ready to help! - + Which devices can I use %1 on? - + Compliance Info - + Due to regulatory and legal circumstances the citizens of certain jurisdictions including, but not limited to, the United States of America, Canada, Hong Kong, Israel, Singapore, Sudan, Austria, Iran and any other state, country or other jurisdiction that is embargoed by the United States of America or the European Union are not allowed to use this application. @@ -3676,19 +3743,19 @@ Network fees can vary greatly depending on your selected trading pair. SwapProgress - + act SHORT FOR ACTUAL TIME - + est SHORT FOR ESTIMATED - + Progress details @@ -3704,27 +3771,27 @@ Network fees can vary greatly depending on your selected trading pair. TableDex - + Asset - + Balance - + Change 24h - + Trend 7d - + Price @@ -3732,20 +3799,33 @@ Network fees can vary greatly depending on your selected trading pair. TextAreaWithTitle - + Save - + Edit + + TextEditWithTitle + + + Swap ID + + + + + copied to clipboard + + + TextFieldWithTitle - + Required @@ -3753,7 +3833,7 @@ Network fees can vary greatly depending on your selected trading pair. Toast - + Click here to see the details @@ -3761,130 +3841,145 @@ Network fees can vary greatly depending on your selected trading pair. Trade - + Swap - + Instant trading with best orders - + From - + Minimum: %1 - + Enter an amount - + MAX - + To - + Pick an order - + Price - + Better price found: %1. Updating forms. - + Better price (%1) found but received quantity (%2) is lower than your current one (%3). Click here to update the selected order. - + Reset form. - + %1 - + Tradable: - + + Pick a coin + + + + Swap Now - + Failed to place the order - + Placed the order - + Entered amount must be superior than 0. - + You must select an order. - + Entered amount is below the minimum required by this order: %1 - - + + %1 needs to be enabled in order to use %2 - - + + %1 balance needs to be funded, a non-zero balance is required to pay the gas of %2 transactions - - + + Search - + + No buy orders found for %1. + + + + + You can check later or try to sell a different coin. + + + + Total %1 fees: - + %2 (%3) @@ -3892,12 +3987,12 @@ Network fees can vary greatly depending on your selected trading pair. TradeViewHeader - + How to trade - + FAQ @@ -3905,67 +4000,67 @@ Network fees can vary greatly depending on your selected trading pair. TransactionDetailsModal - + Transaction Details - + Amount - + Fees - + Date - + Unconfirmed - + Transaction Hash - + Confirmations - + Block Height - + From - + To - + Notes - + Close - + View on Explorer @@ -3973,22 +4068,22 @@ Network fees can vary greatly depending on your selected trading pair. Transactions - + Sent - + Received - + fees - + Unconfirmed @@ -4017,77 +4112,97 @@ Network fees can vary greatly depending on your selected trading pair. atomic_dex::wallet_page - + You do not have enough funds. - + %1 is not activated: click on the button to enable it or enable it manually - + You need to have %1 to pay the gas for %2 transactions. - + Checksum verification failed for %1. - + Invalid checksum for %1. Click on the convert button to turn it into a mixed case address - + Legacy address used for %1, click on the convert button to convert it to a Cashaddress. - + %1 address must be prefixed with 0x - + %1 address length is invalid, please use a valid address. + + + %1 address is invalid. + + + + + Invalid checksum. + + + + + %1 address has invalid prefixes. + + + + + Unknown error. + + main - + Logout - + Confirm Logout - + Are you sure you want to log out? - + Yes Yes - + Cancel Cancel - + Balance - \ No newline at end of file + diff --git a/atomic_defi_design/assets/languages/atomic_defi_fr.ts b/atomic_defi_design/assets/languages/atomic_defi_fr.ts index c6c363cca2..a2149e05f0 100644 --- a/atomic_defi_design/assets/languages/atomic_defi_fr.ts +++ b/atomic_defi_design/assets/languages/atomic_defi_fr.ts @@ -19,154 +19,154 @@ AddCustomCoinModal - + Choose the asset type Choisir le type d'actif - + Type Type - + Cancel Annuler - - - + + + Next Suivant - - + + Enter the contract address Entrer l'adresse du contrat - + Choose the asset ticker Choisissez le symbole de l'actif - + Ticker Symbole - + Enter the ticker Entrez le symbole - + Contract Address Adresse du contrat - + Get the contract address from Obtenez l'adresse du contrat de - + Get the contract address from Obtenez l'adresse du contrat de - - - - + + + + Previous Précedent - + Choose the asset logo Choisissez le logo de l'actif - + Browse Naviguer - + Please choose the asset logo S'il-vous-plaît choissisez le logo de l'actif - + Configuration Configuration - + All configuration fields will be fetched using the contract address you provided. Tous les champs de configuration vont être récupérés à partir de l'adresse du contrat que vous avez fournis. - + Name Nom - + Enter the name Entrez le nom - + Coingecko ID Coingecko ID - + Enter the Coingecko ID Entrer l'identifiant coingecko - + Get the Coingecko ID Récupérer l'identifiant coingecko - + Active Actif - - + + Preview Pré-visualisation - + WARNING: Application will restart immidiately to apply the changes! AVERTISSEMENT: l'application redémarrera immédiatement pour appliquer les modifications! - + Asset not found, please go back and make sure Contract Address is correct Actif introuvable, veuillez revenir en arrière et vous assurer que l'adresse du contrat est correcte - + Config Fields Champs de configuration - + Fetched Data Données récupérées - + Submit & Restart Soumettre et redémarrer @@ -174,57 +174,57 @@ AddressBook - + Address Book Carnet d'adresses - + New Contact Nouveau contact - + Search a contact by name or tags Rechercher un contact par nom ou par tags - + Name Nom - + Tags (first 6) Tags (Les 6 premiers) - + Actions Actions - + Edit Éditer - + Remove Retirer - + Do you want to remove this contact ? Voulez-vous supprimer ce contact ? - + Yes Oui - + No Non @@ -232,174 +232,194 @@ AddressBookAddContactAddressModal - + Create a new address Créer une nouvelle adresse - + Edit address entry Edition de l'entrée pour l'addresse - + Selected wallet: %1 Portefeuille sélectionné : %1 - + NONE RIEN - + Enter a name Entrez un nom - + This key already exists. Cette clé existe déjà. - + Enter the address Entrez l'adresse - + Validate Valider - + Cancel Annuler + + + Convert + + AddressBookEditContactModal - + Edit contact Modifier le contact - + Contact Name Nom du contact - + Enter a contact name Entrez un nom de contact - + Address List Liste d'addresse - + Search for an address entry. Rechercher une addresse. - + Type Type - + Key Clef - + Address Addresse - + Actions Actions - + New Address Nouvelle addresse - + Tags Tags - + + + - + Confirm Confirmer - - + + Cancel Annuler - + The selected address belongs to a disabled coin, you need to enabled it before sending. L'adresse sélectionnée appartient à un actif désactivée, vous devez l'activer avant l'envoi. - + Enable Activer - + Cannot send to this address Impossible d'envoyer à cette adresse - + Your balance is empty Votre solde est vide - + Ok Ok + + + Remove address ? + + + + + Yes + Oui + + + + No + Non + AddressBookNewContactCategoryModal - + Add a new tag Ajouter un nouveau tag - + Enter the tag name Entrer le nom du tag - + This contact already has this tag Ce contact possède déjà ce tag - + Add Ajouter - + Cancel Annuler @@ -407,27 +427,27 @@ AddressBookNewContactModal - + Create a new contact Créer un nouveau contact - + Enter the contact name Entrez le nom du contact - + This contact name already exists. Ce nom de contact existe déjà. - + Confirm Confirmer - + Cancel Annuler @@ -435,12 +455,12 @@ AddressBookSendWalletSelector - + Choose a valid Choisissez un actif - + coin valide @@ -448,12 +468,12 @@ AddressBookWalletTypeListModal - + Select wallet type Sélectionnez le type de portefeuille - + Search Rechercher @@ -461,7 +481,7 @@ AmountChart - + Work in progress Travail en cours @@ -469,7 +489,7 @@ App - + Recover Funds Result Le résultat de la récupération des fonds @@ -477,7 +497,7 @@ AssetPieChart - + Assets Actifs @@ -533,7 +553,7 @@ BuyBox - + Buy Acheter @@ -541,37 +561,37 @@ CamouflagePasswordModal - + Setup Camouflage Password Configurer le mot de passe de camouflage - + Camouflage Password is a secret password for emergency situations. Le mot de passe de camouflage est un mot de passe secret pour les situations d'urgence. - + Using it to login will display your balance lower than it actually is. Son utilisation pour vous connecter affichera votre solde inférieur à ce qu'il est réellement. - + Here you enter the suffix and at login you need to enter {real_password}{suffix} Ici, vous entrez le suffixe et lors de la connexion, vous devez entrer {mot de passe réel}{suffixe} - + Enter a suffix Entrer un suffixe - + Cancel Annuler - + Save Sauvegarder @@ -579,12 +599,12 @@ CandleStickChart - + Loading market data Chargement des données de marché - + There is no chart data for this pair yet Il n'y a pas encore de données graphiques pour cette paire @@ -615,12 +635,12 @@ CexInfoModal - + Market Data Données du marché - + Market data (prices, charts, etc.) marked with the ⓘ icon originates from third-party sources.<br><br>Data is sourced via <a href="https://bandprotocol.com/">Band Decentralized Oracle</a> and <a href="https://coingecko.com">CoinGecko</a>.<br><br><b>Oracle Supported Pairs:</b><br>%1<br><br><b>Last reference (Band Oracle):</b><br><a href="%2">%2</a> Les données de marché (prix, graphiques, etc.) marquées de l'icône ⓘ proviennent de sources tierces.<br><br>Les données proviennent de <a href="https://bandprotocol.com/"> Band Decentralized Oracle</a> et <a href="https://www.coingecko.com/fr">Coingecko </a>.<br><br><b>Paires prises en charge par Oracle:</b><br>%1<br><br><b>Dernière référence (Band Oracle) :</b><br><a href="%2">%2</a> @@ -636,12 +656,12 @@ ClaimRewardsModal - + Failed to prepare to claim rewards Échec de la préparation de la réclamation des récompenses - + Claim your %1 reward? TICKER Réclamer votre %1 récompense ? @@ -748,7 +768,7 @@ Annuler - + Confirm Confirmer @@ -756,24 +776,24 @@ CoinMenu - + Disable %1 TICKER Désactiver %1 - + Disable and Delete %1 TICKER Désactiver et Supprimer %1 - + Disable all %1 assets Désactiver tous les actifs %1 - + Disable all assets Désactiver tous les actifs @@ -794,12 +814,12 @@ Combo_fiat - + Fiat Monnaie fiduciaire - + Recommended: Conseillé: @@ -850,74 +870,74 @@ ConfirmTradeModal - + Confirm Exchange Details Détails de la confirmation de l'échange - + This swap request can not be undone and is a final event! La requête de ce swap ne peut pas être annulé, c'est irréversible ! - + Total %1 fees: %2 (%3) Total %1 frais: %2 (%3) - + Security configuration Configuration de la sécurité - + dPoW protected dPoW protégé - - + + Read more about dPoW En savoir plus sur dPoW - + Use custom protection settings for incoming %1 transactions TICKER Utiliser les paramètres de protection personnalisés pour les transactions%1 entrantes - + Enable Komodo dPoW security Activer la sécurité de Komodo dPoW - + %1 confirmations for incoming %2 transactions Il y a %1 confirmations pour les transactions entrantes du ticker %2 - + This transaction can take up to 60 mins - DO NOT close this application! Cette transaction peut prendre jusqu'à 60 minutes - NE fermez PAS cette application ! - + Required Confirmations Confirmations requises - + Warning, this atomic swap is not dPoW protected! Attention, ce swap atomique n'est pas protégé par dPoW ! - + Cancel Annuler - + Confirm Confirmer @@ -925,7 +945,7 @@ CopyFieldButton - + Copied to Clipboard Copier dans le presse-papier @@ -933,188 +953,188 @@ Dashboard - + The current number of enabled coins does not match your configuration specification. Your assets configuration will be reset. Le nombre actuel d'actifs activées ne correspond pas à vos spécifications de configuration. La configuration de vos actifs sera réinitialisée. - - + + Content for this section will be added later. Stay tuned! Le contenu de cette section sera ajouté ultérieurement. Restez à l'écoute ! - + Matching Recherche en cours - + Order Matching Recherche d'un ordre - + Matched Trouvé - + Order Matched Ordre trouvé - + Ongoing En cours - + Swap Ongoing Échange en cours - + Successful Réussi - + Swap Successful Échange terminé - + Refunding En cours de remboursement - + Failed Échoué - + Swap Failed Erreur lors de l'échange - + Unknown Inconnue - + Unknown State État inconnu - + Started Commencé - + Negotiated Négocié - + Taker fee sent Frais de preneur envoyés - + Maker payment received Paiement de l'envoyeur reçu - + Maker payment wait confirm started La confirmation d'attente de paiement de l'envoyeur a commencé - + Maker payment validated and confirmed Paiement de l'envoyeur validé et confirmé - + Taker payment sent Paiement du preneur envoyé - + Taker payment spent Paiement du preneur dépensé - + Maker payment spent Paiement de l'envoyeur dépensé - + Finished Fini - + Start failed Le démarrage a échoué - + Negotiate failed La négociation a échoué - + Taker fee validate failed Échec de la validation des frais du preneur - + Maker payment transaction failed La transaction de paiement du créateur a échoué - + Maker payment Data send failed Échec de l'envoi des données de paiement du créateur - + Maker payment wait confirm failed La confirmation de l'attente de paiement du créateur a échoué - + Taker payment validate failed La validation du paiement du preneur a échoué - + Taker payment wait confirm failed La confirmation de l'attente de paiement du preneur a échoué - + Taker payment spend failed Échec des dépenses de paiement du preneur - + Maker payment wait refund started attente de paiement du créateur, remboursement commencé - + Maker payment refunded Paiement du créateur remboursé - + Maker payment refund failed échec du remboursement du paiement du créateur @@ -1137,49 +1157,41 @@ Max - - DefaultSweetComboBox - - - Search - Rechercher - - DeleteWalletModal - + Delete Wallet Supprimez votre portefeuille - + Are you sure you want to delete %1 wallet? WALLET_NAME Êtes-vous sûre de supprimez le portefeuille %1 ? - + If so, make sure you record your seed phrase in order to restore your wallet in the future. Si tel est le cas, assurez-vous d'enregistrer votre phrase de départ afin de restaurer votre portefeuille à l'avenir. - + Enter your wallet password Entrez le mot de passe de votre portefeuille - + Wrong Password Mauvais mot de passe - + Cancel Annuler - + Delete Supprimez @@ -1187,7 +1199,7 @@ DexAppPasswordField - + Type password Tapez votre mot de passe @@ -1195,27 +1207,27 @@ DexKeyChecker - + At least 1 lowercase alphabetical character Au moins 1 caractère alphabétique en minuscule - + At least 1 uppercase alphabetical character Au moins 1 caractère alphabétique en majuscule - + At least 1 numeric character Au moins 1 caractère numérique - + At least 1 special character (eg. !@#$%) Au moins 1 caractère spécial (ex: ! @ # $%) - + At least %n character(s) Au moins %n caractère @@ -1223,7 +1235,7 @@ - + Password and Confirm Password have to be same Le mot de passe et la confirmation du mot de passe doivent être identiques @@ -1231,7 +1243,7 @@ DexPaginator - + items per page Nombres d'éléments par page @@ -1239,17 +1251,17 @@ DexRangeSlider - + Min Min - + Half Moitié - + Max Max @@ -1257,7 +1269,7 @@ DexSweetComboBox - + Search Rechercher @@ -1265,47 +1277,47 @@ EnableCoinModal - + Enable assets Activer les actifs - + Add a custom asset to the list Ajouter un token personnalisé à la liste - + All assets are already enabled! Tous les actifs sont déjà activés ! - + Change assets limit Limiter le nombre d'actifs - + Search Rechercher - + Select all assets Sélectionnez tous les actifs - + You can still enable %1 assets. Selected: %2. Vous pouvez toujours activer %1 actifs. Sélectionnés: %2. - + Close Fermer - + Enable Activer @@ -1313,88 +1325,50 @@ EulaModal - + Disclaimer & Terms of Service Clause de non-responsabilité et conditions d'utilisation - + Accept EULA Acceptez l'EULA - + Accept Terms and Conditions Accepter les termes et conditions - + Close Fermer - + Cancel Annuler - + Confirm Confirmer - - - <h2>This End-User License Agreement ('EULA') is a legal agreement between you and Komodo Platform.</h2> - -<p>This EULA agreement governs your acquisition and use of our %1 software ('Software', 'Mobile Application', 'Application' or 'App') directly from Komodo Platform or indirectly through a Komodo Platform authorized entity, reseller or distributor (a 'Distributor').</p> -<p>Please read this EULA agreement carefully before completing the installation process and using the %1 software. It provides a license to use the %1 software and contains warranty information and liability disclaimers.</p> -<p>If you register for the beta program of the %1 software, this EULA agreement will also govern that trial. By clicking 'accept' or installing and/or using the %1 software, you are confirming your acceptance of the Software and agreeing to become bound by the terms of this EULA agreement.</p> -<p>If you are entering into this EULA agreement on behalf of a company or other legal entity, you represent that you have the authority to bind such entity and its affiliates to these terms and conditions. If you do not have such authority or if you do not agree with the terms and conditions of this EULA agreement, do not install or use the Software, and you must not accept this EULA agreement.</p> -<p>This EULA agreement shall apply only to the Software supplied by Komodo Platform herewith regardless of whether other software is referred to or described herein. The terms also apply to any Komodo Platform updates, supplements, Internet-based services, and support services for the Software, unless other terms accompany those items on delivery. If so, those terms apply.</p> - -<h3>License Grant</h3> -<p>Komodo Platform hereby grants you a personal, non-transferable, non-exclusive licence to use the %1 software on your devices in accordance with the terms of this EULA agreement.</p> - -<p>You are permitted to load the %1 software (for example a PC, laptop, mobile or tablet) under your control. You are responsible for ensuring your device meets the minimum security and resource requirements of the %1 software.</p> - -<p><b>You are not permitted to:</b></p> -<ul> -<li>Edit, alter, modify, adapt, translate or otherwise change the whole or any part of the Software nor permit the whole or any part of the Software to be combined with or become incorporated in any other software, nor decompile, disassemble or reverse engineer the Software or attempt to do any such things</li> -<li>Reproduce, copy, distribute, resell or otherwise use the Software for any commercial purpose</li> -<li>Use the Software in any way which breaches any applicable local, national or international law</li> -<li>Use the Software for any purpose that Komodo Platform considers is a breach of this EULA agreement</li> -</ul> - -<h3>Intellectual Property and Ownership</h3> -<p>Komodo Platform shall at all times retain ownership of the Software as originally downloaded by you and all subsequent downloads of the Software by you. The Software (and the copyright, and other intellectual property rights of whatever nature in the Software, including any modifications made thereto) are and shall remain the property of Komodo Platform.</p> - -<p>Komodo Platform reserves the right to grant licences to use the Software to third parties.</p> - -<h3>Termination</h3> -<p>This EULA agreement is effective from the date you first use the Software and shall continue until terminated. You may terminate it at any time upon written notice to Komodo Platform.</p> -<p>It will also terminate immediately if you fail to comply with any term of this EULA agreement. Upon such termination, the licenses granted by this EULA agreement will immediately terminate and you agree to stop all access and use of the Software. The provisions that by their nature continue and survive will survive any termination of this EULA agreement.</p> - -<h3>Governing Law</h3> -<p>This EULA agreement, and any dispute arising out of or in connection with this EULA agreement, shall be governed by and construed in accordance with the laws of Vietnam.</p> - -<p><b>This document was last updated on January 31st, 2020</b></p> - - FatalErrorModal - + Fatal Error Erreur fatale - + Connection has been lost. You have been disconnected. La connexion a été perdue. Vous avez été déconnecté. - + Close Fermer @@ -1415,73 +1389,69 @@ FirstLaunch - + Type password Tapez votre mot de passe - + connect Connection - + Welcome Bienvenue - + New Wallet Nouveau portefeuille - Recover Wallet - Récupérer portefeuille - - - + Import wallet - + My Wallets Mes portefeuilles + - Delete Supprimez - + Enter password to confirm deletion of Entrez le mot de passe pour confirmer la suppression de - + wallet portefeuille - + Cancel Annuler - - + + Wallet status État du portefeuille - + wallet deleted successfully portefeuille supprimé avec succès - + wallet password entered is incorrect Le mot de passe du portefeuille est incorrect @@ -1489,7 +1459,7 @@ General - + %n day(s) %n jour(s) @@ -1497,7 +1467,7 @@ - + %nd day @@ -1506,7 +1476,7 @@ - + %nh hours @@ -1515,7 +1485,7 @@ - + %nm minutes @@ -1524,7 +1494,7 @@ - + %ns seconds @@ -1533,7 +1503,7 @@ - + %nms milliseconds @@ -1542,66 +1512,66 @@ - + - - - + Trading Fee Frais d'échanges - + Minimum Trading Amount Frais d'échange minimum - + Wallet %1 already exists WALLETNAME Le portefeuille %1 existe déjà - + %1 balance is lower than the fees amount: %2 %3 La %1 balance est inférieur aux frais: %2 %3 - + Tradable (after fees) %1 balance is lower than minimum trade amount Le solde négociable (après frais) %1 est inférieur au montant minimum de la transaction - + Please fill the price field Veuillez remplir le champ de prix - + Please fill the volume field Veuillez remplir le champ de volume - - + + %1 volume is lower than minimum trade amount Le volume de %1 est inférieur au montant minimum de la transaction - - + + %1 needs to be enabled in order to use %2 %1 doit être activé pour utiliser %2 - - + + %1 balance needs to be funded, a non-zero balance is required to pay the gas of %2 transactions Le solde %1 doit être financé, un solde différent de zéro est requis pour payer les frais de transactions de %2 - + Unknown Error Erreur inconnue @@ -1609,37 +1579,37 @@ Header - + You get Vous recevez - + You send Vous envoyez - + Fiat Price Prix fiduciaire - + CEX rate Taux CEX - + Price Prix - + Quantity Quantité - + Total Total @@ -1655,22 +1625,22 @@ InitialLoading - + Loading, please wait Chargement en cours, veuillez patienter - + Initializing MM2 Initialisation de MM2 - + Enabling assets Activer les actifs - + Getting ready Chargement @@ -1678,7 +1648,7 @@ Languages - + Language Langue @@ -1686,17 +1656,17 @@ LinksRow - + Join our Discord server Rejoignez notre serveur Discord - + Follow us on Twitter Suivez-nous sur Twitter - + Go to Support Guides M'envoyer sur les guides du support @@ -1704,7 +1674,7 @@ List - + Funds are recoverable Les fonds sont récupérables @@ -1712,12 +1682,12 @@ ListDelegate - + This order require a minimum amount of %1 %2 <br>You don't have enough funds.<br> Your max balance after fees is: (%3) Cette commande nécessite un montant minimum de%1 %2 <br> Vous n'avez pas assez de fonds. <br> Votre solde maximum après frais est: (%3) - + %1 is not enabled - Do you want to enable it to be able to select %2 best orders ?<br><a href='#'>Yes</a> - <a href='#no'>No</a> %1 n'est pas activé - Souhaitez vous l'activer pour pouvoir selectionnez les meilleurs offres %2 ?<br><a href='#'>Oui</a> - <a href='#no'>Non</a> @@ -1739,7 +1709,7 @@ - + Login Connection @@ -1749,12 +1719,12 @@ Tapez votre mot de passe - + Back Retour - + Connect Connexion @@ -1762,117 +1732,142 @@ Main - + + Segwit + + + + + Confirmation + + + + + Do you want to send your %1 funds to %2 wallet first? + + + + + Success + + + + + Your transaction is send, may take some time to arrive + + + + Wallet Balance Solde portefeuille - + Price Prix - + Change 24h Changement 24H - + Portfolio % Portefeuille % - + Send Envoyez - + Enable %1 ? Activer %1 ? - + Yes Oui - + No Non - + Receive Recevoir - + Swap Échange - + Claim Rewards Réclamer des récompenses - + Faucet Robinet - + Loading market data Chargement des données de marché - + There is no chart data for this ticker yet Il n'y a pas encore de données graphiques pour ce ticker - + Loading Chargement - + Scanning blocks for TX History... Analyses des blocs pour l'historique TX... - + Syncing TX History... Synchronisation de l'historique de transactions... - + No transactions Pas de transactions - + Refreshing Actualiser - + Fetching transactions Récupération des transactions - + Trade Échanger - + Orders Ordres - + History Historique @@ -1880,12 +1875,12 @@ MinTradeModal - + Minimum Trading Amount Montant de trading minimum - + the minimum amount of %1 coin available for the order; the min_volume must be greater than or equal to %2; it must be also less or equal than volume param; default is %3 Le montant minimum de%1 disponible pour la commande; le min_volume doit être supérieur ou égal à%2; il doit également être inférieur ou égal au paramètre de volume; la valeur par défaut est%3 @@ -1924,67 +1919,67 @@ NewUpdateModal - + Searching new updates... Recherche de nouvelles mises à jour ... - + Please wait while the application is finding a new update... You can close this modal if you want. Veuillez patienter pendant que l'application recherche une nouvelle mise à jour ... Vous pouvez fermer ce modal si vous le souhaitez. - + Already updated Déjà mis à jour - + %1 is already up-to-date ! %1 est déjà à jour ! - + New update detected ! Nouvelle mise à jour détectée ! - + Do you want to update %1 from %2 to %3 ? Voulez-vous mettre à jour %1 de %2 vers %3 ? - + Download Téléchargement - + Remind me later Rappelle-moi plus tard - + Download in progress... Téléchargement en cours... - + Update downloaded Mise à jour téléchargée - + Update has been successfully downloaded. Do you want to restart the application now ? La mise à jour a été téléchargée avec succès. Voulez-vous redémarrer l'application maintenant ? - + Restart now Redémarrer maintenant - + Restart later Redémarrer plus tard @@ -1992,12 +1987,12 @@ NewUser - + Wrong word, please check again Mauvais mot, veuillez vérifier à nouveau - + Failed to create a wallet Impossible de créer un portefeuille @@ -2012,17 +2007,17 @@ Important: sauvegardez votre phrase de recupération avant de continuer ! - + We recommend storing it offline. Nous vous recommandons de le stocker hors ligne. - + Generated Seed Générer un Seed - + Check Vérifier @@ -2037,32 +2032,32 @@ Confirmer la phrase de récupération - + Continue Continuer - + Let's double check your seed phrase Vérifions à nouveau votre phrase de récupération - + Copied to Clipboard Copier dans le presse-papier - + Next Suivant - + Your seed phrase is important - that's why we like to make sure it's correct. We'll ask you three different questions about your seed phrase to make sure you'll be able to easily restore your wallet whenever you want. Votre phrase de récupération est importante - c'est pourquoi nous aimons nous assurer qu'elle est correcte. Nous vous poserons trois questions différentes au sujet de votre phrase source pour vous assurer que vous pourrez facilement restaurer votre portefeuille à tout moment. - + Enter the %n. word Entrez le mot numéro %n @@ -2096,136 +2091,113 @@ NotificationsModal - + Swap status updated État du swap mis à jour - + You sent %1 Vous avez envoyé %1 - + You received %1 Vous avez reçu %1 - + Your wallet balance changed Le solde de votre portefeuille a changé - + Please check your internet connection (e.g. VPN service or firewall might block it). Veuillez vérifier votre connexion Internet (par exemple, le service VPN ou le pare-feu peut la bloquer). - + Failed to enable %1 TICKER Échec de l'activation de %1 - + Endpoint not reachable Point final non accessible - + Could not reach to endpoint Impossible d'atteindre le point de terminaison - + Mismatch at %1 custom asset configuration TICKER Non-correspondance à la configuration de l'asset personnalisé %1 - + Application needs to be restarted for %1 custom asset. TICKER L'application doit être redémarrée pour l'asset personnalisé %1. - + Batch %1 failed. Reason: %2 Le lot %1 a échoué. Raison :%2 - + Show Montrer - + Restart Redémarrer - + Quit Quitter - + There isn't any notification Il n'y a aucune notification - - OrderContent - - - ID - ID - - - - Maker Order - Ordre de vente - - - - Taker Order - Ordre d'achat - - - - Cancel - Annuler - - OrderForm - + Cancel selected order to change price Annuler la commande sélectionnée pour modifier le prix - + Amount to sell Montant à vendre - + Amount to receive Montant à recevoir - + Minimum volume: %1 Volume minimal : %1 - + Volume: %1 Volume: %1 - + How it works ? Comment ça fonctionne ? @@ -2249,12 +2221,12 @@ Curseur droit : définit le volume que vous souhaitez trader. Utiliser le montant d'échange minimum personnalisé - + Price Prix - + Volume Volume @@ -2262,7 +2234,7 @@ Curseur droit : définit le volume que vous souhaitez trader. OrderLine - + Funds are recoverable Les fonds sont récupérables @@ -2270,97 +2242,97 @@ Curseur droit : définit le volume que vous souhaitez trader. OrderModal - + Swap Details Détails de l'échange - + Order Details Détails de l'ordre - + Maker Order Ordre de vente - + Taker Order Ordre d'achat - + Refund State État de remboursement - + Your swap failed but the auto-refund process for your payment started already. Please wait and keep application opened until you receive your payment back Votre échange a échoué, mais le processus de remboursement automatique de votre paiement a déjà commencé. Veuillez patienter et garder l'application ouverte jusqu'à ce que vous receviez votre remboursement - + Date Date - + ID ID - + Recover Funds Récupérer des fonds - + Refunding... Remboursement... - + View on Explorer Voir dans l'explorateur - + Maker Payment Sent ID Identifiant d'envoi du paiement du créateur - + Maker Payment Spent ID Identifiant de paiement du créateur - + Taker Payment Spent ID Identifiant de paiement du preneur d'achat - + Taker Payment Sent ID Identifiant d'envoi du paiement du preneur - + Cancel Order Annuler l'ordre - + Error ID ID de l'erreur - + Error Log Journal des erreurs - + Close Fermer @@ -2394,38 +2366,38 @@ Curseur droit : définit le volume que vous souhaitez trader. OrdersPage - + From De - + To Vers - + Apply Filter Appliquer les changements - - + + Filter Filtrer - + Date Date - + Export CSV Exporter CSV - + Please choose the CSV export name and location Veuillez choisir le nom et l'emplacement de l'exportation CSV @@ -2441,37 +2413,37 @@ Curseur droit : définit le volume que vous souhaitez trader. PasswordField - + Password Mot de passe - + Enter your wallet password Entrez le mot de passe de votre portefeuille - + At least 1 lowercase alphabetical character Au moins 1 caractère alphabétique en minuscule - + At least 1 uppercase alphabetical character Au moins 1 caractère alphabétique en majuscule - + At least 1 numeric character Au moins 1 caractère numérique - + At least 1 special character (eg. !@#$%) Au moins 1 caractère spécial (ex: ! @ # $%) - + At least %n character(s) Au moins %n caractère @@ -2479,7 +2451,7 @@ Curseur droit : définit le volume que vous souhaitez trader. - + Password and Confirm Password have to be same Le mot de passe et la confirmation du mot de passe doivent être identiques @@ -2487,12 +2459,12 @@ Curseur droit : définit le volume que vous souhaitez trader. PasswordForm - + Confirm Password Confirmez le mot de passe - + Enter the same password to confirm Entrez le même mot de passe pour confirmer @@ -2500,27 +2472,27 @@ Curseur droit : définit le volume que vous souhaitez trader. Portfolio - + Search Rechercher - + Show only coins with balance Afficher uniquement les assets avec solde - + (%1/%2) - - Portfolio - Portfolio + + Dashboard + Tableau de bord - + Add asset Ajouter un actif @@ -2564,75 +2536,114 @@ Curseur droit : définit le volume que vous souhaitez trader. Taux du CEX + + PriceLineSimplified + + + Set swap price for evaluation + Définir le prix d'échange pour l'évaluation + + + + Exchange rate + Taux de l'échange + + + + Selected + Choisi + + + + CEXchange rate + Taux du CEX + + + + Expensive + Coûteuse + + + + Expedient + Abordable + + + + %1 compared to CEX + PRICE_DIFF% + %1 par rapport aux CEX + + ProView - + Failed to place the order Échec lors du placement de l'ordre - + Placed the order L'ordre a été placé avec succès - + Chart Chart - + Trading Information Informations de Trading - + Exchange Rates Taux d'échanges - + Orders Ordres - + History Historique - + Order Book Carnet d'ordres - + Best Orders Meilleurs offres - + Place Order Placer l'ordre - + Buy Acheter - + Sell Vendre - + Order Selected Ordre séléctionné - + Start Swap Commencez le swap @@ -2640,18 +2651,28 @@ Curseur droit : définit le volume que vous souhaitez trader. ReceiveModal - + Receive Recevoir - + Only send %1 to this address TICKER Envoyez uniquement %1 à cette adresse - + + %1 address + + + + + copied to clipboard + + + + Close Fermer @@ -2659,19 +2680,7 @@ Curseur droit : définit le volume que vous souhaitez trader. RecoverSeed - Failed to recover the seed - Impossible de récupérer la phrase de récupération - - - Recover wallet - Setup - Récupérer le portefeuille - Configuration - - - Recover wallet - Choose password - Récupérer le portefeuille - Choisir le mot de passe - - - + Failed to Import the wallet @@ -2686,33 +2695,54 @@ Curseur droit : définit le volume que vous souhaitez trader. - + Wallet Name Nom du portefeuille - - + + Enter seed Entrez la phrase de récupération - + BIP39 seed validation failed, try again or select 'Allow custom seed' Échec de la validation de la phrase de récupération BIP39, réessayez ou sélectionnez ' Autoriser les phrases de récupérations personnalisées' - + + <strong>Allow custom seed</strong> + + + + + Custom seed phrases might be less secure and easier to crack than a generated BIP39 compliant seed phrase or private key (WIF).<br><br>To confirm you understand the risk and know what you are doing, type <strong>'I understand'</strong> in the box below. + + + + + + I understand + + + + + Enable + Activer + + + Next Suivant - + Continue Continuer - + Allow custom seed Autoriser les phrases de récupération personnalisées @@ -2720,58 +2750,58 @@ Curseur droit : définit le volume que vous souhaitez trader. RecoverSeedModal - - + + View seed and private keys Afficher le seed et les clefs privées - + Please enter your password to view the seed. Veuillez entrer votre mot de passe pour voir la phrase de récupération. - + Wrong Password Mauvais mot de passe - + Cancel Annuler - + Backup seed Seed de récuperation - + RPC Password Mot de passe RPC - + Search a coin. Rechercher une asset. - + Public Address Adresse publique - + Private Key Clé privée - + Close Fermer - + View Voir @@ -2779,17 +2809,17 @@ Curseur droit : définit le volume que vous souhaitez trader. RestartModal - + Applying the changes... Application des modifications... - + Restarting the application... Redémarrage de l'application ... - + Restarting the application. %1 Redémarrage de l'application. %1 @@ -2815,7 +2845,7 @@ Curseur droit : définit le volume que vous souhaitez trader. SellBox - + Sell Vendre @@ -2823,150 +2853,145 @@ Curseur droit : définit le volume que vous souhaitez trader. SendModal - + Failed to send Échec de l'envoi - + Failed to Send Échec de l'envoi - + Prepare to send Préparez à envoyer du - - + + Recipient's address Adresse du destinataire - + Enter address of the recipient Entrez l'adresse du destinataire - + Address Book Carnet d'adresses - + The address has to be mixed case. L'adresse doit être mixte (case). - + Fix Réparer - - Amount to send - Montant à envoyer - - - + Enter the amount to send Entrez le montant à envoyer - + MAX MAX - + Enable Custom Fees Activer les frais personnalisés - + Only use custom fees if you know what you are doing! N'utilisez des frais personnalisés que si vous savez ce que vous faites ! - + Custom Fee Frais personnalisés - + Enter the custom fee Entrez les frais personnalisées - + Gas Limit Limite de gaz - + Enter the gas limit Entrez la limite de gaz - + Gas Price Prix ​​du gaz - + Enter the gas price Entrez le prix du gaz - + Custom Fee can't be higher than the amount Les frais personnalisées ne peuvent pas être supérieurs au montant - + Not enough funds. Pas assez de fonds. - + You have %1 AMT TICKER Vous avez %1 - + Close Fermer - + Prepare Préparer - - + + Send Envoyez - + Amount Montant - + Fees Frais - + Date Date - + Back Retour @@ -2974,43 +2999,43 @@ Curseur droit : définit le volume que vous souhaitez trader. SendModalContactList - + Select a contact with an %1 address Sélectionnez un contact avec une adresse %1 - + Search for contacts... Rechercher des contacts... - + %1 addresses %1 adresses - + 1 address 1 adresse - - + + Back Retour - + Choose an %1 address of %2 Choisissez une adresse %1 de %2 - + Name Nom - + Address Adresse @@ -3018,42 +3043,42 @@ Curseur droit : définit le volume que vous souhaitez trader. SendResult - + Transaction Complete! Transaction terminée ! - + Recipient's address Adresse du destinataire - + Amount Montant - + Fees Frais - + Date Date - + Transaction Hash Hachage de la transaction - + Close Fermer - + View on Explorer Voir dans l'explorateur @@ -3061,128 +3086,166 @@ Curseur droit : définit le volume que vous souhaitez trader. SettingModal - + Confirm Logout Confirmer la déconnexion - + Are you sure you want to log out? Êtes-vous sûr de vouloir vous déconnecter ? - + + Yes Oui - + + Cancel Annuler - - + + Settings + Réglages + + + + Language Langue - + User Interface Interface utilsateur - + Security Sécurité - - About - À propos - - - + General Général - - Version - Version + + About & Version + - + Enable Desktop Notifications Activer les notifications - + Maximum number of enabled coins Nombre maximum d'actifs activés - + Logs Journaux - + Open Folder Ouvrir le dossier - + + Reset assets configuration Réinitialiser la configuration d'assets - + Reset Réinitialiser - + + This will reset your wallet config to default + + + + Current Font Police actuelle - + Theme Thème - + Apply Changes Appliquer les changements - + Ask system's password before sending coins ? (2FA) Demander le mot de passe du système avant d'envoyer des actifs ? (2FA) - + Application version Version de l'application - + + DEX Version + + + + + DEX Version copied to clipboard. + + + + MM2 version Version de MM2 - + + MM2 Version + + + + + MM2 Version copied to clipboard. + + + + Qt version Version de Qt - + + Qt Version + + + + + Qt Version copied to clipboard. + + + + Search Update Rechercher une mise à jour - + Logout Se déconnecter @@ -3197,23 +3260,23 @@ Curseur droit : définit le volume que vous souhaitez trader. Afficher la phrase de récupération et les clefs privées - - + + Show Montrer - + Setup Camouflage Password Configurer le mot de passe de camouflage - + Open Ouvrir - + Disclaimer and ToS Clause de non-responsabilité et conditions d'utilisation @@ -3221,80 +3284,93 @@ Curseur droit : définit le volume que vous souhaitez trader. Settings - + Fiat Monnaie fiduciaire - + Recommended: Conseillé : - + Enable Desktop Notifications Activer les notifications - + Use QtTextRendering Or NativeTextRendering Utilisez QtTextRendering ou NativeTextRendering - + Open Logs Folder Ouvrir le répertoire de logs - + View seed and private keys Voir le seed et les clefs privées - + Disclaimer and ToS Clause de non-responsabilité et conditions d'utilisation - + Setup Camouflage Password Configurez un mot de passe de camouflage - + Reset assets configuration Réinitialiser la configuration d'assets - + Delete Wallet Supprimez le portefeuille - + Log out Déconnection - + mm2 version Version de mm2 + + Sidebar + + + Search coin + + + + + Add crypto + + + SidebarBottom - + Settings Réglages - + Support Support - + Privacy Intimité @@ -3302,43 +3378,43 @@ Curseur droit : définit le volume que vous souhaitez trader. SidebarCenter - - + + Dashboard Tableau de bord - - + + Wallet Portefeuille - - + + DEX DEX - + DEX features are not allowed in %1 COUNTRY Les fonctionnalités DEX ne sont pas autorisées dans %1 - - + + Address Book Carnet d'adresses - - + + Fiat Monnaie fiduciaire - + Coming soon ! Bientôt disponible ! @@ -3346,12 +3422,12 @@ Curseur droit : définit le volume que vous souhaitez trader. SmartChartView - + Loading market data Chargement des données de marché - + There is no chart data for this ticker yet Il n'y a pas encore de données graphiques pour cet actif @@ -3359,60 +3435,55 @@ Curseur droit : définit le volume que vous souhaitez trader. SubBestOrder - + Token Asset - + Available Quantity Quantité disponible - + Available Quantity (in %1) Quantité disponible (en %1) - + Fiat Volume Montant Fiduciaire - + CEX Rate Taux CEX - + %1 is not enabled - Do you want to enable it to be able to select %2 best orders ?<br><a href='#'>Yes</a> - <a href='#no'>No</a> %1 n'est pas activé - Souhaitez vous l'activer pour pouvoir selectionnez les meilleurs offres %2 ?<br><a href='#'>Oui</a> - <a href='#no'>Non</a> - - - No best order. - Pas de meilleurs offres. - SubCoinSelector - + Token Asset - + Balance Balance - + Balance Fiat Balance Fiduciaire - + No Selectable coin. Aucune asset sélectionnable. @@ -3420,72 +3491,62 @@ Curseur droit : définit le volume que vous souhaitez trader. SubHistory - + History Historique - + Filter Filtrer - + Date Date - + Close filtering options. Fermez les options de filtrage. - + Open filering options. Ouvrez les options de filtrage. - + Filter settings Paramètres de filtre - - Base Ticker - Base Asset - - - - Rel Ticker - Rel Asset - - - + From De - + To Vers - + Cancel Annuler - + Apply filter Appliquer changement - + Export Exportation - + Please choose the CSV export name and location Veuillez choisir le nom et l'emplacement de l'exportation CSV @@ -3493,63 +3554,53 @@ Curseur droit : définit le volume que vous souhaitez trader. SubOrders - - + + Orders Ordres - + Close filtering options. Fermez les options de filtrage. - + Filter Filtrer - + Date Date - + Open filering options. Ouvrez les options de filtrage. - + Filter settings Paramètres de filtre - - Base Ticker - Base Asset - - - - Rel Ticker - Rel Asset - - - + From De - + To Vers - + Cancel Annuler - + Apply filter Appliquer changement @@ -3557,60 +3608,60 @@ Curseur droit : définit le volume que vous souhaitez trader. Support - + Update available Mise à jour disponible - + Up to date À jour - + Changelog Anglicisme Changelog - + Open Logs Folder Ouvrir le répertoire de logs - + Frequently Asked Questions Foire aux questions - + Do you store my private keys? Stockez-vous mes clés privées ? - + No! %1 is non-custodial. We never store any sensitive data, including your private keys, seed phrases, or PIN. This data is only stored on the user’s device and never leaves it. You are in full control of your assets. - + How is trading on %1 different from trading on other DEXs? - + Other DEXs generally only allow you to trade assets that are based on a single blockchain network, use proxy tokens, and only allow placing a single order with the same funds. %1 enables you to natively trade across two different blockchain networks without proxy tokens. You can also place multiple orders with the same funds. For example, you can sell 0.1 BTC for KMD, QTUM, or VRSC — the first order that fills automatically cancels all other orders. - + Several factors determine the processing time for each swap. The block time of the traded assets depends on each network (Bitcoin typically being the slowest) Additionally, the user can customize security preferences. For example, (you can ask %1 to consider a KMD transaction as final after just 3 confirmations which makes the swap time shorter compared to waiting for a <a href="https://komodoplatform.com/security-delayed-proof-of-work-dpow/">notarization</a>. - + Yes. You must remain connected to the internet and have your app running to successfully complete each atomic swap (very short breaks in connectivity are usually fine). Otherwise, there is risk of trade cancellation if you are a maker, and risk of loss of funds if you are a taker. The atomic swap protocol requires both participants to stay online and monitor the involved blockchains for the process to stay atomic. If you go offline, so will your orders, and any that are in progress will fail, leading to potential loss of trade / transaction fees, and a wait for the swap to timeout and issue a refund. It may also negatively affect your wallet's reputation score for future trade matching. @@ -3619,37 +3670,37 @@ For this reason, we recommend cancelling orders before closing %1, or reviewing - + How are the fees on %1 calculated? Comment les frais sur %1 sont-ils calculés ? - + Who is behind %1? Qui est derrière %1 ? - + %1 is developed by the Komodo team. Komodo is one of the most established blockchain projects working on innovative solutions like atomic swaps, Delayed Proof of Work, and an interoperable multi-chain architecture. - + Is it possible to develop my own white-label exchange on %1? Est-il possible de développer mon propre échange en white label sur %1 ? - + Absolutely! You can read our developer documentation for more details or contact us with your partnership inquiries. Have a specific technical question? The %1 developer community is always ready to help! Absolument! Vous pouvez lire notre documentation développeur pour plus de détails ou nous contacter avec vos demandes de partenariat. Vous avez une question technique spécifique? La communauté de développeurs %1 est toujours prête à vous aider ! - + Which devices can I use %1 on? Sur quels appareils puis-je utiliser %1 ? - + There are two fee categories to consider when trading on %1. 1. %1 charges approximately 0.13% (1/777 of trading volume but not lower than 0.0001) as the trading fee for taker orders, and maker orders have zero fees. @@ -3664,37 +3715,37 @@ Network fees can vary greatly depending on your selected trading pair. Les frais de réseau peuvent varier considérablement en fonction de votre paire de trading sélectionnée. - + Yes! %1 offers support through the <a href="%2">%1 Discord server</a>. The team and the community are always happy to help! - + %1 is available for mobile on both <a href="%2">Android and iPhone, and for desktop on Windows, Mac, and Linux</a> operating systems. - + Compliance Info Informations de conformité - + Due to regulatory and legal circumstances the citizens of certain jurisdictions including, but not limited to, the United States of America, Canada, Hong Kong, Israel, Singapore, Sudan, Austria, Iran and any other state, country or other jurisdiction that is embargoed by the United States of America or the European Union are not allowed to use this application. En raison de circonstances réglementaires et juridiques, les citoyens de certaines juridictions, y compris, mais sans s'y limiter, les États-Unis d'Amérique, le Canada, Hong Kong, Israël, Singapour, le Soudan, l'Autriche, l'Iran et tout autre État, pays ou autre juridiction sous embargo par les États-Unis d'Amérique ou l'Union européenne ne sont pas autorisés à utiliser cette application. - + How long does each atomic swap take? Combien de temps dure chaque échange atomique ? - + Do I need to be online for the duration of the swap? Dois-je être en ligne pendant toute la durée du swap ? - + Do you provide user support? Fournissez-vous un support utilisateur ? @@ -3702,19 +3753,19 @@ Les frais de réseau peuvent varier considérablement en fonction de votre paire SwapProgress - + act SHORT FOR ACTUAL TIME act - + est SHORT FOR ESTIMATED est - + Progress details Détails de la progression @@ -3730,27 +3781,27 @@ Les frais de réseau peuvent varier considérablement en fonction de votre paire TableDex - + Asset Actif - + Balance Balance - + Change 24h Changement 24H - + Trend 7d Tendance 7j - + Price Prix @@ -3758,20 +3809,33 @@ Les frais de réseau peuvent varier considérablement en fonction de votre paire TextAreaWithTitle - + Save Sauvegarder - + Edit Éditer + + TextEditWithTitle + + + Swap ID + + + + + copied to clipboard + + + TextFieldWithTitle - + Required Requis @@ -3779,7 +3843,7 @@ Les frais de réseau peuvent varier considérablement en fonction de votre paire Toast - + Click here to see the details Cliquez ici pour voir les détails @@ -3787,130 +3851,145 @@ Les frais de réseau peuvent varier considérablement en fonction de votre paire Trade - + Swap Échange - + Instant trading with best orders Trading instantané avec les meilleurs ordres - + From De - + Minimum: %1 Minimum : %1 - + Enter an amount Entrez un montant - + MAX MAX - + To Vers - + Pick an order Choisir une commande - + Price Prix - + Better price found: %1. Updating forms. Meilleur prix trouvé : %1. Mise à jour du formulaire. - + Better price (%1) found but received quantity (%2) is lower than your current one (%3). Click here to update the selected order. Meilleur prix (%1) trouvé mais la quantité reçue (%2) est inférieure à votre montant de réception (%3). Cliquez ici pour mettre à jour la commande sélectionnée. - + Reset form. Réinitialiser le formulaire. - + %1 - + Tradable: Disponible: - + + Pick a coin + + + + Swap Now Échanger maintenant - + Failed to place the order Échec lors du placement de l'ordre - + Placed the order L'ordre a été placé - + Entered amount must be superior than 0. Le montant saisi doit être supérieur à 0. - + You must select an order. Vous devez sélectionner une commande. - + Entered amount is below the minimum required by this order: %1 Le montant saisi est inférieur au minimum requis par cette commande : %1 - - + + %1 needs to be enabled in order to use %2 %1 doit être activé pour utiliser %2 - - + + %1 balance needs to be funded, a non-zero balance is required to pay the gas of %2 transactions Le solde %1 doit être financé, un solde différent de zéro est requis pour payer les frais de transactions de %2 - - + + Search Rechercher - + + No buy orders found for %1. + + + + + You can check later or try to sell a different coin. + + + + Total %1 fees: Frais totaux %1 : - + %2 (%3) @@ -3918,12 +3997,12 @@ Les frais de réseau peuvent varier considérablement en fonction de votre paire TradeViewHeader - + How to trade Comment faire des echanges - + FAQ FAQ @@ -3931,67 +4010,67 @@ Les frais de réseau peuvent varier considérablement en fonction de votre paire TransactionDetailsModal - + Transaction Details Détails de la transaction - + Amount Montant - + Fees Frais - + Date Date - + Unconfirmed Non confirmé - + Transaction Hash Hachage de la transaction - + Confirmations Confirmations - + Block Height Hauteur de bloc - + From De - + To Vers - + Notes Remarques - + Close Fermer - + View on Explorer Voir dans l'explorateur @@ -3999,22 +4078,22 @@ Les frais de réseau peuvent varier considérablement en fonction de votre paire Transactions - + Received Reçue - + Sent Envoyé - + fees frais - + Unconfirmed Non confirmé @@ -4043,77 +4122,97 @@ Les frais de réseau peuvent varier considérablement en fonction de votre paire atomic_dex::wallet_page - + You do not have enough funds. Vous n'avez pas assez de fonds. - + %1 is not activated: click on the button to enable it or enable it manually %1 n'est pas activé : cliquez sur le bouton pour l'activer ou l'activer manuellement - + You need to have %1 to pay the gas for %2 transactions. Vous devez avoir %1 activée pour payer les frais de transactions de %2. - + Checksum verification failed for %1. Échec de la vérification du checksum de contrôle pour %1. - + Invalid checksum for %1. Click on the convert button to turn it into a mixed case address Checksum-non valide pour %1. Cliquez sur le bouton pour avoir une adresse de cas mixte - + Legacy address used for %1, click on the convert button to convert it to a Cashaddress. Ancien format d'adresse utilisée pour %1, cliquez sur le bouton pour la convertir en Cashaddress. - + %1 address must be prefixed with 0x L'adresse %1 doit être précédée de 0x - + %1 address length is invalid, please use a valid address. La longueur de l'adresse %1 n'est pas valide, veuillez utiliser une adresse valide. + + + %1 address is invalid. + + + + + Invalid checksum. + + + + + %1 address has invalid prefixes. + + + + + Unknown error. + + main - + Logout Se déconnecter - + Confirm Logout Confirmer la déconnexion - + Are you sure you want to log out? Êtes-vous sûr de vouloir vous déconnecter ? - + Yes Oui - + Cancel Annuler - + Balance Balance - \ No newline at end of file + diff --git a/atomic_defi_design/assets/languages/atomic_defi_ru.ts b/atomic_defi_design/assets/languages/atomic_defi_ru.ts index 88ca8d9082..d4196ac7be 100644 --- a/atomic_defi_design/assets/languages/atomic_defi_ru.ts +++ b/atomic_defi_design/assets/languages/atomic_defi_ru.ts @@ -19,154 +19,154 @@ AddCustomCoinModal - + Choose the asset type Выберите тип монеты - + Type Тип - + Cancel Отменить - - - + + + Next Далее - - + + Enter the contract address Введите адрес контракта - + Choose the asset ticker Введите тикер монеты - + Ticker Тикер - + Enter the ticker Введите тикер - + Contract Address Адрес контракта - + Get the contract address from Получить адрес контракта от - + Get the contract address from Получить адрес контракта от - - - - + + + + Previous Назад - + Choose the asset logo Загрузите логотип монеты - + Browse Выбрать - + Please choose the asset logo Выберите логотип монеты - + Configuration Конфигурация - + All configuration fields will be fetched using the contract address you provided. Все параметры конфигурации будут получены с помощью адреса контракта. - + Name Название - + Enter the name Введите название - + Coingecko ID Coingecko ID - + Enter the Coingecko ID Введите Coingecko ID - + Get the Coingecko ID Получить Coingecko ID - + Active Активно - - + + Preview Превью - + WARNING: Application will restart immidiately to apply the changes! ПРЕДУПРЕЖДЕНИЕ: Приложение будет немедленно перезапущено для применения изменений! - + Asset not found, please go back and make sure Contract Address is correct Токен не найден, убедитесь, что адрес контракта указан верно - + Config Fields Параметры конфигурации - + Fetched Data Полученные данные - + Submit & Restart Отправить и перезапустить @@ -174,57 +174,57 @@ AddressBook - + Address Book Адресная книга - + New Contact Новый контакт - + Search a contact by name or tags Поиск контакта по имени или тегам - + Name Имя - + Tags (first 6) Теги (первые 6) - + Actions Действия - + Edit Редактировать - + Remove Удалить - + Do you want to remove this contact ? Вы действительно хотите удалить этот контакт? - + Yes Да - + No Нет @@ -232,174 +232,194 @@ AddressBookAddContactAddressModal - + Create a new address Добавить новый адрес - + Edit address entry Внести изменения в адрес - + Selected wallet: %1 Выбранный кошелек: %1 - + NONE НИ ОДИН - + Enter a name Введите имя - + This key already exists. Этот ключ уже существует. - + Enter the address Введите адрес - + Validate Валидировать - + Cancel Отменить + + + Convert + + AddressBookEditContactModal - + Edit contact Редактировать контакт - + Contact Name Имя контакта - + Enter a contact name Введите имя - + Address List Список адресов - + Search for an address entry. Поиск адреса. - + Type Тип - + Key Ключ - + Address Адрес - + Actions Действия - + New Address Новый Адрес - + Tags Теги - + + + - + Confirm Подтвердить - - + + Cancel Отменить - + The selected address belongs to a disabled coin, you need to enabled it before sending. Вы выбрали адрес отключенной монеты, ее необходимо включить перед отправкой. - + Enable Добавить - + Cannot send to this address Отправка на этот адрес невозможна - + Your balance is empty Баланс отсутствует - + Ok ОК + + + Remove address ? + + + + + Yes + Да + + + + No + Нет + AddressBookNewContactCategoryModal - + Add a new tag Добавить новый тег - + Enter the tag name Добавить имя тега - + This contact already has this tag У этого контакта уже есть этот тег - + Add Добавить - + Cancel Отменить @@ -407,27 +427,27 @@ AddressBookNewContactModal - + Create a new contact Добавить новый контакт - + Enter the contact name Введите имя контакта - + This contact name already exists. Контакт с таким именем уже существует. - + Confirm Подтвердить - + Cancel Отменить @@ -435,12 +455,12 @@ AddressBookSendWalletSelector - + Choose a valid Выберите валидную - + coin монету @@ -448,12 +468,12 @@ AddressBookWalletTypeListModal - + Select wallet type Выберите тип кошелька - + Search Поиск @@ -461,7 +481,7 @@ AmountChart - + Work in progress Разработка в процессе @@ -469,7 +489,7 @@ App - + Recover Funds Result Результат восстановления средств @@ -477,7 +497,7 @@ AssetPieChart - + Assets Активы @@ -533,7 +553,7 @@ BuyBox - + Buy Купить @@ -541,37 +561,37 @@ CamouflagePasswordModal - + Setup Camouflage Password Установить камуфляжный пароль - + Camouflage Password is a secret password for emergency situations. Камуфляжный пароль - секретный пароль для чрезвычайных ситуаций. - + Using it to login will display your balance lower than it actually is. Используйте его во время входа, чтобы ваш баланс не отображался полностью. - + Here you enter the suffix and at login you need to enter {real_password}{suffix} Здесь вы можете ввести окончание пароля. Во время входа в приложения необходимо будет ввести {ваш пароль}{окончание} - + Enter a suffix Введите окончание - + Cancel Отменить - + Save Сохранить @@ -579,12 +599,12 @@ CandleStickChart - + Loading market data Загрузка данных - + There is no chart data for this pair yet Нет данных для построения графика для этой торговой пары @@ -615,12 +635,12 @@ CexInfoModal - + Market Data Рыночные данные (CEX) - + Market data (prices, charts, etc.) marked with the ⓘ icon originates from third-party sources.<br><br>Data is sourced via <a href="https://bandprotocol.com/">Band Decentralized Oracle</a> and <a href="https://coingecko.com">CoinGecko</a>.<br><br><b>Oracle Supported Pairs:</b><br>%1<br><br><b>Last reference (Band Oracle):</b><br><a href="%2">%2</a> Рыночные данные (цены, графики, и тд.) отмеченные ⓘ иконкой получены от <a href="https://bandprotocol.com/">Band Decentralized Oracle</a> и <a href="https://coingecko.com">CoinGecko</a>.<br><br><b>Oracle Supported Pairs:</b><br>%1<br><br><b>Last reference (Band Oracle):</b><br><a href="%2">%2</a> @@ -636,12 +656,12 @@ ClaimRewardsModal - + Failed to prepare to claim rewards Ошибка при создании транзакции для получения вознаграждения - + Claim your %1 reward? TICKER Получить %1 вознаграждение? @@ -748,7 +768,7 @@ Отменить - + Confirm Подтвердить @@ -756,24 +776,24 @@ CoinMenu - + Disable %1 TICKER Удалить %1 - + Disable and Delete %1 TICKER Удалить токен %1 из AtomicDex - + Disable all %1 assets Отключить все %1 ассеты - + Disable all assets Отключить все ассеты @@ -794,12 +814,12 @@ Combo_fiat - + Fiat Фиат - + Recommended: Рекомендации: @@ -850,74 +870,74 @@ ConfirmTradeModal - + Confirm Exchange Details Подтвердить данные обмена - + This swap request can not be undone and is a final event! Этот запрос на своп не может быть отменен и является окончательным! - + This transaction can take up to 60 mins - DO NOT close this application! Эта транзакция может занять до 60 минут - НЕ закрывайте приложение! - + Total %1 fees: %2 (%3) Всего %1 комиссии: %2 (%3) - + Security configuration Настройки безопасности - + dPoW protected защищено dPoW - + %1 confirmations for incoming %2 transactions %1 подтверждений для входящих %2 транзакций - - + + Read more about dPoW Узнать больше о dPoW - + Use custom protection settings for incoming %1 transactions TICKER Использовать пользовательские настройки защиты для входящих транзакций %1 - + Enable Komodo dPoW security Включить Komodo dPoW - + Required Confirmations Необходимое количество подтверждений - + Warning, this atomic swap is not dPoW protected! Предупреждение, этот атомарный своп не защищен dPoW! - + Cancel Отменить - + Confirm Подтверждение @@ -925,7 +945,7 @@ CopyFieldButton - + Copied to Clipboard Скопировано в буфер обмена @@ -933,188 +953,188 @@ Dashboard - + The current number of enabled coins does not match your configuration specification. Your assets configuration will be reset. Текущее количество включенных монет не совпадает с конфигурацией. Ваша конфигурация активов будет сброшена. - - + + Content for this section will be added later. Stay tuned! Содержание этого раздела будет добавлено в следующих обновлениях. Следите за новостями! - + Matching Матчинг - + Order Matching Матчинг ордеров - + Matched Сматчен - + Order Matched Ордер сматчен - + Ongoing В процессе - + Swap Ongoing Своп продолжается - + Successful Успешно - + Swap Successful Своп успешно завершен - + Refunding Проводится возврат - + Failed Не завершено - + Swap Failed Своп не был завершен - + Unknown Неизвестно - + Unknown State Статус неизвестен - + Started Начат - + Negotiated Согласован - + Taker fee sent Комиссия тейкера отправлена - + Maker payment received Платеж мейкера получен - + Maker payment wait confirm started Ожидание платежа мейкера - + Maker payment validated and confirmed Платеж мейкера валидирован и подтвержден - + Taker payment sent Платеж тейкера отправлен - + Taker payment spent Платеж тейкера потрачен - + Maker payment spent Платеж мейкера потрачен - + Finished Завершено - + Start failed Не удалось начать - + Negotiate failed Согласование не прошло - + Taker fee validate failed Валидация комиссии тейкера не прошла - + Maker payment transaction failed Платежная транзакция мейкера не прошла - + Maker payment Data send failed Отправка платежных данных мейкера не прошла - + Maker payment wait confirm failed Платежная транзакция мейкера не была подтверждена - + Taker payment validate failed Не прошла валидация платежа тейкера - + Taker payment wait confirm failed Платежная транзакция тейкера не была подтверждена - + Taker payment spend failed Spend платежа тейкера не прошел - + Maker payment wait refund started Ожидание возврата платежа мейкера - + Maker payment refunded Платеж мейкера возвращен - + Maker payment refund failed Возврат платежа мейкера не выполнен @@ -1137,49 +1157,41 @@ Макс - - DefaultSweetComboBox - - - Search - Поиск - - DeleteWalletModal - + Delete Wallet Удалить кошелек - + Are you sure you want to delete %1 wallet? WALLET_NAME Вы уверены, что хотите удалить кошелек %1? - + If so, make sure you record your seed phrase in order to restore your wallet in the future. Если да, не забудьте записать seed-фразу, чтобы иметь возможность восстановить свой кошелек. - + Enter your wallet password Введите пароль кошелька - + Wrong Password Неправильный пароль - + Cancel Отмена - + Delete Удалить @@ -1187,7 +1199,7 @@ DexAppPasswordField - + Type password Введите пароль @@ -1195,27 +1207,27 @@ DexKeyChecker - + At least 1 lowercase alphabetical character Как минимум 1 строчная буква - + At least 1 uppercase alphabetical character Как минимум 1 заглавная буква - + At least 1 numeric character Как минимум 1 цифра - + At least 1 special character (eg. !@#$%) Как минимум 1 специальный символ (!@#$%) - + At least %n character(s) Не менее %n символов @@ -1224,7 +1236,7 @@ - + Password and Confirm Password have to be same Пароль и подтверждение пароля должны совпадать @@ -1232,7 +1244,7 @@ DexPaginator - + items per page элементов на странице @@ -1240,17 +1252,17 @@ DexRangeSlider - + Min Мин - + Half Половина - + Max Макс @@ -1258,7 +1270,7 @@ DexSweetComboBox - + Search Поиск @@ -1266,47 +1278,47 @@ EnableCoinModal - + Enable assets Подключить активы - + Add a custom asset to the list Добавить пользовательский ассет в список - + All assets are already enabled! Все ассеты уже добавлены! - + Change assets limit Изменить лимит - + Search Поиск - + Select all assets Выбрать все ассеты - + You can still enable %1 assets. Selected: %2. Вы можете активировать еще %1 активов. Активно: %2. - + Close Закрыть - + Enable Добавить @@ -1314,88 +1326,50 @@ EulaModal - + Disclaimer & Terms of Service Дисклеймер и условия использования - + Accept EULA Принять EULA - + Accept Terms and Conditions Принять Terms of Service - + Close Закрыть - + Cancel Отменить - + Confirm Подтвердить - - - <h2>This End-User License Agreement ('EULA') is a legal agreement between you and Komodo Platform.</h2> - -<p>This EULA agreement governs your acquisition and use of our %1 software ('Software', 'Mobile Application', 'Application' or 'App') directly from Komodo Platform or indirectly through a Komodo Platform authorized entity, reseller or distributor (a 'Distributor').</p> -<p>Please read this EULA agreement carefully before completing the installation process and using the %1 software. It provides a license to use the %1 software and contains warranty information and liability disclaimers.</p> -<p>If you register for the beta program of the %1 software, this EULA agreement will also govern that trial. By clicking 'accept' or installing and/or using the %1 software, you are confirming your acceptance of the Software and agreeing to become bound by the terms of this EULA agreement.</p> -<p>If you are entering into this EULA agreement on behalf of a company or other legal entity, you represent that you have the authority to bind such entity and its affiliates to these terms and conditions. If you do not have such authority or if you do not agree with the terms and conditions of this EULA agreement, do not install or use the Software, and you must not accept this EULA agreement.</p> -<p>This EULA agreement shall apply only to the Software supplied by Komodo Platform herewith regardless of whether other software is referred to or described herein. The terms also apply to any Komodo Platform updates, supplements, Internet-based services, and support services for the Software, unless other terms accompany those items on delivery. If so, those terms apply.</p> - -<h3>License Grant</h3> -<p>Komodo Platform hereby grants you a personal, non-transferable, non-exclusive licence to use the %1 software on your devices in accordance with the terms of this EULA agreement.</p> - -<p>You are permitted to load the %1 software (for example a PC, laptop, mobile or tablet) under your control. You are responsible for ensuring your device meets the minimum security and resource requirements of the %1 software.</p> - -<p><b>You are not permitted to:</b></p> -<ul> -<li>Edit, alter, modify, adapt, translate or otherwise change the whole or any part of the Software nor permit the whole or any part of the Software to be combined with or become incorporated in any other software, nor decompile, disassemble or reverse engineer the Software or attempt to do any such things</li> -<li>Reproduce, copy, distribute, resell or otherwise use the Software for any commercial purpose</li> -<li>Use the Software in any way which breaches any applicable local, national or international law</li> -<li>Use the Software for any purpose that Komodo Platform considers is a breach of this EULA agreement</li> -</ul> - -<h3>Intellectual Property and Ownership</h3> -<p>Komodo Platform shall at all times retain ownership of the Software as originally downloaded by you and all subsequent downloads of the Software by you. The Software (and the copyright, and other intellectual property rights of whatever nature in the Software, including any modifications made thereto) are and shall remain the property of Komodo Platform.</p> - -<p>Komodo Platform reserves the right to grant licences to use the Software to third parties.</p> - -<h3>Termination</h3> -<p>This EULA agreement is effective from the date you first use the Software and shall continue until terminated. You may terminate it at any time upon written notice to Komodo Platform.</p> -<p>It will also terminate immediately if you fail to comply with any term of this EULA agreement. Upon such termination, the licenses granted by this EULA agreement will immediately terminate and you agree to stop all access and use of the Software. The provisions that by their nature continue and survive will survive any termination of this EULA agreement.</p> - -<h3>Governing Law</h3> -<p>This EULA agreement, and any dispute arising out of or in connection with this EULA agreement, shall be governed by and construed in accordance with the laws of Vietnam.</p> - -<p><b>This document was last updated on January 31st, 2020</b></p> - - FatalErrorModal - + Fatal Error Критическая ошибка - + Connection has been lost. You have been disconnected. Cоединение потеряно. Вы были отключены. - + Close Закрыть @@ -1416,73 +1390,69 @@ FirstLaunch - + Type password Введите пароль - + connect подключиться - + Welcome Добро пожаловать - + New Wallet Новый кошелек - Recover Wallet - Восстановить кошелек - - - + Import wallet Импортировать кошелек - + My Wallets Мои кошельки + - Delete Удалить - + Enter password to confirm deletion of Введите пароль чтобы подтвердить удаление - + wallet кошелек - + Cancel Отмена - - + + Wallet status Статус кошелька - + wallet deleted successfully кошелек успешно удален - + wallet password entered is incorrect введен неверный пароль к кошельку @@ -1490,7 +1460,7 @@ General - + %n day(s) %n день @@ -1499,7 +1469,7 @@ - + %nd day @@ -1509,7 +1479,7 @@ - + %nh hours @@ -1519,7 +1489,7 @@ - + %nm minutes @@ -1529,7 +1499,7 @@ - + %ns seconds @@ -1539,7 +1509,7 @@ - + %nms milliseconds @@ -1549,66 +1519,66 @@ - + - - - + Trading Fee Торговая комиссия - + Minimum Trading Amount Минимальный объем сделки - + Wallet %1 already exists WALLETNAME Кошелек %1 уже существует - + %1 balance is lower than the fees amount: %2 %3 %1 баланс менее чем размер комиссий: %2 %3 - + Tradable (after fees) %1 balance is lower than minimum trade amount Торгуемый (после комиссий) баланс %1 - меньше минимальной суммы сделки - + Please fill the price field Пожалуйста, укажите цену - + Please fill the volume field Пожалуйста, укажите сумму - - + + %1 volume is lower than minimum trade amount Сумма %1 меньше минимальной суммы сделки - - + + %1 needs to be enabled in order to use %2 %1 должен быть активным для использования %2 - - + + %1 balance needs to be funded, a non-zero balance is required to pay the gas of %2 transactions нужно пополнить баланс %1 для оплаты газа %2 транзакций - + Unknown Error Неизвестная ошибка @@ -1616,37 +1586,37 @@ Header - + You get Вы получите - + You send Вы отправите - + Fiat Price фиатная цена - + CEX rate Цена на CEX - + Price Цена - + Quantity Количество - + Total Всего @@ -1662,22 +1632,22 @@ InitialLoading - + Loading, please wait Загрузка. Пожалуйста, подождите - + Initializing MM2 Инициализация MM2 - + Enabling assets Добавление ассетов - + Getting ready Подготовка @@ -1685,7 +1655,7 @@ Languages - + Language Язык @@ -1693,17 +1663,17 @@ LinksRow - + Join our Discord server Присоединяйтесь к нашему Discord серверу - + Follow us on Twitter Подписывайтесь на наш Twitter - + Go to Support Guides Форум и база знаний @@ -1711,7 +1681,7 @@ List - + Funds are recoverable Средства могут быть восстановлены @@ -1719,12 +1689,12 @@ ListDelegate - + This order require a minimum amount of %1 %2 <br>You don't have enough funds.<br> Your max balance after fees is: (%3) Минимальный объем для данного ордера %1 %2 <br>У вас не достаточно средств.<br>Ваш максимальный баланс после вычета комиссий: (%3) - + %1 is not enabled - Do you want to enable it to be able to select %2 best orders ?<br><a href='#'>Yes</a> - <a href='#no'>No</a> %1 не активирован -Вы хотите активировать этот %2 актив чтобы видеть лучшие ордеры для него ?<br><a href='#'>Да</a> - <a href='#no'>Нет</a> @@ -1746,7 +1716,7 @@ - + Login Вход @@ -1756,12 +1726,12 @@ Введите пароль - + Back Назад - + Connect Подключиться @@ -1769,117 +1739,142 @@ Main - + + Segwit + + + + + Confirmation + + + + + Do you want to send your %1 funds to %2 wallet first? + + + + + Success + + + + + Your transaction is send, may take some time to arrive + + + + Wallet Balance Баланс кошелька - + Price Цена - + Change 24h Изменение за 24ч - + Portfolio % % портфолио - + Send Отправить - + Enable %1 ? Активировать %1 ? - + Yes Да - + No Нет - + Receive Получить - + Swap Обменять - + Claim Rewards Получить вознаграждение - + Faucet Фаусет - + Loading market data Загрузка рыночных данных - + There is no chart data for this ticker yet Для данного актива пока еще нет графиков данных - + Loading Загрузка - + Scanning blocks for TX History... Сканирование блокчейна для получения данных о транзакциях... - + Syncing TX History... Синхронизация истории транзакций... - + No transactions Нет транзакций - + Refreshing Обновление данных - + Fetching transactions Получение данных о транзакциях - + Trade - + Orders Ордеры - + History История @@ -1887,12 +1882,12 @@ MinTradeModal - + Minimum Trading Amount Минимальный торговый объем - + the minimum amount of %1 coin available for the order; the min_volume must be greater than or equal to %2; it must be also less or equal than volume param; default is %3 Минимальное кол-во %1 монеты доступное для торгов; минимальный объем должен быть больше или равен %2; Также он должен быть меньше или равен объему; Значение по умолчанию %3 @@ -1931,67 +1926,67 @@ NewUpdateModal - + Searching new updates... Ищем обновление... - + Please wait while the application is finding a new update... You can close this modal if you want. Пожалуйста подождите пока приложение ищет обновление... Вы можете закрыть это окно если желаете. - + Already updated Обновлено - + %1 is already up-to-date ! %1 уже последней версии! - + New update detected ! Обнаружено обновление ! - + Do you want to update %1 from %2 to %3 ? Хотели бы вы обновить %1 с %2 на %3 ? - + Download Скачать - + Remind me later Напомнить мне позже - + Download in progress... В процессе скачивания... - + Update downloaded Новая версия скачана - + Update has been successfully downloaded. Do you want to restart the application now ? Новая версия была успешно скачана. Хотели бы вы перезагрузить приложение сейчас? - + Restart now Перезагрузить сейчас - + Restart later Перезагрузить потом @@ -1999,12 +1994,12 @@ NewUser - + Wrong word, please check again Неверное слово. Пожалуйста, попробуйте еще раз - + Failed to create a wallet Ошибка при создании кошелька @@ -2019,12 +2014,12 @@ Задайте пароль - + Generated Seed Сгенерированный seed ключ - + Check Проверить @@ -2034,7 +2029,7 @@ Важно: убедитесь, что вы сохранили ваш seed ключ, прежде чем продолжить! - + We recommend storing it offline. Мы рекумендуем хранить его офлайн. @@ -2044,32 +2039,32 @@ Подтвердить seed ключ - + Continue Продолжить - + Let's double check your seed phrase Давайте перепроверим ваш seed ключ - + Copied to Clipboard Скопировано в буфер обмена - + Next Далее - + Your seed phrase is important - that's why we like to make sure it's correct. We'll ask you three different questions about your seed phrase to make sure you'll be able to easily restore your wallet whenever you want. Ваш seed ключ важен, и поэтому мы хотим убедиться, что вы его сохранили. Мы зададим вам три разных вопроса о вашем seed ключе, чтобы убедиться, что вы сможете легко восстановить свой кошелек, когда захотите. - + Enter the %n. word Введите %nе слово @@ -2104,146 +2099,123 @@ NotificationsModal - + Swap status updated Обновление статуса Свопа - + You sent %1 Вы отправили %1 - + You received %1 Вы получили %1 - + Your wallet balance changed Баланс вашего кошелька изменился - + Please check your internet connection (e.g. VPN service or firewall might block it). Пожалуйста, проверьте ваше интернет-соединение (например, служба VPN или брандмауэр могут блокировать подключение). - + Failed to enable %1 TICKER Не получается включить %1 - + Endpoint not reachable Эндпоинт не доступен - + Could not reach to endpoint Не удалось подключиться - + Mismatch at %1 custom asset configuration TICKER Несоответствие в конфигурации актива %1 - + Application needs to be restarted for %1 custom asset. TICKER Необходимо перезапустить приложение для %1. - + Batch %1 failed. Reason: %2 Группа %1 .не удалась. Причина: %2 - + Show Показать - + Restart Перезапустить - + Quit Выйти - + There isn't any notification Нет новых уведомлений - - OrderContent - - - ID - ID - - - - Maker Order - Мейкер ордер - - - - Taker Order - Тейкер ордер - - - - Cancel - Отменить - - OrderForm - + Price Цена - + Cancel selected order to change price Отменить выбранный ордер чтобы изменить цену - + Volume Объем - + Amount to sell Сумма для продажи - + Amount to receive Получаемая сумма - + Minimum volume: %1 Минимальный объем: %1 - + Volume: %1 Объем: %1 - + How it works ? Как это работает? @@ -2270,7 +2242,7 @@ Right slider: Sets the volume you want to trade. OrderLine - + Funds are recoverable Средства могут быть восстановлены @@ -2278,97 +2250,97 @@ Right slider: Sets the volume you want to trade. OrderModal - + Swap Details Детали свопа - + Order Details Детали ордера - + Maker Order Мейкер ордер - + Taker Order Тейкер ордер - + Refund State Статус рефанда - + Your swap failed but the auto-refund process for your payment started already. Please wait and keep application opened until you receive your payment back Обмен не был завершен, но процесс автоматического рефанда уже начался. Пожалуйста, подождите, оставляя приложение открытым, пока вы не получите свои средства - + Date Дата - + ID ID - + Maker Payment Sent ID ID отправки платежа мейкера - + Maker Payment Spent ID ID spend платежа мейкера - + Taker Payment Spent ID ID spend платежа тейкера - + Taker Payment Sent ID ID отправки платежа тейкера - + Error ID ID ошибки - + Error Log Лог ошибки - + Close Закрыть - + Cancel Order Отменить ордер - + Recover Funds Восстановить средства - + Refunding... Возмещается... - + View on Explorer Показать в эксплорере @@ -2402,38 +2374,38 @@ Right slider: Sets the volume you want to trade. OrdersPage - + From От - + To Кому - + Export CSV Скачать CSV - - + + Filter Фильтр - + Date Дата - + Apply Filter Применить фильтр - + Please choose the CSV export name and location Выберите название и расположение загружаемого файла @@ -2449,37 +2421,37 @@ Right slider: Sets the volume you want to trade. PasswordField - + Password Пароль - + Enter your wallet password Введите пароль вашего кошелька - + At least 1 lowercase alphabetical character Как минимум 1 строчная буква - + At least 1 uppercase alphabetical character Как минимум 1 заглавная буква - + At least 1 numeric character Как минимум 1 цифра - + At least 1 special character (eg. !@#$%) Как минимум 1 специальный символ (!@#$%) - + At least %n character(s) Не менее %n символов @@ -2488,7 +2460,7 @@ Right slider: Sets the volume you want to trade. - + Password and Confirm Password have to be same Пароль и подтверждение пароля должны совпадать @@ -2496,12 +2468,12 @@ Right slider: Sets the volume you want to trade. PasswordForm - + Confirm Password Подтверждения пароля - + Enter the same password to confirm Введите тот же пароль для подтверждения @@ -2509,27 +2481,27 @@ Right slider: Sets the volume you want to trade. Portfolio - + Search Поиск - + Show only coins with balance Показывать только монеты с балансом - + (%1/%2) - - Portfolio - Портфолио + + Dashboard + Портфолио - + Add asset Добавить крипто актив @@ -2573,75 +2545,114 @@ Right slider: Sets the volume you want to trade. CEXchange Цена + + PriceLineSimplified + + + Set swap price for evaluation + Установите цену для оценки + + + + Exchange rate + Обменный курс + + + + Selected + Выбрано + + + + CEXchange rate + CEXchange Цена + + + + Expensive + Невыгодный курс + + + + Expedient + Выгодный курс + + + + %1 compared to CEX + PRICE_DIFF% + %1 по сравнению с CEX + + ProView - + Failed to place the order Не удалось разместить ордер - + Placed the order Ордер размещен - + Chart График - + Trading Information Торговая информация - + Exchange Rates Курс обмена - + Orders Ордеры - + History История - + Order Book Ордербук - + Best Orders Лучшие ордеры - + Place Order Разместить ордер - + Buy Купить - + Sell Продать - + Order Selected Ордер выбран - + Start Swap Начать Своп @@ -2649,18 +2660,28 @@ Right slider: Sets the volume you want to trade. ReceiveModal - + Receive Получить - + Only send %1 to this address TICKER Отправить %1 на данный адресс - + + %1 address + + + + + copied to clipboard + + + + Close Закрыть @@ -2668,19 +2689,7 @@ Right slider: Sets the volume you want to trade. RecoverSeed - Failed to recover the seed - Ошибка при восстановлении seed ключа - - - Recover wallet - Setup - Импорт кошелька - Настройка - - - Recover wallet - Choose password - Импорт кошелька - Задайте пароль - - - + Failed to Import the wallet Не удалось импортировать кошелек @@ -2695,33 +2704,54 @@ Right slider: Sets the volume you want to trade. Импорт кошелька - Задайте пароль - + Wallet Name Название кошелька - - + + Enter seed Введите сид-фразу - + BIP39 seed validation failed, try again or select 'Allow custom seed' BIP39 валидация сид-фразы неуспешна, пожалуйста попробуйте снова или выберите 'Разрешить пользовательский формат сид-фразы' - + + <strong>Allow custom seed</strong> + + + + + Custom seed phrases might be less secure and easier to crack than a generated BIP39 compliant seed phrase or private key (WIF).<br><br>To confirm you understand the risk and know what you are doing, type <strong>'I understand'</strong> in the box below. + + + + + + I understand + + + + + Enable + Добавить + + + Next Далее - + Continue Продолжить - + Allow custom seed Разрешить пользовательский формат сид-фразы @@ -2729,58 +2759,58 @@ Right slider: Sets the volume you want to trade. RecoverSeedModal - - + + View seed and private keys Показать seed-фразу и приватные ключи - + Please enter your password to view the seed. Введите пароль для отображения seed ключа. - + Wrong Password Неправильный пароль - + Cancel Отменить - + Backup seed Сделать бекап seed-фразы - + RPC Password RPC Пароль - + Search a coin. Поиск актива. - + Public Address Публичный адрес - + Private Key Приватный ключ - + Close Закрыть - + View Показать @@ -2788,17 +2818,17 @@ Right slider: Sets the volume you want to trade. RestartModal - + Applying the changes... Применяю изменения... - + Restarting the application... Перезапуск приложения... - + Restarting the application. %1 Перезапуск приложения. %1 @@ -2824,7 +2854,7 @@ Right slider: Sets the volume you want to trade. SellBox - + Sell Продать @@ -2832,150 +2862,145 @@ Right slider: Sets the volume you want to trade. SendModal - + Failed to send Ошибка отправки - + Failed to Send Отправка не прошла - + Prepare to send Подготовить к отправке - - + + Recipient's address Адрес получателя - + Enter address of the recipient Введите адрес получателя - + Address Book Адресная книга - + The address has to be mixed case. Адрес должен быть написан в смешанном регистре. - + Fix Фикс - - Amount to send - Отправляемая сумма - - - + Enter the amount to send Введите сумму для отправки - + MAX МАКС - + Enable Custom Fees Включить настройку комиссий - + Only use custom fees if you know what you are doing! Используйте настраиваемые комиссии только если знаете, что делаете! - + Custom Fee Комиссия - + Enter the custom fee Введите комиссию сети - + Gas Limit Gas лимит - + Enter the gas limit Введите gas лимит - + Gas Price Цена за Gas - + Enter the gas price Введите цену за gas - + Custom Fee can't be higher than the amount Комиссия не может больше общей суммы транзакции - + Not enough funds. Недостаточно средств. - + You have %1 AMT TICKER У вас %1 - + Close Закрыть - + Prepare Подготовка - - + + Send Отправить - + Amount Сумма - + Fees Комиссия - + Date Дата - + Back Назад @@ -2983,43 +3008,43 @@ Right slider: Sets the volume you want to trade. SendModalContactList - + Select a contact with an %1 address Выберите контакт с %1 адресом - + Search for contacts... Поиск по контактам... - + %1 addresses %1 адреса - + 1 address 1 адрес - - + + Back Назад - + Choose an %1 address of %2 Выбрать %1 адрес из %2 - + Name Название - + Address Адрес @@ -3027,42 +3052,42 @@ Right slider: Sets the volume you want to trade. SendResult - + Transaction Complete! Транзакция завершена! - + Recipient's address Адрес получателя - + Amount Общая сумма транзакции - + Fees Комиссия сети - + Date Дата - + Transaction Hash Хэш транзакции - + Close Закрыть - + View on Explorer Смотреть в эксплорере @@ -3070,128 +3095,166 @@ Right slider: Sets the volume you want to trade. SettingModal - + Confirm Logout Подтвердите выход - + Are you sure you want to log out? Вы действительно хотите выйти? - + + Yes Да - + + Cancel Отмена - - + + Settings + Настройки + + + + Language Язык - + User Interface Интерфейс - + Security Приватность - - About - Дисклеймер - - - + General Общие - - Version - Версия + + About & Version + - + Enable Desktop Notifications Включить уведомления для рабочего стола - + Maximum number of enabled coins Макс. количество активированных монет - + Logs Логи - + Open Folder Открыть папку с логами - + + Reset assets configuration Сбросить конфигурацию ассетов - + Reset Сбросить - + + This will reset your wallet config to default + + + + Current Font Текущий шрифт - + Theme Тема - + Apply Changes Применить изменения - + Ask system's password before sending coins ? (2FA) Спрашивать системный пароль перед отправкой монет? (2FA) - + Application version Версия приложения - + + DEX Version + + + + + DEX Version copied to clipboard. + + + + MM2 version Версия MM2 - + + MM2 Version + + + + + MM2 Version copied to clipboard. + + + + Qt version Версия Qt - + + Qt Version + + + + + Qt Version copied to clipboard. + + + + Search Update Проверить на обновления - + Logout Выход @@ -3206,23 +3269,23 @@ Right slider: Sets the volume you want to trade. Показать seed-фразу и приватные ключи - - + + Show Показать - + Setup Camouflage Password Установить камуфляжный пароль - + Open Установить - + Disclaimer and ToS Дисклеймер и Условия Использования @@ -3230,80 +3293,93 @@ Right slider: Sets the volume you want to trade. Settings - + Fiat Фиат - + Recommended: Рекомендации: - + Enable Desktop Notifications Включить уведомления для рабочего стола - + Use QtTextRendering Or NativeTextRendering Использовать QtTextRendering или NativeTextRendering - + Open Logs Folder Открыть папку с логами - + View seed and private keys Показать seed-фразу и приватные ключи - + Disclaimer and ToS Дисклеймер и TOS - + Setup Camouflage Password Установить камуфляжный пароль - + Reset assets configuration Сбросить конфигурацию ассетов - + Delete Wallet Удалить кошелек - + Log out Выйти - + mm2 version версия MM2 + + Sidebar + + + Search coin + + + + + Add crypto + + + SidebarBottom - + Settings Настройки - + Support Поддержка - + Privacy Скрыть баланс @@ -3311,43 +3387,43 @@ Right slider: Sets the volume you want to trade. SidebarCenter - - + + Dashboard Портфолио - - + + Wallet Кошелек - - + + DEX DEX - + DEX features are not allowed in %1 COUNTRY Функции DEX заблокированы в %1 - - + + Address Book Адресная книга - - + + Fiat Фиат - + Coming soon ! Скоро в приложении ! @@ -3355,12 +3431,12 @@ Right slider: Sets the volume you want to trade. SmartChartView - + Loading market data Загрузка рыночных данных - + There is no chart data for this ticker yet Для этого графика пока еще нет данных @@ -3368,60 +3444,55 @@ Right slider: Sets the volume you want to trade. SubBestOrder - + Token Токен - + Available Quantity Доступное количество - + Available Quantity (in %1) Доступное количество (в %1) - + Fiat Volume Фиатный объем - + CEX Rate CEX цена - + %1 is not enabled - Do you want to enable it to be able to select %2 best orders ?<br><a href='#'>Yes</a> - <a href='#no'>No</a> %1 не активирован -Вы хотите активировать этот %2 актив чтобы видеть лучшие ордеры для него ?<br><a href='#'>Да</a> - <a href='#no'>Нет</a> - - - No best order. - - SubCoinSelector - + Token - + Balance Баланс - + Balance Fiat Баланс в фиате - + No Selectable coin. Нет монет для выбора. @@ -3429,72 +3500,62 @@ Right slider: Sets the volume you want to trade. SubHistory - + History История - + Filter Фильтр - + Date Дата - + Close filtering options. Закрыть настройки фильтра. - + Open filering options. Открыть настройки фильтра. - + Filter settings Настроить фильтр - - Base Ticker - Первый тикер - - - - Rel Ticker - Второй тикер - - - + From От - + To Кому - + Cancel Отменить - + Apply filter Применить фильтр - + Export Экспорт - + Please choose the CSV export name and location Выберите название и расположение экспортируемого CSV файла @@ -3502,63 +3563,53 @@ Right slider: Sets the volume you want to trade. SubOrders - - + + Orders Ордеры - + Close filtering options. Закрыть настройки фильтра. - + Filter Фильтр - + Date Дата - + Open filering options. Открыть настройки фильтра. - + Filter settings - - Base Ticker - Первый тикер - - - - Rel Ticker - Второй тикер - - - + From От - + To Кому - + Cancel Отменить - + Apply filter Применить фильтр @@ -3566,47 +3617,47 @@ Right slider: Sets the volume you want to trade. Support - + Update available Доступно обновление - + Up to date Последняя версия - + Changelog Журнал изменений - + Open Logs Folder Открыть папку с логами - + Frequently Asked Questions Часто задаваемые вопросы - + Do you store my private keys? Вы храните мои личные ключи? - + No! %1 is non-custodial. We never store any sensitive data, including your private keys, seed phrases, or PIN. This data is only stored on the user’s device and never leaves it. You are in full control of your assets. Нет! %1 не хранит персональную информацию, включая приватные ключи, seed фразы, или PIN. Эти данные хранятся только у вас и никогда не покидают ваше устройство. Ваши активы всегда в вашем и только вашем распоряжении. - + How is trading on %1 different from trading on other DEXs? Как торговля на %1 отличается от других торговли на других децентрализованных биржах? - + Other DEXs generally only allow you to trade assets that are based on a single blockchain network, use proxy tokens, and only allow placing a single order with the same funds. %1 enables you to natively trade across two different blockchain networks without proxy tokens. You can also place multiple orders with the same funds. For example, you can sell 0.1 BTC for KMD, QTUM, or VRSC — the first order that fills automatically cancels all other orders. @@ -3615,12 +3666,12 @@ Right slider: Sets the volume you want to trade. %1 же позволяет вам торговать нативно через две разные блокчейн сети без прокси токенов. Также вы можете размещать несколько ордеов одним и тем же балансом. Например вы можете продать 0.1 BTC за KMD, QTUM или VRSC – первый сматченный ордер автоматически отменит остальные. - + Several factors determine the processing time for each swap. The block time of the traded assets depends on each network (Bitcoin typically being the slowest) Additionally, the user can customize security preferences. For example, (you can ask %1 to consider a KMD transaction as final after just 3 confirmations which makes the swap time shorter compared to waiting for a <a href="https://komodoplatform.com/security-delayed-proof-of-work-dpow/">notarization</a>. Несколько факторов определяют время завершения каждого Атомарного Свопа. Время блока на каждой из торгуемых сетей (Bitcoin обычно самый медленный) В добавок каждый юзер может кастомизировать опции защиты. Например в пред-настройках Свопа, (вы можете установить %1 так чтобы протокол считал транзакцию KMD финальной как только она получит всего 3 подтверждения что уменьшает время Атомарного Свопа в сравнении с ожиданием <a href="https://komodoplatform.com/security-delayed-proof-of-work-dpow/">нотаризации</a>. - + Yes. You must remain connected to the internet and have your app running to successfully complete each atomic swap (very short breaks in connectivity are usually fine). Otherwise, there is risk of trade cancellation if you are a maker, and risk of loss of funds if you are a taker. The atomic swap protocol requires both participants to stay online and monitor the involved blockchains for the process to stay atomic. If you go offline, so will your orders, and any that are in progress will fail, leading to potential loss of trade / transaction fees, and a wait for the swap to timeout and issue a refund. It may also negatively affect your wallet's reputation score for future trade matching. @@ -3633,67 +3684,67 @@ For this reason, we recommend cancelling orders before closing %1, or reviewing По этой причине мы рекомендуем отменять заказы перед закрытием%1 или проверять и корректировать свои цены при перезапуске%1. - + Yes! %1 offers support through the <a href="%2">%1 Discord server</a>. The team and the community are always happy to help! Да! %1 предоставляет саппорт через <a href="%2">%1 Discord сервер</a>. Команда и сообщество проекта всегда рады помочь! - + %1 is available for mobile on both <a href="%2">Android and iPhone, and for desktop on Windows, Mac, and Linux</a> operating systems. %1 доступен для Android и iOS мобильных устройв <a href="%2">, и для операционных систем Windows, Mac и Linux</a> на PC. - + Who is behind %1? Кто создал %1? - + %1 is developed by the Komodo team. Komodo is one of the most established blockchain projects working on innovative solutions like atomic swaps, Delayed Proof of Work, and an interoperable multi-chain architecture. %1 разрабатывается командой Komodo. Komodo один из наиболее известных блокчейн проектов который работает над такими инновационными решениями как Атомарные Свопы, "Отложенный" PoW, а также над совместимой мульти-чейн архитектурой. - + Is it possible to develop my own white-label exchange on %1? Возможно ли разработать децентрализованную биржу с моим брендом на %1? - + Absolutely! You can read our developer documentation for more details or contact us with your partnership inquiries. Have a specific technical question? The %1 developer community is always ready to help! Обязательно! Вы можете прочитать нашу документацию для разработчиков для более детального ревью или же связаться с нашей командой по поводу партнерства. Есть очень специфичный технический вопрос? %1 наше комьюнити разработчиков всегда готово помочь! - + Which devices can I use %1 on? На каких устройствах я могу использовать %1 ? - + Compliance Info Комплаенс информация - + Due to regulatory and legal circumstances the citizens of certain jurisdictions including, but not limited to, the United States of America, Canada, Hong Kong, Israel, Singapore, Sudan, Austria, Iran and any other state, country or other jurisdiction that is embargoed by the United States of America or the European Union are not allowed to use this application. В связи с нормативными и правовыми обстоятельствами граждане определенных юрисдикций, включая, помимо прочего, Соединенные Штаты Америки, Канаду, Гонконг, Израиль, Сингапур, Судан, Австрию, Иран и любые другие государства, страны или другие юрисдикции, на которые введено эмбарго. Соединенных Штатов Америки или Европейского Союза не могут использовать это приложение. - + How long does each atomic swap take? Сколько времени занимает каждый атомарный своп? - + Do I need to be online for the duration of the swap? Необходимо ли мне быть в сети во время свопа? - + How are the fees on %1 calculated? Как подсчитывается %1 комиссия? - + There are two fee categories to consider when trading on %1. 1. %1 charges approximately 0.13% (1/777 of trading volume but not lower than 0.0001) as the trading fee for taker orders, and maker orders have zero fees. @@ -3708,7 +3759,7 @@ Network fees can vary greatly depending on your selected trading pair. Комиссии сети могут очень сильно варьироваться в зависимости от выбранной торговой пары. - + Do you provide user support? Предоставляете ли вы поддержку пользователей? @@ -3716,19 +3767,19 @@ Network fees can vary greatly depending on your selected trading pair. SwapProgress - + act SHORT FOR ACTUAL TIME фактич - + est SHORT FOR ESTIMATED прибл - + Progress details Прогресс @@ -3744,27 +3795,27 @@ Network fees can vary greatly depending on your selected trading pair. TableDex - + Asset Актив - + Balance Баланс - + Change 24h Изменение за 24ч - + Trend 7d Тренд 7д - + Price Цена @@ -3772,20 +3823,33 @@ Network fees can vary greatly depending on your selected trading pair. TextAreaWithTitle - + Save Сохранить - + Edit Редактировать + + TextEditWithTitle + + + Swap ID + + + + + copied to clipboard + + + TextFieldWithTitle - + Required Обязательное поле @@ -3793,7 +3857,7 @@ Network fees can vary greatly depending on your selected trading pair. Toast - + Click here to see the details Нажмите, чтобы узнать подробности @@ -3801,130 +3865,145 @@ Network fees can vary greatly depending on your selected trading pair. Trade - + Swap Обменять - + Instant trading with best orders Быстрая торговля с лучшими ордерами - + From От - + Minimum: %1 Минимум: %1 - + Enter an amount Введите количество - + MAX МАКС - + To Получатель - + Pick an order Выберите ордер - + Price Цена - + Better price found: %1. Updating forms. Найдена цена лучше: %1.Обновляю форму. - + Better price (%1) found but received quantity (%2) is lower than your current one (%3). Click here to update the selected order. Лучшая цена (%1) была обнаружена но количество (%2) меньше чем в вашем текущем ордере (%3).Нажмите чтобы обновить выбранный ордер. - + Reset form. Сбросить форму. - + %1 - + Tradable: Доступно: - + + Pick a coin + + + + Swap Now Начать обмен - + Failed to place the order Не удалось разместить ордер - + Placed the order Ордер размещен - + Entered amount must be superior than 0. Введенная сумма должна быть больше 0. - + You must select an order. Вы должны выбрать ордер. - + Entered amount is below the minimum required by this order: %1 Введнная сумма меньше минимальной для этого ордера: %1 - - + + %1 needs to be enabled in order to use %2 %1 должен быть активным для использования %2 - - + + %1 balance needs to be funded, a non-zero balance is required to pay the gas of %2 transactions нужно пополнить баланс %1 для оплаты газа %2 транзакций - - + + Search Поиск - + + No buy orders found for %1. + + + + + You can check later or try to sell a different coin. + + + + Total %1 fees: Всего %1 комиссий: - + %2 (%3) @@ -3932,12 +4011,12 @@ Network fees can vary greatly depending on your selected trading pair. TradeViewHeader - + How to trade Как начатаь торговлю - + FAQ FAQ @@ -3945,67 +4024,67 @@ Network fees can vary greatly depending on your selected trading pair. TransactionDetailsModal - + Transaction Details Детали транзакции - + Amount Сумма - + Fees Комиссия сети - + Date Дата - + Unconfirmed Не подтверждена - + Transaction Hash Хэш транзакции - + Confirmations Подтверждения - + Block Height Блок - + From От - + To Получатель - + Notes Заметки - + Close Закрыть - + View on Explorer Смотреть в эксплорере @@ -4013,22 +4092,22 @@ Network fees can vary greatly depending on your selected trading pair. Transactions - + Received Получено - + Sent Отправлено - + fees комиссии - + Unconfirmed Не подтверждена @@ -4058,77 +4137,97 @@ Network fees can vary greatly depending on your selected trading pair. atomic_dex::wallet_page - + You do not have enough funds. У вас не достаточно средств. - + %1 is not activated: click on the button to enable it or enable it manually %1 не активирован: нажмите на кнопку чтобы активировать или сделайте это вручную - + You need to have %1 to pay the gas for %2 transactions. Вам нужен %1 для оплаты газа за %2 транзакции. - + Checksum verification failed for %1. Checksum верфикация неуспешна для %1. - + Invalid checksum for %1. Click on the convert button to turn it into a mixed case address Невалидная хэш-сумма для %1. Нажмите на кнопку конвертации в mixed case адрес - + Legacy address used for %1, click on the convert button to convert it to a Cashaddress. Введен legacy адрес для %1, нажмите на кнопку для конвертации в Cashaddress формат. - + %1 address must be prefixed with 0x %1 адрес должен начинаться с 0x - + %1 address length is invalid, please use a valid address. %1 длина адреса не валидна, пожалуйста используйте валидный адрес. + + + %1 address is invalid. + + + + + Invalid checksum. + + + + + %1 address has invalid prefixes. + + + + + Unknown error. + + main - + Logout Выход - + Confirm Logout Подтверждение выхода - + Are you sure you want to log out? Вы действительно хотите выйти? - + Yes Да - + Cancel Отменить - + Balance Баланс - \ No newline at end of file + diff --git a/atomic_defi_design/assets/languages/atomic_defi_tr.ts b/atomic_defi_design/assets/languages/atomic_defi_tr.ts index f94a1d9e8a..f942e54aeb 100644 --- a/atomic_defi_design/assets/languages/atomic_defi_tr.ts +++ b/atomic_defi_design/assets/languages/atomic_defi_tr.ts @@ -17,154 +17,154 @@ AddCustomCoinModal - + Choose the asset type Varlık türünü seçin - + Type Tip - + Cancel İptal - - - + + + Next İleri - - + + Enter the contract address Kontrat adresini girin - + Choose the asset ticker Varlık kodunu girin - + Ticker Varlık Kodu - + Enter the ticker Varlık kodunu girin - + Contract Address Kontrat Adresi - + Get the contract address from Kontrat adresini şuradan alın - + Get the contract address from Kontrat adresini şuradan alın - - - - + + + + Previous Geri - + Choose the asset logo Varlık logosunu seçin - + Browse Göz at - + Please choose the asset logo Lütfen varlık logosunu seçin - + Configuration Konfigürasyon - + All configuration fields will be fetched using the contract address you provided. Tüm konfigürasyon bilgileri verdiğiniz kontrat adresinden edinilip doldurulacak. - + Name İsim - + Enter the name İsmi girin - + Coingecko ID Coingecko ID - + Enter the Coingecko ID Coingecko ID'sini girin - + Get the Coingecko ID Coingecko ID'si al - + Active Aktif - - + + Preview Görüntüle - + WARNING: Application will restart immidiately to apply the changes! DİKKAT: Program değişiklikleri uygulamak için yeniden başlatılacak! - + Asset not found, please go back and make sure Contract Address is correct Varlık bulunamadı, lütfen geri dönün ve Kontrat Adresi'nin doğruluğundan emin olun - + Config Fields Konfig Alanları - + Fetched Data Çekilen Veri - + Submit & Restart Yolla ve Yeniden Başlat @@ -172,57 +172,57 @@ AddressBook - + Address Book Adres Defteri - + New Contact Yeni Kişi - + Search a contact by name or tags İsim ya da etiket ile kişi ara - + Name İsim - + Tags (first 6) Etiket - + Actions Eylemler - + Edit Düzenle - + Remove Kaldır - + Do you want to remove this contact ? Bu kişiyi kaldırmak istiyor musunuz ? - + Yes Evet - + No Hayır @@ -230,174 +230,194 @@ AddressBookAddContactAddressModal - + Create a new address Yeni bir adres oluştur - + Edit address entry Adres girdisini düzenleyin - + Selected wallet: %1 - + NONE - + Enter a name Bir ad girin - + This key already exists. Bu anahtar zaten mevcut. - + Enter the address Adresi girin - + Validate Geçerle - + Cancel İptal + + + Convert + + AddressBookEditContactModal - + Edit contact Kişiyi düzenle - + Contact Name Kişi Adı - + Enter a contact name Bir kişi adı girin - + Address List Adres Listesi - + Search for an address entry. Bir adres girdisi arayın. - + Type Tür - + Key Anahtar - + Address Adres - + Actions Eylemler - + New Address Yeni Adres - + Tags Etiketler - + + + - + Confirm Onayla - - + + Cancel İptal - + The selected address belongs to a disabled coin, you need to enabled it before sending. Seçilen adres devre dışı bırakılmış bir koine aittir, göndermeden önce etkinleştirmeniz gerekir. - + Enable Etkinleştir - + Cannot send to this address Bu adrese gönderilemiyor - + Your balance is empty Bakiyeniz boş - + Ok Tamam + + + Remove address ? + + + + + Yes + Evet + + + + No + Hayır + AddressBookNewContactCategoryModal - + Add a new tag Yeni etiket ekle - + Enter the tag name Etiket adı girin - + This contact already has this tag Bu kişi zaten bu etikete sahip - + Add Ekle - + Cancel İptal @@ -405,27 +425,27 @@ AddressBookNewContactModal - + Create a new contact Yeni bir kişi ekle - + Enter the contact name Kişi adını girin - + This contact name already exists. Bu kişi adı zaten mevcut. - + Confirm Onayla - + Cancel İptal @@ -433,12 +453,12 @@ AddressBookSendWalletSelector - + Choose a valid Geçerli bir - + coin koin seçin @@ -446,12 +466,12 @@ AddressBookWalletTypeListModal - + Select wallet type Cüzdan türünü seçin - + Search Ara @@ -459,7 +479,7 @@ AmountChart - + Work in progress İş devam ediyor @@ -467,7 +487,7 @@ App - + Recover Funds Result Fon Kurtarma Sonucu @@ -475,7 +495,7 @@ AssetPieChart - + Assets Varlıklar @@ -531,7 +551,7 @@ BuyBox - + Buy Satın Al @@ -539,37 +559,37 @@ CamouflagePasswordModal - + Setup Camouflage Password Kamuflaj Parolasını Ayarla - + Camouflage Password is a secret password for emergency situations. Kamuflaj Parolası acil durumlar için olan gizli bir paroladır. - + Using it to login will display your balance lower than it actually is. Bu parolayla giriş yapınca bakiyeniz normalinden daha az görünecektir. - + Here you enter the suffix and at login you need to enter {real_password}{suffix} Buraya son eki gireceksiniz, giriş yaparken ise {gerçek_şifre}{son ek} şeklinde giriş yapacaksınız - + Enter a suffix Son eki giriniz - + Cancel İptal - + Save Kaydet @@ -577,12 +597,12 @@ CandleStickChart - + Loading market data Borsa bilgisi yükleniyor - + There is no chart data for this pair yet Bu parite için henüz grafik verisi yok @@ -613,12 +633,12 @@ CexInfoModal - + Market Data Piyasa Verisi - + Market data (prices, charts, etc.) marked with the ⓘ icon originates from third-party sources.<br><br>Data is sourced via <a href="https://bandprotocol.com/">Band Decentralized Oracle</a> and <a href="https://coingecko.com">CoinGecko</a>.<br><br><b>Oracle Supported Pairs:</b><br>%1<br><br><b>Last reference (Band Oracle):</b><br><a href="%2">%2</a> ⓘ simgesiyle işaretlenen piyasa verileri (fiyatlar, grafikler vb.) üçüncü taraf kaynaklardan alınmıştır. .<br><br>Veriler kaynakları: <a href="https://bandprotocol.com/">Band Decentralized Oracle</a> ve <a href="https://coingecko.com">CoinGecko</a>.<br><br><b>Oracle Supported Pairs:</b><br>%1<br><br><b>Son referans (Band Oracle):</b><br><a href="%2">%2</a> @@ -634,12 +654,12 @@ ClaimRewardsModal - + Failed to prepare to claim rewards Ödül alımı hazırlığı başarısız sonuçlandı - + Claim your %1 reward? TICKER %1 ödülünüzü alacak mısınız? @@ -746,7 +766,7 @@ İptal - + Confirm Onayla @@ -754,24 +774,24 @@ CoinMenu - + Disable %1 TICKER %1'i Etkisizleştir - + Disable and Delete %1 TICKER %1'i Etkisizleştir ve Sil - + Disable all %1 assets Tüm %1 türü varlıkları etkisizleştir - + Disable all assets Tüm varlıkları etkisizleştir @@ -792,12 +812,12 @@ Combo_fiat - + Fiat Döviz - + Recommended: Önerilen: @@ -848,74 +868,74 @@ ConfirmTradeModal - + Confirm Exchange Details Al-Sat Detaylarını Onayla - + This swap request can not be undone and is a final event! Bu takas isteği geri döndürülemez! - + Total %1 fees: %2 (%3) Toplam %1 ücreti: %2 (%3) - + Security configuration Güvenlik yapılandırması - + dPoW protected dPoW korumalı - - + + Read more about dPoW dPoW hakkında daha fazla bilgi - + Use custom protection settings for incoming %1 transactions TICKER %1 işlemleri için özel güvenlik ayarları kullan - + Enable Komodo dPoW security Komodo dPoW güvenliğini etkinleştir - + %1 confirmations for incoming %2 transactions Gelen %2 işlemleri için %1 onay - + This transaction can take up to 60 mins - DO NOT close this application! Bu işlem 60 dakikayı bulabilir - Programı KAPATMAYINIZ! - + Required Confirmations Gereken Onaylar - + Warning, this atomic swap is not dPoW protected! Uyarı, bu atomik takas dPoW korumalı değil! - + Cancel İptal - + Confirm Onayla @@ -923,7 +943,7 @@ CopyFieldButton - + Copied to Clipboard Panoya Kopyalandı @@ -931,188 +951,188 @@ Dashboard - + The current number of enabled coins does not match your configuration specification. Your assets configuration will be reset. Etkinleştirilmiş koinlerin mevcut sayısı yapılandırma ayarlarınızla eşleşmiyor. Varlık yapılandırmanız sıfırlanacak. - - + + Content for this section will be added later. Stay tuned! Bu kısmın içeriği daha sonra eklenecektir. Takipte kalın! - + Matching Eşleşiyor - + Order Matching Emir Eşleşiyor - + Matched Eşleşti - + Order Matched Emir Eşleşti - + Ongoing Devam ediyor - + Swap Ongoing Takas Devam Ediyor - + Successful Başarılı - + Swap Successful Takas Başarılı - + Refunding Geri ödeniyor - + Failed Başarısız - + Swap Failed Takas Başarısız - + Unknown Bilinmiyor - + Unknown State Bilinmeyen durum - + Started Başlatıldı - + Negotiated Pazarlık yapıldı - + Taker fee sent Alıcı ücreti gönderildi - + Maker payment received Yapıcı ödemesi alındı - + Maker payment wait confirm started Yapıcı ödemesi bekleme onayı başladı - + Maker payment validated and confirmed Yapıcı ödemesi doğrulandı ve onaylandı - + Taker payment sent Alıcı ödemesi gönderildi - + Taker payment spent Alıcı ödemesi harcandı - + Maker payment spent Yapıcı ödemesi harcandı - + Finished Tamamlandı - + Start failed Başlatılamadı - + Negotiate failed Pazarlık başarısız - + Taker fee validate failed Alıcı ücreti doğrulanamadı - + Maker payment transaction failed Yapıcı ödeme işlemi başarısız - + Maker payment Data send failed Yapıcı ödeme verileri gönderilemedi - + Maker payment wait confirm failed Yapıcı ödemesi bekleme onayı başarısız - + Taker payment validate failed Alıcı ödemesi doğrulanamadı - + Taker payment wait confirm failed Alıcı ödemesi bekleme onayı başarısız oldu - + Taker payment spend failed Alıcı ödeme harcaması başarısız oldu - + Maker payment wait refund started Yapıcı ödemesi bekleme iadesi başladı - + Maker payment refunded Yapıcı ödemesi iade edildi - + Maker payment refund failed Yapıcı ödeme iadesi başarısız @@ -1135,49 +1155,41 @@ Maks - - DefaultSweetComboBox - - - Search - Ara - - DeleteWalletModal - + Delete Wallet Cüzdanı Sil - + Are you sure you want to delete %1 wallet? WALLET_NAME %1 cüzdanını silmek istediğinizden emin misiniz? - + If so, make sure you record your seed phrase in order to restore your wallet in the future. Öyleyse, daha sonra cüzdanınızı geri yükleyebilmek için seed kelimelerinizi kaydettiğinizden emin olun. - + Enter your wallet password Cüzdan parolasını girin - + Wrong Password Yanlış Parola - + Cancel İptal - + Delete Sil @@ -1185,7 +1197,7 @@ DexAppPasswordField - + Type password @@ -1193,34 +1205,34 @@ DexKeyChecker - + At least 1 lowercase alphabetical character En az 1 küçük harf - + At least 1 uppercase alphabetical character En az 1 büyük harf - + At least 1 numeric character En az 1 sayı - + At least 1 special character (eg. !@#$%) En az 1 özel karakter (ör. !@#$%) - + At least %n character(s) En az %n karakter - + Password and Confirm Password have to be same Parola ve Parola Doğrulaması aynı olmalıdır @@ -1228,7 +1240,7 @@ DexPaginator - + items per page sayfa başına öğe @@ -1236,17 +1248,17 @@ DexRangeSlider - + Min Min - + Half Yarısı - + Max Maks @@ -1254,7 +1266,7 @@ DexSweetComboBox - + Search Ara @@ -1262,47 +1274,47 @@ EnableCoinModal - + Enable assets Varlıkları etkineştir - + Add a custom asset to the list Listeye özel varlık ekleyin - + All assets are already enabled! Bütün varlıklar zaten etkinleştirildi! - + Change assets limit Varlıkların limitini değiştirin - + Search Ara - + Select all assets Tüm varlıkları seç - + You can still enable %1 assets. Selected: %2. Hala %1 varlık etkinleştirebilirsiniz. Seçilen: %2. - + Close Kapat - + Enable Etkinleştir @@ -1310,121 +1322,50 @@ EulaModal - + Disclaimer & Terms of Service Sorumluluk Reddi & Kullanım Şartları - + Accept EULA Son Kullanıcı Lisans Sözleşmesi (EULA) 'ni kabul ediyorum - + Accept Terms and Conditions Şartları ve koşulları kabul ediyorum - + Close Kapat - + Cancel İptal - + Confirm Onayla - - - <h2>This End-User License Agreement ('EULA') is a legal agreement between you and Komodo Platform.</h2> - -<p>This EULA agreement governs your acquisition and use of our %1 software ('Software', 'Mobile Application', 'Application' or 'App') directly from Komodo Platform or indirectly through a Komodo Platform authorized entity, reseller or distributor (a 'Distributor').</p> -<p>Please read this EULA agreement carefully before completing the installation process and using the %1 software. It provides a license to use the %1 software and contains warranty information and liability disclaimers.</p> -<p>If you register for the beta program of the %1 software, this EULA agreement will also govern that trial. By clicking 'accept' or installing and/or using the %1 software, you are confirming your acceptance of the Software and agreeing to become bound by the terms of this EULA agreement.</p> -<p>If you are entering into this EULA agreement on behalf of a company or other legal entity, you represent that you have the authority to bind such entity and its affiliates to these terms and conditions. If you do not have such authority or if you do not agree with the terms and conditions of this EULA agreement, do not install or use the Software, and you must not accept this EULA agreement.</p> -<p>This EULA agreement shall apply only to the Software supplied by Komodo Platform herewith regardless of whether other software is referred to or described herein. The terms also apply to any Komodo Platform updates, supplements, Internet-based services, and support services for the Software, unless other terms accompany those items on delivery. If so, those terms apply.</p> - -<h3>License Grant</h3> -<p>Komodo Platform hereby grants you a personal, non-transferable, non-exclusive licence to use the %1 software on your devices in accordance with the terms of this EULA agreement.</p> - -<p>You are permitted to load the %1 software (for example a PC, laptop, mobile or tablet) under your control. You are responsible for ensuring your device meets the minimum security and resource requirements of the %1 software.</p> - -<p><b>You are not permitted to:</b></p> -<ul> -<li>Edit, alter, modify, adapt, translate or otherwise change the whole or any part of the Software nor permit the whole or any part of the Software to be combined with or become incorporated in any other software, nor decompile, disassemble or reverse engineer the Software or attempt to do any such things</li> -<li>Reproduce, copy, distribute, resell or otherwise use the Software for any commercial purpose</li> -<li>Use the Software in any way which breaches any applicable local, national or international law</li> -<li>Use the Software for any purpose that Komodo Platform considers is a breach of this EULA agreement</li> -</ul> - -<h3>Intellectual Property and Ownership</h3> -<p>Komodo Platform shall at all times retain ownership of the Software as originally downloaded by you and all subsequent downloads of the Software by you. The Software (and the copyright, and other intellectual property rights of whatever nature in the Software, including any modifications made thereto) are and shall remain the property of Komodo Platform.</p> - -<p>Komodo Platform reserves the right to grant licences to use the Software to third parties.</p> - -<h3>Termination</h3> -<p>This EULA agreement is effective from the date you first use the Software and shall continue until terminated. You may terminate it at any time upon written notice to Komodo Platform.</p> -<p>It will also terminate immediately if you fail to comply with any term of this EULA agreement. Upon such termination, the licenses granted by this EULA agreement will immediately terminate and you agree to stop all access and use of the Software. The provisions that by their nature continue and survive will survive any termination of this EULA agreement.</p> - -<h3>Governing Law</h3> -<p>This EULA agreement, and any dispute arising out of or in connection with this EULA agreement, shall be governed by and construed in accordance with the laws of Vietnam.</p> - -<p><b>This document was last updated on January 31st, 2020</b></p> - <h2>Bu Son Kullanıcı Lisans Sözleşmesi ('EULA') sizinle Komodo Platformu arasındaki yasal bir sözleşmedir.</h2> - -<p>Bu EULA sözleşmesi, %1 yazılımımızı ('Yazılım', 'Mobil Uygulama', 'Uygulama', veya 'Uyg') doğrudan Komodo Platformundan veya bir Komodo yetkili kuruluşu, satıcısı veya distribütörü (bir 'Distribütör') aracılığıyla dolaylı olarak satın almanızı ve kullanmanızı düzenler </p> -<p>Yükleme işlemini tamamlamadan ve %1 yazılımını kullanmadan önce lütfen bu EULA sözleşmesini dikkatlice okuyun.Sözleşme, %1 yazılımını kullanmak için bir lisans sağlar ve garanti bilgileri ile sorumluluk reddi beyanlarını içerir.</p> -<p>%1 yazılımının beta programına kaydolursanız, bu EULA sözleşmesi bu deneme için de geçerli olacaktır. 'Kabul et'i tıklayarak veya %1 yazılımını yükleyerek ve/veya kullanarak, Yazılımı kabul ettiğinizi ve bu EULA sözleşmesinin şartlarına bağlı kalmayı onaylıyorsunuz. .</p> -<p>Bu EULA sözleşmesini bir şirket veya başka bir tüzel kişilik adına yapıyorsanız, söz konusu kuruluşu ve bağlı kuruluşlarını bu hüküm ve koşullara bağlama yetkiniz olduğunu beyan edersiniz. Böyle bir yetkiniz yoksa veya bu EULA sözleşmesinin hüküm ve koşullarını kabul etmiyorsanız, Yazılımı kurmayın veya kullanmayın ve bu EULA sözleşmesini kabul etmemelisiniz.</p> -<p>Bu EULA sözleşmesi, burada başka bir yazılıma atıfta bulunulup bulunulmadığına veya burada açıklandığına bakılmaksızın, yalnızca burada Komodo Platformu tarafından sağlanan Yazılım için geçerli olacaktır. Koşullar, teslimat sırasında bu öğelere başka koşullar eklenmedikçe, Komodo Platformu güncellemeleri, ekleri, İnternet tabanlı hizmetler ve Yazılım için destek hizmetleri için de geçerlidir. Değilse, belirtilen şartlar geçerlidir.</p> - -<h3>Lisanslama</h3> -<p>Komodo Platformu işbu belge ile size %1 yazılımını bu EULA sözleşmesinin şartlarına uygun olarak cihazlarınızda kullanmanız için kişisel, devredilemez, münhasır olmayan bir lisans verir.</p> - -<p>%1 yazılımını (örneğin bir PC, dizüstü bilgisayar, cep telefonu veya tablet) kontrolünüz altında yüklemenize izin verilir. Cihazınızın %1 yazılımının minimum güvenlik ve kaynak gereksinimlerini karşılamasını sağlamaktan siz sorumlusunuz.</p> - -<p><b>İzin verimeyenler:</b></p> -<ul> -<li>Yazılımın tamamını veya herhangi bir bölümünü düzenlemek, değiştirmek, değiştirmek, uyarlamak, uyarlamak, tercüme etmek veya başka bir şekilde değiştirmek veya Yazılımın tamamının veya herhangi bir bölümünün başka bir yazılımla birleştirilmesine veya başka bir yazılıma dahil edilmesine veya kaynak koda dönüştürülmesine, ayrıştırılmasına veya Yazılımda tersine mühendislik veya bu tür şeyler yapmaya çalışma</li> -<li>Yazılımı herhangi bir ticari amaç için çoğaltma, kopyalama, dağıtma, yeniden satma veya başka bir şekilde kullanma</li> -<li>Yazılımı, geçerli yerel, ulusal veya uluslararası yasaları ihlal edecek şekilde kullanma</li> -<li>Yazılımı, Komodo Platformunun bu EULA sözleşmesinin ihlali olarak değerlendirdiği herhangi bir amaç için kullanma</li> -</ul> - -<h3>Fikri Mülkiyet ve Sahiplik</h3> -<p>Komodo Platformu, Yazılımın ilk olarak sizin tarafınızdan indirildiği şekliyle ve Yazılımın sizin tarafınızdan sonraki tüm indirmelerinin mülkiyetini her zaman elinde tutacaktır. Yazılım (ve üzerinde yapılan her türlü değişiklik dahil olmak üzere Yazılımın içeriği ne olursa olsun telif hakkı ve diğer fikri mülkiyet hakları) Komodo Platformu'nun mülkiyetindedir ve öyle kalacaktır.</p> - -<p>Komodo Platformu, Yazılımı üçüncü taraflara kullanma lisansları verme hakkını saklı tutar.</p> - -<h3>Fesih</h3> -<p>Bu EULA sözleşmesi, Yazılımı ilk kullandığınız tarihten itibaren geçerlidir ve feshedilene kadar devam edecektir. Komodo Platformu'na yazılı bildirimde bulunarak istediğiniz zaman feshedebilirsiniz.</p> -<p>Ayrıca, bu EULA sözleşmesinin herhangi bir şartına uymamanız durumunda da derhal feshedilecektir. Böyle bir fesih üzerine, bu EULA sözleşmesi tarafından verilen lisanslar derhal feshedilecektir ve siz Yazılımın tüm erişimini ve kullanımını durdurmayı kabul etmektesiniz. Doğaları gereği devam eden ve geçerliliğini koruyan hükümler, bu EULA sözleşmesinin herhangi bir şekilde feshedilmesi durumunda geçerliliğini koruyacaktır.</p> - -<h3>Geçerli Yasa</h3> -<p>Bu EULA sözleşmesi ve bu EULA sözleşmesinden kaynaklanan veya bu sözleşmeyle bağlantılı olarak ortaya çıkan tüm anlaşmazlıklar, Vietnam yasalarına göre yönetilecek ve yorumlanacaktır.</p> - -<p><b><b>Bu belge en son 31 Ocak 2020'de güncellenmiştir</b></p> - FatalErrorModal - + Fatal Error Kritik Hata - + Connection has been lost. You have been disconnected. Bağlantı kaybedildi. - + Close Kapat @@ -1445,73 +1386,69 @@ FirstLaunch - + Type password - + connect - + Welcome Hoşgeldiniz - + New Wallet Yeni Cüzdan - Recover Wallet - Cüzdan Kurtar - - - + Import wallet - + My Wallets Cüzdanlarım + - Delete Sil - + Enter password to confirm deletion of - + wallet - + Cancel İptal - - + + Wallet status - + wallet deleted successfully - + wallet password entered is incorrect @@ -1519,14 +1456,14 @@ General - + %n day(s) %n gün - + %nd day @@ -1534,7 +1471,7 @@ - + %nh hours @@ -1542,7 +1479,7 @@ - + %nm minutes @@ -1550,7 +1487,7 @@ - + %ns seconds @@ -1558,7 +1495,7 @@ - + %nms milliseconds @@ -1566,66 +1503,66 @@ - + - - - + Trading Fee Takas Ücreti - + Minimum Trading Amount Minimum Takas Hacmi - + Wallet %1 already exists WALLETNAME %1 cüzdanı zaten mevcut - + %1 balance is lower than the fees amount: %2 %3 %1 bakiye ücret tutarının altında: %2 %3 - + Tradable (after fees) %1 balance is lower than minimum trade amount Takas edilebilir (ücretlerden sonra)%1 bakiyesi minimum işlem ücretinden düşük - + Please fill the price field Lütfen fiyat alanını doldurun - + Please fill the volume field Lütfen hacim alanını doldurunuz - - + + %1 volume is lower than minimum trade amount %1 hacmi, minimum işlem ücretinden düşük - - + + %1 needs to be enabled in order to use %2 - - + + %1 balance needs to be funded, a non-zero balance is required to pay the gas of %2 transactions - + Unknown Error Bilinmeyen Hata @@ -1633,37 +1570,37 @@ Header - + You get Alacağınız - + You send Göndereceğiniz - + Fiat Price Döviz Fiyatı - + CEX rate CEX oranı - + Price Fiyat - + Quantity Miktar - + Total Toplam @@ -1679,22 +1616,22 @@ InitialLoading - + Loading, please wait Yükleniyor, lütfen bekleyiniz - + Initializing MM2 MM2 başlatılıyor - + Enabling assets Varlıklar etkinleştiriliyor - + Getting ready Hazırlanıyor @@ -1702,7 +1639,7 @@ Languages - + Language Dil @@ -1710,17 +1647,17 @@ LinksRow - + Join our Discord server Discord kanalımıza katılın - + Follow us on Twitter Bizi Twitter'dan takip edin - + Go to Support Guides Destek Kılavuzlarına Git @@ -1728,7 +1665,7 @@ List - + Funds are recoverable Fonlar kurtarılabilir @@ -1736,12 +1673,12 @@ ListDelegate - + This order require a minimum amount of %1 %2 <br>You don't have enough funds.<br> Your max balance after fees is: (%3) Bu sipariş minimum %1 %2 tutarını gerektiriyor <br> Yeterli bakiyeniz yok. <br> İşlem ücretlerinden sonra maksimum bakiyeniz: (%3) - + %1 is not enabled - Do you want to enable it to be able to select %2 best orders ?<br><a href='#'>Yes</a> - <a href='#no'>No</a> %1 etkin değil - En iyi %2 siparişini seçebilmesi için etkinleştirmek istiyor musunuz ? <br><a href='#'>Evet</a> - <a href='#no'>Hayır</a> @@ -1763,7 +1700,7 @@ - + Login Giriş @@ -1773,12 +1710,12 @@ - + Back Geri - + Connect @@ -1786,117 +1723,142 @@ Main - + + Segwit + + + + + Confirmation + + + + + Do you want to send your %1 funds to %2 wallet first? + + + + + Success + + + + + Your transaction is send, may take some time to arrive + + + + Wallet Balance Cüzdan Bakiyesi - + Price Fiyat - + Change 24h Değişim 24sa - + Portfolio % Portföy % - + Send Gönder - + Enable %1 ? %1 Etkinleştirilsin mi ? - + Yes Evet - + No Hayır - + Receive Al - + Swap Takasla - + Claim Rewards Ödülleri Al - + Faucet Musluk - + Loading market data Piyasa bilgisi yükleniyor - + There is no chart data for this ticker yet Henüz bu hisse senedi için grafik verisi yok - + Loading Yükleniyor - + Scanning blocks for TX History... TX Geçmişi için bloklar taranıyor ... - + Syncing TX History... TX Geçmişi senkronize ediliyor ... - + No transactions İşlem yok - + Refreshing Yenileniyor - + Fetching transactions İşlemler alınıyor - + Trade Al Sat - + Orders Emirler - + History Tarihçe @@ -1904,12 +1866,12 @@ MinTradeModal - + Minimum Trading Amount Minimum Takas Tutarı - + the minimum amount of %1 coin available for the order; the min_volume must be greater than or equal to %2; it must be also less or equal than volume param; default is %3 emir için mevcut minimum %1 koin miktarı; min_volume %2'den büyük veya eşit olmalıdır; ayrıca hacim parametresinden küçük veya eşit olmalıdır; varsayılan%3'tür @@ -1948,67 +1910,67 @@ NewUpdateModal - + Searching new updates... Yeni güncellemeler aranıyor... - + Please wait while the application is finding a new update... You can close this modal if you want. Uygulama yeni bir güncelleme ararken lütfen bekleyin... İsterseniz bu sekmeyi kapatabilirsiniz. - + Already updated Zaten güncellendi - + %1 is already up-to-date ! %1 zaten güncel ! - + New update detected ! Yeni güncelleme tespit edildi ! - + Do you want to update %1 from %2 to %3 ? %1'i %2'den %3'e güncellemek istiyor musunuz ? - + Download İndir - + Remind me later Daha sonra hatırlat - + Download in progress... İndirme işlemi devam ediyor... - + Update downloaded Güncelleme indirildi - + Update has been successfully downloaded. Do you want to restart the application now ? Güncelleme başarıyla indirildi. Uygulamayı şimdi yeniden başlatmak istiyor musunuz ? - + Restart now Şimdi yeniden başlat - + Restart later Daha sonra yeniden başlat @@ -2016,12 +1978,12 @@ NewUser - + Wrong word, please check again Hatalı kelime, lütfen kontrol ediniz - + Failed to create a wallet Cüzdan oluşturulamadı @@ -2036,17 +1998,17 @@ Önemli: Devam etmeden önce seed kelimelerinizi yedekleyin! - + We recommend storing it offline. Çevrimdışı saklamanızı öneririz. - + Generated Seed Seed Oluştur - + Check @@ -2061,32 +2023,32 @@ Seed'i Onayla - + Continue Devam - + Let's double check your seed phrase Seed kelimelerinizi tekrar kontrol edelim - + Copied to Clipboard Panoya Kopyalandı - + Next İleri - + Your seed phrase is important - that's why we like to make sure it's correct. We'll ask you three different questions about your seed phrase to make sure you'll be able to easily restore your wallet whenever you want. Seed kelimeleriniz önemlidir - bu yüzden doğru olduğundan emin olmak istiyoruz. Cüzdanınızı istediğiniz zaman kolayca kurtarabileceğinizden emin olmak için seed kelimeleriniz hakkında üç farklı soru soracağız. - + Enter the %n. word %n. kelimeyi giriniz @@ -2119,136 +2081,113 @@ NotificationsModal - + Swap status updated Takas durumu güncellendi - + You sent %1 %1 gönderdiniz - + You received %1 %1 aldınız - + Your wallet balance changed Cüzdan bakiyeniz değişti - + Please check your internet connection (e.g. VPN service or firewall might block it). Lütfen internet bağlantınızı kontrol edin (ör. VPN hizmeti veya güvenlik duvarı bağlantıyı engelliyor olabilir). - + Failed to enable %1 TICKER %1 etkinleştirilemedi - + Endpoint not reachable Uç nokta ulaşılabilir değil - + Could not reach to endpoint Uç noktaya ulaşılamadı - + Mismatch at %1 custom asset configuration TICKER %1 özel varlık yapılandırmasında uyuşmazlık - + Application needs to be restarted for %1 custom asset. TICKER %1 özel varlığı için uygulamanın yeniden başlatılması gerekiyor. - + Batch %1 failed. Reason: %2 %1 toplu işlemi başarısız oldu. Sebep: %2 - + Show Göster - + Restart Yeniden Başlat - + Quit Çık - + There isn't any notification Bildirim yok - - OrderContent - - - ID - ID - - - - Maker Order - Yapıcı Emir - - - - Taker Order - Alıcı Emir - - - - Cancel - İptal - - OrderForm - + Cancel selected order to change price Fiyatı değiştirmek için seçili emri iptal edin - + Amount to sell Satılacak miktar - + Amount to receive Alınacak miktar - + Minimum volume: %1 - + Volume: %1 - + How it works ? @@ -2270,12 +2209,12 @@ Right slider: Sets the volume you want to trade. - + Price Fiyat - + Volume Hacim @@ -2283,7 +2222,7 @@ Right slider: Sets the volume you want to trade. OrderLine - + Funds are recoverable Fonlar kurtarılabilir @@ -2291,97 +2230,97 @@ Right slider: Sets the volume you want to trade. OrderModal - + Swap Details Takas Detayları - + Order Details Emir Detayları - + Maker Order Yapıcı Emri - + Taker Order Alıcı Emri - + Refund State Geri Ödeme Durumu - + Your swap failed but the auto-refund process for your payment started already. Please wait and keep application opened until you receive your payment back Takas işlemi başarısız oldu, ancak otomatik geri ödeme süreci başladı. Lütfen bekleyin ve ödemenizi geri alana kadar uygulamayı açık tutun - + Date Tarih - + ID ID - + Recover Funds Fon Kurtar - + Refunding... - + View on Explorer Explorer'da Göster - + Maker Payment Sent ID Yapıcı Ödemesi Gönderilen Kimliği - + Maker Payment Spent ID Yapıcı Ödemesi Harcanan Kimliği - + Taker Payment Spent ID Alıcı Ödemesi Harcanan Kimliği - + Taker Payment Sent ID Alıcı Ödemesi Gönderilen Kimliği - + Cancel Order Emri İptal Et - + Error ID Hata ID - + Error Log Hata Kaydı - + Close Kapat @@ -2415,38 +2354,38 @@ Right slider: Sets the volume you want to trade. OrdersPage - + From Gönderen - + To Alan - + Apply Filter Filtreyi Uygula - - + + Filter - + Date Tarih - + Export CSV CSV'yi dışa aktar - + Please choose the CSV export name and location Lütfen CSV dışa aktarma adını ve konumunu seçin @@ -2462,44 +2401,44 @@ Right slider: Sets the volume you want to trade. PasswordField - + Password Parola - + Enter your wallet password Cüzdan parolanızı girin - + At least 1 lowercase alphabetical character En az 1 küçük harf - + At least 1 uppercase alphabetical character En az 1 büyük harf - + At least 1 numeric character En az 1 sayı - + At least 1 special character (eg. !@#$%) En az 1 özel karakter (ör. !@#$%) - + At least %n character(s) En az %n karakter - + Password and Confirm Password have to be same Parola ve Parola Doğrulaması aynı olmalıdır @@ -2507,12 +2446,12 @@ Right slider: Sets the volume you want to trade. PasswordForm - + Confirm Password Parola Doğrulaması - + Enter the same password to confirm Doğrulamak için aynı parolayı giriniz @@ -2520,27 +2459,27 @@ Right slider: Sets the volume you want to trade. Portfolio - + Search Ara - + Show only coins with balance Sadece bakiyesi olan koinleri göster - + (%1/%2) - - Portfolio - Portföy + + Dashboard + Panel - + Add asset Varlık ekle @@ -2584,75 +2523,114 @@ Right slider: Sets the volume you want to trade. CEXchange kuru + + PriceLineSimplified + + + Set swap price for evaluation + Değerlendirme için takas fiyatı belirleyin + + + + Exchange rate + Döviz kuru + + + + Selected + Seçili + + + + CEXchange rate + CEXchange kuru + + + + Expensive + Pahalı + + + + Expedient + Uygun + + + + %1 compared to CEX + PRICE_DIFF% + CEX ile karşılaştırıldığında %1 + + ProView - + Failed to place the order Emir başarısız oldu - + Placed the order Emir başarılı - + Chart Grafik - + Trading Information Al Sat Bilgisi - + Exchange Rates Döviz kurları - + Orders Emirler - + History Tarihçe - + Order Book Emir Defteri - + Best Orders En İyi Emirler - + Place Order Emir Ver - + Buy Al - + Sell Sat - + Order Selected Emir Seçildi - + Start Swap Takas Başlat @@ -2660,18 +2638,28 @@ Right slider: Sets the volume you want to trade. ReceiveModal - + Receive Al - + Only send %1 to this address TICKER Bu adrese yalnızca %1 gönder - + + %1 address + + + + + copied to clipboard + + + + Close Kapat @@ -2679,11 +2667,7 @@ Right slider: Sets the volume you want to trade. RecoverSeed - Failed to recover the seed - Seed kurtarılamadı - - - + Failed to Import the wallet @@ -2698,33 +2682,54 @@ Right slider: Sets the volume you want to trade. - + Wallet Name Cüzdan Adı - - + + Enter seed - + BIP39 seed validation failed, try again or select 'Allow custom seed' - + + <strong>Allow custom seed</strong> + + + + + Custom seed phrases might be less secure and easier to crack than a generated BIP39 compliant seed phrase or private key (WIF).<br><br>To confirm you understand the risk and know what you are doing, type <strong>'I understand'</strong> in the box below. + + + + + + I understand + + + + + Enable + Etkinleştir + + + Next İleri - + Continue Devam - + Allow custom seed Özel Seed'e izin ver @@ -2732,58 +2737,58 @@ Right slider: Sets the volume you want to trade. RecoverSeedModal - - + + View seed and private keys Seed ve özel anahtarları görüntüle - + Please enter your password to view the seed. Seed'i görmek için lütfen parolanızı giriniz. - + Wrong Password Yanlış Parola - + Cancel İptal - + Backup seed Seed'i yedekle - + RPC Password RPC Parolası - + Search a coin. Koin ara. - + Public Address Public Adres - + Private Key Private Key - + Close Kapat - + View Görüntüle @@ -2791,17 +2796,17 @@ Right slider: Sets the volume you want to trade. RestartModal - + Applying the changes... Değişiklikler uygulanıyor... - + Restarting the application... Uygulama yeniden başlatılıyor... - + Restarting the application. %1 @@ -2827,7 +2832,7 @@ Right slider: Sets the volume you want to trade. SellBox - + Sell Sat @@ -2835,150 +2840,145 @@ Right slider: Sets the volume you want to trade. SendModal - + Failed to send Gönderilemedi - + Failed to Send Gönderilemedi - + Prepare to send Göndermeye hazırlanıyor - - + + Recipient's address Alıcı adresi - + Enter address of the recipient Alıcının adresini giriniz - + Address Book Adres Defteri - + The address has to be mixed case. Adres, büyük-küçük harf karışık olmalıdır. - + Fix Düzelt - - Amount to send - Gönderilecek miktar - - - + Enter the amount to send Gönderilecek miktarı giriniz - + MAX MAKS - + Enable Custom Fees Özel İşlem Ücretlerini Etkinleştir - + Only use custom fees if you know what you are doing! Özel işlem ücretleri hakkında bilginiz yoksa kullanmayınız! - + Custom Fee Özel İşelm Ücreti - + Enter the custom fee Özel ücreti giriniz - + Gas Limit Gas Limiti - + Enter the gas limit Gas limitini giriniz - + Gas Price Gas Fiyatı - + Enter the gas price Gas fiyatını giriniz - + Custom Fee can't be higher than the amount Özel İşlem Ücreti takas miktarından daha yüksek olamaz - + Not enough funds. Yetersiz bakiye. - + You have %1 AMT TICKER %1'niz var - + Close Kapat - + Prepare Hazırla - - + + Send Gönder - + Amount Miktar - + Fees İşlem Ücreti - + Date Tarih - + Back Geri @@ -2986,43 +2986,43 @@ Right slider: Sets the volume you want to trade. SendModalContactList - + Select a contact with an %1 address %1 adresi olan bir kişi seçin - + Search for contacts... Kişi ara... - + %1 addresses %1 adresleri - + 1 address 1 adres - - + + Back Geri - + Choose an %1 address of %2 %2'nin bir %1 adresini seçin - + Name İsim - + Address Adres @@ -3030,42 +3030,42 @@ Right slider: Sets the volume you want to trade. SendResult - + Transaction Complete! İşlem Tamamlandı! - + Recipient's address Alıcının adresi - + Amount Miktar - + Fees İşlem Ücreti - + Date Tarih - + Transaction Hash İşlem Hash'i - + Close Kapat - + View on Explorer Explorer'da göster @@ -3073,128 +3073,166 @@ Right slider: Sets the volume you want to trade. SettingModal - + Confirm Logout - + Are you sure you want to log out? - + + Yes Evet - + + Cancel İptal - - + + Settings + Ayarlar + + + + Language Dil - + User Interface Kullanıcı Arayüzü - + Security Güvenlik - - About - Hakkında - - - + General Genel - - Version - Versiyon + + About & Version + - + Enable Desktop Notifications Masaüstü Bildirimlerini Aktif Et - + Maximum number of enabled coins Maksimum etkin koin sayısı - + Logs Günlük Kaydı - + Open Folder Klasörü Aç - + + Reset assets configuration Varlık yapılandırmasını sıfırla - + Reset Sıfırla - + + This will reset your wallet config to default + + + + Current Font Geçerli Yazı Tipi - + Theme Tema - + Apply Changes Değişiklikleri Uygula - + Ask system's password before sending coins ? (2FA) Para göndermeden önce sistem parolası sorulsun mu ? (2FA) - + Application version Uygulama sürümü - + + DEX Version + + + + + DEX Version copied to clipboard. + + + + MM2 version MM2 sürümü - + + MM2 Version + + + + + MM2 Version copied to clipboard. + + + + Qt version Qt sürümü - + + Qt Version + + + + + Qt Version copied to clipboard. + + + + Search Update Güncelleme Ara - + Logout Çıkış @@ -3209,23 +3247,23 @@ Right slider: Sets the volume you want to trade. Seed ve özel anahtarları görüntüle - - + + Show Göster - + Setup Camouflage Password Kamuflaj Parolasını Ayarla - + Open - + Disclaimer and ToS Sorumluluk Reddi ve K.Ş. @@ -3233,80 +3271,93 @@ Right slider: Sets the volume you want to trade. Settings - + Fiat Döviz - + Recommended: Önerilen: - + Enable Desktop Notifications Masaüstü Bildirimlerini Aktif Et - + Use QtTextRendering Or NativeTextRendering QtTextRendering veya NativeTextRendering Kullan - + Open Logs Folder Günlük Kaydı Klasörünü Aç - + Disclaimer and ToS Sorumluluk Reddi ve K.Ş. - + Setup Camouflage Password Kamuflaj Parolasını Ayarla - + Reset assets configuration Varlık yapılandırmasını sıfırla - + mm2 version mm2 versiyonu - + Delete Wallet Cüzdanı Sil - + View seed and private keys Seed ve özel anahtarları görüntüle - + Log out Çıkış yap + + Sidebar + + + Search coin + + + + + Add crypto + + + SidebarBottom - + Settings Ayarlar - + Support Destek - + Privacy Gizlilik @@ -3314,43 +3365,43 @@ Right slider: Sets the volume you want to trade. SidebarCenter - - + + Dashboard Panel - - + + Wallet Cüzdan - - + + DEX DEX - + DEX features are not allowed in %1 COUNTRY DEX özellikleri %1'de kullanılamıyor - - + + Address Book Adres Defteri - - + + Fiat Döviz - + Coming soon ! Çok yakında ! @@ -3358,12 +3409,12 @@ Right slider: Sets the volume you want to trade. SmartChartView - + Loading market data Piyasa bilgisi yükleniyor - + There is no chart data for this ticker yet Henüz bu kontrat için grafik verisi yok @@ -3371,60 +3422,55 @@ Right slider: Sets the volume you want to trade. SubBestOrder - + Token Token - + Available Quantity Mevcut Miktar - + Available Quantity (in %1) Mevcut Miktar (%1 olarak) - + Fiat Volume Fiat Hacmi - + CEX Rate CEX Oranı - + %1 is not enabled - Do you want to enable it to be able to select %2 best orders ?<br><a href='#'>Yes</a> - <a href='#no'>No</a> %1 etkin değil - En iyi %2 siparişini seçebilmesi için etkinleştirmek istiyor musunuz ? <br><a href='#'>Evet</a> - <a href='#no'>Hayır</a> - - - No best order. - En iyi emir yok - SubCoinSelector - + Token Token - + Balance Bakiye - + Balance Fiat Fiat Bakiye - + No Selectable coin. Seçilebilir Koin Yok @@ -3432,72 +3478,62 @@ Right slider: Sets the volume you want to trade. SubHistory - + History Tarihçe - + Filter - + Date Tarih - + Close filtering options. - + Open filering options. - + Filter settings Ayarları filtrele - - Base Ticker - Taban Para - - - - Rel Ticker - Karşıdaki para - - - + From Gönderen - + To Alan - + Cancel İptal - + Apply filter Filtreyi uygula - + Export Dışarı al - + Please choose the CSV export name and location Lütfen CSV dışa aktarma adını ve konumunu seçin @@ -3505,63 +3541,53 @@ Right slider: Sets the volume you want to trade. SubOrders - - + + Orders Emirler - + Filter - + Date Tarih - + Close filtering options. - + Open filering options. - + Filter settings Ayarları filtrele - - Base Ticker - Taban Para - - - - Rel Ticker - Karşıdaki para - - - + From Gönderen - + To Alan - + Cancel İptal - + Apply filter Filtreyi uygula @@ -3569,47 +3595,47 @@ Right slider: Sets the volume you want to trade. Support - + Update available Güncelleme mevcut - + Up to date Güncel - + Changelog Değişim günlüğü - + Open Logs Folder Günlük Kaydı Klasörünü Aç - + Frequently Asked Questions Sıkça Sorulan Sorular - + Do you store my private keys? Özel anahtarlarımızı depoluyor musunuz? - + No! %1 is non-custodial. We never store any sensitive data, including your private keys, seed phrases, or PIN. This data is only stored on the user’s device and never leaves it. You are in full control of your assets. Hayır! %1 gözetlenmiyor. Özel anahtarlarınız, seed veya PIN'iniz dahil olmak üzere hiçbir hassas veriyi asla depolamayız. Bu veriler yalnızca kullanıcının cihazında depolanır ve asla oradan çıkmaz. Varlıklarınızın tam kontrolü sizdedir. - + How is trading on %1 different from trading on other DEXs? %1'de işlem yapmanın diğer DEX'lerde işlem yapmaktan farkı nedir? - + Other DEXs generally only allow you to trade assets that are based on a single blockchain network, use proxy tokens, and only allow placing a single order with the same funds. %1 enables you to natively trade across two different blockchain networks without proxy tokens. You can also place multiple orders with the same funds. For example, you can sell 0.1 BTC for KMD, QTUM, or VRSC — the first order that fills automatically cancels all other orders. @@ -3618,12 +3644,12 @@ Right slider: Sets the volume you want to trade. %1, aracı token olmadan iki farklı blok zinciri ağında yerel olarak ticaret yapmanızı sağlar. Aynı parayla birden fazla sipariş verebilirsiniz. Örneğin, KMD, QTUM veya VRSC için 0,1 BTC satabilirsiniz - otomatik olarak doldurulan ilk sipariş diğer tüm siparişleri iptal eder. - + Several factors determine the processing time for each swap. The block time of the traded assets depends on each network (Bitcoin typically being the slowest) Additionally, the user can customize security preferences. For example, (you can ask %1 to consider a KMD transaction as final after just 3 confirmations which makes the swap time shorter compared to waiting for a <a href="https://komodoplatform.com/security-delayed-proof-of-work-dpow/">notarization</a>. Her takas için işlem süresini birkaç faktör belirler. İşlem gören varlıkların blok süresi her bir ağa bağlıdır (Bitcoin tipik olarak en yavaş olanıdır) Ek olarak, kullanıcı güvenlik tercihlerini özelleştirebilir. (Örneğin; %1 in KMD işlemini sadece 3 onayla gerçekleştirmesini seçerek takas süresini <a href="https://komodoplatform.com/security-delayed-proof-of-work-dpow/">notarizasyon</a> süresinden daha öncesine kısaltabilirsiniz. - + Yes. You must remain connected to the internet and have your app running to successfully complete each atomic swap (very short breaks in connectivity are usually fine). Otherwise, there is risk of trade cancellation if you are a maker, and risk of loss of funds if you are a taker. The atomic swap protocol requires both participants to stay online and monitor the involved blockchains for the process to stay atomic. If you go offline, so will your orders, and any that are in progress will fail, leading to potential loss of trade / transaction fees, and a wait for the swap to timeout and issue a refund. It may also negatively affect your wallet's reputation score for future trade matching. @@ -3636,12 +3662,12 @@ Tekrar çevrimiçi olduğunuzda, siparişleriniz çevrimdışı olmadan önce be Bu nedenle, %1 'i kapatmadan önce siparişleri iptal etmenizi veya %1 'i yeniden başlatırken fiyatlarınızı gözden geçirmenizi ve revize etmenizi öneririz. - + How are the fees on %1 calculated? %1 üzerinde işlem ücretleri nasıl hesaplanır? - + There are two fee categories to consider when trading on %1. 1. %1 charges approximately 0.13% (1/777 of trading volume but not lower than 0.0001) as the trading fee for taker orders, and maker orders have zero fees. @@ -3656,62 +3682,62 @@ Network fees can vary greatly depending on your selected trading pair. Ağ ücretleri, seçtiğiniz işlem çiftine bağlı olarak büyük ölçüde değişebilir. - + Yes! %1 offers support through the <a href="%2">%1 Discord server</a>. The team and the community are always happy to help! - + %1 is available for mobile on both <a href="%2">Android and iPhone, and for desktop on Windows, Mac, and Linux</a> operating systems. - + Who is behind %1? %1 arkasında kim var? - + %1 is developed by the Komodo team. Komodo is one of the most established blockchain projects working on innovative solutions like atomic swaps, Delayed Proof of Work, and an interoperable multi-chain architecture. %1, Komodo ekibi tarafından geliştirilmiştir. Komodo, atomik takaslar, Gecikmeli Çalışma Kanıtı ve birlikte çalışabilir bir çok zincirli mimari gibi yenilikçi çözümler üzerinde çalışan en köklü blok zinciri projelerinden biridir. - + Is it possible to develop my own white-label exchange on %1? %1 üzerinde kendi markamla borsamı geliştirmem mümkün mü? - + Absolutely! You can read our developer documentation for more details or contact us with your partnership inquiries. Have a specific technical question? The %1 developer community is always ready to help! Kesinlikle! Daha fazla ayrıntı için geliştirici belgelerimizi okuyabilir veya ortaklık sorularınız için bizimle iletişime geçebilirsiniz. Belirli bir teknik sorunuz mu var? %1 geliştirici topluluğu her zaman yardıma hazır! - + Which devices can I use %1 on? %1 'i hangi cihazlarda kullanabilirim? - + Compliance Info Uyumluluk Bilgisi - + Due to regulatory and legal circumstances the citizens of certain jurisdictions including, but not limited to, the United States of America, Canada, Hong Kong, Israel, Singapore, Sudan, Austria, Iran and any other state, country or other jurisdiction that is embargoed by the United States of America or the European Union are not allowed to use this application. Düzenleyici ve yasal koşullar nedeniyle, Amerika Birleşik Devletleri, Kanada, Hong Kong, İsrail, Singapur, Sudan, Avusturya, İran ve Amerika Birleşik Devletleri veya Avrupa Birliği tarafından ambargo uygulanan diğer herhangi bir eyalet, ülke veya diğer bölge vatandaşlarının bu uygulamayı kullanmasına izin verilmez. - + How long does each atomic swap take? Her bir atomik takas ne kadar sürer? - + Do I need to be online for the duration of the swap? Takas süresi boyunca çevrimiçi olmam gerekir mi? - + Do you provide user support? Kullanıcı desteği sağlıyor musunuz? @@ -3719,19 +3745,19 @@ Ağ ücretleri, seçtiğiniz işlem çiftine bağlı olarak büyük ölçüde de SwapProgress - + act SHORT FOR ACTUAL TIME gerçek - + est SHORT FOR ESTIMATED tahmini - + Progress details İlerleme ayrıntıları @@ -3747,27 +3773,27 @@ Ağ ücretleri, seçtiğiniz işlem çiftine bağlı olarak büyük ölçüde de TableDex - + Asset Varlık - + Balance Bakiye - + Change 24h Değişim 24sa - + Trend 7d Trend 7g - + Price Fiyat @@ -3775,20 +3801,33 @@ Ağ ücretleri, seçtiğiniz işlem çiftine bağlı olarak büyük ölçüde de TextAreaWithTitle - + Save Kaydet - + Edit Düzenle + + TextEditWithTitle + + + Swap ID + + + + + copied to clipboard + + + TextFieldWithTitle - + Required Gerekli @@ -3796,7 +3835,7 @@ Ağ ücretleri, seçtiğiniz işlem çiftine bağlı olarak büyük ölçüde de Toast - + Click here to see the details Detayları görmek için buraya tıklayın @@ -3804,130 +3843,145 @@ Ağ ücretleri, seçtiğiniz işlem çiftine bağlı olarak büyük ölçüde de Trade - + Swap Takasla - + Instant trading with best orders En iyi emirlerle anında alım satım - + From Gönderen - + Minimum: %1 Minimum: %1 - + Enter an amount Bir miktar gir - + MAX MAKS - + To Alan - + Pick an order Emri seç - + Price Fiyat - + Better price found: %1. Updating forms. Daha iyi fiyat bulundu: %1. Formları güncelliyor. - + Better price (%1) found but received quantity (%2) is lower than your current one (%3). Click here to update the selected order. Daha iyi fiyat (%1) bulundu, ancak alınan miktar (%2) mevcut fiyattan (%3) daha düşük. Seçilen emri güncellemek için buraya tıklayın. - + Reset form. Formu sıfırla - + %1 %1 - + Tradable: Al sat yapılabilir: - + + Pick a coin + + + + Swap Now Şimdi Takasla - + Failed to place the order Emir başarısız oldu - + Placed the order Emir başarılı - + Entered amount must be superior than 0. Girilen tutar 0'dan büyük olmalıdır. - + You must select an order. Bir emir seçmelisiniz. - + Entered amount is below the minimum required by this order: %1 Girilen miktar, bu emrin gerektirdiği minimum %1 tutarının altında - - + + %1 needs to be enabled in order to use %2 - - + + %1 balance needs to be funded, a non-zero balance is required to pay the gas of %2 transactions - - + + Search Ara - + + No buy orders found for %1. + + + + + You can check later or try to sell a different coin. + + + + Total %1 fees: Toplam %1 işlem giderleri: - + %2 (%3) %2 (%3) @@ -3935,12 +3989,12 @@ Ağ ücretleri, seçtiğiniz işlem çiftine bağlı olarak büyük ölçüde de TradeViewHeader - + How to trade Nasıl al sat yapılır - + FAQ SSS @@ -3948,67 +4002,67 @@ Ağ ücretleri, seçtiğiniz işlem çiftine bağlı olarak büyük ölçüde de TransactionDetailsModal - + Transaction Details İşlem Detayları - + Amount Miktar - + Fees İşlem Ücreti - + Date Tarih - + Unconfirmed Onaylanmamış - + Transaction Hash İşlem Hash'i - + Confirmations Onay Sayısı - + Block Height Blok Uzunluğu - + From Gönderen - + To Alan - + Notes Notlar - + Close Kapat - + View on Explorer Explorer'da göster @@ -4016,22 +4070,22 @@ Ağ ücretleri, seçtiğiniz işlem çiftine bağlı olarak büyük ölçüde de Transactions - + Received Alınan - + Sent Gönderilen - + fees işlem ücretleri - + Unconfirmed Onaylanmamış @@ -4060,77 +4114,97 @@ Ağ ücretleri, seçtiğiniz işlem çiftine bağlı olarak büyük ölçüde de atomic_dex::wallet_page - + You do not have enough funds. Bakiye yetersiz. - + %1 is not activated: click on the button to enable it or enable it manually %1 etkinleştirilmedi: etkinleştirmek için düğmeye tıklayın veya manuel olarak etkinleştirin - + You need to have %1 to pay the gas for %2 transactions. %2 işlemi için gaz ödemek üzere %1'e sahip olmanız gerekir. - + Checksum verification failed for %1. %1 için sağlama toplamı doğrulaması başarısız oldu. - + Invalid checksum for %1. Click on the convert button to turn it into a mixed case address %1 için geçersiz sağlama toplamı. Karışık bir durum adresine dönüştürmek için dönüştür düğmesine tıklayın - + Legacy address used for %1, click on the convert button to convert it to a Cashaddress. %1 için kullanılan eski adres, onu bir Cashaddress'e dönüştürmek için dönüştür düğmesine tıklayın. - + %1 address must be prefixed with 0x %1 adresinin önüne 0x konulmalı - + %1 address length is invalid, please use a valid address. %1 adres uzunluğu geçersiz, lütfen geçerli bir adres kullanın. + + + %1 address is invalid. + + + + + Invalid checksum. + + + + + %1 address has invalid prefixes. + + + + + Unknown error. + + main - + Logout Çıkış - + Confirm Logout - + Are you sure you want to log out? - + Yes Evet - + Cancel İptal - + Balance Bakiye - \ No newline at end of file + diff --git a/atomic_defi_design/qml/Components/CoinTypeTag.qml b/atomic_defi_design/qml/Components/CoinTypeTag.qml index 1ddf092576..5f996ef89b 100644 --- a/atomic_defi_design/qml/Components/CoinTypeTag.qml +++ b/atomic_defi_design/qml/Components/CoinTypeTag.qml @@ -16,7 +16,7 @@ AnimatedRectangle { anchors.verticalCenter: parent.verticalCenter anchors.horizontalCenter: parent.horizontalCenter text: type - color: DexTheme.foregroundColor + color: Style.getCoinTypeTextColor(model.type) font: DexTypo.overLine } } diff --git a/atomic_defi_design/qml/Components/ColumnHeader.qml b/atomic_defi_design/qml/Components/ColumnHeader.qml index 5ba97db931..75330b9c3a 100644 --- a/atomic_defi_design/qml/Components/ColumnHeader.qml +++ b/atomic_defi_design/qml/Components/ColumnHeader.qml @@ -27,7 +27,7 @@ Item { DefaultImage { id: arrow_icon - source: General.image_path + "arrow-" + (ascending ? "up" : "down") + ".svg" + source: General.image_path + "arrow-" + (ascending ? "down" : "up") + ".svg" width: title.font.pixelSize * 0.5 diff --git a/atomic_defi_design/qml/Components/DexSweetComboBox.qml b/atomic_defi_design/qml/Components/DexSweetComboBox.qml index b667b28413..deeaaef971 100644 --- a/atomic_defi_design/qml/Components/DexSweetComboBox.qml +++ b/atomic_defi_design/qml/Components/DexSweetComboBox.qml @@ -150,7 +150,8 @@ ComboBox { highlighted: control.highlightedIndex === index //foregroundColor: DexTheme.foregroundColor contentItem: DefaultText { - text_value: ticker + text_value: "" + ticker + "" + " %1".arg(General.coinName(ticker)) + } background: DexRectangle { diff --git a/atomic_defi_design/qml/Constants/DexTheme.qml b/atomic_defi_design/qml/Constants/DexTheme.qml index 9f24443aa3..4bde1a2069 100644 --- a/atomic_defi_design/qml/Constants/DexTheme.qml +++ b/atomic_defi_design/qml/Constants/DexTheme.qml @@ -450,13 +450,6 @@ QtObject { return Style.colorWhite4 } - function getCoinTypeColor(type) { - return getCoinColor(type === "ERC-20" ? "ETH" : - type === "QRC-20" ? "QTUM" : - type === "Smart Chain" ? "KMD" : - "BTC") - } - function getCoinColor(ticker) { const c = colorCoin[ticker] return c || Style.colorTheme2 diff --git a/atomic_defi_design/qml/Constants/General.qml b/atomic_defi_design/qml/Constants/General.qml index 277045a255..2978e9af0d 100644 --- a/atomic_defi_design/qml/Constants/General.qml +++ b/atomic_defi_design/qml/Constants/General.qml @@ -15,6 +15,7 @@ QtObject { readonly property string image_path: assets_path + "atomic_defi_design/assets/images/" readonly property string coin_icons_path: image_path + "coins/" readonly property string custom_coin_icons_path: os_file_prefix + API.app.settings_pg.get_custom_coins_icons_path() + "/" + readonly property string providerIconsPath: image_path + "providers/" function coinIcon(ticker) { if(ticker === "" || ticker === "All" || ticker===undefined) { @@ -44,6 +45,13 @@ QtObject { return coin_icons_path + filename + ".png" } + // Returns the full path of a provider icon. + function providerIcon(providerName) + { + if (providerName === "") return "" + return providerIconsPath + providerName + ".png"; + } + function qaterialIcon(name) { return "qrc:/Qaterial/Icons/" + name + ".svg" } @@ -557,6 +565,7 @@ QtObject { "ARPA/HUSD": "BINANCE:ARPAUSD", "ARPA/DAI": "BINANCE:ARPAUSD", "ARPA/PAX": "BINANCE:ARPAUSD", + "ARPA/TRYB": "BINANCE:ARPATRY", "ATOM/BTC": "BINANCE:ATOMBTC", "ATOM/ETH": "KRAKEN:ATOMETH", "ATOM/USDT": "COINBASE:ATOMUSD", @@ -590,6 +599,17 @@ QtObject { "AVAX/PAX": "BINANCE:AVAXUSD", "AVAX/BNB": "BINANCE:AVAXBNB", "AVAX/EURS": "BINANCE:AVAXEUR", + "AXS/BTC": "BINANCE:AXSBTC", + "AXS/ETH": "HUOBI:AXSETH", + "AXS/USDT": "BINANCE:AXSUSD", + "AXS/BUSD": "BINANCE:AXSUSD", + "AXS/USDC": "BINANCE:AXSUSD", + "AXS/TUSD": "BINANCE:AXSUSD", + "AXS/HUSD": "BINANCE:AXSUSD", + "AXS/DAI": "BINANCE:AXSUSD", + "AXS/PAX": "BINANCE:AXSUSD", + "AXS/BNB": "BINANCE:AXSBNB", + "AXS/EURS": "KRAKEN:AXSEUR", "BAL/BTC": "BINANCE:BALBTC", "BAL/ETH": "HUOBI:BALETH", "BAL/USDT": "BINANCE:BALUSD", @@ -690,6 +710,7 @@ QtObject { "BTC/EURS": "COINBASE:BTCEUR", "BTC/TRYB": "BINANCE:BTCTRY", "BTC/BIDR": "BITFINEX:BTCIDR", + "BTC/QC": "BITFINEX:BTCCNHT", "BTT/BTC": "BITFINEX:BTTBTC", "BTT/ETH": "KUCOIN:BTTETH", "BTT/USDT": "BITFINEX:BTTUSD", @@ -1048,8 +1069,13 @@ QtObject { "HOT/EURS": "BINANCE:HOTEUR", "HT/BTC": "HUOBI:HTBTC", "HT/ETH": "HUOBI:HTETH", - "HT/USDT": "HUOBI:HTUSDT", - "HT/HUSD": "HUOBI:HTHUSD", + "HT/USDT": "FTX:HTUSD", + "HT/BUSD": "FTX:HTUSD", + "HT/USDC": "FTX:HTUSD", + "HT/TUSD": "FTX:HTUSD", + "HT/HUSD": "FTX:HTUSD", + "HT/DAI": "FTX:HTUSD", + "HT/PAX": "FTX:HTUSD", "INJ/BTC": "BINANCE:INJBTC", "INJ/ETH": "HUOBI:INJETH", "INJ/USDT": "BINANCE:INJUSD", @@ -1239,8 +1265,13 @@ QtObject { "OCEAN/EURS": "KRAKEN:OCEANEUR", "OKB/BTC": "OKEX:OKBBTC", "OKB/ETH": "OKEX:OKBETH", - "OKB/USDT": "OKEX:OKBUSDT", - "OKB/USDC": "OKEX:OKBUSDC", + "OKB/USDT": "FTX:OKBUSD", + "OKB/BUSD": "FTX:OKBUSD", + "OKB/USDC": "FTX:OKBUSD", + "OKB/TUSD": "FTX:OKBUSD", + "OKB/HUSD": "FTX:OKBUSD", + "OKB/DAI": "FTX:OKBUSD", + "OKB/PAX": "FTX:OKBUSD", "ONT/BTC": "BINANCE:ONTBTC", "ONT/ETH": "BINANCE:ONTETH", "ONT/USDT": "BINANCE:ONTUSD", @@ -1266,9 +1297,22 @@ QtObject { "PAXG/EURS": "KRAKEN:PAXGEUR", "PNK/BTC": "BITFINEX:PNKBTC", "PNK/ETH": "BITFINEX:PNKETH", - "PNK/USDT": "OKEX:PNKUSDT", + "PNK/USDT": "BITFINEX:PNKUSD", + "PNK/BUSD": "BITFINEX:PNKUSD", + "PNK/USDC": "BITFINEX:PNKUSD", + "PNK/TUSD": "BITFINEX:PNKUSD", + "PNK/HUSD": "BITFINEX:PNKUSD", + "PNK/DAI": "BITFINEX:PNKUSD", + "PNK/PAX": "BITFINEX:PNKUSD", "POWR/BTC": "BINANCE:POWRBTC", "POWR/ETH": "BINANCE:POWRETH", + "POWR/USDT": "BINANCE:POWRUSD", + "POWR/BUSD": "BINANCE:POWRUSD", + "POWR/USDC": "BINANCE:POWRUSD", + "POWR/TUSD": "BINANCE:POWRUSD", + "POWR/HUSD": "BINANCE:POWRUSD", + "POWR/DAI": "BINANCE:POWRUSD", + "POWR/PAX": "BINANCE:POWRUSD", "QC/USDT": "FX_IDC:CNYUSD", "QC/BUSD": "FX_IDC:CNYUSD", "QC/USDC": "FX_IDC:CNYUSD", @@ -1366,7 +1410,13 @@ QtObject { "RVN/BNB": "BINANCE:RVNBNB", "RVN/HT": "HUOBI:RVNHT", "SHR/BTC": "KUCOIN:SHRBTC", - "SHR/USDT": "KUCOIN:SHRUSDT", + "SHR/USDT": "BITTREX:SHRUSD", + "SHR/BUSD": "BITTREX:SHRUSD", + "SHR/USDC": "BITTREX:SHRUSD", + "SHR/TUSD": "BITTREX:SHRUSD", + "SHR/HUSD": "BITTREX:SHRUSD", + "SHR/DAI": "BITTREX:SHRUSD", + "SHR/PAX": "BITTREX:SHRUSD", "SKL/BTC": "BINANCE:SKLBTC", "SKL/ETH": "HUOBI:SKLETH", "SKL/USDT": "COINBASE:SKLUSD", @@ -1401,8 +1451,15 @@ QtObject { "SPC/ETH": "HITBTC:SPCETH", "SPC/USDT": "HITBTC:SPCUSDT", "SRM/BTC": "BINANCE:SRMBTC", - "SRM/USDT": "BINANCE:SRMUSDT", - "SRM/BUSD": "BINANCE:SRMBUSD", + "SRM/USDT": "FTX:SRMUSD", + "SRM/BUSD": "FTX:SRMUSD", + "SRM/USDC": "FTX:SRMUSD", + "SRM/TUSD": "FTX:SRMUSD", + "SRM/HUSD": "FTX:SRMUSD", + "SRM/DAI": "FTX:SRMUSD", + "SRM/PAX": "FTX:SRMUSD", + "SRM/BNB": "BINANCE:SRMBNB", + "SRM/EURS": "KRAKEN:SRMEUR", "STFIRO/ETH": "SUSHISWAP:STFIROWETH", "STORJ/BTC": "BINANCE:STORJBTC", "STORJ/ETH": "KRAKEN:STORJETH", @@ -1608,8 +1665,10 @@ QtObject { "XRP/BNB": "BINANCE:XRPBNB", "XRP/EURS": "HITBTC:XRPEURS", "XRP/TRYB": "BINANCE:XRPTRY", + "XRP/BIDR": "BITFINEX:XRPIDR", "XRP/BCH": "HITBTC:XRPBCH", "XRP/HT": "HUOBI:XRPHT", + "XRP/TRX": "POLONIEX:XRPTRX", "XTZ/BTC": "BINANCE:XTZBTC", "XTZ/ETH": "KRAKEN:XTZETH", "XTZ/USDT": "COINBASE:XTZUSD", @@ -1621,6 +1680,7 @@ QtObject { "XTZ/PAX": "COINBASE:XTZUSD", "XTZ/BNB": "BINANCE:XTZBNB", "XTZ/EURS": "KRAKEN:XTZEUR", + "XTZ/TRX": "POLONIEX:XTZTRX", "XVS/BTC": "BINANCE:XVSBTC", "XVS/USDT": "BINANCE:XVSUSD", "XVS/BUSD": "BINANCE:XVSUSD", diff --git a/atomic_defi_design/qml/Constants/Style.qml b/atomic_defi_design/qml/Constants/Style.qml index e1ec399b31..2b5862105f 100644 --- a/atomic_defi_design/qml/Constants/Style.qml +++ b/atomic_defi_design/qml/Constants/Style.qml @@ -254,6 +254,15 @@ QtObject { } } + function getCoinTypeTextColor(type) + { + switch (type) + { + case 'BEP-20': return '#232323' + default: return '#F9F9F9' + } + } + function getCoinColor(ticker) { const c = colorCoin[atomic_qt_utilities.retrieve_main_ticker(ticker)] return c || Style.colorTheme2 @@ -269,12 +278,13 @@ QtObject { "AUR": "#0A6C5E", "AVA": "#5B567F", "AVAX": "#E84142", + "AXS": "#0055D5", "BAL": "#4D4D4D", - "BNB": "#F3BA2F", + "BNB": "#F9D987", "BCH": "#8DC351", "BIDR": "#F0B90B", "BSTY": "#78570D", - "BTC": "#F7931A", + "BTC": "#E9983C", "BTT": "#666666", "BTE": "#FFE201", "CAKE": "#D1884F", @@ -286,14 +296,15 @@ QtObject { "FTC": "#FFFFFF", "FTM": "#13B5EC", "GLEEC": "#8C41FF", + "GRMS": "#12B690", "GRS": "#377E96", "IOTA": "#404040", "JSTR": "#627EEA", "DOGE": "#C3A634", "ETC": "#328432", - "ETH": "#627EEA", + "ETH": "#687DE3", "ETHR": "#627EEA", - "KMD": "#2B6680", + "KMD": "#7490AA", "MORTY": "#A4764D", "RICK": "#A5CBDD", "EMC2": "#00CCFF", @@ -306,6 +317,7 @@ QtObject { "LBC": "#00775C", "LTC": "#BFBBBB", "LYNX": "#0071BA", + "LTFN": "#0099CC", "XPM": "#A67522", "XVC": "#B50126", "ZEC": "#ECB244", @@ -341,6 +353,7 @@ QtObject { "ILN": "#523170", "VRSC": "#3164D3", "WCN": "#E49F00", + "WWCN": "#E49F00", "THC": "#819F6F", "1INCH": "#95A7C5", "BABYDOGE": "#F3AA47", @@ -435,6 +448,7 @@ QtObject { "ZET": "#155169", "ZIL": "#42BBB9", "ZRX": "#302C2C", - "UNI": "#FF007A" + "UNI": "#FF007A", + "USBL": "#279553" }) } diff --git a/atomic_defi_design/qml/Dashboard/NotificationsModal.qml b/atomic_defi_design/qml/Dashboard/NotificationsModal.qml index a00f0ad1a5..f501aea027 100644 --- a/atomic_defi_design/qml/Dashboard/NotificationsModal.qml +++ b/atomic_defi_design/qml/Dashboard/NotificationsModal.qml @@ -62,10 +62,10 @@ DexPopup { break case "open_wallet_page": api_wallet_page.ticker = notification.params.ticker - dashboard.current_page = idx_dashboard_wallet + dashboard.switchPage(idx_dashboard_wallet) break case "open_swaps_page": - dashboard.current_page = idx_dashboard_exchange + dashboard.switchPage(idx_dashboard_exchange) dashboard.loader.onLoadComplete = () => { dashboard.current_component.current_page = dashboard.isSwapDone(notification.params.new_swap_status) ? idx_exchange_history : idx_exchange_orders @@ -144,6 +144,26 @@ DexPopup { notifications_list = notifications_list } + + function getOrderStatusText(status, short_text = false) { + switch (status) { + case "matching": + return short_text ? qsTr("Matching") : qsTr("Order Matching") + case "matched": + return short_text ? qsTr("Matched") : qsTr("Order Matched") + case "ongoing": + return short_text ? qsTr("Ongoing") : qsTr("Swap Ongoing") + case "successful": + return short_text ? qsTr("Successful") : qsTr("Swap Successful") + case "refunding": + return short_text ? qsTr("Refunding") : qsTr("Refunding") + case "failed": + return short_text ? qsTr("Failed") : qsTr("Swap Failed") + default: + return short_text ? qsTr("Unknown") : qsTr("Unknown State") + } + } + // Events function onUpdateSwapStatus(old_swap_status, new_swap_status, swap_uuid, base_coin, rel_coin, human_date) { newNotification("onUpdateSwapStatus", { @@ -156,7 +176,7 @@ DexPopup { }, swap_uuid, base_coin + "/" + rel_coin + " - " + qsTr("Swap status updated"), - getStatusText(old_swap_status) + " " + General.right_arrow_icon + " " + getStatusText(new_swap_status), + getOrderStatusText(old_swap_status) + " " + General.right_arrow_icon + " " + getOrderStatusText(new_swap_status), human_date, "open_swaps_page") } @@ -491,4 +511,4 @@ DexPopup { } } } -} \ No newline at end of file +} diff --git a/atomic_defi_design/qml/Exchange/Trade/BestOrder/ListDelegate.qml b/atomic_defi_design/qml/Exchange/Trade/BestOrder/ListDelegate.qml index 2970ce0aa3..37ae553491 100644 --- a/atomic_defi_design/qml/Exchange/Trade/BestOrder/ListDelegate.qml +++ b/atomic_defi_design/qml/Exchange/Trade/BestOrder/ListDelegate.qml @@ -133,11 +133,21 @@ Item { anchors.fill: parent hoverEnabled: true onClicked: { + console.log(order_form.visible) if(!Constants.API.app.portfolio_pg.global_cfg_mdl.get_coin_info(coin).is_enabled){ _tooltip.open() }else { app.pairChanged(base_ticker, coin) Constants.API.app.trading_pg.orderbook.select_best_order(uuid) + if(order_form.visible === false) { + order_form.visible = true + } + if(order_form.hidden === true) { + order_form.hidden = false + if(order_form.contentVisible === false) { + order_form.contentVisible = true + } + } } //if(is_mine) return diff --git a/atomic_defi_design/qml/Exchange/Trade/CandleStickChart.qml b/atomic_defi_design/qml/Exchange/Trade/CandleStickChart.qml index f9e7e54ea7..da0f3a7c25 100644 --- a/atomic_defi_design/qml/Exchange/Trade/CandleStickChart.qml +++ b/atomic_defi_design/qml/Exchange/Trade/CandleStickChart.qml @@ -25,10 +25,12 @@ DexBox { height: graph_bg.height property bool pair_supported: false - readonly property bool is_fetching: chart.loadProgress < 100 + readonly property bool is_fetching: dashboard.webEngineView.loadProgress < 100 + + onIs_fetchingChanged: dashboard.webEngineView.visible = !is_fetching && pair_supported RowLayout { - visible: pair_supported && !chart.visible + visible: pair_supported && !dashboard.webEngineView.visible anchors.centerIn: parent DefaultBusyIndicator { @@ -101,39 +103,32 @@ DexBox { chart_base = atomic_qt_utilities.retrieve_main_ticker(base) chart_rel = atomic_qt_utilities.retrieve_main_ticker(rel) - chart.loadHtml(` - - - -
-
- - -
- `) - } - - WebEngineView { - id: chart - anchors.fill: parent - anchors.margins: -1 - visible: !is_fetching && pair_supported + dashboard.webEngineView.loadHtml(` + + + +
+
+ + +
+ `); } } } diff --git a/atomic_defi_design/qml/Exchange/Trade/OrderBook/ListDelegate.qml b/atomic_defi_design/qml/Exchange/Trade/OrderBook/ListDelegate.qml index b33b8c63a2..91a1363b28 100644 --- a/atomic_defi_design/qml/Exchange/Trade/OrderBook/ListDelegate.qml +++ b/atomic_defi_design/qml/Exchange/Trade/OrderBook/ListDelegate.qml @@ -132,9 +132,16 @@ Item { }else { selectOrder(false, coin, price, quantity, price_denom, price_numer, quantity_denom, quantity_numer, min_volume, base_min_volume, base_max_volume, rel_min_volume, rel_max_volume, base_max_volume_denom, base_max_volume_numer, uuid) } + if(order_form.visible === false) { + order_form.visible = true + } + if(order_form.hidden === true) { + order_form.hidden = false + if(order_form.contentVisible === false) { + order_form.contentVisible = true + } + } } - - } } diff --git a/atomic_defi_design/qml/Exchange/Trade/Orders/OrderList.qml b/atomic_defi_design/qml/Exchange/Trade/Orders/OrderList.qml index a5cf5dfd36..9377ee37db 100644 --- a/atomic_defi_design/qml/Exchange/Trade/Orders/OrderList.qml +++ b/atomic_defi_design/qml/Exchange/Trade/Orders/OrderList.qml @@ -80,4 +80,11 @@ Item { Layout.bottomMargin: 10 } } -} \ No newline at end of file + + DexLabel + { + visible: list.count === 0 + anchors.centerIn: parent + text: qsTr("No results found") + } +} diff --git a/atomic_defi_design/qml/Exchange/Trade/ProView.qml b/atomic_defi_design/qml/Exchange/Trade/ProView.qml index 2fdd79ffc5..65899a5c88 100644 --- a/atomic_defi_design/qml/Exchange/Trade/ProView.qml +++ b/atomic_defi_design/qml/Exchange/Trade/ProView.qml @@ -2,11 +2,10 @@ import QtQuick 2.15 import QtQuick.Layouts 1.15 import QtQuick.Controls 2.15 import QtQuick.Controls.Material 2.15 - import QtGraphicalEffects 1.0 +import Qt.labs.settings 1.0 import Qaterial 1.0 as Qaterial -import Qt.labs.settings 1.0 import AtomicDEX.MarketMode 1.0 import AtomicDEX.TradingError 1.0 @@ -30,7 +29,7 @@ import "BestOrder/" as BestOrder // Orders (orders, history) import "Orders/" as OrdersView -import "./" as Here +import "../../Screens" ColumnLayout { id: form @@ -171,6 +170,17 @@ ColumnLayout { color: 'transparent' anchors.fill: parent } + + Component.onCompleted: + { + dashboard.webEngineView.parent = chart_view; + dashboard.webEngineView.anchors.fill = chart_view; + } + Component.onDestruction: + { + dashboard.webEngineView.visible = false; + dashboard.webEngineView.stop(); + } } } DexTradeBox { diff --git a/atomic_defi_design/qml/Exchange/Trade/SimpleView/List.qml b/atomic_defi_design/qml/Exchange/Trade/SimpleView/List.qml index cbb1ba6fa4..14aad50fb8 100644 --- a/atomic_defi_design/qml/Exchange/Trade/SimpleView/List.qml +++ b/atomic_defi_design/qml/Exchange/Trade/SimpleView/List.qml @@ -261,7 +261,7 @@ DexListView { bottomInset: 0 topInset: 0 outlinedColor: DexTheme.redColor - visible: (!main_order.is_history? details.cancellable?? false : false)===true? (order_mouse_area.containsMouse || hovered)? true : false : false + visible: !main_order.is_history && details.cancellable onClicked: { if(details) cancelOrder(details.order_id) } Row { anchors.centerIn: parent @@ -315,4 +315,4 @@ DexListView { } } -} \ No newline at end of file +} diff --git a/atomic_defi_design/qml/Exchange/Trade/SimpleView/SubHistory.qml b/atomic_defi_design/qml/Exchange/Trade/SimpleView/SubHistory.qml index 0303626ae6..28d2be000c 100644 --- a/atomic_defi_design/qml/Exchange/Trade/SimpleView/SubHistory.qml +++ b/atomic_defi_design/qml/Exchange/Trade/SimpleView/SubHistory.qml @@ -13,7 +13,7 @@ import "../../../Constants" as Constants //> Style import "../Orders" as Orders import "Main.js" as Main -import App 1.0 +import App 1.0 Item { id: _subHistoryRoot @@ -27,7 +27,7 @@ Item { reset() if(combo_base.currentTicker !== "All" | combo_rel.currentTicker !== "All") { buttonDelay.start() - } + } } function reset() { @@ -35,10 +35,10 @@ Item { applyFilter() applyAllFiltering() list_model_proxy.is_history = true - + } - function applyTickerFilter() { + function applyTickerFilter() { applyTickerFilter2(combo_base.currentTicker, combo_rel.currentTicker) } @@ -75,7 +75,7 @@ Item { onTriggered: applyButton.clicked() } - ColumnLayout // History + ColumnLayout // History { height: parent.height width: parent.width @@ -105,10 +105,10 @@ Item { .arg(combo_rel.currentTicker) .arg(qsTr("Date")) .arg(min_date.date.toLocaleDateString(Locale.ShortFormat, "yyyy.MM.dd")) - .arg(max_date.date.toLocaleDateString(Locale.ShortFormat, "yyyy.MM.dd")) + .arg(max_date.date.toLocaleDateString(Locale.ShortFormat, "yyyy.MM.dd")) } - DexAppButton + DexAppButton { anchors.right: parent.right anchors.rightMargin: -5 @@ -123,7 +123,7 @@ Item { ToolTip.delay: 500 ToolTip.timeout: 5000 ToolTip.visible: containsMouse - ToolTip.text: _subHistoryRoot.displayFilter ? qsTr("Close filtering options.") : qsTr("Open filering options.") + ToolTip.text: _subHistoryRoot.displayFilter ? qsTr("Close filtering options.") : qsTr("Open filtering options.") onClicked: _subHistoryRoot.displayFilter = !_subHistoryRoot.displayFilter } } @@ -136,7 +136,7 @@ Item { Layout.fillHeight: true Layout.fillWidth: true property bool is_history: true - + Component.onCompleted: { _subHistoryRoot.list_model_proxy.is_history = is_history } @@ -144,7 +144,7 @@ Item { id: order_list_view } DexRectangle { - anchors.fill: parent + anchors.fill: parent color: DexTheme.portfolioPieGradient ? 'transparent' : DexTheme.dexBoxBackgroundColor opacity: .8 visible: _subHistoryRoot.displayFilter @@ -160,7 +160,7 @@ Item { y: -20 Column { anchors.horizontalCenter: parent.horizontalCenter - leftPadding: 15 + leftPadding: 15 rightPadding: 15 visible: parent.height > 250 DexLabel { @@ -184,7 +184,7 @@ Item { valueRole: "ticker" textRole: 'ticker' } - + } RowLayout { width: main_order.width - 30 @@ -201,7 +201,7 @@ Item { textRole: 'ticker' } - + } spacing: 10 RowLayout { @@ -238,7 +238,7 @@ Item { color: DexTheme.foregroundColor backgroundColor: DexTheme.portfolioPieGradient ? '#FFFFFF' : 'transparent' } - + } } @@ -276,7 +276,7 @@ Item { } } } - + } Item { @@ -313,7 +313,7 @@ Item { } } } - + } FileDialog { id: export_csv_dialog @@ -326,7 +326,7 @@ Item { onAccepted: { const path = currentFile.toString() - + // Export console.log("Exporting to CSV: " + path) API.app.exporter_service.export_swaps_history_to_csv(path.replace(General.os_file_prefix, "")) @@ -339,6 +339,13 @@ Item { console.log("CSV export cancelled") } } - + + } + + DexLabel + { + visible: !_subHistoryRoot.displayFilter && order_list_view.count === 0 + anchors.centerIn: parent + text: qsTr("No results found") } } diff --git a/atomic_defi_design/qml/Exchange/Trade/SimpleView/SubOrders.qml b/atomic_defi_design/qml/Exchange/Trade/SimpleView/SubOrders.qml index f414ca3011..7720e99e6f 100644 --- a/atomic_defi_design/qml/Exchange/Trade/SimpleView/SubOrders.qml +++ b/atomic_defi_design/qml/Exchange/Trade/SimpleView/SubOrders.qml @@ -116,7 +116,7 @@ Item ToolTip.delay: 500 ToolTip.timeout: 5000 ToolTip.visible: containsMouse - ToolTip.text: _subOrdersRoot.displayFilter ? qsTr("Close filtering options.") : qsTr("Open filering options.") + ToolTip.text: _subOrdersRoot.displayFilter ? qsTr("Close filtering options.") : qsTr("Open filtering options.") onClicked: _subOrdersRoot.displayFilter = !_subOrdersRoot.displayFilter } } @@ -295,4 +295,11 @@ Item } } + + DexLabel + { + visible: !_subOrdersRoot.displayFilter && order_list_view.count === 0 + anchors.centerIn: parent + text: qsTr("No results found") + } } diff --git a/atomic_defi_design/qml/Portfolio/AssetsList.qml b/atomic_defi_design/qml/Portfolio/AssetsList.qml new file mode 100644 index 0000000000..7a91efdda4 --- /dev/null +++ b/atomic_defi_design/qml/Portfolio/AssetsList.qml @@ -0,0 +1,231 @@ +import QtQuick 2.12 +import QtQuick.Layouts 1.12 + +import "../Constants" as Dex +import "../Components" as Dex +import "../String.js" as DexString +import App 1.0 as Dex + +Dex.DefaultListView +{ + id: list + + property real _assetRowHeight: 65 + property real _assetNameColumnWidth: 160 + property real _assetNameColumnLeftMargin: 15 + property real _assetBalanceColumnWidth: 380 + property real _assetChange24hColumnWidth: 120 + property real _assetPriceColumWidth: 140 + property real _assetProviderColumnWidth: 42 + + model: Dex.API.app.portfolio_pg.portfolio_mdl.portfolio_proxy_mdl + + width: _assetNameColumnWidth + _assetNameColumnLeftMargin + _assetBalanceColumnWidth + _assetChange24hColumnWidth + _assetPriceColumWidth + _assetProviderColumnWidth + height: (count * _assetRowHeight) + 30 + interactive: false + scrollbar_visible: false + + // Header + header: RowLayout + { + id: columnsHeader + + width: list.width + height: 40 + + Dex.ColumnHeader + { + Layout.preferredWidth: _assetNameColumnWidth - _assetNameColumnLeftMargin + Layout.leftMargin: _assetNameColumnLeftMargin + icon_at_left: true + sort_type: sort_by_name + text: qsTr("Asset") + } + Dex.ColumnHeader + { + Layout.preferredWidth: _assetBalanceColumnWidth + icon_at_left: true + sort_type: sort_by_value + text: qsTr("Balance") + } + Dex.ColumnHeader + { + Layout.preferredWidth: _assetChange24hColumnWidth + icon_at_left: true + sort_type: sort_by_change + text: qsTr("Change 24h") + } + Dex.ColumnHeader + { + Layout.preferredWidth: _assetPriceColumWidth + icon_at_left: true + sort_type: sort_by_price + text: qsTr("Price") + } + Dex.DexLabel + { + Layout.preferredWidth: _assetProviderColumnWidth + text: qsTr("Source") + } + } + + delegate: Dex.DexRectangle + { + width: list.width + height: _assetRowHeight + color: mouseArea.containsMouse ? Dex.DexTheme.buttonColorHovered : Dex.DexTheme.contentColorTopBold + + Dex.DefaultMouseArea + { + id: mouseArea + anchors.fill: parent + hoverEnabled: true + acceptedButtons: Qt.LeftButton | Qt.RightButton + + onClicked: + { + if (!can_change_ticker) + return + if (mouse.button === Qt.RightButton) + contextMenu.popup() + else + { + api_wallet_page.ticker = ticker + dashboard.switchPage(idx_dashboard_wallet) + } + } + onPressAndHold: + { + if (!can_change_ticker) + return + + if (mouse.source === Qt.MouseEventNotSynthesized) + contextMenu.popup() + } + } + + RowLayout + { + anchors.fill: parent + + Item // Asset Column. + { + Layout.preferredWidth: _assetNameColumnWidth + + Image + { + id: assetImage + anchors.verticalCenter: parent.verticalCenter + anchors.left: parent.left + anchors.leftMargin: 15 + source: Dex.General.coinIcon(ticker) + width: 26 + height: 26 + } + + Dex.DexLabel + { + id: assetNameLabel + anchors.verticalCenter: assetImage.top + anchors.left: assetImage.right + anchors.leftMargin: _assetNameColumnLeftMargin + text: model.ticker + + } + + Dex.DexLabel + { + id: typeTag + anchors.verticalCenter: assetImage.bottom + anchors.left: assetImage.right + anchors.leftMargin: 15 + + text: model.type + font: Dex.DexTypo.overLine + opacity: .7 + color: Dex.Style.getCoinTypeColor(model.type) + + Dex.DexLabel + { + enabled: name === "Tokel" + visible: enabled + anchors.left: parent.right + anchors.leftMargin: 5 + + text: "IDO" + font: Dex.DexTypo.overLine + opacity: .7 + color: Dex.DexTheme.redColor + } + } + + } + + Dex.DexLabel // Balance Column. + { + id: assetBalanceLabel + + Layout.preferredWidth: _assetBalanceColumnWidth + + font: Dex.DexTypo.body2 + text_value: Dex.General.formatCrypto("", balance, ticker, main_currency_balance, + Dex.API.app.settings_pg.current_currency) + color: Qt.darker(Dex.DexTheme.foregroundColor, 0.8) + privacy: true + } + + Dex.DexLabel // Change 24h. + { + Layout.preferredWidth: _assetChange24hColumnWidth + font: Dex.DexTypo.body2 + text_value: + { + const v = parseFloat(change_24h) + return v === 0 ? '-' : Dex.General.formatPercent(v) + } + color: Dex.DexTheme.getValueColor(change_24h) + } + + Dex.DexLabel // Price Column. + { + Layout.preferredWidth: _assetPriceColumWidth + font: Dex.DexTypo.body2 + text_value: Dex.General.formatFiat('', main_currency_price_for_one_unit, + Dex.API.app.settings_pg.current_currency) + color: Dex.DexTheme.colorThemeDarkLight + } + + Item // Price Provider + { + Layout.preferredWidth: _assetProviderColumnWidth + + Image // Price Provider Icon. + { + id: priceProviderIcon + + enabled: priceProvider !== "unknown" + visible: enabled + anchors.centerIn: parent + width: 16 + height: 16 + source: enabled ? Dex.General.providerIcon(priceProvider) : "" + + Dex.DefaultMouseArea + { + id: priceProviderIconMouseArea + anchors.fill: parent + hoverEnabled: true + } + + Dex.DexTooltip + { + visible: priceProviderIconMouseArea.containsMouse + text: qsTr("Price provider is: %1").arg(DexString.capitalizeFirstLetter(priceProvider)) + } + } + } + + Dex.CoinMenu { id: contextMenu } + } + } +} diff --git a/atomic_defi_design/qml/Portfolio/Portfolio.qml b/atomic_defi_design/qml/Portfolio/Portfolio.qml index 25e9ee8eea..adfc830035 100644 --- a/atomic_defi_design/qml/Portfolio/Portfolio.qml +++ b/atomic_defi_design/qml/Portfolio/Portfolio.qml @@ -117,7 +117,6 @@ Item { anchors.topMargin: 90 contentHeight: _column.height clip: true - onHeightChanged: console.log(height) Column { id: _column topPadding: 10 @@ -196,17 +195,21 @@ Item { DefaultSwitch { Layout.alignment: Qt.AlignVCenter - text: qsTr("Show only coins with balance") + " %1".arg(qsTr("(%1/%2)").arg(coinsList.innerList.count).arg(portfolio_mdl.length)) + text: qsTr("Show only coins with balance") + " %1".arg(qsTr("(%1/%2)").arg(coinsList.count).arg(portfolio_mdl.length)) checked: portfolio_coins.with_balance onCheckedChanged: portfolio_coins.with_balance = checked + + Component.onDestruction: portfolio_coins.with_balance = false } } } } - TableDex + AssetsList { id: coinsList + width: parent.parent.width - 80 + anchors.horizontalCenter: parent.horizontalCenter } Item { diff --git a/atomic_defi_design/qml/Portfolio/TableDex.qml b/atomic_defi_design/qml/Portfolio/TableDex.qml index 181510b6f7..d2702c513d 100644 --- a/atomic_defi_design/qml/Portfolio/TableDex.qml +++ b/atomic_defi_design/qml/Portfolio/TableDex.qml @@ -172,7 +172,7 @@ Item { context_menu.popup() else { api_wallet_page.ticker = ticker - dashboard.current_page = idx_dashboard_wallet + dashboard.switchPage(idx_dashboard_wallet) } } onPressAndHold: { diff --git a/atomic_defi_design/qml/Screens/Dashboard.qml b/atomic_defi_design/qml/Screens/Dashboard.qml index 2c2df092b6..804ffb4009 100644 --- a/atomic_defi_design/qml/Screens/Dashboard.qml +++ b/atomic_defi_design/qml/Screens/Dashboard.qml @@ -1,12 +1,12 @@ import QtQuick 2.15 import QtQuick.Layouts 1.15 import QtQuick.Controls 2.15 - import QtGraphicalEffects 1.0 +import QtWebEngine 1.10 + import "../Components" import "../Constants" import App 1.0 - import "../Dashboard" import "../Portfolio" import "../Wallet" @@ -15,13 +15,14 @@ import "../Settings" import "../Support" import "../Sidebar" import "../Fiat" -import "../Settings" -as SettingsPage +import "../Settings" as SettingsPage Item { id: dashboard + property alias webEngineView: webEngineView + readonly property int idx_dashboard_portfolio: 0 readonly property int idx_dashboard_wallet: 1 readonly property int idx_dashboard_exchange: 2 @@ -39,8 +40,7 @@ Item { readonly property int idx_exchange_orders: 1 readonly property int idx_exchange_history: 2 - property - var current_ticker + property var current_ticker Layout.fillWidth: true @@ -57,6 +57,7 @@ Item { readonly property alias loader: loader readonly property alias current_component: loader.item property int current_page: idx_dashboard_portfolio + onCurrent_pageChanged: { app.deepPage = current_page * 10 } @@ -68,6 +69,14 @@ Item { return app.current_page === idx_dashboard } + function switchPage(page) + { + if (loader.status === Loader.Ready) + current_page = page + else + console.warn("Tried to switch to page %1 when loader is not ready yet.".arg(page)) + } + property var notifications_list: ([]) @@ -194,11 +203,18 @@ Item { } } + WebEngineView + { + id: webEngineView + backgroundColor: "transparent" + } + DefaultLoader { id: loader anchors.fill: parent transformOrigin: Item.Center + asynchronous: true sourceComponent: { switch (current_page) { @@ -293,25 +309,6 @@ Item { } } - function getStatusText(status, short_text = false) { - switch (status) { - case "matching": - return short_text ? qsTr("Matching") : qsTr("Order Matching") - case "matched": - return short_text ? qsTr("Matched") : qsTr("Order Matched") - case "ongoing": - return short_text ? qsTr("Ongoing") : qsTr("Swap Ongoing") - case "successful": - return short_text ? qsTr("Successful") : qsTr("Swap Successful") - case "refunding": - return short_text ? qsTr("Refunding") : qsTr("Refunding") - case "failed": - return short_text ? qsTr("Failed") : qsTr("Swap Failed") - default: - return short_text ? qsTr("Unknown") : qsTr("Unknown State") - } - } - function isSwapDone(status) { switch (status) { case "matching": @@ -345,6 +342,25 @@ Item { } } + function getStatusText(status, short_text=false) { + switch(status) { + case "matching": + return short_text ? qsTr("Matching") : qsTr("Order Matching") + case "matched": + return short_text ? qsTr("Matched") : qsTr("Order Matched") + case "ongoing": + return short_text ? qsTr("Ongoing") : qsTr("Swap Ongoing") + case "successful": + return short_text ? qsTr("Successful") : qsTr("Swap Successful") + case "refunding": + return short_text ? qsTr("Refunding") : qsTr("Refunding") + case "failed": + return short_text ? qsTr("Failed") : qsTr("Swap Failed") + default: + return short_text ? qsTr("Unknown") : qsTr("Unknown State") + } + } + function getStatusTextWithPrefix(status, short_text = false) { return getStatusStep(status) + " " + getStatusText(status, short_text) } @@ -399,4 +415,4 @@ Item { return qsTr(event_name) } } -} \ No newline at end of file +} diff --git a/atomic_defi_design/qml/Screens/InitialLoading.qml b/atomic_defi_design/qml/Screens/InitialLoading.qml index 0548b3bb6d..5e6086b7ef 100644 --- a/atomic_defi_design/qml/Screens/InitialLoading.qml +++ b/atomic_defi_design/qml/Screens/InitialLoading.qml @@ -17,7 +17,7 @@ SetupPage { readonly property string current_status: API.app.wallet_mgr.initial_loading_status onCurrent_statusChanged: { - if (current_status === "complete") + if (current_status === "enabling_coins") onLoaded() } @@ -47,4 +47,4 @@ SetupPage { current_status === "enabling_coins" ? qsTr("Enabling assets") : qsTr("Getting ready")) + "..." } } -} \ No newline at end of file +} diff --git a/atomic_defi_design/qml/Settings/SettingModal.qml b/atomic_defi_design/qml/Settings/SettingModal.qml index daec67acfd..ff1ef4cc93 100644 --- a/atomic_defi_design/qml/Settings/SettingModal.qml +++ b/atomic_defi_design/qml/Settings/SettingModal.qml @@ -228,14 +228,14 @@ Qaterial.Dialog SettingsButton { width: parent.width-30 height: 50 - title: qsTr("Reset assets configuration") + title: qsTr("Reset wallet configuration") buttonText: qsTr("Reset") onClicked: { dialog = app.showText({ - title: qsTr("Reset assets configuration"), - text: qsTr("This will reset your wallet config to default"), + title: qsTr("Reset wallet configuration"), + text: qsTr("This will restart your wallet with default settings"), standardButtons: Dialog.Yes | Dialog.Cancel, - yesButtonText: qsTr("Yes"), + yesButtonText: qsTr("Confirm"), cancelButtonText: qsTr("Cancel"), onAccepted: function() { restart_modal.open() diff --git a/atomic_defi_design/qml/Settings/Settings.qml b/atomic_defi_design/qml/Settings/Settings.qml index 24240aaa19..b7db1dcfa5 100644 --- a/atomic_defi_design/qml/Settings/Settings.qml +++ b/atomic_defi_design/qml/Settings/Settings.qml @@ -216,7 +216,7 @@ Item { Layout.fillWidth: true Layout.leftMargin: combo_fiat.Layout.leftMargin Layout.rightMargin: Layout.leftMargin - text: qsTr("Reset assets configuration") + text: qsTr("Reset wallet configuration") onClicked: { restart_modal.open() restart_modal.item.onTimerEnded = () => { API.app.settings_pg.reset_coin_cfg() } diff --git a/atomic_defi_design/qml/Sidebar/Sidebar.qml b/atomic_defi_design/qml/Sidebar/Sidebar.qml index 3f840b5651..801c04bed0 100644 --- a/atomic_defi_design/qml/Sidebar/Sidebar.qml +++ b/atomic_defi_design/qml/Sidebar/Sidebar.qml @@ -12,7 +12,7 @@ import Qaterial 1.0 as Qaterial Item { id: sidebar - property bool expanded: dashboard.current_page===dashboard.idx_dashboard_exchange? false : true + property bool expanded: dashboard.current_page === dashboard.idx_dashboard_exchange ? false : true readonly property alias app_logo: app_logo x: -top_rect.radius diff --git a/atomic_defi_design/qml/Sidebar/SidebarLine.qml b/atomic_defi_design/qml/Sidebar/SidebarLine.qml index 0cb176e8ae..ab8dd7166c 100644 --- a/atomic_defi_design/qml/Sidebar/SidebarLine.qml +++ b/atomic_defi_design/qml/Sidebar/SidebarLine.qml @@ -127,7 +127,7 @@ Item { else if(dashboard_index === idx_dashboard_privacy_mode) { togglePrivacyMode() } - else dashboard.current_page = dashboard_index + else dashboard.switchPage(dashboard_index) } } diff --git a/atomic_defi_design/qml/String.js b/atomic_defi_design/qml/String.js new file mode 100644 index 0000000000..2766351a58 --- /dev/null +++ b/atomic_defi_design/qml/String.js @@ -0,0 +1,4 @@ +function capitalizeFirstLetter(string) +{ + return string.charAt(0).toUpperCase() + string.slice(1); +} diff --git a/atomic_defi_design/qml/Wallet/Main.qml b/atomic_defi_design/qml/Wallet/Main.qml index 70ce986286..05d28df044 100644 --- a/atomic_defi_design/qml/Wallet/Main.qml +++ b/atomic_defi_design/qml/Wallet/Main.qml @@ -439,6 +439,7 @@ Item { // Price Graph InnerBackground { id: price_graph_bg + Layout.fillWidth: true Layout.fillHeight: true Layout.leftMargin: layout_margin @@ -450,7 +451,7 @@ Item { content: Item { property bool ticker_supported: false - readonly property bool is_fetching: chart.loadProgress < 100 + readonly property bool is_fetching: webEngineView.loadProgress < 100 readonly property string chartTheme: DexTheme.theme ?? "dark" property color backgroundColor: DexTheme.contentColorTop property var ticker: api_wallet_page.ticker @@ -466,37 +467,38 @@ Item { // Normal pair let symbol = General.supported_pairs[pair] if (!symbol) { - console.log("Symbol not found for", pair) + console.warn("Symbol not found for", pair) symbol = General.supported_pairs[pair_reversed] } // Reversed pair if (!symbol) { - console.log("Symbol not found for", pair_reversed) + console.warn("Symbol not found for", pair_reversed) symbol = General.supported_pairs[pair_usd] } // Pair with USD if (!symbol) { - console.log("Symbol not found for", pair_usd) + console.warn("Symbol not found for", pair_usd) symbol = General.supported_pairs[pair_usd_reversed] } // Reversed pair with USD if (!symbol) { - console.log("Symbol not found for", pair_usd_reversed) + console.warn("Symbol not found for", pair_usd_reversed) symbol = General.supported_pairs[pair_busd] } // Pair with BUSD if (!symbol) { - console.log("Symbol not found for", pair_busd) + console.warn("Symbol not found for", pair_busd) symbol = General.supported_pairs[pair_busd_reversed] } // Reversed pair with BUSD if (!symbol) { - console.log("Symbol not found for", pair_busd_reversed) + console.warn("Symbol not found for", pair_busd_reversed) + console.warn("No chart for", ticker) ticker_supported = false return } @@ -505,7 +507,7 @@ Item { console.debug("Wallet: Loading chart for %1".arg(symbol)) - chart.loadHtml(` + webEngineView.loadHtml(` @@ -529,7 +531,7 @@ Item { `.arg(DexTheme.theme === "dark" ? DexTheme.backgroundColor : DexTheme.contentColorTopBold).arg(DexTheme.chartTradingLineColor).arg(DexTheme.chartTradingLineBackgroundColor)) - } + } width: price_graph_bg.width height: price_graph_bg.height @@ -538,6 +540,13 @@ Item { onChartThemeChanged: loadChart() onBackgroundColorChanged: loadChart() + WebEngineView + { + id: webEngineView + anchors.fill: parent + visible: ticker_supported && !loading + } + Connections { target: DexTheme function onBackgroundColorChanged() { @@ -546,7 +555,7 @@ Item { } RowLayout { - visible: ticker_supported && !chart.visible + visible: !webEngineView.visible && ticker_supported anchors.centerIn: parent DefaultBusyIndicator { @@ -566,14 +575,6 @@ Item { text_value: qsTr("There is no chart data for this ticker yet") anchors.centerIn: parent } - - WebEngineView { - id: chart - anchors.fill: parent - anchors.margins: -1 - backgroundColor: DexTheme.contentColorTop - visible: !is_fetching && ticker_supported - } } } diff --git a/atomic_defi_design/qml/Wallet/Sidebar.qml b/atomic_defi_design/qml/Wallet/Sidebar.qml index 759d2f9be3..f7f2c0eb3b 100644 --- a/atomic_defi_design/qml/Wallet/Sidebar.qml +++ b/atomic_defi_design/qml/Wallet/Sidebar.qml @@ -179,7 +179,7 @@ Item { family: DexTypo.fontFamily, weight: Font.Normal }) - text: qsTr("Add crypto") + text: qsTr("Add asset") iconSource: Qaterial.Icons.plus leftPadding: 3 rightPadding: 3 diff --git a/atomic_defi_design/qml/Wallet/Wallet.qml b/atomic_defi_design/qml/Wallet/Wallet.qml index 363664c0e9..96141edbb8 100644 --- a/atomic_defi_design/qml/Wallet/Wallet.qml +++ b/atomic_defi_design/qml/Wallet/Wallet.qml @@ -22,7 +22,7 @@ RowLayout // Local function onClickedSwap() { - dashboard.current_page = idx_dashboard_exchange + dashboard.switchPage(idx_dashboard_exchange) dashboard.current_ticker = api_wallet_page.ticker API.app.trading_pg.set_pair(true, api_wallet_page.ticker) } diff --git a/ci_tools_atomic_dex/installer/osx/config/config.xml.in b/ci_tools_atomic_dex/installer/osx/config/config.xml.in index 1f06280e9b..d4da1dbd0a 100644 --- a/ci_tools_atomic_dex/installer/osx/config/config.xml.in +++ b/ci_tools_atomic_dex/installer/osx/config/config.xml.in @@ -1,7 +1,7 @@ ${DEX_DISPLAY_NAME} - 0.4.3 + 0.5.1 ${DEX_DISPLAY_NAME} Installer ${DEX_WEBSITE} ${DEX_COMPANY} diff --git a/ci_tools_atomic_dex/installer/osx/packages/com.komodoplatform.atomicdex/meta/package.xml.in b/ci_tools_atomic_dex/installer/osx/packages/com.komodoplatform.atomicdex/meta/package.xml.in index 5d995a7c33..697f2859b2 100644 --- a/ci_tools_atomic_dex/installer/osx/packages/com.komodoplatform.atomicdex/meta/package.xml.in +++ b/ci_tools_atomic_dex/installer/osx/packages/com.komodoplatform.atomicdex/meta/package.xml.in @@ -2,8 +2,8 @@ ${DEX_DISPLAY_NAME} Install ${DEX_DISPLAY_NAME}. - 0.4.3 - 2021-05-10 + 0.5.1 + 2021-09-06 diff --git a/ci_tools_atomic_dex/installer/windows/config/config.xml.in b/ci_tools_atomic_dex/installer/windows/config/config.xml.in index 29f1fbc777..71063b5a74 100644 --- a/ci_tools_atomic_dex/installer/windows/config/config.xml.in +++ b/ci_tools_atomic_dex/installer/windows/config/config.xml.in @@ -1,7 +1,7 @@ @DEX_DISPLAY_NAME@ - 0.4.3 + 0.5.1 @DEX_DISPLAY_NAME@ Installer @DEX_WEBSITE@ @DEX_COMPANY@ diff --git a/ci_tools_atomic_dex/installer/windows/packages/com.komodoplatform.atomicdex/meta/package.xml.in b/ci_tools_atomic_dex/installer/windows/packages/com.komodoplatform.atomicdex/meta/package.xml.in index 5d995a7c33..697f2859b2 100644 --- a/ci_tools_atomic_dex/installer/windows/packages/com.komodoplatform.atomicdex/meta/package.xml.in +++ b/ci_tools_atomic_dex/installer/windows/packages/com.komodoplatform.atomicdex/meta/package.xml.in @@ -2,8 +2,8 @@ ${DEX_DISPLAY_NAME} Install ${DEX_DISPLAY_NAME}. - 0.4.3 - 2021-05-10 + 0.5.1 + 2021-09-06 diff --git a/cmake/install/macos/dex_install.cmake b/cmake/install/macos/dex_install.cmake index 3dfda7315a..dd551ae91d 100644 --- a/cmake/install/macos/dex_install.cmake +++ b/cmake/install/macos/dex_install.cmake @@ -4,8 +4,8 @@ if (APPLE) MACOSX_BUNDLE_BUNDLE_NAME "${PROJECT_NAME}" RESOURCE ${ICON} MACOSX_BUNDLE_ICON_FILE dex-logo - MACOSX_BUNDLE_SHORT_VERSION_STRING 0.5.0 - MACOSX_BUNDLE_LONG_VERSION_STRING 0.5.0 + MACOSX_BUNDLE_SHORT_VERSION_STRING 0.5.1 + MACOSX_BUNDLE_LONG_VERSION_STRING 0.5.1 MACOSX_BUNDLE_INFO_PLIST "${PROJECT_SOURCE_DIR}/cmake/MacOSXBundleInfo.plist.in") add_custom_command(TARGET ${PROJECT_NAME} POST_BUILD COMMAND diff --git a/qml.qrc b/qml.qrc index 5badce21c5..44fe3a527e 100644 --- a/qml.qrc +++ b/qml.qrc @@ -31,6 +31,7 @@ atomic_defi_design/assets/images/coins/avax.png atomic_defi_design/assets/images/coins/awc.png atomic_defi_design/assets/images/coins/axe.png + atomic_defi_design/assets/images/coins/axs.png atomic_defi_design/assets/images/coins/babydoge.png atomic_defi_design/assets/images/coins/bal.png atomic_defi_design/assets/images/coins/band.png @@ -102,6 +103,7 @@ atomic_defi_design/assets/images/coins/gleec.png atomic_defi_design/assets/images/coins/gno.png atomic_defi_design/assets/images/coins/grs.png + atomic_defi_design/assets/images/coins/grms.png atomic_defi_design/assets/images/coins/hex.png atomic_defi_design/assets/images/coins/hlc.png atomic_defi_design/assets/images/coins/hodl.png @@ -130,6 +132,7 @@ atomic_defi_design/assets/images/coins/lstr.png atomic_defi_design/assets/images/coins/ltc.png atomic_defi_design/assets/images/coins/lynx.png + atomic_defi_design/assets/images/coins/ltfn.png atomic_defi_design/assets/images/coins/mana.png atomic_defi_design/assets/images/coins/matic.png atomic_defi_design/assets/images/coins/mcl.png @@ -215,6 +218,7 @@ atomic_defi_design/assets/images/coins/uno.png atomic_defi_design/assets/images/coins/uos.png atomic_defi_design/assets/images/coins/uqc.png + atomic_defi_design/assets/images/coins/usbl.png atomic_defi_design/assets/images/coins/usdc.png atomic_defi_design/assets/images/coins/usdt.png atomic_defi_design/assets/images/coins/utk.png @@ -228,6 +232,7 @@ atomic_defi_design/assets/images/coins/wcn.png atomic_defi_design/assets/images/coins/wlc.png atomic_defi_design/assets/images/coins/wsb.png + atomic_defi_design/assets/images/coins/wwcn.png atomic_defi_design/assets/images/coins/xlm.png atomic_defi_design/assets/images/coins/xmy.png atomic_defi_design/assets/images/coins/xor.png @@ -244,6 +249,9 @@ atomic_defi_design/assets/images/coins/zil.png atomic_defi_design/assets/images/coins/zilla.png atomic_defi_design/assets/images/coins/zrx.png + atomic_defi_design/assets/images/providers/binance.png + atomic_defi_design/assets/images/providers/coingecko.png + atomic_defi_design/assets/images/providers/coinpaprika.png atomic_defi_design/assets/images/dashboard-copy.svg atomic_defi_design/assets/images/dashboard-eye-hide.svg atomic_defi_design/assets/images/dashboard-eye.svg @@ -287,6 +295,7 @@ atomic_defi_design/assets/languages/atomic_defi_ru.qm atomic_defi_design/assets/languages/atomic_defi_tr.qm atomic_defi_design/qml/App.qml + atomic_defi_design/qml/String.js atomic_defi_design/qml/Components/AddressField.qml atomic_defi_design/qml/Components/AddressFieldWithTitle.qml atomic_defi_design/qml/Components/AmountField.qml @@ -545,6 +554,7 @@ atomic_defi_design/qml/Portfolio/PieItem.qml atomic_defi_design/qml/Portfolio/SmartChartView.qml atomic_defi_design/qml/Portfolio/TableDex.qml + atomic_defi_design/qml/Portfolio/AssetsList.qml atomic_defi_design/qml/main.qml qtquickcontrols2.conf diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index b1f257f307..50a48397ab 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -10,6 +10,7 @@ DEX_NEW_LIB(core INTERFACE INTERFACE_DEFS $<$,$>:QT_QML_DEBUG> $<$:HAS_REMOTE_API> $<$:AUTO_DOWNLOAD> + $<$:NOMINMAX> $<$:SPDLOG_WCHAR_TO_UTF8_SUPPORT> _TURN_OFF_PLATFORM_STRING DEX_NAME="${DEX_DISPLAY_NAME}" DEX_WEBSITE_URL="${DEX_WEBSITE}" @@ -83,7 +84,7 @@ set_target_properties(${PROJECT_NAME} PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin/") -set_target_properties(${PROJECT_NAME} PROPERTIES UNITY_BUILD ON) +#set_target_properties(${PROJECT_NAME} PROPERTIES UNITY_BUILD ON) if (APPLE) set_property(SOURCE core/atomicdex/platform/osx/manager.mm PROPERTY SKIP_UNITY_BUILD_INCLUSION ON) endif () @@ -98,6 +99,7 @@ add_executable(${PROJECT_NAME}_tests MACOSX_BUNDLE ${ICON} tests/config/coins.cfg.tests.cpp ##! API tests/api/coingecko/coingecko.tests.cpp + tests/api/komodo_prices/komodo.prices.tests.cpp tests/api/mm2/mm2.rpc.trade.preimage.tests.cpp tests/api/mm2/mm2.fraction.tests.cpp #tests/api/github/github.api.tests.cpp diff --git a/src/app/app.cpp b/src/app/app.cpp index aa72133f7d..2600f25a1e 100644 --- a/src/app/app.cpp +++ b/src/app/app.cpp @@ -39,7 +39,8 @@ #include "app.hpp" #include "atomicdex/services/exporter/exporter.service.hpp" #include "atomicdex/services/mm2/auto.update.maker.order.service.hpp" -#include "atomicdex/services/price/coingecko/coingecko.provider.hpp" +//#include "atomicdex/services/price/coingecko/coingecko.provider.hpp" +#include "atomicdex/services/price/komodo_prices/komodo.prices.provider.hpp" #include "atomicdex/services/price/coingecko/coingecko.wallet.charts.hpp" #include "atomicdex/services/price/coinpaprika/coinpaprika.provider.hpp" #include "atomicdex/services/price/oracle/band.provider.hpp" @@ -82,7 +83,7 @@ namespace atomic_dex if (coin_info.has_parent_fees_ticker && coin_info.ticker != coin_info.fees_ticker) { auto coin_parent_info = mm2.get_coin_info(coin_info.fees_ticker); - if (extra_coins.insert(coin_parent_info.ticker).second) + if (!coin_parent_info.currently_enabled && !coin_parent_info.active && extra_coins.insert(coin_parent_info.ticker).second) { SPDLOG_INFO("Adding extra coin: {} to enable", coin_parent_info.ticker); } @@ -189,7 +190,7 @@ namespace atomic_dex system_manager_.create_system(system_manager_); // system_manager_.create_system(system_manager_); - system_manager_.create_system(system_manager_); + // system_manager_.create_system(system_manager_); connect_signals(); m_event_actions[events_action::need_a_full_refresh_of_mm2] = false; } @@ -340,8 +341,12 @@ namespace atomic_dex system_manager_.create_system(system_manager_); system_manager_.create_system(); // system_manager_.create_system(system_manager_); - system_manager_.create_system(system_manager_); - system_manager_.create_system(); + //system_manager_.create_system(system_manager_); + system_manager_.create_system(); + auto& self_update_system = system_manager_.create_system(); +#if !defined(Q_OS_WINDOWS) + self_update_system.disable(); +#endif system_manager_.create_system(system_manager_); system_manager_.create_system(system_manager_); system_manager_.create_system( @@ -438,13 +443,14 @@ namespace atomic_dex orders->reset(); system_manager_.get_system().get_portfolio()->reset(); + system_manager_.get_system().set_current_balance_fiat_all("0"); system_manager_.get_system().clear_models(); get_wallet_page()->get_transactions_mdl()->reset(); + //! Mark systems system_manager_.mark_system(); - // system_manager_.mark_system(); - system_manager_.mark_system(); + //system_manager_.mark_system(); //! Disconnect signals get_trading_page()->disconnect_signals(); @@ -455,7 +461,6 @@ namespace atomic_dex dispatcher_.sink().disconnect<&application::on_coin_fully_initialized_event>(*this); dispatcher_.sink().disconnect<&application::on_mm2_initialized_event>(*this); dispatcher_.sink().disconnect<&application::on_process_orders_and_swaps_finished_event>(*this); - // dispatcher_.sink().disconnect<&application::on_process_swaps_finished_event>(*this); m_event_actions[events_action::need_a_full_refresh_of_mm2] = true; @@ -547,16 +552,23 @@ namespace atomic_dex void application::on_ticker_balance_updated_event(const ticker_balance_updated& evt) { - SPDLOG_DEBUG("on_ticker_balance_updated_event"); - if (not m_event_actions[events_action::about_to_exit_app]) + SPDLOG_DEBUG("Ticker balance is about to be updated."); + if (m_event_actions[events_action::about_to_exit_app]) { - if (not evt.tickers.empty()) - { - if (get_portfolio_page()->get_portfolio()->update_balance_values(evt.tickers)) - { - this->dispatcher_.trigger(false); - } - } + SPDLOG_DEBUG("Ticker balance not updated because app is exiting."); + } + else if (evt.tickers.empty()) + { + SPDLOG_DEBUG("Ticker balance not updated because there are not tickers to update"); + } + else if (get_portfolio_page()->get_portfolio()->update_balance_values(evt.tickers)) + { + this->dispatcher_.trigger(false); + SPDLOG_DEBUG("Ticker balance updated."); + } + else + { + SPDLOG_ERROR("Ticker balance not updated, tickers not found in the registry: {}", fmt::join(evt.tickers, ", ")); } } } // namespace atomic_dex @@ -652,7 +664,7 @@ namespace atomic_dex trading_page* application::get_trading_page() const { - trading_page* ptr = const_cast(std::addressof(system_manager_.get_system())); + auto ptr = const_cast(std::addressof(system_manager_.get_system())); assert(ptr != nullptr); return ptr; } @@ -779,8 +791,6 @@ namespace atomic_dex if (appimage == nullptr || not QString(appimage).contains(DEX_PROJECT_NAME)) { - // qDebug() << qApp->arguments(); - // SPDLOG_INFO("arg: {}, dir path: {}", qApp->arguments()[0].toStdString(), qApp->applicationDirPath().toStdString()); bool res = QProcess::startDetached(qApp->arguments()[0], qApp->arguments(), qApp->applicationDirPath()); if (!res) { diff --git a/src/core/atomicdex/api/coingecko/coingecko.cpp b/src/core/atomicdex/api/coingecko/coingecko.cpp index fff54a825f..673a9253cb 100644 --- a/src/core/atomicdex/api/coingecko/coingecko.cpp +++ b/src/core/atomicdex/api/coingecko/coingecko.cpp @@ -15,15 +15,16 @@ namespace { //! Constants - constexpr const char* g_coingecko_endpoint = "https://api.coingecko.com/api/v3"; - constexpr const char* g_coingecko_base_uri{"/coins/markets"}; - web::http::client::http_client_config g_cfg{[]() { - web::http::client::http_client_config cfg; - cfg.set_validate_certificates(false); - cfg.set_timeout(std::chrono::seconds(30)); - return cfg; - }()}; - t_http_client_ptr g_coingecko_client = std::make_unique(FROM_STD_STR(g_coingecko_endpoint), g_cfg); + constexpr const char* g_coingecko_endpoint = "https://api.coingecko.com/api/v3"; + constexpr const char* g_coingecko_base_uri{"/coins/markets"}; + web::http::client::http_client_config g_cfg{[]() + { + web::http::client::http_client_config cfg; + cfg.set_validate_certificates(false); + cfg.set_timeout(std::chrono::seconds(30)); + return cfg; + }()}; + t_http_client_ptr g_coingecko_client = std::make_unique(FROM_STD_STR(g_coingecko_endpoint), g_cfg); } // namespace @@ -58,7 +59,8 @@ namespace atomic_dex::coingecko::api uri.append("&ids="); using ranges::views::ints; using ranges::views::zip; - auto fill_list_functor = [](auto&& container, auto& uri) { + auto fill_list_functor = [](auto&& container, auto& uri) + { for (auto&& [cur_quote, idx]: zip(container, ints(0u, ranges::unreachable))) { uri.append(cur_quote); @@ -71,7 +73,8 @@ namespace atomic_dex::coingecko::api } }; - auto fill_single_field_functor = [&uri](const std::string& field_name, auto&& value) { + auto fill_single_field_functor = [&uri](const std::string& field_name, auto&& value) + { uri.append(field_name); if constexpr (std::is_same_v>>) { @@ -124,13 +127,34 @@ namespace atomic_dex::coingecko::api void from_json(const nlohmann::json& j, single_infos_answer& answer) { - answer.current_price = std::to_string(j.at("current_price").get()); + if (!j.at("current_price").is_null()) + { + answer.current_price = std::to_string(j.at("current_price").get()); + } + else + { + answer.current_price = "0"; + } boost::algorithm::replace_all(answer.current_price, ",", "."); - answer.total_volume = std::to_string(j.at("total_volume").get()); + if (!j.at("total_volume").is_null()) + { + answer.total_volume = std::to_string(j.at("total_volume").get()); + } + else + { + answer.total_volume = "0"; + } boost::algorithm::replace_all(answer.total_volume, ",", "."); - std::ostringstream ss; - ss << std::setprecision(2) << j.at("price_change_percentage_24h").get(); - answer.price_change_24h = ss.str(); + if (!j.at("price_change_percentage_24h").is_null()) + { + std::ostringstream ss; + ss << std::setprecision(2) << j.at("price_change_percentage_24h").get(); + answer.price_change_24h = ss.str(); + } + else + { + answer.price_change_24h = "0"; + } boost::algorithm::replace_all(answer.price_change_24h, ",", "."); j.at("sparkline_in_7d").at("price").get_to(answer.sparkline_in_7d); } @@ -147,7 +171,7 @@ namespace atomic_dex::coingecko::api } catch (const std::exception& error) { - // SPDLOG_ERROR("Error when treating coingecko answer: {} - error: {}", cur_json_obj.dump(1), error.what()); + SPDLOG_ERROR("Error when treating coingecko answer: {} - error: {}", cur_json_obj.dump(1), error.what()); } } } diff --git a/src/core/atomicdex/api/komodo_prices/komodo.prices.cpp b/src/core/atomicdex/api/komodo_prices/komodo.prices.cpp new file mode 100644 index 0000000000..ddb8afeb46 --- /dev/null +++ b/src/core/atomicdex/api/komodo_prices/komodo.prices.cpp @@ -0,0 +1,75 @@ +// +// Created by Sztergbaum Roman on 09/09/2021. +// + +//! Deps +#include + +//! Project Headers +#include "atomicdex/api/komodo_prices/komodo.prices.hpp" + +namespace +{ + constexpr const char* g_komodo_prices_endpoint = "https://prices.komodo.live:1313"; + web::http::client::http_client_config g_komodo_prices_cfg{[]() + { + web::http::client::http_client_config cfg; + cfg.set_validate_certificates(false); + cfg.set_timeout(std::chrono::seconds(30)); + return cfg; + }()}; + t_http_client_ptr g_komodo_prices_client = std::make_unique(FROM_STD_STR(g_komodo_prices_endpoint), g_komodo_prices_cfg); +} // namespace + +namespace atomic_dex::komodo_prices::api +{ + void + from_json(const nlohmann::json& j, komodo_ticker_infos& x) + { + x.ticker = j.at("ticker").get(); + x.last_price = j.at("last_price").get(); + x.last_updated = j.at("last_updated").get(); + x.last_updated_timestamp = j.at("last_updated_timestamp").get(); + x.volume24_h = j.at("volume24h").get(); + x.price_provider = j.at("price_provider").get(); + x.volume_provider = j.at("volume_provider").get(); + x.sparkline_7_d = j.at("sparkline_7d"); + x.sparkline_provider = j.at("sparkline_provider").get(); + x.change_24_h = j.at("change_24h").get(); + x.change_24_h_provider = j.at("change_24h_provider").get(); + } + + void + from_json(const nlohmann::json& j, provider& x) + { + if (j == "binance") + { + x = provider::binance; + } + else if (j == "coingecko") + { + x = provider::coingecko; + } + else if (j == "coinpaprika") + { + x = provider::coinpaprika; + } + else + { + x = provider::unknown; + } + } +} // namespace atomic_dex::komodo_prices::api + +namespace atomic_dex::komodo_prices::api +{ + pplx::task + async_market_infos() + { + web::http::http_request req; + req.set_method(web::http::methods::GET); + SPDLOG_INFO("url: {}", TO_STD_STR(g_komodo_prices_client->base_uri().to_string()) + "api/v1/tickers?expire_at=600"); + req.set_request_uri(FROM_STD_STR("/api/v1/tickers?expire_at=600")); + return g_komodo_prices_client->request(req); + } +} // namespace atomic_dex::komodo_prices::api diff --git a/src/core/atomicdex/api/komodo_prices/komodo.prices.hpp b/src/core/atomicdex/api/komodo_prices/komodo.prices.hpp new file mode 100644 index 0000000000..96458d45ae --- /dev/null +++ b/src/core/atomicdex/api/komodo_prices/komodo.prices.hpp @@ -0,0 +1,42 @@ +#pragma once + +#include +#include + +#include "atomicdex/utilities/cpprestsdk.utilities.hpp" + +namespace atomic_dex::komodo_prices::api +{ + enum class provider : int + { + binance, + coingecko, + coinpaprika, + unknown + }; + + struct komodo_ticker_infos + { + std::string ticker; + std::string last_price{"0.00"}; + std::string last_updated; + int64_t last_updated_timestamp; + std::string volume24_h{"0.00"}; + provider price_provider{provider::unknown}; + provider volume_provider{provider::unknown}; + std::string change_24_h{"0.00"}; + provider change_24_h_provider{provider::unknown}; + nlohmann::json sparkline_7_d; + provider sparkline_provider; + }; + + void from_json(const nlohmann::json& j, komodo_ticker_infos& x); + void from_json(const nlohmann::json& j, provider& x); + + using t_komodo_tickers_price_registry = std::unordered_map; +} // namespace atomic_dex::komodo_prices::api + +namespace atomic_dex::komodo_prices::api +{ + ENTT_API pplx::task async_market_infos(); +} \ No newline at end of file diff --git a/src/core/atomicdex/api/mm2/rpc.electrum.hpp b/src/core/atomicdex/api/mm2/rpc.electrum.hpp index 80f0cfdec9..4c206a9d91 100644 --- a/src/core/atomicdex/api/mm2/rpc.electrum.hpp +++ b/src/core/atomicdex/api/mm2/rpc.electrum.hpp @@ -17,7 +17,7 @@ #pragma once //! Deps -#include +#include //! Project Headers #include "atomicdex/config/electrum.cfg.hpp" diff --git a/src/core/atomicdex/api/mm2/rpc.sell.hpp b/src/core/atomicdex/api/mm2/rpc.sell.hpp index 02be4e5071..3847d8052f 100644 --- a/src/core/atomicdex/api/mm2/rpc.sell.hpp +++ b/src/core/atomicdex/api/mm2/rpc.sell.hpp @@ -21,7 +21,7 @@ #include //! Deps -#include +#include //! Project Headers #include "atomicdex/api/mm2/trading.order.contents.hpp" diff --git a/src/core/atomicdex/api/mm2/rpc.tx.history.cpp b/src/core/atomicdex/api/mm2/rpc.tx.history.cpp index 79aff426a9..42c6e4b378 100644 --- a/src/core/atomicdex/api/mm2/rpc.tx.history.cpp +++ b/src/core/atomicdex/api/mm2/rpc.tx.history.cpp @@ -1,3 +1,7 @@ +//! Deps +#include + +//! Project Headers #include "rpc.tx.history.hpp" namespace mm2::api diff --git a/src/core/atomicdex/data/wallet/qt.portfolio.data.hpp b/src/core/atomicdex/data/wallet/qt.portfolio.data.hpp index ce89df8ab2..766683ce0f 100644 --- a/src/core/atomicdex/data/wallet/qt.portfolio.data.hpp +++ b/src/core/atomicdex/data/wallet/qt.portfolio.data.hpp @@ -57,9 +57,15 @@ namespace atomic_dex //! eg: Real fiat values eg: 9400$ QString main_fiat_price_for_one_unit; - //! Paprika data rates + //! eg: Komodo data rates QJsonArray trend_7d; + //! Price provider + QString price_provider; + + //! Last price timestamp; + int price_last_timestamp; + bool is_excluded{false}; QString display; diff --git a/src/core/atomicdex/managers/qt.wallet.manager.cpp b/src/core/atomicdex/managers/qt.wallet.manager.cpp index 6c29772b69..9352542fea 100644 --- a/src/core/atomicdex/managers/qt.wallet.manager.cpp +++ b/src/core/atomicdex/managers/qt.wallet.manager.cpp @@ -338,6 +338,7 @@ namespace atomic_dex { this->m_current_status = std::move(status); emit onStatusChanged(); + SPDLOG_INFO("Set status: {}", m_current_status.toStdString()); } bool diff --git a/src/core/atomicdex/models/qt.orderbook.model.cpp b/src/core/atomicdex/models/qt.orderbook.model.cpp index dde3f93e07..1af5c89fb3 100644 --- a/src/core/atomicdex/models/qt.orderbook.model.cpp +++ b/src/core/atomicdex/models/qt.orderbook.model.cpp @@ -238,7 +238,8 @@ namespace atomic_dex case HaveCEXIDRole: { const auto* global_cfg = m_system_mgr.get_system().get_global_cfg(); - return global_cfg->get_coin_info(data(index, CoinRole).toString().toStdString()).coingecko_id != "test-coin"; + auto infos = global_cfg->get_coin_info(data(index, CoinRole).toString().toStdString()); + return infos.coingecko_id != "test-coin" || infos.coinpaprika_id != "test-coin"; } } } @@ -427,7 +428,7 @@ namespace atomic_dex auto& trading_pg = m_system_mgr.get_system(); if (trading_pg.get_market_mode() == MarketMode::Sell) { - const auto preferred_order = trading_pg.get_preffered_order(); + const auto preferred_order = trading_pg.get_preferred_order(); if (!preferred_order.empty()) { const t_float_50 price_std = safe_float(order.price); @@ -510,7 +511,7 @@ namespace atomic_dex auto& trading_pg = m_system_mgr.get_system(); if (trading_pg.get_market_mode() == MarketMode::Sell) { - const auto preferred_order = trading_pg.get_preffered_order(); + const auto preferred_order = trading_pg.get_preferred_order(); if (!preferred_order.empty()) { const t_float_50 price_std = safe_float(new_price.toString().toStdString()); @@ -597,7 +598,7 @@ namespace atomic_dex if (m_system_mgr.has_system() && m_current_orderbook_kind == kind::bids) { auto& trading_pg = m_system_mgr.get_system(); - const auto preffered_order = trading_pg.get_preffered_order(); + const auto preffered_order = trading_pg.get_preferred_order(); if (!preffered_order.empty()) { const auto selected_order_uuid = preffered_order.value("uuid", "").toString().toStdString(); diff --git a/src/core/atomicdex/models/qt.orderbook.proxy.model.cpp b/src/core/atomicdex/models/qt.orderbook.proxy.model.cpp index 4e4883e911..aae397e27d 100644 --- a/src/core/atomicdex/models/qt.orderbook.proxy.model.cpp +++ b/src/core/atomicdex/models/qt.orderbook.proxy.model.cpp @@ -20,9 +20,10 @@ //! Project #include "atomicdex/models/qt.orderbook.model.hpp" #include "atomicdex/models/qt.orderbook.proxy.model.hpp" -#include "atomicdex/utilities/global.utilities.hpp" -#include "atomicdex/services/price/coingecko/coingecko.provider.hpp" +#include "atomicdex/pages/qt.portfolio.page.hpp" #include "atomicdex/pages/qt.trading.page.hpp" +#include "atomicdex/services/price/komodo_prices/komodo.prices.provider.hpp" +#include "atomicdex/utilities/global.utilities.hpp" namespace atomic_dex { @@ -97,10 +98,33 @@ namespace atomic_dex break; case orderbook_model::CEXRatesRole: { - t_float_50 left = safe_float(left_data.toString().toStdString()); - t_float_50 right = safe_float(right_data.toString().toStdString()); + t_float_50 left = safe_float(left_data.toString().toStdString()); + t_float_50 right = safe_float(right_data.toString().toStdString()); const bool is_buy = this->m_system_mgr.get_system().get_market_mode() == MarketMode::Buy; - return !is_buy ? left > right : left < right; + if (!is_buy) + { + if (left.is_zero()) //< NA + { + return true; + } + if (right.is_zero()) + { + return false; + } + return left > right; + } + else + { + if (left.is_zero()) + { + return false; + } + if (right.is_zero()) + { + return true; + } + return left < right; + } } case orderbook_model::SendRole: break; @@ -137,13 +161,19 @@ namespace atomic_dex case orderbook_model::kind::bids: break; case orderbook_model::kind::best_orders: - t_float_50 rates = safe_float(this->sourceModel()->data(idx, orderbook_model::CEXRatesRole).toString().toStdString()); - t_float_50 fiat_price = safe_float(this->sourceModel()->data(idx, orderbook_model::PriceFiatRole).toString().toStdString()); - std::string ticker = this->sourceModel()->data(idx, orderbook_model::CoinRole).toString().toStdString(); - const auto& gecko_provider = this->m_system_mgr.get_system(); + t_float_50 rates = safe_float(this->sourceModel()->data(idx, orderbook_model::CEXRatesRole).toString().toStdString()); + t_float_50 fiat_price = safe_float(this->sourceModel()->data(idx, orderbook_model::PriceFiatRole).toString().toStdString()); + std::string ticker = this->sourceModel()->data(idx, orderbook_model::CoinRole).toString().toStdString(); + const auto& provider = this->m_system_mgr.get_system(); + const auto coin_info = this->m_system_mgr.get_system().get_global_cfg()->get_coin_info(ticker); t_float_50 limit("10000"); + bool is_cex_id_available = this->sourceModel()->data(idx, orderbook_model::HaveCEXIDRole).toBool(); - if (rates > 100 || fiat_price <= 0 || safe_float(gecko_provider.get_total_volume(ticker)) < limit) + if (coin_info.ticker.empty() || coin_info.wallet_only) //< this means it's not present in our cfg - skipping + { + return false; + } + if (is_cex_id_available && (rates > 100 || fiat_price <= 0 || safe_float(provider.get_total_volume(ticker)) < limit)) { return false; } @@ -151,14 +181,14 @@ namespace atomic_dex } } - if (orderbook != nullptr && orderbook->get_orderbook_kind() == orderbook_model::kind::best_orders) + /*if (orderbook != nullptr && orderbook->get_orderbook_kind() == orderbook_model::kind::best_orders) { bool is_cex_id_available = this->sourceModel()->data(idx, orderbook_model::HaveCEXIDRole).toBool(); if (!is_cex_id_available) { return false; } - } + }*/ return QSortFilterProxyModel::filterAcceptsRow(source_row, source_parent); } } // namespace atomic_dex diff --git a/src/core/atomicdex/models/qt.orders.model.cpp b/src/core/atomicdex/models/qt.orders.model.cpp index a3069d9a47..2c73a8b3b0 100644 --- a/src/core/atomicdex/models/qt.orders.model.cpp +++ b/src/core/atomicdex/models/qt.orders.model.cpp @@ -16,14 +16,15 @@ //! Deps #include +#include //! Project +#include "atomicdex/api/mm2/rpc.recover.funds.hpp" #include "atomicdex/events/qt.events.hpp" #include "atomicdex/models/qt.orders.model.hpp" #include "atomicdex/pages/qt.settings.page.hpp" #include "atomicdex/services/mm2/mm2.service.hpp" #include "atomicdex/utilities/qt.utilities.hpp" -#include "atomicdex/api/mm2/rpc.recover.funds.hpp" //! Constructor namespace atomic_dex @@ -46,7 +47,7 @@ namespace atomic_dex int orders_model::rowCount([[maybe_unused]] const QModelIndex& parent) const { - return this->m_model_data.orders_and_swaps.size(); + return static_cast(this->m_model_data.orders_and_swaps.size()); } bool @@ -129,6 +130,8 @@ namespace atomic_dex case ErrorEventsRole: item.error_events = value.toStringList(); break; + default: + break; } emit dataChanged(index, index, {role}); @@ -192,6 +195,8 @@ namespace atomic_dex return item.success_events; case ErrorEventsRole: return item.error_events; + default: + break; } return {}; } @@ -285,8 +290,7 @@ namespace atomic_dex this->set_fetching_busy(true); this->reset_backend("set_current_page"); ///< We change page, we need to clear, but do not notify the front-end auto& mm2 = this->m_system_manager.get_system(); - mm2.set_orders_and_swaps_pagination_infos( - static_cast(current_page), static_cast(m_model_data.limit), m_model_data.filtering_infos); + mm2.set_orders_and_swaps_pagination_infos(static_cast(current_page), m_model_data.limit, m_model_data.filtering_infos); } } @@ -307,8 +311,7 @@ namespace atomic_dex this->set_fetching_busy(true); this->reset_backend("set_limit_nb_elements"); ///< We change page, we need to clear, but do not notify the front-end auto& mm2 = this->m_system_manager.get_system(); - mm2.set_orders_and_swaps_pagination_infos( - static_cast(m_model_data.current_page), static_cast(limit), m_model_data.filtering_infos); + mm2.set_orders_and_swaps_pagination_infos(m_model_data.current_page, static_cast(limit), m_model_data.filtering_infos); } else { @@ -326,7 +329,7 @@ namespace atomic_dex void orders_model::set_recover_fund_data(QVariant rpc_data) { - auto json_result = rpc_data.toJsonObject(); + auto json_result = rpc_data.toJsonObject(); m_recover_funds_data = json_result; emit recoverFundDataChanged(); } @@ -366,7 +369,7 @@ namespace atomic_dex int orders_model::get_nb_pages() const { - return m_model_data.nb_pages; + return static_cast(m_model_data.nb_pages); } } // namespace atomic_dex @@ -388,7 +391,7 @@ namespace atomic_dex void orders_model::update_existing_order(const t_order_swaps_data& contents) { - if (const auto res = this->match(index(0, 0), OrderIdRole, contents.order_id); not res.isEmpty()) + if (const auto res = this->match(index(0, 0), OrderIdRole, contents.order_id); !res.isEmpty()) { const QModelIndex& idx = res.at(0); update_value(OrdersRoles::CancellableRole, contents.is_cancellable, idx, *this); @@ -408,7 +411,7 @@ namespace atomic_dex void orders_model::update_swap(const t_order_swaps_data& contents) { - if (const auto res = this->match(index(0, 0), OrderIdRole, contents.order_id); not res.isEmpty()) + if (const auto res = this->match(index(0, 0), OrderIdRole, contents.order_id); !res.isEmpty()) { const QModelIndex& idx = res.at(0); update_value(OrdersRoles::IsRecoverableRole, contents.is_recoverable, idx, *this); @@ -449,7 +452,7 @@ namespace atomic_dex return; SPDLOG_INFO("Full initialization, inserting {} elements, nb_elements / page {}", size, contents.limit); beginResetModel(); - m_model_data = std::move(contents); + m_model_data = contents; endResetModel(); m_orders_id_registry = std::move(m_model_data.orders_registry); m_swaps_id_registry = std::move(m_model_data.swaps_registry); @@ -465,7 +468,7 @@ namespace atomic_dex { SPDLOG_INFO("common_insert, nb elements to insert: {}", contents.size()); auto& data = m_model_data.orders_and_swaps; - beginInsertRows(QModelIndex(), rowCount(), rowCount() + contents.size() - 1); + beginInsertRows(QModelIndex(), rowCount(), rowCount() + static_cast(contents.size()) - 1); data.insert(end(data), begin(contents), end(contents)); if (kind == "orders") { @@ -488,7 +491,7 @@ namespace atomic_dex std::vector to_init; std::for_each( begin(data) + contents.nb_orders, end(data), - [this, &to_init](auto&& cur) + [this, &to_init](const auto& cur) { if (cur.is_swap) { @@ -504,7 +507,7 @@ namespace atomic_dex } } }); - if (not to_init.empty()) + if (!to_init.empty()) { this->common_insert(to_init, "swaps"); } @@ -520,7 +523,7 @@ namespace atomic_dex std::vector to_init; std::for_each( begin(data), begin(data) + contents.nb_orders, - [this, &to_init, &are_present](auto&& cur) + [this, &to_init, &are_present](const auto& cur) { if (this->m_orders_id_registry.contains(cur.order_id.toStdString())) { @@ -533,7 +536,7 @@ namespace atomic_dex are_present.emplace(cur.order_id.toStdString()); }); - if (not to_init.empty()) + if (!to_init.empty()) { this->common_insert(to_init, "orders"); } @@ -552,7 +555,7 @@ namespace atomic_dex { //! If it's the case retrieve the index of the row that match this id auto res_list = this->match(index(0, 0), OrderIdRole, QString::fromStdString(id)); - if (not res_list.empty()) + if (!res_list.empty()) { //! And then delete it this->removeRow(res_list.at(0).row()); @@ -579,13 +582,13 @@ namespace atomic_dex if (m_model_data.limit != contents.limit) { SPDLOG_INFO("nb elements / page changed"); - this->set_limit_nb_elements(contents.limit); + this->set_limit_nb_elements(static_cast(contents.limit)); } if (m_model_data.current_page != contents.current_page) { SPDLOG_INFO("Page is different from mm2 contents, force change"); - this->set_current_page(contents.current_page); + this->set_current_page(static_cast(contents.current_page)); } } } // namespace atomic_dex @@ -617,15 +620,13 @@ namespace atomic_dex bool atomic_dex::orders_model::swap_is_in_progress(const QString& coin) const { - for (auto&& cur_hist_swap: m_model_data.orders_and_swaps) + auto functor = [coin](const auto& cur_hist_swap) { - if ((cur_hist_swap.base_coin == coin || cur_hist_swap.rel_coin == coin) && - (cur_hist_swap.order_status == "matched" || cur_hist_swap.order_status == "ongoing" || cur_hist_swap.order_status == "matching")) - { - return true; - } - } - return false; + return (cur_hist_swap.base_coin == coin || cur_hist_swap.rel_coin == coin) && + (cur_hist_swap.order_status == "matched" || cur_hist_swap.order_status == "ongoing" || cur_hist_swap.order_status == "matching"); + }; + + return ranges::any_of(m_model_data.orders_and_swaps, functor); } void @@ -646,7 +647,7 @@ namespace atomic_dex const auto contents = mm2.get_orders_and_swaps(); //! If model is empty let's init it once - if (m_model_data.orders_and_swaps.size() == 0) + if (m_model_data.orders_and_swaps.empty()) { init_model(contents); } @@ -675,9 +676,15 @@ namespace atomic_dex this->set_fetching_busy(true); this->reset(); // this->reset_backend("set_filtering_infos"); ///< We change page, we need to clear, but do not notify the front-end - auto& mm2 = this->m_system_manager.get_system(); - mm2.set_orders_and_swaps_pagination_infos( - static_cast(m_model_data.current_page), static_cast(m_model_data.limit), m_model_data.filtering_infos); + if (this->m_system_manager.has_system()) + { + auto& mm2 = this->m_system_manager.get_system(); + mm2.set_orders_and_swaps_pagination_infos(m_model_data.current_page, m_model_data.limit, m_model_data.filtering_infos); + } + else + { + SPDLOG_WARN("MM2 is not available, skipping orders and swaps pagination reset"); + } } else { @@ -705,40 +712,40 @@ namespace atomic_dex auto answer_functor = [this](web::http::http_response resp) { nlohmann::json j_out = nlohmann::json::object(); - std::string body = TO_STD_STR(resp.extract_string(true).get()); + std::string body = TO_STD_STR(resp.extract_string(true).get()); if (resp.status_code() == web::http::status_codes::OK) { auto answers = nlohmann::json::parse(body); auto recover_answer = ::mm2::api::rpc_process_answer_batch(answers[0], "recover_funds_of_swap"); if (recover_answer.result.has_value()) { - auto answer = recover_answer.result.value(); + auto answer = recover_answer.result.value(); j_out["is_valid"] = true; - j_out["coin"] = answer.coin; - j_out["action"] = answer.action; - j_out["tx_hash"] = answer.tx_hash; - j_out["tx_hex"] = answer.tx_hex; + j_out["coin"] = answer.coin; + j_out["action"] = answer.action; + j_out["tx_hash"] = answer.tx_hash; + j_out["tx_hex"] = answer.tx_hex; } else if (recover_answer.error.has_value()) { j_out["is_valid"] = false; - j_out["error"] = recover_answer.error.value(); + j_out["error"] = recover_answer.error.value(); } else { j_out["is_valid"] = false; - j_out["error"] = recover_answer.raw_result; + j_out["error"] = recover_answer.raw_result; } } else if (resp.status_code() == web::http::status_codes::RequestTimeout) { j_out["is_valid"] = false; - j_out["error"] = "Request to mm2 timeout - skipping"; + j_out["error"] = "Request to mm2 timeout - skipping"; } else { j_out["is_valid"] = false; - j_out["error"] = body; + j_out["error"] = body; } this->set_recover_fund_data(nlohmann_json_object_to_qt_json_object(j_out)); this->set_recover_fund_busy(false); @@ -754,11 +761,11 @@ namespace atomic_dex { SPDLOG_ERROR("pplx task error from orders_model::recover_fund(QString uuid): {}", e.what()); nlohmann::json j_out = nlohmann::json::object(); - j_out["is_valid"] = false; - j_out["error"] = e.what(); + j_out["is_valid"] = false; + j_out["error"] = e.what(); this->set_recover_fund_data(nlohmann_json_object_to_qt_json_object(j_out)); this->set_recover_fund_busy(false); - }; + } }; mm2_system.get_mm2_client().async_rpc_batch_standalone(batch).then(answer_functor).then(error_functor); diff --git a/src/core/atomicdex/models/qt.portfolio.model.cpp b/src/core/atomicdex/models/qt.portfolio.model.cpp index 794f8f40a2..6cb81c3cc0 100644 --- a/src/core/atomicdex/models/qt.portfolio.model.cpp +++ b/src/core/atomicdex/models/qt.portfolio.model.cpp @@ -22,11 +22,12 @@ //! Project Headers #include "atomicdex/events/qt.events.hpp" +#include "atomicdex/managers/qt.wallet.manager.hpp" #include "atomicdex/pages/qt.portfolio.page.hpp" #include "atomicdex/pages/qt.trading.page.hpp" #include "atomicdex/pages/qt.wallet.page.hpp" -#include "atomicdex/services/price/coingecko/coingecko.provider.hpp" #include "atomicdex/services/price/global.provider.hpp" +#include "atomicdex/services/price/komodo_prices/komodo.prices.provider.hpp" #include "atomicdex/utilities/global.utilities.hpp" #include "atomicdex/utilities/qt.utilities.hpp" #include "qt.portfolio.model.hpp" @@ -62,12 +63,12 @@ namespace atomic_dex continue; const auto& mm2_system = this->m_system_manager.get_system(); const auto& price_service = this->m_system_manager.get_system(); - const auto& coingecko = this->m_system_manager.get_system(); + const auto& provider = this->m_system_manager.get_system(); auto coin = mm2_system.get_coin_info(ticker); std::error_code ec; - const QString change_24h = retrieve_change_24h(coingecko, coin, *m_config, m_system_manager); - portfolio_data data{ + const QString change_24h = retrieve_change_24h(provider, coin, *m_config, m_system_manager); + portfolio_data data{ .ticker = QString::fromStdString(coin.ticker), .gui_ticker = QString::fromStdString(coin.gui_ticker), .coin_type = QString::fromStdString(coin.type), @@ -77,12 +78,14 @@ namespace atomic_dex .change_24h = change_24h, .main_currency_price_for_one_unit = QString::fromStdString(price_service.get_rate_conversion(m_config->current_currency, coin.ticker, true)), .main_fiat_price_for_one_unit = QString::fromStdString(price_service.get_rate_conversion(m_config->current_fiat, coin.ticker)), - .trend_7d = nlohmann_json_array_to_qt_json_array(coingecko.get_ticker_historical(coin.ticker)), + .trend_7d = nlohmann_json_array_to_qt_json_array(provider.get_ticker_historical(coin.ticker)), + .price_provider = QString::fromStdString(provider.get_price_provider(coin.ticker)), + .price_last_timestamp = static_cast(provider.get_last_price_timestamp(coin.ticker)), .is_excluded = false, .public_address = QString::fromStdString(mm2_system.address(coin.ticker, ec))}; - //data.percent_main_currency = percent_functor(data.main_currency_balance); - data.display = QString::fromStdString(coin.gui_ticker) + " (" + data.balance + ")"; - data.ticker_and_name = QString::fromStdString(coin.gui_ticker) + data.name; + // data.percent_main_currency = percent_functor(data.main_currency_balance); + data.display = QString::fromStdString(coin.gui_ticker) + " (" + data.balance + ")"; + data.ticker_and_name = QString::fromStdString(coin.gui_ticker) + data.name; datas.push_back(std::move(data)); m_ticker_registry.emplace(ticker); } @@ -102,7 +105,7 @@ namespace atomic_dex SPDLOG_INFO("update_currency_values"); const auto& mm2_system = this->m_system_manager.get_system(); const auto& price_service = this->m_system_manager.get_system(); - const auto& coingecko = this->m_system_manager.get_system(); + const auto& provider = this->m_system_manager.get_system(); const auto coins = this->m_system_manager.get_system().get_global_cfg()->get_enabled_coins(); const std::string& currency = m_config->current_currency; const std::string& fiat = m_config->current_fiat; @@ -115,7 +118,7 @@ namespace atomic_dex SPDLOG_WARN("ticker: {} not inserted yet in the model, skipping", coin.ticker); return false; } - auto update_functor = [coin = std::move(coin), &coingecko, &mm2_system, &price_service, currency, fiat, this]() + auto update_functor = [coin = std::move(coin), &provider, &mm2_system, &price_service, currency, fiat, this]() { const std::string& ticker = coin.ticker; if (const auto res = this->match(this->index(0, 0), TickerRole, QString::fromStdString(ticker), 1, Qt::MatchFlag::MatchExactly); @@ -129,17 +132,22 @@ namespace atomic_dex update_value(MainCurrencyPriceForOneUnit, currency_price_for_one_unit, idx, *this); const QString currency_fiat_for_one_unit = QString::fromStdString(price_service.get_rate_conversion(fiat, ticker, false)); update_value(MainFiatPriceForOneUnit, currency_fiat_for_one_unit, idx, *this); - QString change24_h = retrieve_change_24h(coingecko, coin, *m_config, m_system_manager); + const QString price_provider = QString::fromStdString(provider.get_price_provider(ticker)); + update_value(PriceProvider, price_provider, idx, *this); + int last_price_timestamp = static_cast(provider.get_last_price_timestamp(ticker)); + update_value(LastPriceTimestamp, last_price_timestamp, idx, *this); + QString change24_h = retrieve_change_24h(provider, coin, *m_config, m_system_manager); update_value(Change24H, change24_h, idx, *this); const QString balance = QString::fromStdString(mm2_system.my_balance(coin.ticker, ec)); auto&& [prev_balance, new_balance, is_change_b] = update_value(BalanceRole, balance, idx, *this); const QString display = QString::fromStdString(coin.ticker) + " (" + balance + ")"; update_value(Display, display, idx, *this); + // Not a good way to trigger notification, use websocket instead in the future. New was of enabling coins is not compatible. if (is_change_b) { balance_update_handler(prev_balance.toString(), new_balance.toString(), QString::fromStdString(ticker)); } - QJsonArray trend = nlohmann_json_array_to_qt_json_array(coingecko.get_ticker_historical(ticker)); + QJsonArray trend = nlohmann_json_array_to_qt_json_array(provider.get_ticker_historical(ticker)); update_value(Trend7D, trend, idx, *this); // SPDLOG_DEBUG("updated currency values of: {}", ticker); } @@ -153,9 +161,13 @@ namespace atomic_dex bool portfolio_model::update_balance_values(const std::vector& tickers) { - //SPDLOG_INFO("update_balance_values"); + SPDLOG_INFO("update_balance_values"); for (auto&& ticker: tickers) { + if (ticker.empty()) + { + return false; + } if (m_ticker_registry.find(ticker) == m_ticker_registry.end()) { SPDLOG_WARN("ticker: {} not inserted yet in the model, skipping", ticker); @@ -168,7 +180,7 @@ namespace atomic_dex const auto* global_cfg = this->m_system_manager.get_system().get_global_cfg(); const auto coin = global_cfg->get_coin_info(ticker); const auto& price_service = this->m_system_manager.get_system(); - const auto& coingecko = this->m_system_manager.get_system(); + const auto& provider = this->m_system_manager.get_system(); std::error_code ec; const std::string& currency = m_config->current_currency; const std::string& fiat = m_config->current_fiat; @@ -181,15 +193,19 @@ namespace atomic_dex auto&& [_3, _4, is_change_mcpfo] = update_value(MainCurrencyPriceForOneUnit, currency_price_for_one_unit, idx, *this); const QString currency_fiat_for_one_unit = QString::fromStdString(price_service.get_rate_conversion(fiat, ticker, false)); update_value(MainFiatPriceForOneUnit, currency_fiat_for_one_unit, idx, *this); + const QString price_provider = QString::fromStdString(provider.get_price_provider(ticker)); + update_value(PriceProvider, price_provider, idx, *this); + int last_price_timestamp = static_cast(provider.get_last_price_timestamp(ticker)); + update_value(LastPriceTimestamp, last_price_timestamp, idx, *this); const QString display = QString::fromStdString(ticker) + " (" + balance + ")"; update_value(Display, display, idx, *this); - QString change24_h = retrieve_change_24h(coingecko, coin, *m_config, m_system_manager); + QString change24_h = retrieve_change_24h(provider, coin, *m_config, m_system_manager); update_value(Change24H, change24_h, idx, *this); if (is_change_b) { balance_update_handler(prev_balance.toString(), new_balance.toString(), QString::fromStdString(ticker)); } - QJsonArray trend = nlohmann_json_array_to_qt_json_array(coingecko.get_ticker_historical(ticker)); + QJsonArray trend = nlohmann_json_array_to_qt_json_array(provider.get_ticker_historical(ticker)); update_value(Trend7D, trend, idx, *this); if (ticker == mm2_system.get_current_ticker() && (is_change_b || is_change_mc || is_change_mcpfo)) { @@ -255,6 +271,10 @@ namespace atomic_dex return item.priv_key; case PercentMainCurrency: return item.percent_main_currency; + case PriceProvider: + return item.price_provider; + case LastPriceTimestamp: + return item.price_last_timestamp; } return {}; } @@ -338,17 +358,23 @@ namespace atomic_dex break; case PrivKey: item.priv_key = value.toString(); - emit dataChanged(index, index, {role}); + // emit dataChanged(index, index, {role}); break; case PercentMainCurrency: item.percent_main_currency = value.toString(); - emit dataChanged(index, index, {role}); + // emit dataChanged(index, index, {role}); + break; + case PriceProvider: + item.price_provider = value.toString(); + break; + case LastPriceTimestamp: + item.price_last_timestamp = value.toInt(); break; default: return false; } - // emit dataChanged(index, index, {role}); + emit dataChanged(index, index, {role}); return true; } @@ -412,7 +438,9 @@ namespace atomic_dex {MultiTickerFeesInfo, "multi_ticker_fees_info"}, {Address, "public_address"}, {PrivKey, "priv_key"}, - {PercentMainCurrency, "percent_main_currency"}}; + {PercentMainCurrency, "percent_main_currency"}, + {LastPriceTimestamp, "lastPriceTimestamp"}, + {PriceProvider, "priceProvider"}}; } portfolio_proxy_model* @@ -494,7 +522,7 @@ namespace atomic_dex void portfolio_model::adjust_percent_current_currency(QString balance_all) { - //SPDLOG_INFO("adjust_percent_current_currency"); + // SPDLOG_INFO("adjust_percent_current_currency"); const auto coins = this->m_system_manager.get_system().get_global_cfg()->get_enabled_coins(); for (auto&& [coin, cfg]: coins) { diff --git a/src/core/atomicdex/models/qt.portfolio.model.hpp b/src/core/atomicdex/models/qt.portfolio.model.hpp index 914f541e7b..ebec95b815 100644 --- a/src/core/atomicdex/models/qt.portfolio.model.hpp +++ b/src/core/atomicdex/models/qt.portfolio.model.hpp @@ -67,7 +67,9 @@ namespace atomic_dex CoinType, ///< Type of the coin Address, ///< Public address PrivKey, ///< Priv key - PercentMainCurrency + PercentMainCurrency, + LastPriceTimestamp, + PriceProvider }; Q_ENUM(PortfolioRoles) diff --git a/src/core/atomicdex/models/qt.portfolio.proxy.filter.model.cpp b/src/core/atomicdex/models/qt.portfolio.proxy.filter.model.cpp index 799489ab1d..2e8a2c7bff 100644 --- a/src/core/atomicdex/models/qt.portfolio.proxy.filter.model.cpp +++ b/src/core/atomicdex/models/qt.portfolio.proxy.filter.model.cpp @@ -69,6 +69,8 @@ namespace atomic_dex case portfolio_model::Address: case portfolio_model::PrivKey: case portfolio_model::PercentMainCurrency: + case portfolio_model::PriceProvider: + case portfolio_model::LastPriceTimestamp: return false; } } diff --git a/src/core/atomicdex/pages/qt.portfolio.page.cpp b/src/core/atomicdex/pages/qt.portfolio.page.cpp index c6591b41f0..51e1971b0c 100644 --- a/src/core/atomicdex/pages/qt.portfolio.page.cpp +++ b/src/core/atomicdex/pages/qt.portfolio.page.cpp @@ -100,7 +100,7 @@ namespace atomic_dex void portfolio_page::on_update_portfolio_values_event(const update_portfolio_values& evt) { - //SPDLOG_INFO("Updating portfolio values with model: {}", evt.with_update_model); + SPDLOG_INFO("Updating portfolio values with model: {}", evt.with_update_model); bool res = true; if (evt.with_update_model) @@ -167,6 +167,7 @@ namespace atomic_dex void portfolio_page::initialize_portfolio(const std::vector& tickers) { + SPDLOG_INFO("initialize_portfolio with tickers: {}", fmt::join(tickers, ", ")); m_portfolio_mdl->initialize_portfolio(tickers); m_global_cfg_mdl->update_status(tickers, true); } diff --git a/src/core/atomicdex/pages/qt.settings.page.cpp b/src/core/atomicdex/pages/qt.settings.page.cpp index b4dbf6a0c7..5529215ea3 100644 --- a/src/core/atomicdex/pages/qt.settings.page.cpp +++ b/src/core/atomicdex/pages/qt.settings.page.cpp @@ -365,7 +365,7 @@ namespace atomic_dex out["adex_cfg"][ticker]["coingecko_id"] = coingecko_id.toStdString(); out["adex_cfg"][ticker]["explorer_url"] = nlohmann::json::array({"https://explorer.qtum.org/"}); out["adex_cfg"][ticker]["type"] = "QRC-20"; - out["adex_cfg"][ticker]["active"] = false; + out["adex_cfg"][ticker]["active"] = true; out["adex_cfg"][ticker]["currently_enabled"] = false; out["adex_cfg"][ticker]["is_custom_coin"] = true; if (not out.at("mm2_cfg").empty()) @@ -469,7 +469,7 @@ namespace atomic_dex out["adex_cfg"][ticker]["nodes"] = coin_info.urls.value_or(std::vector()); out["adex_cfg"][ticker]["explorer_url"] = coin_info.explorer_url; out["adex_cfg"][ticker]["type"] = adex_platform; - out["adex_cfg"][ticker]["active"] = false; + out["adex_cfg"][ticker]["active"] = true; out["adex_cfg"][ticker]["currently_enabled"] = false; out["adex_cfg"][ticker]["is_custom_coin"] = true; out["adex_cfg"][ticker]["mm2_backup"] = out["mm2_cfg"]; diff --git a/src/core/atomicdex/pages/qt.trading.page.cpp b/src/core/atomicdex/pages/qt.trading.page.cpp index cdd07aedc5..5a81f90d2f 100644 --- a/src/core/atomicdex/pages/qt.trading.page.cpp +++ b/src/core/atomicdex/pages/qt.trading.page.cpp @@ -29,7 +29,7 @@ #include "atomicdex/services/price/global.provider.hpp" #include "atomicdex/utilities/qt.utilities.hpp" -//! Consttructor / Destructor +//! Constructor / Destructor namespace atomic_dex { trading_page::trading_page( @@ -51,7 +51,7 @@ namespace atomic_dex void trading_page::on_process_orderbook_finished_event(const atomic_dex::process_orderbook_finished& evt) { - if (not m_about_to_exit_the_app) + if (!m_about_to_exit_the_app) { m_actions_queue.push(trading_actions::post_process_orderbook_finished); m_models_actions[orderbook_need_a_reset] = evt.is_a_reset; @@ -75,8 +75,7 @@ namespace atomic_dex void trading_page::set_current_orderbook(const QString& base, const QString& rel) { - bool is_wallet_only = m_system_manager.get_system().get_coin_info(base.toStdString()).wallet_only; - if (is_wallet_only) + if (bool is_wallet_only = m_system_manager.get_system().get_coin_info(base.toStdString()).wallet_only; is_wallet_only) { SPDLOG_WARN("{} is wallet only - skipping", base.toStdString()); return; @@ -97,14 +96,13 @@ namespace atomic_dex } emit mm2MinTradeVolChanged(); - //SPDLOG_INFO("Reset orderbook with new pair"); dispatcher_.trigger(base.toStdString(), rel.toStdString()); } void trading_page::swap_market_pair() { - auto* market_selector_mdl = get_market_pairs_mdl(); + const auto* market_selector_mdl = get_market_pairs_mdl(); set_current_orderbook(market_selector_mdl->get_right_selected_coin(), market_selector_mdl->get_left_selected_coin()); } @@ -132,41 +130,37 @@ namespace atomic_dex this->set_buy_sell_rpc_busy(true); this->set_buy_sell_last_rpc_data(QJsonObject{{}}); - auto& mm2_system = m_system_manager.get_system(); - const auto* market_selector = get_market_pairs_mdl(); - const auto& base = market_selector->get_left_selected_coin(); - const auto& rel = market_selector->get_right_selected_coin(); - const bool is_selected_order = m_preffered_order.has_value(); - const bool is_max = m_max_volume == m_volume; - QString orderbook_available_quantity = is_selected_order ? QString::fromStdString(m_preffered_order->at("base_max_volume").get()) : ""; + auto& mm2_system = m_system_manager.get_system(); + const auto* market_selector = get_market_pairs_mdl(); + const auto& base = market_selector->get_left_selected_coin(); + const auto& rel = market_selector->get_right_selected_coin(); + const bool is_selected_order = m_preferred_order.has_value(); + const bool is_max = m_max_volume == m_volume; const bool is_selected_min_max = - is_selected_order && m_preffered_order->at("base_min_volume").get() == m_preffered_order->at("base_max_volume").get(); + is_selected_order && m_preferred_order->at("base_min_volume").get() == m_preferred_order->at("base_max_volume").get(); const bool is_selected_max = is_selected_order && is_max; t_float_50 rel_min_trade = safe_float(get_orderbook_wrapper()->get_rel_min_taker_vol().toStdString()); t_float_50 rel_min_volume_f = safe_float(get_min_trade_vol().toStdString()); if (is_selected_order) { - SPDLOG_INFO("max_volume: {} volume: {} order_volume: {}, order_volume_8_digit: {}, order_volume_8_digit_extracted: {}", - m_max_volume.toStdString(), - m_volume.toStdString(), - m_preffered_order->at("base_max_volume").get(), - utils::adjust_precision(m_preffered_order->at("base_max_volume").get()), - utils::extract_large_float(m_preffered_order->at("base_max_volume").get())); + SPDLOG_INFO( + "max_volume: {} volume: {} order_volume: {}, order_volume_8_digit: {}, order_volume_8_digit_extracted: {}", m_max_volume.toStdString(), + m_volume.toStdString(), m_preferred_order->at("base_max_volume").get(), + utils::adjust_precision(m_preferred_order->at("base_max_volume").get()), + utils::extract_large_float(m_preferred_order->at("base_max_volume").get())); } - // SPDLOG_INFO("base_min_trade: {}", rel_min_trade.str(50, std::ios::fixed)); - // SPDLOG_INFO("rel_min_volume: {} (will be use for mm2)", rel_min_volume_f.str(50, std::ios::fixed)); t_buy_request req{ .base = base.toStdString(), .rel = rel.toStdString(), - .price = is_selected_order ? m_preffered_order->at("price").get() : m_price.toStdString(), + .price = is_selected_order ? m_preferred_order->at("price").get() : m_price.toStdString(), .volume = m_volume.toStdString(), .is_created_order = not is_selected_order, - .price_denom = is_selected_order ? m_preffered_order->at("price_denom").get() : "", - .price_numer = is_selected_order ? m_preffered_order->at("price_numer").get() : "", - .volume_denom = is_selected_order ? m_preffered_order->at("base_max_volume_denom").get() : "", - .volume_numer = is_selected_order ? m_preffered_order->at("base_max_volume_numer").get() : "", - .is_exact_selected_order_volume = is_selected_max && m_max_volume.toStdString() == m_preffered_order->at("base_max_volume").get(), + .price_denom = is_selected_order ? m_preferred_order->at("price_denom").get() : "", + .price_numer = is_selected_order ? m_preferred_order->at("price_numer").get() : "", + .volume_denom = is_selected_order ? m_preferred_order->at("base_max_volume_denom").get() : "", + .volume_numer = is_selected_order ? m_preferred_order->at("base_max_volume_numer").get() : "", + .is_exact_selected_order_volume = is_selected_max && m_max_volume.toStdString() == m_preferred_order->at("base_max_volume").get(), .base_nota = base_nota.isEmpty() ? std::optional{std::nullopt} : boost::lexical_cast(base_nota.toStdString()), .base_confs = base_confs.isEmpty() ? std::optional{std::nullopt} : base_confs.toUInt(), .min_volume = (rel_min_volume_f <= rel_min_trade) ? std::optional{std::nullopt} : get_min_trade_vol().toStdString()}; @@ -176,23 +170,23 @@ namespace atomic_dex req.min_volume = std::optional{std::nullopt}; } - if (m_preffered_order.has_value()) + if (m_preferred_order.has_value()) { if (req.is_exact_selected_order_volume) { //! Selected order and we keep the exact volume (Basically swallow the order) SPDLOG_INFO("swallowing the order from the orderbook"); - req.volume_numer = m_preffered_order->at("base_max_volume_numer").get(); - req.volume_denom = m_preffered_order->at("base_max_volume_denom").get(); + req.volume_numer = m_preferred_order->at("base_max_volume_numer").get(); + req.volume_denom = m_preferred_order->at("base_max_volume_denom").get(); } else if ( - is_max && !req.is_exact_selected_order_volume && m_preffered_order->contains("max_volume_numer") && - m_preffered_order->contains("max_volume_denom")) + is_max && !req.is_exact_selected_order_volume && m_preferred_order->contains("max_volume_numer") && + m_preferred_order->contains("max_volume_denom")) { - SPDLOG_INFO("cannot swallow the selected order from the orderbook, use our theorical max_volume for it"); - //! Selected order but we cannot swallow (not enough funds) set our theorical max_volume_numer and max_volume_denom - req.volume_numer = m_preffered_order->at("max_volume_numer").get(); - req.volume_denom = m_preffered_order->at("max_volume_denom").get(); + SPDLOG_INFO("cannot swallow the selected order from the orderbook, use our theoretical max_volume for it"); + //! Selected order but we cannot swallow (not enough funds) set our theoretical max_volume_numer and max_volume_denom + req.volume_numer = m_preferred_order->at("max_volume_numer").get(); + req.volume_denom = m_preferred_order->at("max_volume_denom").get(); } else { @@ -208,19 +202,19 @@ namespace atomic_dex //! Answer SPDLOG_INFO("buy_request is : {}", buy_request.dump(4)); - auto answer_functor = [this](web::http::http_response resp) + auto answer_functor = [this](const web::http::http_response& resp) { std::string body = TO_STD_STR(resp.extract_string(true).get()); - if (resp.status_code() == 200) + if (resp.status_code() == web::http::status_codes::OK) { if (body.find("error") == std::string::npos) { auto answers = nlohmann::json::parse(body); nlohmann::json answer = answers[0]; this->set_buy_sell_last_rpc_data(nlohmann_json_object_to_qt_json_object(answer)); - auto& mm2_system = m_system_manager.get_system(); + auto& cur_mm2_system = m_system_manager.get_system(); SPDLOG_DEBUG("order successfully placed, refreshing orders and swap"); - mm2_system.batch_fetch_orders_and_swap(); + cur_mm2_system.batch_fetch_orders_and_swap(); } else { @@ -252,7 +246,7 @@ namespace atomic_dex catch (const std::exception& e) { SPDLOG_ERROR("pplx task error: {}", e.what()); - auto error_json = QJsonObject({{"error_code", 500}, {"error_message", e.what()}}); + auto error_json = QJsonObject({{"error_code", web::http::status_codes::InternalError}, {"error_message", e.what()}}); this->set_buy_sell_last_rpc_data(error_json); this->set_buy_sell_rpc_busy(false); this->clear_forms("place_buy_order"); @@ -270,12 +264,11 @@ namespace atomic_dex const auto* market_selector = get_market_pairs_mdl(); const auto& base = market_selector->get_left_selected_coin(); const auto& rel = market_selector->get_right_selected_coin(); - const bool is_selected_order = m_preffered_order.has_value(); + const bool is_selected_order = m_preferred_order.has_value(); const bool is_max = m_max_volume == m_volume; - QString orderbook_available_quantity = is_selected_order ? QString::fromStdString(m_preffered_order->at("base_max_volume").get()) : ""; + QString orderbook_available_quantity = is_selected_order ? QString::fromStdString(m_preferred_order->at("base_max_volume").get()) : ""; const bool is_selected_min_max = - is_selected_order ? m_preffered_order->at("base_min_volume").get() == m_preffered_order->at("base_max_volume").get() - : false; + is_selected_order && m_preferred_order->at("base_min_volume").get() == m_preferred_order->at("base_max_volume").get(); const bool is_selected_max = is_selected_order && m_volume.toStdString() == utils::extract_large_float(orderbook_available_quantity.toStdString()); t_float_50 base_min_trade = safe_float(get_orderbook_wrapper()->get_base_min_taker_vol().toStdString()); t_float_50 cur_min_trade = safe_float(get_min_trade_vol().toStdString()); @@ -287,13 +280,13 @@ namespace atomic_dex t_sell_request req{ .base = base.toStdString(), .rel = rel.toStdString(), - .price = is_selected_order ? m_preffered_order->at("price").get() : m_price.toStdString(), + .price = is_selected_order ? m_preferred_order->at("price").get() : m_price.toStdString(), .volume = m_volume.toStdString(), .is_created_order = not is_selected_order, - .price_denom = is_selected_order ? m_preffered_order->at("price_denom").get() : "", - .price_numer = is_selected_order ? m_preffered_order->at("price_numer").get() : "", - .volume_denom = is_selected_order ? m_preffered_order->at("base_max_volume_denom").get() : "", - .volume_numer = is_selected_order ? m_preffered_order->at("base_max_volume_numer").get() : "", + .price_denom = is_selected_order ? m_preferred_order->at("price_denom").get() : "", + .price_numer = is_selected_order ? m_preferred_order->at("price_numer").get() : "", + .volume_denom = is_selected_order ? m_preferred_order->at("base_max_volume_denom").get() : "", + .volume_numer = is_selected_order ? m_preferred_order->at("base_max_volume_numer").get() : "", .is_exact_selected_order_volume = is_selected_order && is_selected_max, .rel_nota = rel_nota.isEmpty() ? std::optional{std::nullopt} : boost::lexical_cast(rel_nota.toStdString()), .rel_confs = rel_confs.isEmpty() ? std::optional{std::nullopt} : rel_confs.toUInt(), @@ -320,9 +313,9 @@ namespace atomic_dex "The order is a selected order, treating it, input_vol: {} orderbook_max_vol {}", m_volume.toStdString(), orderbook_available_quantity.toStdString()); - const auto base_min_vol_orderbook = m_preffered_order->at("base_min_volume").get(); - t_float_50 base_min_vol_orderbook_f = safe_float(base_min_vol_orderbook); - if (cur_min_trade <= base_min_vol_orderbook_f) + const auto base_min_vol_orderbook = m_preferred_order->at("base_min_volume").get(); + + if (t_float_50 base_min_vol_orderbook_f = safe_float(base_min_vol_orderbook); cur_min_trade <= base_min_vol_orderbook_f) { SPDLOG_INFO("The selected order min_vol input is too low, using null field instead"); req.min_volume = std::optional{std::nullopt}; @@ -332,8 +325,8 @@ namespace atomic_dex { //! Selected order and we keep the exact volume (Basically swallow the order) SPDLOG_INFO("swallowing the order from the orderbook"); - req.volume_numer = m_preffered_order->at("base_max_volume_numer").get(); - req.volume_denom = m_preffered_order->at("base_max_volume_denom").get(); + req.volume_numer = m_preferred_order->at("base_max_volume_numer").get(); + req.volume_denom = m_preferred_order->at("base_max_volume_denom").get(); } else if (is_max && !req.is_exact_selected_order_volume && get_current_trading_mode() != TradingModeGadget::Simple) ///< this one is a bit dangerous, ///< let's forbid it in simple @@ -376,9 +369,9 @@ namespace atomic_dex auto answers = nlohmann::json::parse(body); nlohmann::json answer = answers[0]; this->set_buy_sell_last_rpc_data(nlohmann_json_object_to_qt_json_object(answer)); - auto& mm2_system = m_system_manager.get_system(); + auto& cur_mm2_system = m_system_manager.get_system(); SPDLOG_DEBUG("order successfully placed, refreshing orders and swap"); - mm2_system.batch_fetch_orders_and_swap(); + cur_mm2_system.batch_fetch_orders_and_swap(); } else { @@ -442,7 +435,7 @@ namespace atomic_dex } void - trading_page::clear_models() + trading_page::clear_models() const { get_market_pairs_mdl()->reset(); } @@ -450,6 +443,7 @@ namespace atomic_dex void trading_page::update() { + //! Virtual function, need to be empty. } void @@ -489,14 +483,19 @@ namespace atomic_dex if (m_models_actions[orderbook_need_a_reset] && this->m_current_trading_mode == TradingModeGadget::Pro) { - this->set_preffered_settings(); + this->set_preferred_settings(); } else { const auto base_max_taker_vol = safe_float(wrapper->get_base_max_taker_vol().toJsonObject()["decimal"].toString().toStdString()); - const auto rel_max_taker_vol = safe_float(wrapper->get_rel_max_taker_vol().toJsonObject()["decimal"].toString().toStdString()); - t_float_50 min_vol = safe_float(m_minimal_trading_amount.toStdString()); - auto adjust_functor = [this, wrapper]() + auto rel_max_taker = wrapper->get_rel_max_taker_vol().toJsonObject()["decimal"].toString().toStdString(); + if (rel_max_taker.empty()) + { + rel_max_taker = "0"; + } + const auto rel_max_taker_vol = safe_float(rel_max_taker); + t_float_50 min_vol = safe_float(m_minimal_trading_amount.toStdString()); + auto adjust_functor = [this, wrapper]() { if (m_post_clear_forms && this->m_current_trading_mode == TradingModeGadget::Pro) { @@ -568,7 +567,7 @@ namespace atomic_dex } void - trading_page::set_buy_sell_last_rpc_data(QVariant rpc_data) + trading_page::set_buy_sell_last_rpc_data(const QVariant& rpc_data) { m_rpc_buy_sell_result = rpc_data.toJsonObject(); emit buySellLastRpcDataChanged(); @@ -592,7 +591,7 @@ namespace atomic_dex this->m_market_mode = market_mode; SPDLOG_INFO("switching market_mode, new mode: {}", m_market_mode == MarketMode::Buy ? "buy" : "sell"); this->clear_forms("set_market_mode"); - auto* market_selector_mdl = get_market_pairs_mdl(); + const auto* market_selector_mdl = get_market_pairs_mdl(); set_current_orderbook(market_selector_mdl->get_left_selected_coin(), market_selector_mdl->get_right_selected_coin()); emit marketModeChanged(); if (m_market_mode == MarketMode::Buy) @@ -622,13 +621,12 @@ namespace atomic_dex if (m_price != price) { m_price = std::move(price); - if (this->m_preffered_order.has_value() && this->m_preffered_order->contains("locked")) + if (this->m_preferred_order.has_value() && this->m_preferred_order->contains("locked")) { - SPDLOG_WARN("releasing preffered order because price has been modified"); - this->m_preffered_order = std::nullopt; + SPDLOG_WARN("releasing preferred order because price has been modified"); + this->m_preferred_order = std::nullopt; emit prefferedOrderChanged(); } - // SPDLOG_DEBUG("price is [{}]", m_price.toStdString()); //! When price change in MarketMode::Buy you want to redetermine max_volume if (m_market_mode == MarketMode::Buy) @@ -638,9 +636,9 @@ namespace atomic_dex this->determine_total_amount(); - if (this->m_preffered_order.has_value()) + if (this->m_preferred_order.has_value()) { - this->m_preffered_order.value()["locked"] = true; + this->m_preferred_order.value()["locked"] = true; } this->determine_cex_rates(); emit priceChanged(); @@ -659,13 +657,12 @@ namespace atomic_dex return; } SPDLOG_INFO("clearing forms : {}", from.toStdString()); - // this->set_min_trade_vol("0"); - if (m_preffered_order.has_value() && m_current_trading_mode == TradingModeGadget::Simple && + if (m_preferred_order.has_value() && m_current_trading_mode == TradingModeGadget::Simple && m_selected_order_status == SelectedOrderGadget::OrderNotExistingAnymore) { SPDLOG_INFO("Simple view cancel order, keeping important data"); - this->set_volume(QString::fromStdString(m_preffered_order->at("initial_input_volume").get())); + this->set_volume(QString::fromStdString(m_preferred_order->at("initial_input_volume").get())); const auto max_taker_vol = get_orderbook_wrapper()->get_base_max_taker_vol().toJsonObject()["decimal"].toString(); this->set_max_volume(max_taker_vol); this->set_price("0"); @@ -680,7 +677,7 @@ namespace atomic_dex } this->set_total_amount("0"); this->set_trading_error(TradingError::None); - this->m_preffered_order = std::nullopt; + this->m_preferred_order = std::nullopt; this->m_fees = QVariantMap(); this->m_cex_price = "0"; this->m_post_clear_forms = true; @@ -702,7 +699,7 @@ namespace atomic_dex void trading_page::set_volume(QString volume) { - if (m_volume != volume && not volume.isEmpty()) + if (m_volume != volume && !volume.isEmpty()) { if (safe_float(volume.toStdString()) < 0) { @@ -747,40 +744,40 @@ namespace atomic_dex if (this->m_market_mode == MarketMode::Sell) { //! In MarketMode::Sell mode max volume is just the base_max_taker_vol - const auto max_taker_vol = get_orderbook_wrapper()->get_base_max_taker_vol().toJsonObject()["decimal"].toString().toStdString(); - if (not max_taker_vol.empty()) + const auto max_taker_vol_obj = get_orderbook_wrapper()->get_base_max_taker_vol().toJsonObject(); + const auto max_taker_vol = max_taker_vol_obj["decimal"].toString().toStdString(); + const auto max_taker_vol_coin = max_taker_vol_obj["coin"].toString().toStdString(); + const auto base = get_market_pairs_mdl()->get_left_selected_coin().toStdString(); + + + if (!max_taker_vol.empty()) { - // SPDLOG_INFO("max_taker_vol is valid, processing..."); - // SPDLOG_INFO("max_taker_vol is: [{}]", max_taker_vol); - if (safe_float(max_taker_vol) <= 0) + if (safe_float(max_taker_vol) <= 0 || base != max_taker_vol_coin) { this->set_max_volume("0"); } else { auto max_vol_str = utils::format_float(safe_float(max_taker_vol)); - if (m_preffered_order.has_value() && !m_preffered_order->empty() && m_preffered_order->contains("base_max_volume")) + if (m_preferred_order.has_value() && !m_preferred_order->empty() && m_preferred_order->contains("base_max_volume")) { - auto available_quantity = m_preffered_order->at("base_max_volume").get(); + auto available_quantity = m_preferred_order->at("base_max_volume").get(); t_float_50 available_quantity_order = safe_float(available_quantity); SPDLOG_INFO( "available_quantity_order: {}, max_volume: {}, max_taker_vol: {}", utils::format_float(safe_float(available_quantity)), get_max_volume().toStdString(), max_taker_vol); - if (available_quantity_order < safe_float(max_taker_vol) && !m_preffered_order->at("capped").get()) + if (available_quantity_order < safe_float(max_taker_vol) && !m_preferred_order->at("capped").get()) { - /*SPDLOG_INFO( - "Available quantity in selected order is less than my max tradeable amount, capping it to the order: {}\nmax_vol_str: {}", - m_preffered_order->dump(0), max_vol_str);*/ max_vol_str = available_quantity; - m_preffered_order.value()["capped"] = true; + m_preferred_order.value()["capped"] = true; this->set_max_volume(QString::fromStdString(max_vol_str)); } else { - if (!m_preffered_order->at("capped").get()) + if (!m_preferred_order->at("capped").get()) { - SPDLOG_INFO("Selecter order capping to max_taker_vol because our max_taker_volume is < base_max_volume"); - m_preffered_order.value()["capped"] = true; + SPDLOG_INFO("Selected order capping to max_taker_vol because our max_taker_volume is < base_max_volume"); + m_preferred_order.value()["capped"] = true; this->set_max_volume(QString::fromStdString(max_vol_str)); } } @@ -797,35 +794,32 @@ namespace atomic_dex } else { - SPDLOG_WARN("max_taker_vol cannot be empty, is it called before being determinated ?"); + SPDLOG_WARN("max_taker_vol cannot be empty, is it called before being determined ?"); } } else { //! In MarketMode::Buy mode the max volume is rel_max_taker_vol / price - if (not m_price.isEmpty()) + if (!m_price.isEmpty()) { t_float_50 price_f = safe_float(m_price.toStdString()); //! It's selected let's use rat price - if (m_preffered_order.has_value()) + if (m_preferred_order.has_value()) { const auto& rel_max_taker_json_obj = get_orderbook_wrapper()->get_rel_max_taker_vol().toJsonObject(); const auto& denom = rel_max_taker_json_obj["denom"].toString().toStdString(); const auto& numer = rel_max_taker_json_obj["numer"].toString().toStdString(); - t_float_50 res_f = safe_float(rel_max_taker_json_obj["decimal"].toString().toStdString()); - if (res_f <= 0) + if (t_float_50 res_f = safe_float(rel_max_taker_json_obj["decimal"].toString().toStdString()); res_f <= 0) { res_f = 0; this->set_max_volume(QString::fromStdString(utils::format_float(res_f))); } else { - std::string rel_max_vol = m_preffered_order->at("rel_max_volume").get(); - std::string base_max_vol = m_preffered_order->at("base_max_volume").get(); + auto rel_max_vol = m_preferred_order->at("rel_max_volume").get(); + auto base_max_vol = m_preferred_order->at("base_max_volume").get(); if (res_f >= safe_float(rel_max_vol)) { - // SPDLOG_INFO("Our balance is more or equal than the rel_max_volume, this means we have enough to cover the offer capping to - // base_max_vol"); this->set_max_volume(QString::fromStdString(utils::extract_large_float(base_max_vol))); } else @@ -833,17 +827,13 @@ namespace atomic_dex t_rational rel_max_taker_rat((boost::multiprecision::cpp_int(numer)), boost::multiprecision::cpp_int(denom)); if (price_f > t_float_50(0)) { - const auto price_denom = m_preffered_order->at("price_denom").get(); - const auto price_numer = m_preffered_order->at("price_numer").get(); + const auto price_denom = m_preferred_order->at("price_denom").get(); + const auto price_numer = m_preferred_order->at("price_numer").get(); t_rational price_orderbook_rat((boost::multiprecision::cpp_int(price_numer)), (boost::multiprecision::cpp_int(price_denom))); - - t_rational res = rel_max_taker_rat / price_orderbook_rat; - /*SPDLOG_INFO( - "rat should be: numerator {} denominator {}", boost::multiprecision::numerator(res).str(), - boost::multiprecision::denominator(res).str());*/ + t_rational res = rel_max_taker_rat / price_orderbook_rat; res_f = res.convert_to(); - this->m_preffered_order.value()["max_volume_denom"] = boost::multiprecision::denominator(res).str(); - this->m_preffered_order.value()["max_volume_numer"] = boost::multiprecision::numerator(res).str(); + this->m_preferred_order.value()["max_volume_denom"] = boost::multiprecision::denominator(res).str(); + this->m_preferred_order.value()["max_volume_numer"] = boost::multiprecision::numerator(res).str(); } this->set_max_volume(QString::fromStdString(utils::format_float(res_f))); } @@ -870,20 +860,17 @@ namespace atomic_dex trading_page::cap_volume() { /* - * cap_volume is called only in MarketMode::Buy, and in Sell mode if prefered order + * cap_volume is called only in MarketMode::Buy, and in Sell mode if preferred order * if the current volume text field is > the new max_volume then set volume to max_volume */ - if (auto std_volume = this->get_volume().toStdString(); not std_volume.empty()) + if (auto std_volume = this->get_volume().toStdString(); + !std_volume.empty() && safe_float(std_volume) > safe_float(this->get_max_volume().toStdString())) { - // bool hit = false; - if (safe_float(std_volume) > safe_float(this->get_max_volume().toStdString())) + auto max_volume = this->get_max_volume(); + if (!max_volume.isEmpty() && max_volume != "0") { - auto max_volume = this->get_max_volume(); - if (!max_volume.isEmpty() && max_volume != "0") - { - SPDLOG_INFO("capping volume because {} (volume) > {} (max_volume)", std_volume, max_volume.toStdString()); - this->set_volume(get_max_volume()); - } + SPDLOG_INFO("capping volume because {} (volume) > {} (max_volume)", std_volume, max_volume.toStdString()); + this->set_volume(get_max_volume()); } } } @@ -935,6 +922,8 @@ namespace atomic_dex case TradingErrorGadget::RightParentChainNotEnabled: SPDLOG_WARN("last_trading_error is RightParentChainNotEnabled"); break; + default: + break; } emit tradingErrorChanged(); } @@ -955,7 +944,7 @@ namespace atomic_dex this->set_market_mode(MarketMode::Sell); m_current_trading_mode = trading_mode; entity_registry_.template ctx().setValue("DefaultTradingMode", m_current_trading_mode); - get_market_pairs_mdl()->get_left_selection_box()->set_with_fiat_balance(m_current_trading_mode == TradingMode::Simple); + // get_market_pairs_mdl()->get_left_selection_box()->set_with_fiat_balance(m_current_trading_mode == TradingMode::Simple); get_market_pairs_mdl()->get_left_selection_box()->set_with_balance(m_current_trading_mode == TradingMode::Simple); SPDLOG_DEBUG("Set trading mode to: {}", QMetaEnum::fromType().valueToKey(trading_mode)); emit tradingModeChanged(); @@ -963,15 +952,15 @@ namespace atomic_dex } bool - trading_page::set_pair(bool is_left_side, QString changed_ticker) + trading_page::set_pair(bool is_left_side, const QString& changed_ticker) { SPDLOG_INFO("Changed ticker: {}", changed_ticker.toStdString()); - auto* const market_pair = get_market_pairs_mdl(); + const auto* market_pair = get_market_pairs_mdl(); auto base = market_pair->get_left_selected_coin(); auto rel = market_pair->get_right_selected_coin(); bool is_swap = false; - if (not changed_ticker.isEmpty()) + if (!changed_ticker.isEmpty()) { if (is_left_side) { @@ -1026,43 +1015,41 @@ namespace atomic_dex } QVariantMap - trading_page::get_preffered_order() + trading_page::get_preferred_order() const { - if (m_preffered_order.has_value()) + if (m_preferred_order.has_value()) { - return nlohmann_json_object_to_qt_json_object(m_preffered_order.value()).toVariantMap(); + return nlohmann_json_object_to_qt_json_object(m_preferred_order.value()).toVariantMap(); } - return QVariantMap(); + return {}; } void - trading_page::set_preffered_order(QVariantMap price_object) + trading_page::set_preferred_order(const QVariantMap& price_object) { - // SPDLOG_INFO("order pick from orderbook"); - if (auto preffered_order = nlohmann::json::parse(QString(QJsonDocument(QJsonObject::fromVariantMap(price_object)).toJson()).toStdString()); - preffered_order != m_preffered_order) + if (auto preferred_order = nlohmann::json::parse(QString(QJsonDocument(QJsonObject::fromVariantMap(price_object)).toJson()).toStdString()); + preferred_order != m_preferred_order) { - SPDLOG_INFO("preffered_order: {}", preffered_order.dump(-1)); - m_preffered_order = std::move(preffered_order); + SPDLOG_INFO("preferred_order: {}", preferred_order.dump(-1)); + m_preferred_order = std::move(preferred_order); emit prefferedOrderChanged(); - if (not m_preffered_order->empty() && m_preffered_order->contains("price")) + if (!m_preferred_order->empty() && m_preferred_order->contains("price")) { - m_preffered_order->operator[]("capped") = false; - this->set_price(QString::fromStdString(utils::format_float(safe_float(m_preffered_order->at("price").get())))); + m_preferred_order->operator[]("capped") = false; + this->set_price(QString::fromStdString(utils::format_float(safe_float(m_preferred_order->at("price").get())))); this->determine_max_volume(); - // const bool is_buy = m_market_mode == MarketMode::Buy; - QString min_vol = QString::fromStdString(utils::format_float(safe_float(m_preffered_order->at("base_min_volume").get()))); + QString min_vol = QString::fromStdString(utils::format_float(safe_float(m_preferred_order->at("base_min_volume").get()))); this->set_min_trade_vol(min_vol); - auto available_quantity = m_preffered_order->at("base_max_volume").get(); + auto available_quantity = m_preferred_order->at("base_max_volume").get(); if (this->m_current_trading_mode == TradingModeGadget::Pro) { this->set_volume(QString::fromStdString(utils::extract_large_float(available_quantity))); } - else if (this->m_current_trading_mode == TradingModeGadget::Simple && m_preffered_order->contains("initial_input_volume")) + else if (this->m_current_trading_mode == TradingModeGadget::Simple && m_preferred_order->contains("initial_input_volume")) { SPDLOG_INFO("From simple view, using initial_input_volume from selection to use."); - this->set_volume(QString::fromStdString(m_preffered_order->at("initial_input_volume").get())); + this->set_volume(QString::fromStdString(m_preferred_order->at("initial_input_volume").get())); } this->get_orderbook_wrapper()->refresh_best_orders(); this->determine_fees(); @@ -1093,16 +1080,15 @@ namespace atomic_dex void trading_page::determine_total_amount() { - if (not m_price.isEmpty() && not m_volume.isEmpty()) + if (!m_price.isEmpty() && !m_volume.isEmpty()) { this->set_total_amount(calculate_total_amount(m_price, m_volume)); - // this->determine_fees(); if (const std::string max_dust_str = ((m_market_mode == MarketMode::Sell) ? get_orderbook_wrapper()->get_base_max_taker_vol() : get_orderbook_wrapper()->get_rel_max_taker_vol()) .toJsonObject()["decimal"] .toString() .toStdString(); - not max_dust_str.empty()) + !max_dust_str.empty()) { this->determine_error_cases(); } @@ -1128,12 +1114,11 @@ namespace atomic_dex } void - trading_page::set_fees(QVariantMap fees) + trading_page::set_fees(const QVariantMap& fees) { if (fees != m_fees) { - m_fees = std::move(fees); - // qDebug() << "fees are: [" << m_fees << "]"; + m_fees = fees; emit feesChanged(); } } @@ -1141,24 +1126,17 @@ namespace atomic_dex void trading_page::determine_fees() { - /*if (is_preimage_busy()) - { - SPDLOG_INFO("determine_fees busy - skipping."); - return; - }*/ if (!this->m_system_manager.has_system()) { SPDLOG_WARN("MM2 Service not available, cannot determine fees - skipping"); return; } - //SPDLOG_INFO("determine_fees processing"); using namespace std::string_literals; const auto* market_pair = get_market_pairs_mdl(); auto& mm2 = this->m_system_manager.get_system(); const auto base = market_pair->get_left_selected_coin().toStdString(); const auto rel = market_pair->get_right_selected_coin().toStdString(); - // const bool is_max = m_market_mode == MarketMode::Sell && m_volume == m_max_volume; - const auto swap_method = m_market_mode == MarketMode::Sell ? "sell"s : "buy"s; + const auto swap_method = m_market_mode == MarketMode::Sell ? "sell"s : "buy"s; t_trade_preimage_request req{ .base_coin = base, .rel_coin = rel, .swap_method = swap_method, .volume = get_volume().toStdString(), .price = get_price().toStdString()}; @@ -1175,14 +1153,13 @@ namespace atomic_dex { std::string body = TO_STD_STR(resp.extract_string(true).get()); SPDLOG_INFO("preimage answer received: {}", body); - if (resp.status_code() == 200) + if (resp.status_code() == web::http::status_codes::OK) { auto answers = nlohmann::json::parse(body); nlohmann::json answer = answers[0]; auto trade_preimage_answer = ::mm2::api::rpc_process_answer_batch(answer, "trade_preimage"); if (trade_preimage_answer.result.has_value()) { - //SPDLOG_INFO("preimage answer received"); auto success_answer = trade_preimage_answer.result.value(); QVariantMap fees; @@ -1213,9 +1190,7 @@ namespace atomic_dex } fees["total_fees"] = atomic_dex::nlohmann_json_array_to_qt_json_array(success_answer.total_fees); - // qDebug() << "fees post answer: " << fees; this->set_fees(fees); - // qDebug() << this->get_fees(); } } this->set_preimage_busy(false); @@ -1237,15 +1212,13 @@ namespace atomic_dex t_float_50 max_balance_without_dust = this->get_max_balance_without_dust(); const auto& rel_min_taker_vol = get_orderbook_wrapper()->get_rel_min_taker_vol().toStdString(); const auto regular_min_taker_vol = m_market_mode == MarketMode::Sell ? get_min_trade_vol().toStdString() : rel_min_taker_vol; - // const auto& base_min_taker_vol = get_orderbook_wrapper()->get_base_min_taker_vol().toStdString(); - const auto& cur_min_taker_vol = get_min_trade_vol().toStdString(); - const auto& mm2 = m_system_manager.get_system(); - const auto left_cfg = mm2.get_coin_info(left); - const auto right_cfg = mm2.get_coin_info(right); - const bool has_preffered_order = m_preffered_order.has_value(); - const bool is_selected_min_max = - has_preffered_order ? m_preffered_order->at("base_min_volume").get() == m_preffered_order->at("base_max_volume").get() - : false; + const auto& cur_min_taker_vol = get_min_trade_vol().toStdString(); + const auto& mm2 = m_system_manager.get_system(); + const auto left_cfg = mm2.get_coin_info(left); + const auto right_cfg = mm2.get_coin_info(right); + const bool has_preferred_order = m_preferred_order.has_value(); + const bool is_selected_min_max = + has_preferred_order && m_preferred_order->at("base_min_volume").get() == m_preferred_order->at("base_max_volume").get(); if (left_cfg.has_parent_fees_ticker && left_cfg.ticker != "QTUM") { const auto left_fee_cfg = mm2.get_coin_info(left_cfg.fees_ticker); @@ -1286,15 +1259,8 @@ namespace atomic_dex } else if (safe_float(m_volume.toStdString()) < safe_float(cur_min_taker_vol) && !is_selected_min_max) { - // SPDLOG_INFO("base_amount: {}, cur_min_taker_vol: {}, price: {}", get_base_amount().toStdString(), cur_min_taker_vol, - // get_price().toStdString()); current_trading_error = TradingError::VolumeIsLowerThanTheMinimum; } - /*else if (safe_float(get_rel_amount().toStdString()) < safe_float(m_market_mode == Sell ? rel_min_taker_vol : base_min_taker_vol)) - { - SPDLOG_INFO("rel_amount: {}, rel_min_taker_vol: {}, price: {}", get_rel_amount().toStdString(), rel_min_taker_vol, get_price().toStdString()); - current_trading_error = TradingError::ReceiveVolumeIsLowerThanTheMinimum; ///< need to have for multi ticker check - }*/ else { if (!get_fees().empty()) @@ -1315,8 +1281,7 @@ namespace atomic_dex const auto* market_selector = get_market_pairs_mdl(); const auto& base = market_selector->get_left_selected_coin(); const auto& rel = market_selector->get_right_selected_coin(); - const auto cex_price = QString::fromStdString(price_service.get_cex_rates(base.toStdString(), rel.toStdString())); - if (cex_price != m_cex_price) + if (auto cex_price = QString::fromStdString(price_service.get_cex_rates(base.toStdString(), rel.toStdString())); cex_price != m_cex_price) { m_cex_price = std::move(cex_price); emit cexPriceChanged(); @@ -1341,7 +1306,7 @@ namespace atomic_dex QString trading_page::get_price_reversed() const { - if (not m_price.isEmpty() && safe_float(m_price.toStdString()) > 0) + if (!m_price.isEmpty() && safe_float(m_price.toStdString()) > 0) { t_float_50 reversed_price = t_float_50(1) / safe_float(m_price.toStdString()); return QString::fromStdString(utils::format_float(reversed_price)); @@ -1353,7 +1318,7 @@ namespace atomic_dex QString trading_page::get_cex_price_reversed() const { - if (not get_invalid_cex_price()) + if (!get_invalid_cex_price()) { t_float_50 reversed_cex_price = t_float_50(1) / safe_float(m_cex_price.toStdString()); return QString::fromStdString(utils::format_float(reversed_cex_price)); @@ -1364,8 +1329,7 @@ namespace atomic_dex QString trading_page::get_cex_price_diff() const { - bool is_invalid = get_invalid_cex_price(); - if (is_invalid || safe_float(m_price.toStdString()) <= 0) + if (bool is_invalid = get_invalid_cex_price(); is_invalid || safe_float(m_price.toStdString()) <= 0) { return "0"; } @@ -1377,7 +1341,7 @@ namespace atomic_dex } t_float_50 - trading_page::get_max_balance_without_dust(std::optional trade_with) const + trading_page::get_max_balance_without_dust(const std::optional& trade_with) const { if (!trade_with.has_value()) { @@ -1386,7 +1350,10 @@ namespace atomic_dex .toJsonObject()["decimal"] .toString() .toStdString(); - // assert(not max_dust_str.empty()); + if (max_dust_str.empty()) + { + return t_float_50(0); + } t_float_50 max_balance_without_dust = safe_float(max_dust_str); return max_balance_without_dust; } @@ -1440,11 +1407,8 @@ namespace atomic_dex //! base_min_vol -> 0.0001 KMD //! rel_min_vol -> 10 DOGE const auto& min_taker_vol = get_orderbook_wrapper()->get_base_min_taker_vol().toStdString(); - // SPDLOG_INFO("min_taker_vol: {}", min_taker_vol); - t_float_50 min_vol_f = safe_float(min_taker_vol); - // const bool is_valid = safe_float(min_trade_vol.toStdString()) <= safe_float(get_volume().toStdString()); - if (safe_float(min_trade_vol.toStdString()) <= min_vol_f) + if (t_float_50 min_vol_f = safe_float(min_taker_vol); safe_float(min_trade_vol.toStdString()) <= min_vol_f) { min_trade_vol = QString::fromStdString(min_taker_vol); } @@ -1457,9 +1421,7 @@ namespace atomic_dex if (min_trade_vol != m_minimal_trading_amount) { - // SPDLOG_INFO("min_trade_vol before adjustment: [{}]", min_trade_vol.toStdString()); - min_trade_vol = QString::fromStdString(utils::adjust_precision(min_trade_vol.toStdString())); - // SPDLOG_INFO("min_trade_vol after adjustment: [{}]", min_trade_vol.toStdString()); + min_trade_vol = QString::fromStdString(utils::adjust_precision(min_trade_vol.toStdString())); m_minimal_trading_amount = std::move(min_trade_vol); emit minTradeVolChanged(); this->determine_error_cases(); @@ -1499,7 +1461,7 @@ namespace atomic_dex namespace atomic_dex { QString - trading_page::calculate_total_amount(QString price, QString volume) const + trading_page::calculate_total_amount(QString price, QString volume) { t_float_50 price_f(safe_float(price.toStdString())); t_float_50 volume_f(safe_float(volume.toStdString())); @@ -1508,18 +1470,17 @@ namespace atomic_dex } void - trading_page::set_preffered_settings() + trading_page::set_preferred_settings() { - QSettings& settings = entity_registry_.ctx(); - auto* market_selector_mdl = get_market_pairs_mdl(); + auto& settings = entity_registry_.ctx(); + const auto* market_selector_mdl = get_market_pairs_mdl(); const auto left = market_selector_mdl->get_left_selected_coin(); const auto right = market_selector_mdl->get_right_selected_coin(); const auto category_settings = left + "_" + right; const QString target_settings = "Disabled"; settings.beginGroup(category_settings); - const bool is_disabled = settings.value(target_settings, true).toBool(); - t_float_50 spread = settings.value("Spread", 1.0).toDouble(); - // const bool max = settings.value("Max", false).toBool(); + const bool is_disabled = settings.value(target_settings, true).toBool(); + t_float_50 spread = settings.value("Spread", 1.0).toDouble(); t_float_50 min_volume_percent = settings.value("MinVolume", 10.0).toDouble() / 100; ///< min volume is always 10% of the order or more settings.endGroup(); if (!is_disabled) @@ -1545,9 +1506,9 @@ namespace atomic_dex } std::optional - trading_page::get_raw_preffered_order() const + trading_page::get_raw_preferred_order() const { - return m_preffered_order; + return m_preferred_order; } SelectedOrderStatus diff --git a/src/core/atomicdex/pages/qt.trading.page.hpp b/src/core/atomicdex/pages/qt.trading.page.hpp index 479d937c93..2cf51f4a3c 100644 --- a/src/core/atomicdex/pages/qt.trading.page.hpp +++ b/src/core/atomicdex/pages/qt.trading.page.hpp @@ -59,7 +59,7 @@ namespace atomic_dex Q_PROPERTY(QString base_amount READ get_base_amount NOTIFY baseAmountChanged) Q_PROPERTY(QString rel_amount READ get_rel_amount NOTIFY relAmountChanged) Q_PROPERTY(QVariantMap fees READ get_fees WRITE set_fees NOTIFY feesChanged) - Q_PROPERTY(QVariantMap preffered_order READ get_preffered_order WRITE set_preffered_order NOTIFY prefferedOrderChanged) + Q_PROPERTY(QVariantMap preffered_order READ get_preferred_order WRITE set_preferred_order NOTIFY prefferedOrderChanged) Q_PROPERTY(SelectedOrderStatus selected_order_status READ get_selected_order_status WRITE set_selected_order_status NOTIFY selectedOrderStatusChanged) Q_PROPERTY(QString price_reversed READ get_price_reversed NOTIFY priceReversedChanged) Q_PROPERTY(QString cex_price READ get_cex_price NOTIFY cexPriceChanged) @@ -101,7 +101,7 @@ namespace atomic_dex ag::ecs::system_manager& m_system_manager; std::atomic_bool& m_about_to_exit_the_app; t_models m_models; - t_models_actions m_models_actions; + t_models_actions m_models_actions{}; t_actions_queue m_actions_queue{g_max_actions_size}; std::atomic_bool m_rpc_buy_sell_busy{false}; std::atomic_bool m_rpc_preimage_busy{false}; @@ -119,7 +119,7 @@ namespace atomic_dex QString m_total_amount{"0"}; QString m_cex_price{"0"}; QString m_minimal_trading_amount{"0"}; - std::optional m_preffered_order; + std::optional m_preferred_order; boost::synchronized_value m_fees; bool m_skip_taker{false}; @@ -128,10 +128,10 @@ namespace atomic_dex void determine_total_amount(); void determine_cex_rates(); void cap_volume(); - [[nodiscard]] t_float_50 get_max_balance_without_dust(std::optional trade_with = std::nullopt) const; + [[nodiscard]] t_float_50 get_max_balance_without_dust(const std::optional& trade_with = std::nullopt) const; [[nodiscard]] TradingError generate_fees_error(QVariantMap fees) const; - void set_preffered_settings(); - QString calculate_total_amount(QString price, QString volume) const; + void set_preferred_settings(); + static QString calculate_total_amount(QString price, QString volume) ; public: //! Constructor @@ -147,7 +147,7 @@ namespace atomic_dex void process_action(); void connect_signals(); void disconnect_signals(); - void clear_models(); + void clear_models() const; void disable_coins(const QStringList& coins); //! Public QML API @@ -158,7 +158,7 @@ namespace atomic_dex //! Trading business Q_INVOKABLE void swap_market_pair(); ///< market_selector (button to switch market selector and orderbook) - Q_INVOKABLE bool set_pair(bool is_left_side, QString changed_ticker); + Q_INVOKABLE bool set_pair(bool is_left_side, const QString& changed_ticker); Q_INVOKABLE void set_current_orderbook(const QString& base, const QString& rel); ///< market_selector (called and selecting another coin) Q_INVOKABLE void place_buy_order(const QString& base_nota = "", const QString& base_confs = ""); @@ -204,17 +204,17 @@ namespace atomic_dex [[nodiscard]] QString get_cex_price_reversed() const; [[nodiscard]] QString get_cex_price_diff() const; [[nodiscard]] bool get_invalid_cex_price() const; - [[nodiscard]] QVariantMap get_preffered_order(); - void set_preffered_order(QVariantMap price_object); - std::optional get_raw_preffered_order() const; + [[nodiscard]] QVariantMap get_preferred_order() const; + void set_preferred_order(const QVariantMap& price_object); + std::optional get_raw_preferred_order() const; [[nodiscard]] QVariantMap get_fees() const; - void set_fees(QVariantMap fees); + void set_fees(const QVariantMap& fees); [[nodiscard]] bool get_skip_taker() const; void set_skip_taker(bool skip_taker); [[nodiscard]] bool is_preimage_busy() const; void set_preimage_busy(bool status); [[nodiscard]] QVariant get_buy_sell_last_rpc_data() const; - void set_buy_sell_last_rpc_data(QVariant rpc_data); + void set_buy_sell_last_rpc_data(const QVariant& rpc_data); //! Events Callbacks void on_process_orderbook_finished_event(const process_orderbook_finished& evt); diff --git a/src/core/atomicdex/pages/qt.wallet.page.cpp b/src/core/atomicdex/pages/qt.wallet.page.cpp index bc609ab11b..82376baf14 100644 --- a/src/core/atomicdex/pages/qt.wallet.page.cpp +++ b/src/core/atomicdex/pages/qt.wallet.page.cpp @@ -16,8 +16,8 @@ #include "atomicdex/api/mm2/rpc.validate.address.hpp" #include "atomicdex/api/mm2/rpc.withdraw.hpp" #include "atomicdex/services/mm2/mm2.service.hpp" -#include "atomicdex/services/price/coingecko/coingecko.provider.hpp" #include "atomicdex/services/price/global.provider.hpp" +#include "atomicdex/services/price/komodo_prices/komodo.prices.provider.hpp" #include "atomicdex/utilities/qt.utilities.hpp" #include "qt.portfolio.page.hpp" #include "qt.settings.page.hpp" @@ -237,7 +237,7 @@ namespace atomic_dex QVariant wallet_page::get_ticker_infos() const { - //SPDLOG_DEBUG("get_ticker_infos"); + // SPDLOG_DEBUG("get_ticker_infos"); QJsonObject obj{ {"balance", "0"}, {"name", "Komodo"}, @@ -265,7 +265,7 @@ namespace atomic_dex { auto& price_service = m_system_manager.get_system(); const auto& settings_system = m_system_manager.get_system(); - const auto& coingecko = m_system_manager.get_system(); + const auto& provider = m_system_manager.get_system(); const auto& ticker = mm2_system.get_current_ticker(); const auto& coin_info = mm2_system.get_coin_info(ticker); const auto& config = settings_system.get_cfg(); @@ -274,17 +274,16 @@ namespace atomic_dex obj["type"] = QString::fromStdString(coin_info.type); obj["segwit_supported"] = coin_info.segwit; obj["is_segwit_on"] = coin_info.is_segwit_on; - //SPDLOG_DEBUG("is_segwit_on {} segwit: {}", coin_info.is_segwit_on, coin_info.segwit); obj["is_claimable"] = coin_info.is_claimable; obj["address"] = QString::fromStdString(mm2_system.address(ticker, ec)); obj["minimal_balance_for_asking_rewards"] = QString::fromStdString(coin_info.minimal_claim_amount); obj["explorer_url"] = QString::fromStdString(coin_info.explorer_url[0]); obj["current_currency_ticker_price"] = QString::fromStdString(price_service.get_rate_conversion(config.current_currency, ticker, true)); - obj["change_24h"] = retrieve_change_24h(coingecko, coin_info, config, m_system_manager); + obj["change_24h"] = retrieve_change_24h(provider, coin_info, config, m_system_manager); const auto& tx_state = mm2_system.get_tx_state(ec); obj["tx_state"] = QString::fromStdString(tx_state.state); obj["fiat_amount"] = QString::fromStdString(price_service.get_price_in_fiat(config.current_currency, ticker, ec)); - obj["trend_7d"] = nlohmann_json_array_to_qt_json_array(coingecko.get_ticker_historical(ticker)); + obj["trend_7d"] = nlohmann_json_array_to_qt_json_array(provider.get_ticker_historical(ticker)); // SPDLOG_INFO("fee_ticker of ticker :{} is {}", ticker, coin_info.fees_ticker); obj["fee_ticker"] = QString::fromStdString(coin_info.fees_ticker); obj["blocks_left"] = static_cast(tx_state.blocks_left); @@ -295,6 +294,7 @@ namespace atomic_dex qrcodegen::QrCode qr0 = qrcodegen::QrCode::encodeText(mm2_system.address(ticker, ec).c_str(), qrcodegen::QrCode::Ecc::MEDIUM); std::string svg = qr0.toSvgString(2); obj["qrcode_address"] = QString::fromStdString("data:image/svg+xml;base64,") + QString::fromStdString(svg).toLocal8Bit().toBase64(); + // SPDLOG_DEBUG("is_segwit_on {} segwit: {}", coin_info.is_segwit_on, coin_info.segwit); } return obj; } @@ -343,7 +343,7 @@ namespace atomic_dex reason = tr("%1 address length is invalid, please use a valid address.").arg(json_result["ticker"].toString()); json_result["convertible"] = false; } - else if (reason.contains("Invalid Address")) + else if (reason.toLower().contains("invalid address")) { reason = tr("%1 address is invalid.").arg(json_result["ticker"].toString()); json_result["convertible"] = false; @@ -355,11 +355,11 @@ namespace atomic_dex } else if (reason.contains("has invalid prefixes")) { - reason = tr("%1 address has invalid prefixes.").arg(json_result["ticker"].toString()); + reason = tr("%1 address has invalid prefixes.").arg(json_result["ticker"].toString()); } else { - reason = tr("Unknown error."); + reason = tr("Backend error: %1").arg(reason); json_result["convertible"] = false; } json_result["reason"] = reason; @@ -566,8 +566,23 @@ namespace atomic_dex this->set_send_busy(false); }; + auto error_functor = [this](pplx::task previous_task) + { + try + { + previous_task.wait(); + } + catch (const std::exception& e) + { + SPDLOG_ERROR("error caught in send: {}", e.what()); + auto error_json = QJsonObject({{"error_code", 500}, {"error_message", QString::fromStdString(e.what())}}); + this->set_rpc_send_data(error_json); + this->set_send_busy(false); + } + }; + //! Process - mm2_system.get_mm2_client().async_rpc_batch_standalone(batch).then(answer_functor).then(&handle_exception_pplx_task); + mm2_system.get_mm2_client().async_rpc_batch_standalone(batch).then(answer_functor).then(error_functor); } void @@ -645,7 +660,21 @@ namespace atomic_dex this->set_broadcast_busy(false); }; - mm2_system.get_mm2_client().async_rpc_batch_standalone(batch).then(answer_functor).then(&handle_exception_pplx_task); + auto error_functor = [this](pplx::task previous_task) + { + try + { + previous_task.wait(); + } + catch (const std::exception& e) + { + SPDLOG_ERROR("error caught in broadcast finished: {}", e.what()); + this->set_rpc_broadcast_data(QString::fromStdString(e.what())); + this->set_broadcast_busy(false); + } + }; + + mm2_system.get_mm2_client().async_rpc_batch_standalone(batch).then(answer_functor).then(error_functor); } void @@ -661,36 +690,50 @@ namespace atomic_dex batch.push_back(json_data); json_data = ::mm2::api::template_request("kmd_rewards_info"); batch.push_back(json_data); - mm2_system.get_mm2_client() - .async_rpc_batch_standalone(batch) - .then( - [this](web::http::http_response resp) - { - std::string body = TO_STD_STR(resp.extract_string(true).get()); - // SPDLOG_DEBUG("resp claiming: {}", body); - if (resp.status_code() == static_cast(antara::app::http_code::ok) && body.find("error") == std::string::npos) - { - auto answers = nlohmann::json::parse(body); - auto withdraw_answer = ::mm2::api::rpc_process_answer_batch(answers[0], "withdraw"); - nlohmann::json j_out = nlohmann::json::object(); - j_out["withdraw_answer"] = answers[0]["result"]; - j_out.at("withdraw_answer")["date"] = withdraw_answer.result.value().timestamp_as_date; - auto kmd_rewards_answer = ::mm2::api::process_kmd_rewards_answer(answers[1]); - j_out["kmd_rewards_info"] = kmd_rewards_answer.result; - this->set_rpc_claiming_data(nlohmann_json_object_to_qt_json_object(j_out)); - } - else - { - auto error_json = QJsonObject({{"error_code", resp.status_code()}, {"error_message", QString::fromStdString(body)}}); - this->set_rpc_claiming_data(error_json); - } - this->set_claiming_is_busy(false); - }) - .then(&handle_exception_pplx_task); + + auto answer_functor = [this](web::http::http_response resp) + { + std::string body = TO_STD_STR(resp.extract_string(true).get()); + // SPDLOG_DEBUG("resp claiming: {}", body); + if (resp.status_code() == static_cast(antara::app::http_code::ok) && body.find("error") == std::string::npos) + { + auto answers = nlohmann::json::parse(body); + auto withdraw_answer = ::mm2::api::rpc_process_answer_batch(answers[0], "withdraw"); + nlohmann::json j_out = nlohmann::json::object(); + j_out["withdraw_answer"] = answers[0]["result"]; + j_out.at("withdraw_answer")["date"] = withdraw_answer.result.value().timestamp_as_date; + auto kmd_rewards_answer = ::mm2::api::process_kmd_rewards_answer(answers[1]); + j_out["kmd_rewards_info"] = kmd_rewards_answer.result; + this->set_rpc_claiming_data(nlohmann_json_object_to_qt_json_object(j_out)); + } + else + { + auto error_json = QJsonObject({{"error_code", resp.status_code()}, {"error_message", QString::fromStdString(body)}}); + this->set_rpc_claiming_data(error_json); + } + this->set_claiming_is_busy(false); + }; + + auto error_functor = [this](pplx::task previous_task) + { + try + { + previous_task.wait(); + } + catch (const std::exception& e) + { + SPDLOG_ERROR("error caught in claim_rewards: {}", e.what()); + auto error_json = QJsonObject({{"error_code", 500}, {"error_message", QString::fromStdString(e.what())}}); + this->set_rpc_claiming_data(error_json); + this->set_claiming_is_busy(false); + } + }; + + mm2_system.get_mm2_client().async_rpc_batch_standalone(batch).then(answer_functor).then(error_functor); } void - wallet_page::claim_faucet() + wallet_page ::claim_faucet() { const auto& mm2_system = m_system_manager.get_system(); const auto& ticker = mm2_system.get_current_ticker(); @@ -756,7 +799,7 @@ namespace atomic_dex auto& mm2_system = m_system_manager.get_system(); if (mm2_system.is_mm2_running()) { - const auto& ticker = mm2_system.get_current_ticker(); + const auto& ticker = mm2_system.get_current_ticker(); validate_address(address, QString::fromStdString(ticker)); } } @@ -780,7 +823,7 @@ namespace atomic_dex std::string body = TO_STD_STR(resp.extract_string(true).get()); SPDLOG_DEBUG("resp validateaddress: {}", body); nlohmann::json j_out = nlohmann::json::object(); - j_out["ticker"] = ticker.toStdString(); + j_out["ticker"] = ticker.toStdString(); if (resp.status_code() == static_cast(antara::app::http_code::ok)) { auto answers = nlohmann::json::parse(body); @@ -815,7 +858,7 @@ namespace atomic_dex auto& mm2_system = m_system_manager.get_system(); if (mm2_system.is_mm2_running()) { - const auto& ticker = mm2_system.get_current_ticker(); + const auto& ticker = mm2_system.get_current_ticker(); convert_address(from, QString::fromStdString(ticker), to_address_format); } } @@ -924,7 +967,7 @@ namespace atomic_dex wallet_page::post_switch_address_mode(bool is_segwit) { SPDLOG_INFO("switching to : {}", is_segwit ? "segwit" : "legacy"); - auto& mm2_system = m_system_manager.get_system(); + auto& mm2_system = m_system_manager.get_system(); if (mm2_system.is_mm2_running()) { //! Need disable + enable + refresh balance + refresh current coin info (address) + change segwit in cfg @@ -937,11 +980,12 @@ namespace atomic_dex //! Disable is in the batch //! electrum - auto coin_info = mm2_system.get_coin_info(ticker); - t_electrum_request electrum_req{.coin_name = coin_info.ticker, .servers = coin_info.electrum_urls.value(), .coin_type = coin_info.coin_type, .with_tx_history = true}; + auto coin_info = mm2_system.get_coin_info(ticker); + t_electrum_request electrum_req{ + .coin_name = coin_info.ticker, .servers = coin_info.electrum_urls.value(), .coin_type = coin_info.coin_type, .with_tx_history = true}; if (is_segwit) { - electrum_req.address_format = nlohmann::json::object(); + electrum_req.address_format = nlohmann::json::object(); electrum_req.address_format.value()["format"] = "segwit"; } nlohmann::json electrum_data = ::mm2::api::template_request("electrum"); @@ -953,15 +997,15 @@ namespace atomic_dex //! Answer functor auto answer_functor = [this, ticker, is_segwit](web::http::http_response resp) { - std::string body = TO_STD_STR(resp.extract_string(true).get()); - SPDLOG_DEBUG("resp disable/enable: {}", body); - if (resp.status_code() == static_cast(antara::app::http_code::ok)) - { - auto& mm2_system = m_system_manager.get_system(); - mm2_system.change_segwit_status(ticker, is_segwit); - mm2_system.fetch_infos_thread(true, false); - SPDLOG_INFO("Switching address mode success"); - } + std::string body = TO_STD_STR(resp.extract_string(true).get()); + SPDLOG_DEBUG("resp disable/enable: {}", body); + if (resp.status_code() == static_cast(antara::app::http_code::ok)) + { + auto& mm2_system = m_system_manager.get_system(); + mm2_system.change_segwit_status(ticker, is_segwit); + mm2_system.fetch_infos_thread(true, false); + SPDLOG_INFO("Switching address mode success"); + } }; //! Rpc processing diff --git a/src/core/atomicdex/pages/widgets/dex/qt.market.pairs.cpp b/src/core/atomicdex/pages/widgets/dex/qt.market.pairs.cpp index 5904083346..ff7a993adb 100644 --- a/src/core/atomicdex/pages/widgets/dex/qt.market.pairs.cpp +++ b/src/core/atomicdex/pages/widgets/dex/qt.market.pairs.cpp @@ -32,14 +32,14 @@ namespace atomic_dex m_left_selection_box->is_a_market_selector(true); m_left_selection_box->setSourceModel(portfolio_mdl); m_left_selection_box->setDynamicSortFilter(true); - m_left_selection_box->sort_by_name(true); + m_left_selection_box->sort_by_currency_balance(false); this->m_left_selection_box->setFilterRole(portfolio_model::PortfolioRoles::NameAndTicker); this->m_left_selection_box->setFilterCaseSensitivity(Qt::CaseInsensitive); m_right_selection_box->is_a_market_selector(true); m_right_selection_box->setSourceModel(portfolio_mdl); m_right_selection_box->setDynamicSortFilter(true); - m_right_selection_box->sort_by_name(true); + m_right_selection_box->sort_by_currency_balance(false); this->m_right_selection_box->setFilterRole(portfolio_model::PortfolioRoles::NameAndTicker); this->m_right_selection_box->setFilterCaseSensitivity(Qt::CaseInsensitive); diff --git a/src/core/atomicdex/pages/widgets/dex/qt.orderbook.cpp b/src/core/atomicdex/pages/widgets/dex/qt.orderbook.cpp index 550381d93d..6c064b8143 100644 --- a/src/core/atomicdex/pages/widgets/dex/qt.orderbook.cpp +++ b/src/core/atomicdex/pages/widgets/dex/qt.orderbook.cpp @@ -109,7 +109,7 @@ namespace atomic_dex if (m_selected_best_order->has_value()) { SPDLOG_INFO("selected best orders have a value - set preffered order"); - m_system_manager.get_system().set_preffered_order(m_selected_best_order->value()); + m_system_manager.get_system().set_preferred_order(m_selected_best_order->value()); m_selected_best_order = std::nullopt; } m_best_orders->clear_orderbook(); ///< Remove all elements from the model @@ -141,10 +141,16 @@ namespace atomic_dex { auto&& [base, rel] = m_system_manager.get_system().get_taker_vol(); this->m_base_max_taker_vol = QJsonObject{ - {"denom", QString::fromStdString(base.denom)}, {"numer", QString::fromStdString(base.numer)}, {"decimal", QString::fromStdString(base.decimal)}}; + {"denom", QString::fromStdString(base.denom)}, + {"numer", QString::fromStdString(base.numer)}, + {"decimal", QString::fromStdString(base.decimal)}, + {"coin", QString::fromStdString(base.coin)}}; emit baseMaxTakerVolChanged(); this->m_rel_max_taker_vol = QJsonObject{ - {"denom", QString::fromStdString(rel.denom)}, {"numer", QString::fromStdString(rel.numer)}, {"decimal", QString::fromStdString(rel.decimal)}}; + {"denom", QString::fromStdString(rel.denom)}, + {"numer", QString::fromStdString(rel.numer)}, + {"decimal", QString::fromStdString(rel.decimal)}, + {"coin", QString::fromStdString(rel.coin)}}; emit relMaxTakerVolChanged(); auto&& [min_base, min_rel] = m_system_manager.get_system().get_min_vol(); @@ -206,14 +212,14 @@ namespace atomic_dex { out["initial_input_volume"] = trading_pg.get_volume(); } - m_selected_best_order = out; + m_selected_best_order = out; auto right_coin = trading_pg.get_market_pairs_mdl()->get_right_selected_coin(); if (right_coin == out.value("coin").toString()) { SPDLOG_INFO("Selected order is from the same pair, overriding preffered_order"); - trading_pg.set_preffered_order(out); + trading_pg.set_preferred_order(out); } else { @@ -249,7 +255,7 @@ namespace atomic_dex { QString cur_taker_vol = get_base_min_taker_vol(); auto& trading_pg = m_system_manager.get_system(); - auto preffered_order = trading_pg.get_raw_preffered_order(); + auto preffered_order = trading_pg.get_raw_preferred_order(); t_float_50 price_f = safe_float(trading_pg.get_price().toStdString()); if (preffered_order.has_value()) { diff --git a/src/core/atomicdex/services/mm2/mm2.service.cpp b/src/core/atomicdex/services/mm2/mm2.service.cpp index 05be593f0d..931bcb6bc1 100644 --- a/src/core/atomicdex/services/mm2/mm2.service.cpp +++ b/src/core/atomicdex/services/mm2/mm2.service.cpp @@ -18,9 +18,9 @@ #include ///! Qt +#include #include #include -#include //! Project Headers #include "atomicdex/api/mm2/mm2.constants.hpp" @@ -28,6 +28,7 @@ #include "atomicdex/api/mm2/rpc.enable.hpp" #include "atomicdex/api/mm2/rpc.min.volume.hpp" #include "atomicdex/api/mm2/rpc.tx.history.hpp" +#include "atomicdex/pages/qt.portfolio.page.hpp" #include "atomicdex/config/mm2.cfg.hpp" #include "atomicdex/managers/qt.wallet.manager.hpp" #include "atomicdex/services/internet/internet.checker.service.hpp" @@ -69,7 +70,7 @@ namespace //! New cfg to ifs fs::path actual_version_filepath = cfg_path / (std::string(atomic_dex::get_raw_version()) + "-coins."s + wallet_name + ".json"s); LOG_PATH("opening file: {}", actual_version_filepath); - QFile actual_version_ifs; + QFile actual_version_ifs; actual_version_ifs.setFileName(atomic_dex::std_path_to_qstring(actual_version_filepath)); actual_version_ifs.open(QIODevice::Text | QIODevice::ReadOnly); nlohmann::json actual_config_data = nlohmann::json::parse(QString(actual_version_ifs.readAll()).toStdString()); @@ -127,7 +128,7 @@ namespace const std::string& wallet_name, const std::vector& tickers, bool status, atomic_dex::t_coins_registry& registry, std::shared_mutex& registry_mtx, std::string field_name = "active") { - SPDLOG_INFO("Update coins status to: {} - field_name: {}", status, field_name); + SPDLOG_INFO("Update coins status to: {} - field_name: {} - tickers: {}", status, field_name, fmt::join(tickers, ", ")); fs::path cfg_path = atomic_dex::utils::get_atomic_dex_config_folder(); std::string filename = std::string(atomic_dex::get_raw_version()) + "-coins." + wallet_name + ".json"; std::string custom_tokens_filename = "custom-tokens." + wallet_name + ".json"; @@ -164,8 +165,11 @@ namespace } if (field_name == "active") { + SPDLOG_INFO("ticker: {} status active: {}", ticker, status); registry[ticker].active = status; - } else if (field_name == "is_segwit_on") { + } + else if (field_name == "is_segwit_on") + { registry[ticker].is_segwit_on = status; } } @@ -469,17 +473,18 @@ namespace atomic_dex mm2_service::batch_balance_and_tx(bool is_a_reset, std::vector tickers, bool is_during_enabling, bool only_tx) { // SPDLOG_INFO("batch_balance_and_tx"); + (void)tickers; + (void)is_during_enabling; auto&& [batch_array, tickers_idx, tokens_to_fetch] = prepare_batch_balance_and_tx(only_tx); return m_mm2_client.async_rpc_batch_standalone(batch_array) .then( - [this, tickers_idx = tickers_idx, tokens_to_fetch = tokens_to_fetch, is_a_reset, tickers, is_during_enabling](web::http::http_response resp) + [this, tokens_to_fetch = tokens_to_fetch, is_a_reset, tickers](web::http::http_response resp) { try { auto answers = ::mm2::api::basic_batch_answer(resp); if (not answers.contains("error")) { - std::size_t idx = 0; for (auto&& answer: answers) { if (answer.contains("balance")) @@ -501,15 +506,9 @@ namespace atomic_dex //! Emit error for UI Change } } - ++idx; } for (auto&& coin: tokens_to_fetch) { process_tx_tokenscan(coin, is_a_reset); } - this->dispatcher_.trigger(tickers_idx); - if (is_during_enabling) - { - dispatcher_.trigger(tickers); - } } } catch (const std::exception& error) @@ -595,11 +594,12 @@ namespace atomic_dex { coin_config coin_info = get_coin_info(g_second_primary_dex_coin); t_electrum_request request{.coin_name = coin_info.ticker, .servers = coin_info.electrum_urls.value(), .with_tx_history = true}; - if (coin_info.segwit && coin_info.is_segwit_on) { - request.address_format = nlohmann::json::object(); + if (coin_info.segwit && coin_info.is_segwit_on) + { + request.address_format = nlohmann::json::object(); request.address_format.value()["format"] = "segwit"; } - nlohmann::json j = ::mm2::api::template_request("electrum"); + nlohmann::json j = ::mm2::api::template_request("electrum"); ::mm2::api::to_json(j, request); btc_kmd_batch.push_back(j); coin_info = get_coin_info(g_primary_dex_coin); @@ -633,8 +633,9 @@ namespace atomic_dex .coin_type = coin_info.coin_type, .is_testnet = coin_info.is_testnet.value_or(false), .with_tx_history = true}; - if (coin_info.segwit && coin_info.is_segwit_on) { - request.address_format = nlohmann::json::object(); + if (coin_info.segwit && coin_info.is_segwit_on) + { + request.address_format = nlohmann::json::object(); request.address_format.value()["format"] = "segwit"; } nlohmann::json j = ::mm2::api::template_request("electrum"); @@ -687,37 +688,56 @@ namespace atomic_dex for (auto&& answer: answers) { auto [res, error] = this->process_batch_enable_answer(answer); - if (not res && idx < tickers.size()) + if (!res) { SPDLOG_DEBUG( "bad answer for: [{}] -> removing it from enabling, idx: {}, tickers size: {}, answers size: {}", tickers[idx], idx, tickers.size(), answers.size()); this->dispatcher_.trigger(tickers[idx], error); to_remove.emplace(tickers[idx]); + if (error.find("already initialized") == std::string::npos) + { + SPDLOG_WARN("Should set to false the active field in cfg for: {} - reason: {}", tickers[idx], error); + } } idx += 1; + if (res) + { + this->process_balance_answer(answer); + } } for (auto&& t: to_remove) { tickers.erase(std::remove(tickers.begin(), tickers.end(), t), tickers.end()); } - if (not tickers.empty()) + if (!tickers.empty()) { if (tickers == g_default_coins) { + SPDLOG_INFO("Trigger default_coins_enabled"); this->dispatcher_.trigger(); + batch_balance_and_tx(false, tickers, true); } - batch_balance_and_tx(false, tickers, true); + dispatcher_.trigger(tickers); + if (tickers.size() == 1) + { + fetch_single_balance(get_coin_info(tickers[0])); + } + // batch_balance_and_tx(false, tickers, true); } } } catch (const std::exception& error) { SPDLOG_ERROR("exception caught in batch_enable_coins: {}", error.what()); + //update_coin_status(this->m_current_wallet_name, tickers, false, m_coins_informations, m_coin_cfg_mutex); //! Emit event here } }) - .then([this, batch_array](pplx::task previous_task) - { this->handle_exception_pplx_task(previous_task, "batch_enable_coins", batch_array); }); + .then([this, tickers, batch_array](pplx::task previous_task) + { + this->handle_exception_pplx_task(previous_task, "batch_enable_coins", batch_array); + //update_coin_status(this->m_current_wallet_name, tickers, false, m_coins_informations, m_coin_cfg_mutex); + }); }; SPDLOG_DEBUG("starting async enabling coin"); @@ -727,9 +747,15 @@ namespace atomic_dex functor(btc_kmd_batch, g_default_coins); } - if (not batch_array.empty()) + if (!batch_array.empty()) { - functor(batch_array, copy_tickers); + for (std::size_t idx = 0; idx < batch_array.size(); ++idx) + { + nlohmann::json single_batch = nlohmann::json::array(); + single_batch.push_back(batch_array.at(idx)); + functor(single_batch, {copy_tickers[idx]}); + } + // functor(batch_array, copy_tickers); } } @@ -773,7 +799,7 @@ namespace atomic_dex nlohmann::json mm2_service::prepare_batch_orderbook(bool is_a_reset) { - //SPDLOG_INFO("is_a_reset: {}", is_a_reset); + // SPDLOG_INFO("is_a_reset: {}", is_a_reset); auto&& [base, rel] = m_synchronized_ticker_pair.get(); if (rel.empty()) return nlohmann::json::array(); @@ -794,7 +820,7 @@ namespace atomic_dex generate_req("min_trading_vol", t_min_volume_request{.coin = base}); generate_req("min_trading_vol", t_min_volume_request{.coin = rel}); } - //SPDLOG_INFO("batch max: {}", batch.dump(4)); + // SPDLOG_INFO("batch max: {}", batch.dump(4)); return batch; } @@ -805,12 +831,12 @@ namespace atomic_dex if (batch.empty()) return; // SPDLOG_DEBUG("batch request: {}", batch.dump(4)); - //auto&& [base, rel] = m_synchronized_ticker_pair.get(); + // auto&& [base, rel] = m_synchronized_ticker_pair.get(); auto answer_functor = [this, is_a_reset](web::http::http_response resp) { auto&& [base, rel] = m_synchronized_ticker_pair.get(); - auto answer = ::mm2::api::basic_batch_answer(resp); + auto answer = ::mm2::api::basic_batch_answer(resp); if (answer.is_array()) { auto orderbook_answer = ::mm2::api::rpc_process_answer_batch(answer[0], "orderbook"); @@ -824,9 +850,9 @@ namespace atomic_dex { this->m_synchronized_max_taker_vol->first = base_max_taker_vol_answer.result.value(); } - //t_float_50 base_res = t_float_50(this->m_synchronized_max_taker_vol->first.decimal) * m_balance_factor; - //this->m_synchronized_max_taker_vol->first.decimal = base_res.str(8); - //SPDLOG_INFO("max_taker_vol: {}", answer[1].dump(4)); + // t_float_50 base_res = t_float_50(this->m_synchronized_max_taker_vol->first.decimal) * m_balance_factor; + // this->m_synchronized_max_taker_vol->first.decimal = base_res.str(8); + // SPDLOG_INFO("max_taker_vol: {}", answer[1].dump(4)); } auto rel_max_taker_vol_answer = ::mm2::api::rpc_process_answer_batch<::mm2::api::max_taker_vol_answer>(answer[2], "max_taker_vol"); @@ -836,8 +862,8 @@ namespace atomic_dex { this->m_synchronized_max_taker_vol->second = rel_max_taker_vol_answer.result.value(); } - //t_float_50 rel_res = t_float_50(this->m_synchronized_max_taker_vol->second.decimal) * m_balance_factor; - //this->m_synchronized_max_taker_vol->second.decimal = rel_res.str(8); + // t_float_50 rel_res = t_float_50(this->m_synchronized_max_taker_vol->second.decimal) * + // m_balance_factor; this->m_synchronized_max_taker_vol->second.decimal = rel_res.str(8); } auto base_min_taker_vol_answer = ::mm2::api::rpc_process_answer_batch(answer[3], "min_trading_vol"); @@ -881,11 +907,55 @@ namespace atomic_dex } void - mm2_service::fetch_infos_thread(bool is_a_refresh, bool only_tx) + mm2_service::fetch_single_balance(const coin_config& cfg_infos) { - // SPDLOG_INFO("fetch_infos_thread"); + nlohmann::json batch_array = nlohmann::json::array(); + if (is_pin_cfg_enabled()) + { + std::shared_lock lock(m_balance_mutex); ///< shared_lock + if (m_balance_informations.find(cfg_infos.ticker) != m_balance_informations.cend()) + { + return; + } + } + t_balance_request balance_request{.coin = cfg_infos.ticker}; + nlohmann::json j = ::mm2::api::template_request("my_balance"); + ::mm2::api::to_json(j, balance_request); + batch_array.push_back(j); + auto answer_functor = [this](web::http::http_response resp) + { + try + { + auto answers = ::mm2::api::basic_batch_answer(resp); + if (!answers.contains("error") && !answers[0].contains("error")) + { + this->process_balance_answer(answers[0]); + } + } + catch (const std::exception& error) + { + SPDLOG_ERROR("exception in fetch_single_balance: {}", error.what()); + } + }; + auto error_functor = [this, batch = batch_array](pplx::task previous_task) + { this->handle_exception_pplx_task(previous_task, "fetch_single_balance", batch); }; + m_mm2_client.async_rpc_batch_standalone(batch_array).then(answer_functor).then(error_functor); + } - batch_balance_and_tx(is_a_refresh, {}, false, only_tx); + void + mm2_service::fetch_infos_thread(bool is_a_refresh, bool only_tx) + { + SPDLOG_INFO("fetch_infos_thread"); + if (only_tx) + { + batch_balance_and_tx(is_a_refresh, {}, false, only_tx); + } + else + { + const auto& enabled_coins = get_enabled_coins(); + for (auto&& coin: enabled_coins) { fetch_single_balance(coin); } + batch_balance_and_tx(is_a_refresh, {}, false, true); + } } void @@ -913,7 +983,6 @@ namespace atomic_dex ofs.close(); QProcessEnvironment env = QProcessEnvironment::systemEnvironment(); - ; env.insert("MM_CONF_PATH", std_path_to_qstring(mm2_cfg_path)); env.insert("MM_LOG", std_path_to_qstring(utils::get_mm2_atomic_dex_current_log_file())); env.insert("MM_COINS_PATH", std_path_to_qstring((utils::get_current_configs_path() / "coins.json"))); @@ -1103,14 +1172,14 @@ namespace atomic_dex } //! Post Metrics - SPDLOG_INFO( + /*SPDLOG_INFO( "Metrics -> [total_swaps: {}, " "active_swaps: {}, " "nb_orders: {}, " "nb_pages: {}, " "current_page: {}, " "total_finished_swaps: {}]", - result.total_swaps, result.active_swaps, result.nb_orders, result.nb_pages, result.current_page, result.total_finished_swaps); + result.total_swaps, result.active_swaps, result.nb_orders, result.nb_pages, result.current_page, result.total_finished_swaps);*/ //! Compute everything m_orders_and_swaps = std::move(result); @@ -1456,10 +1525,12 @@ namespace atomic_dex t_float_50 result = t_float_50(answer_r.balance) * m_balance_factor; answer_r.balance = result.str(8, std::ios_base::fixed); + //auto copy_coin = answer_r.coin; { std::unique_lock lock(m_balance_mutex); m_balance_informations[answer_r.coin] = std::move(answer_r); } + //m_system_manager.get_system().get_portfolio()->update_balance_values({copy_coin}); } mm2_client& @@ -1673,16 +1744,17 @@ namespace atomic_dex } catch (const std::exception& e) { - if (std::string(e.what()).find("mutex lock failed") != std::string::npos) { + if (std::string(e.what()).find("mutex lock failed") != std::string::npos) + { return; } for (auto&& cur: request) cur["userpass"] = ""; SPDLOG_ERROR("pplx task error: {} from: {}, request: {}", e.what(), from, request.dump(4)); - this->dispatcher_.trigger(from, e.what()); + //this->dispatcher_.trigger(from, e.what()); -#if defined(linux) || defined(__APPLE__) - SPDLOG_ERROR("stacktrace: {}", boost::stacktrace::to_string(boost::stacktrace::stacktrace())); -#endif +//#if defined(linux) || defined(__APPLE__) + //SPDLOG_ERROR("stacktrace: {}", boost::stacktrace::to_string(boost::stacktrace::stacktrace())); +//#endif if (std::string(e.what()).find("Failed to read HTTP status line") != std::string::npos || std::string(e.what()).find("WinHttpReceiveResponse: 12002: The operation timed out") != std::string::npos) { diff --git a/src/core/atomicdex/services/mm2/mm2.service.hpp b/src/core/atomicdex/services/mm2/mm2.service.hpp index c7d280494a..654a4b7fbd 100644 --- a/src/core/atomicdex/services/mm2/mm2.service.hpp +++ b/src/core/atomicdex/services/mm2/mm2.service.hpp @@ -135,6 +135,7 @@ namespace atomic_dex void process_balance_answer(const nlohmann::json& answer); void process_tx_answer(const nlohmann::json& answer_json); void process_tx_tokenscan(const std::string& ticker, bool is_a_refresh); + void fetch_single_balance(const coin_config& cfg_infos); //! std::pair process_batch_enable_answer(const nlohmann::json& answer); diff --git a/src/core/atomicdex/services/price/coingecko/coingecko.provider.cpp b/src/core/atomicdex/services/price/coingecko/coingecko.provider.cpp index b225475f6d..f5414da671 100644 --- a/src/core/atomicdex/services/price/coingecko/coingecko.provider.cpp +++ b/src/core/atomicdex/services/price/coingecko/coingecko.provider.cpp @@ -43,14 +43,20 @@ namespace atomic_dex void coingecko_provider::on_mm2_started([[maybe_unused]] const mm2_started& evt) { + SPDLOG_INFO("on_mm2_started"); update_ticker_and_provider(); } void coingecko_provider::on_coin_enabled(const coin_enabled& evt) { + SPDLOG_INFO("coin_enabled: {}", fmt::join(evt.tickers, ", ")); dispatcher_.trigger(evt.tickers); - this->update_ticker_and_provider(); + if (evt.tickers.size() > 1) + { + SPDLOG_INFO("on_coin_enabled size() > 1"); + this->update_ticker_and_provider(); + } } void @@ -69,9 +75,16 @@ namespace atomic_dex coingecko_provider::update_ticker_and_provider() { SPDLOG_INFO("update_ticker_and_provider"); - const auto coins = this->m_system_manager.get_system().get_global_cfg()->get_model_data(); - auto&& [ids, registry] = coingecko::api::from_enabled_coins(coins); - internal_update(ids, registry); + if (m_system_manager.has_system() && m_system_manager.get_system().is_mm2_running()) + { + const auto coins = this->m_system_manager.get_system().get_global_cfg()->get_model_data(); + auto&& [ids, registry] = coingecko::api::from_enabled_coins(coins); + internal_update(ids, registry); + } + else + { + SPDLOG_WARN("mm2 not running - skipping update_ticker_and_provider"); + } } std::string @@ -137,6 +150,11 @@ namespace atomic_dex t_coingecko_market_infos_answer answer; coingecko::api::from_json(j, answer, registry); std::size_t nb_coins = 0; + /*if (answer.raw_result.empty()) + { + SPDLOG_ERROR("Coingecko answer not available - skipping"); + return; + }*/ { std::unique_lock lock(m_market_mutex); if (should_move) ///< Override diff --git a/src/core/atomicdex/services/price/global.provider.cpp b/src/core/atomicdex/services/price/global.provider.cpp index d411856067..b31752ab09 100644 --- a/src/core/atomicdex/services/price/global.provider.cpp +++ b/src/core/atomicdex/services/price/global.provider.cpp @@ -18,7 +18,7 @@ #include "atomicdex/services/price/global.provider.hpp" #include "atomicdex/api/coinpaprika/coinpaprika.hpp" #include "atomicdex/pages/qt.settings.page.hpp" -#include "atomicdex/services/price/coingecko/coingecko.provider.hpp" +#include "atomicdex/services/price/komodo_prices/komodo.prices.provider.hpp" #include "atomicdex/services/price/oracle/band.provider.hpp" namespace @@ -39,6 +39,7 @@ namespace web::http::http_request req; req.set_method(web::http::methods::GET); req.set_request_uri(FROM_STD_STR("api/v1/usd_rates")); + //SPDLOG_INFO("req: {}", TO_STD_STR(req.to_string())); return g_openrates_client->request(req, g_token_source.get_token()); } @@ -153,7 +154,7 @@ namespace atomic_dex } if (with_update_providers) { - this->m_system_manager.get_system().update_ticker_and_provider(); + //this->m_system_manager.get_system().update_ticker_and_provider(); } }) .then(error_functor); @@ -187,20 +188,24 @@ namespace atomic_dex std::string global_price_service::get_rate_conversion(const std::string& fiat, const std::string& ticker_in, bool adjusted) const { - std::string ticker = atomic_dex::utils::retrieve_main_ticker(ticker_in); + if (fiat == utils::retrieve_main_ticker(ticker_in)) + { + return "1"; + } + std::string ticker = ticker_in; try { //! FIXME: fix zatJum crash report, frontend QML try to retrieve price before program is even launched if (ticker.empty()) return "0"; - auto& coingecko = m_system_manager.get_system(); + auto& provider = m_system_manager.get_system(); auto& band_service = m_system_manager.get_system(); std::string current_price = band_service.retrieve_if_this_ticker_supported(ticker); const bool is_oracle_ready = band_service.is_oracle_ready(); if (current_price.empty()) { - current_price = coingecko.get_rate_conversion(ticker); + current_price = provider.get_rate_conversion(ticker); if (!is_this_currency_a_fiat(m_cfg, fiat)) { t_float_50 rate(1); @@ -264,12 +269,6 @@ namespace atomic_dex std::string global_price_service::get_price_as_currency_from_tx(const std::string& currency, const std::string& ticker, const tx_infos& tx) const { - auto& mm2_instance = m_system_manager.get_system(); - - if (mm2_instance.get_coin_info(ticker).coingecko_id == "test-coin") - { - return "0.00"; - } const auto amount = tx.am_i_sender ? tx.my_balance_change.substr(1) : tx.my_balance_change; const auto current_price = get_rate_conversion(currency, ticker); if (current_price == "0.00") @@ -292,11 +291,6 @@ namespace atomic_dex for (auto&& current_coin: coins) { - if (current_coin.coingecko_id == "test-coin") - { - continue; - } - current_price = get_price_in_fiat(fiat, current_coin.ticker, ec, true); if (ec) @@ -336,11 +330,6 @@ namespace atomic_dex auto& mm2_instance = m_system_manager.get_system(); const auto ticker_infos = mm2_instance.get_coin_info(ticker); - if (ticker_infos.coingecko_id == "test-coin") - { - return "0.00"; - } - const auto current_price = get_rate_conversion(currency, ticker); if (current_price == "0.00") @@ -364,11 +353,6 @@ namespace atomic_dex { auto& mm2_instance = m_system_manager.get_system(); - if (mm2_instance.get_coin_info(ticker).coingecko_id == "test-coin") - { - return "0.00"; - } - if (m_supported_fiat_registry.count(fiat) == 0u) { ec = dextop_error::invalid_fiat_for_rate_conversion; @@ -388,7 +372,7 @@ namespace atomic_dex if (t_ec) { ec = t_ec; - SPDLOG_ERROR("my_balance error: {}", t_ec.message()); + //SPDLOG_ERROR("my_balance error: {} {}", t_ec.message(), ticker); return "0.00"; } diff --git a/src/core/atomicdex/services/price/komodo_prices/komodo.prices.provider.cpp b/src/core/atomicdex/services/price/komodo_prices/komodo.prices.provider.cpp new file mode 100644 index 0000000000..48a425ad8e --- /dev/null +++ b/src/core/atomicdex/services/price/komodo_prices/komodo.prices.provider.cpp @@ -0,0 +1,142 @@ +//! Deps +#include + +//! Project Headers +#include "atomicdex/events/events.hpp" +#include "atomicdex/services/price/komodo_prices/komodo.prices.provider.hpp" + +//! Constructor +namespace atomic_dex +{ + komodo_prices_provider::komodo_prices_provider(entt::registry& registry) : system(registry) + { + SPDLOG_INFO("komodo_prices_provider created"); + m_clock = std::chrono::high_resolution_clock::now(); + process_update(); + } +} // namespace atomic_dex + +//! Private functions +namespace atomic_dex +{ + komodo_prices::api::komodo_ticker_infos + komodo_prices_provider::get_info_answer(const std::string& ticker) const + { + std::shared_lock lock(m_market_mutex); + // SPDLOG_INFO("Looking for ticker: {}", ticker); + const auto it = m_market_registry.find(ticker); + return it != m_market_registry.cend() ? it->second : komodo_prices::api::komodo_ticker_infos{.ticker = ticker}; + } + + void + komodo_prices_provider::process_update() + { + SPDLOG_INFO("komodo price service tick loop"); + + auto answer_functor = [this](web::http::http_response resp) + { + std::string body = TO_STD_STR(resp.extract_string(true).get()); + if (resp.status_code() == 200) + { + nlohmann::json j = nlohmann::json::parse(body); + t_market_registry answer; + answer = j.get(); + { + std::unique_lock lock(m_market_mutex); + m_market_registry = std::move(answer); + SPDLOG_INFO("komodo price registry size: {}", m_market_registry.size()); + } + dispatcher_.trigger(""); + } + else + { + SPDLOG_ERROR("Error during the rpc call to komodo price provider: {}", body); + } + }; + + auto error_functor = [](pplx::task previous_task) + { + try + { + previous_task.wait(); + } + catch (const std::exception& e) + { + SPDLOG_ERROR("error occured when fetching price: {}", e.what()); + }; + }; + + atomic_dex::komodo_prices::api::async_market_infos().then(answer_functor).then(error_functor); + } +} // namespace atomic_dex + +//! Public Functions +namespace atomic_dex +{ + void + komodo_prices_provider::update() + { + using namespace std::chrono_literals; + + const auto now = std::chrono::high_resolution_clock::now(); + const auto s = std::chrono::duration_cast(now - m_clock); + + if (s >= 30s) + { + process_update(); + m_clock = std::chrono::high_resolution_clock::now(); + } + } + + std::string + komodo_prices_provider::get_total_volume(const std::string& ticker) const + { + return get_info_answer(ticker).volume24_h; + } + + nlohmann::json + komodo_prices_provider::get_ticker_historical(const std::string& ticker) const + { + nlohmann::json j = get_info_answer(ticker).sparkline_7_d; + if (j.is_null()) + { + j = nlohmann::json::array(); + } + return j; + } + + std::string + komodo_prices_provider::get_change_24h(const std::string& ticker) const + { + return get_info_answer(ticker).change_24_h; + } + + std::string + komodo_prices_provider::get_rate_conversion(const std::string& ticker) const + { + return get_info_answer(ticker).last_price; + } + + std::string + komodo_prices_provider::get_price_provider(const std::string& ticker) const + { + auto provider = get_info_answer(ticker).price_provider; + switch (provider) + { + case komodo_prices::api::provider::binance: + return "binance"; + case komodo_prices::api::provider::coingecko: + return "coingecko"; + case komodo_prices::api::provider::coinpaprika: + return "coinpaprika"; + default: + return "unknown"; + } + } + + int64_t + komodo_prices_provider::get_last_price_timestamp(const std::string& ticker) const + { + return get_info_answer(ticker).last_updated_timestamp; + } +} // namespace atomic_dex \ No newline at end of file diff --git a/src/core/atomicdex/services/price/komodo_prices/komodo.prices.provider.hpp b/src/core/atomicdex/services/price/komodo_prices/komodo.prices.provider.hpp new file mode 100644 index 0000000000..bc4ea13e1d --- /dev/null +++ b/src/core/atomicdex/services/price/komodo_prices/komodo.prices.provider.hpp @@ -0,0 +1,60 @@ +#pragma once + +//! STD +#include + +//! Deps +#include + +//! Project Headers +#include "atomicdex/api/komodo_prices/komodo.prices.hpp" + +namespace atomic_dex +{ + class komodo_prices_provider final : public ag::ecs::pre_update_system + { + //! private type definition + using t_market_registry = komodo_prices::api::t_komodo_tickers_price_registry; + using t_komodo_prices_time_point = std::chrono::high_resolution_clock::time_point; + + //! private fields + t_market_registry m_market_registry; + mutable std::shared_mutex m_market_mutex; + t_komodo_prices_time_point m_clock; + + //! private functions + void process_update(); + komodo_prices::api::komodo_ticker_infos get_info_answer(const std::string& ticker) const; + + public: + //! Constructor + komodo_prices_provider(entt::registry& registry); + + //! Destructor + ~komodo_prices_provider() final = default; + + //! Override ag::system functions + void update() final; + + //! Get the rate conversion for the given ticker. + [[nodiscard]] std::string get_rate_conversion(const std::string& ticker) const; + ; + + //! Get the ticker informations. + [[nodiscard]] std::string get_change_24h(const std::string& ticker) const; + + //! Get the volume information + [[nodiscard]] std::string get_total_volume(const std::string& ticker) const; + + //! Get the ticker informations. + [[nodiscard]] nlohmann::json get_ticker_historical(const std::string& ticker) const; + + //! Get the provider informations for a given ticker. + [[nodiscard]] std::string get_price_provider(const std::string& ticker) const; + + //! Get the last timestamp for a given ticker. + [[nodiscard]] int64_t get_last_price_timestamp(const std::string& ticker) const; + }; +} // namespace atomic_dex + +REFL_AUTO(type(atomic_dex::komodo_prices_provider)) \ No newline at end of file diff --git a/src/core/atomicdex/services/price/oracle/band.provider.cpp b/src/core/atomicdex/services/price/oracle/band.provider.cpp index 3ea9d68624..94724b861c 100644 --- a/src/core/atomicdex/services/price/oracle/band.provider.cpp +++ b/src/core/atomicdex/services/price/oracle/band.provider.cpp @@ -62,7 +62,7 @@ namespace atomic_dex from_json(j, result); this->m_oracle_price_result = result; using namespace std::chrono_literals; - auto last_oracle_timestamp = result.band_oracle_data.at("BTC").timestamp; + auto last_oracle_timestamp = result.band_oracle_data.at("BAND").timestamp; const auto now = std::chrono::system_clock::now(); const auto last_oracle_timestamp_std = std::chrono::system_clock::from_time_t(last_oracle_timestamp); const auto s = std::chrono::duration_cast(now - last_oracle_timestamp_std); diff --git a/src/core/atomicdex/services/price/oracle/band.provider.hpp b/src/core/atomicdex/services/price/oracle/band.provider.hpp index 3f73ebf55d..6f694da823 100644 --- a/src/core/atomicdex/services/price/oracle/band.provider.hpp +++ b/src/core/atomicdex/services/price/oracle/band.provider.hpp @@ -30,7 +30,7 @@ namespace atomic_dex t_update_time_point m_update_clock; t_oracle_price_synchronized m_oracle_price_result; std::atomic_bool m_oracle_ready{false}; - std::vector m_supported_tickers{"BTC", "ETH", "DAI", "BAT", "KMD", "BCH", "LTC", "ZEC", "XZC", "RVN", "DOGE", "DGB", "SUSHI", "LINK", "BNB", "XTZ", "USDC", "YFI", "DASH", "BAL", "YFII", "BUSD", "CRV", "WBTC"}; + std::vector m_supported_tickers{"BAND"}; void fetch_oracle() ; pplx::task async_fetch_oracle_result() ; diff --git a/src/core/atomicdex/services/update/self.update.service.cpp b/src/core/atomicdex/services/update/self.update.service.cpp index f94c5074ab..9d33f780ef 100644 --- a/src/core/atomicdex/services/update/self.update.service.cpp +++ b/src/core/atomicdex/services/update/self.update.service.cpp @@ -36,7 +36,9 @@ namespace atomic_dex remove_update_files(); dispatcher_.sink().connect<&self_update_service::on_download_release_finished>(*this); dispatcher_.sink().connect<&self_update_service::on_download_release_progressed>(*this); +#if !defined (Q_OS_WINDOWS) fetch_last_release_info(); +#endif } void diff --git a/src/core/atomicdex/utilities/qt.utilities.cpp b/src/core/atomicdex/utilities/qt.utilities.cpp index 392e1b65dc..74061e94c0 100644 --- a/src/core/atomicdex/utilities/qt.utilities.cpp +++ b/src/core/atomicdex/utilities/qt.utilities.cpp @@ -50,13 +50,13 @@ namespace atomic_dex QString retrieve_change_24h( - const atomic_dex::coingecko_provider& coingecko, const atomic_dex::coin_config& coin, const atomic_dex::cfg& config, + const atomic_dex::komodo_prices_provider& provider, const atomic_dex::coin_config& coin, const atomic_dex::cfg& config, [[maybe_unused]] const ag::ecs::system_manager& system_manager) { QString change_24h = "0"; if (is_this_currency_a_fiat(config, config.current_currency)) { - change_24h = QString::fromStdString(coingecko.get_change_24h(coin.ticker)); + change_24h = QString::fromStdString(provider.get_change_24h(coin.ticker)); } return change_24h; } diff --git a/src/core/atomicdex/utilities/qt.utilities.hpp b/src/core/atomicdex/utilities/qt.utilities.hpp index 1630f50b6a..036c8c0df7 100644 --- a/src/core/atomicdex/utilities/qt.utilities.hpp +++ b/src/core/atomicdex/utilities/qt.utilities.hpp @@ -29,7 +29,7 @@ #include "atomicdex/config/app.cfg.hpp" #include "atomicdex/config/coins.cfg.hpp" #include "atomicdex/config/wallet.cfg.hpp" -#include "atomicdex/services/price/coingecko/coingecko.provider.hpp" +#include "atomicdex/services/price/komodo_prices/komodo.prices.provider.hpp" namespace atomic_dex { @@ -51,7 +51,7 @@ namespace atomic_dex QJsonArray nlohmann_json_array_to_qt_json_array(const nlohmann::json& j); QJsonObject nlohmann_json_object_to_qt_json_object(const nlohmann::json& j); QString retrieve_change_24h( - const atomic_dex::coingecko_provider& coingecko, const atomic_dex::coin_config& coin, const atomic_dex::cfg& config, + const atomic_dex::komodo_prices_provider& provider, const atomic_dex::coin_config& coin, const atomic_dex::cfg& config, const ag::ecs::system_manager& system_manager); [[nodiscard]] QString diff --git a/src/core/atomicdex/version/version.hpp b/src/core/atomicdex/version/version.hpp index 10b39ffc24..a1ab6d1998 100644 --- a/src/core/atomicdex/version/version.hpp +++ b/src/core/atomicdex/version/version.hpp @@ -21,24 +21,24 @@ namespace atomic_dex constexpr const char* get_version() { - return "0.5.0-beta"; + return "0.5.1-beta"; } constexpr int get_num_version() noexcept { - return 50; + return 51; } constexpr const char* get_raw_version() { - return "0.5.0"; + return "0.5.1"; } constexpr const char* get_precedent_raw_version() { - return "0.4.3"; + return "0.5.0"; } } // namespace atomic_dex diff --git a/src/tests/api/komodo_prices/komodo.prices.tests.cpp b/src/tests/api/komodo_prices/komodo.prices.tests.cpp new file mode 100644 index 0000000000..e267e5775f --- /dev/null +++ b/src/tests/api/komodo_prices/komodo.prices.tests.cpp @@ -0,0 +1,22 @@ +// +// Created by Sztergbaum Roman on 10/09/2021. +// + +#include "atomicdex/pch.hpp" + +//! STD +#include + +//! Deps +#include "doctest/doctest.h" + +//! Project Headers +#include "atomicdex/api/komodo_prices/komodo.prices.hpp" + +TEST_CASE("komodo prices api test") +{ + auto resp = atomic_dex::komodo_prices::api::async_market_infos().get(); + std::string body = TO_STD_STR(resp.extract_string(true).get()); + CHECK_EQ(resp.status_code(), 200); + CHECK_FALSE(body.empty()); +} \ No newline at end of file diff --git a/src/tests/atomic.dex.tests.hpp b/src/tests/atomic.dex.tests.hpp index b16f685426..17ae488894 100644 --- a/src/tests/atomic.dex.tests.hpp +++ b/src/tests/atomic.dex.tests.hpp @@ -34,7 +34,7 @@ struct tests_context : public antara::gaming::world::app public: void - on_coin_enabled(const atomic_dex::coin_enabled& evt) + on_coin_initialized(const atomic_dex::coin_fully_initialized& evt) { if (std::any_of(begin(evt.tickers), end(evt.tickers), [this](auto&& item) { return item == this->m_extra_coins[0]; })) { @@ -52,7 +52,7 @@ struct tests_context : public antara::gaming::world::app tests_context([[maybe_unused]] char** argv) { #if !defined(WIN32) && !defined(_WIN32) - this->dispatcher_.sink().connect<&tests_context::on_coin_enabled>(*this); + this->dispatcher_.sink().connect<&tests_context::on_coin_initialized>(*this); //! Creates mm2 service. auto& mm2 = system_manager_.create_system(system_manager_); diff --git a/vcpkg.json b/vcpkg.json index dee7d0c983..cc767caea8 100644 --- a/vcpkg.json +++ b/vcpkg.json @@ -1,6 +1,6 @@ { "name": "atomicdex-desktop", - "version-string": "0.5.0", + "version-string": "0.5.1", "dependencies": [ "entt", "boost-multiprecision",