mirror of
https://github.com/f4exb/sdrangel.git
synced 2024-11-21 23:55:13 -05:00
Web API: resources and static file controller updates
This commit is contained in:
parent
cf2f099c37
commit
e7dc0f9b53
@ -143,6 +143,7 @@ void StaticFileController::service(QByteArray& path, HttpResponse& response)
|
||||
}
|
||||
else
|
||||
{
|
||||
qWarning("StaticFileController: File %s not found",qPrintable(file.fileName()));
|
||||
response.setStatus(404,"not found");
|
||||
response.write("404 not found",true);
|
||||
}
|
||||
|
@ -16,6 +16,8 @@
|
||||
// along with this program. If not, see <http://www.gnu.org/licenses/>. //
|
||||
///////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
//#include <QDirIterator>
|
||||
|
||||
#include "httpdocrootsettings.h"
|
||||
#include "webapirequestmapper.h"
|
||||
#include "SWGInstanceSummaryResponse.h"
|
||||
@ -71,6 +73,11 @@ void WebAPIRequestMapper::service(qtwebapp::HttpRequest& request, qtwebapp::Http
|
||||
}
|
||||
else
|
||||
{
|
||||
// QDirIterator it(":", QDirIterator::Subdirectories);
|
||||
// while (it.hasNext()) {
|
||||
// qDebug() << "WebAPIRequestMapper::service: " << it.next();
|
||||
// }
|
||||
|
||||
QByteArray path = "/index.html";
|
||||
m_staticFileController->service(path, response);
|
||||
//response.setStatus(404,"Not found");
|
||||
|
@ -5,7 +5,6 @@
|
||||
<file>microphone.png</file>
|
||||
<file>checkmark.png</file>
|
||||
<file>questionmark.png</file>
|
||||
<file>res.qrc</file>
|
||||
<file>export.png</file>
|
||||
<file>import.png</file>
|
||||
<file>compressed.png</file>
|
||||
|
Loading…
Reference in New Issue
Block a user