mirror of
https://github.com/feather-wallet/feather.git
synced 2024-12-22 19:49:28 +00:00
send: on failure to commit allow manual rebroadcast
This commit is contained in:
parent
efae6ae70f
commit
68026ee29b
1 changed files with 18 additions and 2 deletions
|
@ -969,8 +969,24 @@ void MainWindow::onTransactionCommitted(bool success, PendingTransaction *tx, co
|
||||||
m_wallet->setForceKeyImageSync(true);
|
m_wallet->setForceKeyImageSync(true);
|
||||||
}
|
}
|
||||||
if (error.contains("no connection to daemon")) {
|
if (error.contains("no connection to daemon")) {
|
||||||
auto button = QMessageBox::question(this, "Unable to send transaction", "No connection to node. Retry sending transaction?");
|
QMessageBox box(this);
|
||||||
if (button == QMessageBox::Yes) {
|
box.setWindowTitle("Question");
|
||||||
|
box.setText("Unable to send transaction");
|
||||||
|
box.setInformativeText("No connection to node. Retry sending transaction?");
|
||||||
|
QPushButton *manual = box.addButton("Broadcast manually", QMessageBox::HelpRole);
|
||||||
|
box.addButton(QMessageBox::No);
|
||||||
|
box.addButton(QMessageBox::Yes);
|
||||||
|
|
||||||
|
box.exec();
|
||||||
|
|
||||||
|
if (box.clickedButton() == manual) {
|
||||||
|
if (txid.empty()) {
|
||||||
|
Utils::showError(this, "Unable to open tx broadcaster", "Cached transaction not found");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
this->onResendTransaction(txid[0]);
|
||||||
|
}
|
||||||
|
else if (box.result() == QMessageBox::Yes) {
|
||||||
m_wallet->commitTransaction(tx, m_wallet->tmpTxDescription);
|
m_wallet->commitTransaction(tx, m_wallet->tmpTxDescription);
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in a new issue