mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-10-01 02:35:48 -04:00
added Popularity/Date to Forum Details
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@1962 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
65b35e8c53
commit
628000480b
@ -29,6 +29,9 @@
|
||||
#include <QDateTime>
|
||||
|
||||
#include <sstream>
|
||||
#include <list>
|
||||
#include <iostream>
|
||||
#include <string>
|
||||
|
||||
|
||||
/* Define the format used for displaying the date and time */
|
||||
@ -86,7 +89,8 @@ void ForumDetails::showDetails(std::string mCurrForumId)
|
||||
void ForumDetails::loadDialog()
|
||||
{
|
||||
|
||||
std::list<ForumInfo>::iterator it;
|
||||
std::list<ForumInfo> forumList;
|
||||
std::list<ForumInfo>::iterator it;
|
||||
|
||||
if (!rsForums)
|
||||
{
|
||||
@ -96,23 +100,28 @@ void ForumDetails::loadDialog()
|
||||
ForumInfo fi;
|
||||
rsForums->getForumInfo(fId, fi);
|
||||
|
||||
rsForums->getForumList(forumList);
|
||||
|
||||
for(it = forumList.begin(); it != forumList.end(); it++)
|
||||
{
|
||||
|
||||
// Set Forum Name
|
||||
ui.nameline->setText(QString::fromStdWString(fi.forumName));
|
||||
|
||||
// Set Popularity
|
||||
/*{
|
||||
{
|
||||
std::ostringstream out;
|
||||
out << it->pop;
|
||||
ui.popline -> setText(QString::fromStdString(out.str()));
|
||||
}*/
|
||||
}
|
||||
|
||||
// Set Last Post Date
|
||||
/*{
|
||||
{
|
||||
QDateTime qtime;
|
||||
qtime.setTime_t(it->lastPost);
|
||||
QString timestamp = qtime.toString("yyyy-MM-dd hh:mm:ss");
|
||||
ui.postline -> setText(timestamp);
|
||||
}*/
|
||||
}
|
||||
|
||||
// Set Forum ID
|
||||
ui.IDline->setText(QString::fromStdString(fi.forumId));
|
||||
@ -120,6 +129,8 @@ void ForumDetails::loadDialog()
|
||||
// Set Forum Description
|
||||
ui.DescriptiontextEdit->setText(QString::fromStdWString(fi.forumDesc));
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void ForumDetails::applyDialog()
|
||||
|
Loading…
Reference in New Issue
Block a user