mirror of
https://github.com/YACReader/yacreader
synced 2025-05-28 03:10:27 -04:00
Implemented ReadingListsController.
This commit is contained in:
parent
85fba7e8f5
commit
6373d3660b
@ -1,5 +1,8 @@
|
||||
#include "readinglistscontroller.h"
|
||||
|
||||
#include "db_helper.h"
|
||||
#include "reading_list.h"
|
||||
|
||||
ReadingListsController::ReadingListsController()
|
||||
{
|
||||
|
||||
@ -20,5 +23,10 @@ void ReadingListsController::service(HttpRequest &request, HttpResponse &respons
|
||||
|
||||
void ReadingListsController::serviceContent(const int library, HttpResponse &response)
|
||||
{
|
||||
QList<ReadingList> readingLists = DBHelper::getReadingLists(library);
|
||||
|
||||
foreach(const ReadingList &item, readingLists)
|
||||
{
|
||||
response.write(QString("%1\t%2\t%3\r\n").arg(library).arg(item.getId()).arg(item.getName()).toUtf8());
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user