Browse Source

Add confirmations to websockets RPC

pull/45/head
adityapk00 5 years ago
parent
commit
cf35953e69
  1. 4
      src/txtablemodel.cpp
  2. 1
      src/txtablemodel.h
  3. 3
      src/websockets.cpp
  4. 8
      zec-qt-wallet.pro

4
src/txtablemodel.cpp

@ -194,6 +194,10 @@ QString TxTableModel::getMemo(int row) const {
return modeldata->at(row).memo;
}
qint64 TxTableModel::getConfirmations(int row) const {
return modeldata->at(row).confirmations;
}
QString TxTableModel::getAddr(int row) const {
return modeldata->at(row).address.trimmed();
}

1
src/txtablemodel.h

@ -20,6 +20,7 @@ public:
QString getAddr(int row) const;
qint64 getDate(int row) const;
QString getType(int row) const;
qint64 getConfirmations(int row) const;
QString getAmt (int row) const;
bool exportToCsv(QString fileName) const;

3
src/websockets.cpp

@ -116,7 +116,8 @@ QJsonDocument AppDataServer::processGetTransactions(MainWindow* mainWindow) {
{"amount", model->getAmt(i)},
{"txid", model->getTxId(i)},
{"address", model->getAddr(i)},
{"memo", model->getMemo(i)}
{"memo", model->getMemo(i)},
{"confirmations", model->getConfirmations(i)}
});
}

8
zec-qt-wallet.pro

@ -109,8 +109,8 @@ qnx: target.path = /tmp/$${TARGET}/bin
else: unix:!android: target.path = /opt/$${TARGET}/bin
!isEmpty(target.path): INSTALLS += target
win32:CONFIG(release, debug|release): LIBS += -L$$PWD/res/ -lsodium
else:win32:CONFIG(debug, debug|release): LIBS += -L$$PWD/res/ -lsodiumd
win32:CONFIG(release, debug|release): LIBS += -L$$PWD/res/ -llibsodium
else:win32:CONFIG(debug, debug|release): LIBS += -L$$PWD/res/ -llibsodiumd
else:unix: LIBS += -L$$PWD/res/ -lsodium
INCLUDEPATH += $$PWD/res
@ -118,6 +118,6 @@ DEPENDPATH += $$PWD/res
win32-g++:CONFIG(release, debug|release): PRE_TARGETDEPS += $$PWD/res/liblibsodium.a
else:win32-g++:CONFIG(debug, debug|release): PRE_TARGETDEPS += $$PWD/res/liblibsodium.a
else:win32:!win32-g++:CONFIG(release, debug|release): PRE_TARGETDEPS += $$PWD/res/sodium.lib
else:win32:!win32-g++:CONFIG(debug, debug|release): PRE_TARGETDEPS += $$PWD/res/sodiumd.lib
else:win32:!win32-g++:CONFIG(release, debug|release): PRE_TARGETDEPS += $$PWD/res/libsodium.lib
else:win32:!win32-g++:CONFIG(debug, debug|release): PRE_TARGETDEPS += $$PWD/res/libsodiumd.lib
else:unix: PRE_TARGETDEPS += $$PWD/res/libsodium.a

Loading…
Cancel
Save