version 0.1.9
[fms.git] / src / http / pages / announceidentitypage.cpp
index 460302a..710904c 100644 (file)
@@ -84,6 +84,8 @@ const std::string AnnounceIdentityPage::GeneratePage(const std::string &method,
        content+="<tr><td colspan=\"4\"><center>Type the answers of a few puzzles</td></tr>";\r
        content+="<tr>";\r
 \r
+       //TODO if we are already inserting a solution for an identity - we shouldn't select any puzzles that are older than the one we are inserting\r
+\r
        date.SetToGMTime();\r
        date.Add(0,0,0,-1);\r
        SQLite3DB::Statement st=m_db->Prepare("SELECT UUID,Day,IdentityID FROM tblIntroductionPuzzleRequests WHERE UUID NOT IN (SELECT UUID FROM tblIdentityIntroductionInserts) AND UUID NOT IN (SELECT UUID FROM tblIntroductionPuzzleInserts) AND Day>='"+date.Format("%Y-%m-%d")+"' AND Found='true' ORDER BY IdentityID, Day DESC, RequestIndex DESC;");\r