mirror of
https://git.wownero.com/wowlet/wowlet.git
synced 2024-08-15 01:03:14 +00:00
update onion URL to new server, fix forum listing
This commit is contained in:
parent
24ff2b7120
commit
9c58913ee2
6 changed files with 15 additions and 14 deletions
|
@ -246,7 +246,8 @@ target_link_libraries(wowlet PUBLIC
|
|||
${OPENSSL_LIBRARIES}
|
||||
${CMAKE_DL_LIBS}
|
||||
${Iconv_LIBRARIES}
|
||||
/usr/local/lib/libunbound.a
|
||||
${UNBOUND_LIBRARIES}
|
||||
# /usr/local/lib/libunbound.a
|
||||
${EXTRA_LIBRARIES})
|
||||
|
||||
# Link Qt libraries
|
||||
|
|
|
@ -554,10 +554,10 @@ void AppContext::onWSForum(const QJsonArray& forum_data) {
|
|||
for (auto &&entry: forum_data) {
|
||||
auto obj = entry.toObject();
|
||||
auto forumPost = new ForumPost(
|
||||
obj.value("title").toString(),
|
||||
obj.value("author").toString(),
|
||||
obj.value("thread").toString(),
|
||||
obj.value("member_name").toString(),
|
||||
obj.value("permalink").toString(),
|
||||
obj.value("comments").toInt());
|
||||
obj.value("member_name").toString());
|
||||
QSharedPointer<ForumPost> r = QSharedPointer<ForumPost>(forumPost);
|
||||
l.append(r);
|
||||
}
|
||||
|
|
|
@ -67,7 +67,7 @@ public:
|
|||
QString tmpTxDescription;
|
||||
|
||||
// https://git.wownero.com/wowlet/wowlet-backend/
|
||||
QString backendHost = "6wku2m4zrv6j666crlo7lzofv6ud6enzllyhou3ijeigpukymi37caad.onion";
|
||||
QString backendHost = "l3hkasj5nnrh24yzj4acj5dgqlscq56o5xjvvqsftj55fkonqly5aiid.onion";
|
||||
unsigned int backendPort = 80;
|
||||
bool backendTLS = false;
|
||||
QString backendWSUrl;
|
||||
|
|
|
@ -56,15 +56,15 @@ QVariant ForumModel::data(const QModelIndex &index, int role) const
|
|||
return post->title;
|
||||
case Author:
|
||||
return post->author;
|
||||
case Comments:
|
||||
return QString::number(post->comments);
|
||||
case DateAdded:
|
||||
return post->date_added;
|
||||
default:
|
||||
return QVariant();
|
||||
}
|
||||
}
|
||||
else if (role == Qt::TextAlignmentRole) {
|
||||
switch(index.column()) {
|
||||
case Comments:
|
||||
case DateAdded:
|
||||
return Qt::AlignRight;
|
||||
default:
|
||||
return QVariant();
|
||||
|
@ -85,8 +85,8 @@ QVariant ForumModel::headerData(int section, Qt::Orientation orientation, int ro
|
|||
return QString("Forum Post");
|
||||
case Author:
|
||||
return QString("Author");
|
||||
case Comments:
|
||||
return QString("Comments");
|
||||
case DateAdded:
|
||||
return QString("Date");
|
||||
default:
|
||||
return QVariant();
|
||||
}
|
||||
|
|
|
@ -18,7 +18,7 @@ public:
|
|||
{
|
||||
Title = 0,
|
||||
Author,
|
||||
Comments,
|
||||
DateAdded,
|
||||
COUNT
|
||||
};
|
||||
|
||||
|
|
|
@ -7,13 +7,13 @@
|
|||
#include <QString>
|
||||
|
||||
struct ForumPost {
|
||||
ForumPost(const QString &title, const QString &author, const QString &permalink, int comments)
|
||||
: title(title), author(author), permalink(permalink), comments(comments){};
|
||||
ForumPost(const QString &title, const QString &author, const QString &permalink, const QString date_added)
|
||||
: title(title), author(author), permalink(permalink), date_added(date_added){};
|
||||
|
||||
QString title;
|
||||
QString author;
|
||||
QString permalink;
|
||||
int comments;
|
||||
QString date_added;
|
||||
};
|
||||
|
||||
#endif //WOWLET_FORUMPOST_H
|
||||
|
|
Loading…
Reference in a new issue