Following on from here: Can I host or wrap the HTTP application for CompleteFTP elsewhere?
I have 2 issues:
1) To access the index.jss page at the CompleteFTP HTTP server, a redirect is invoked back to /Login
This means my application is making the requests but as there is currently no logged in user the 'original' login page is being used.
I have noted that when using the CompleteFTP HTTP server directly, both the 'original' login and the one from the angular filemanager have to be completed.
2) By establishing a session directly and logging in, I can bypass the problem above for (1) and the index.jss calls begin to work:
for example the first response looks like:
{
"id": 0,
"result": {
"serverName": "Server 1",
"siteName": "Default Site",
"welcomeMessage": "Complete FTP server",
"userName": "Test",
"homeFolder": "/Home/Test",
"sharingEnabled": true
}
}
...making a new folder results in an index.jss call that responds with:
{
"id": 0,
"result": {
"canWrite": true,
"canRemove": true,
"canRename": true,
"files": [
{
"name": "NewFolder",
"rights": "drwxr-xr-x",
"size": 0,
"date": "Tue, 04 Dec 2018 09:58:32 UTC",
"type": "dir"
},
{
"name": "NewTest",
"rights": "drwxr-xr-x",
"size": 0,
"date": "Tue, 04 Dec 2018 11:19:41 UTC",
"type": "dir"
}
]
}
}
...all this looks great!
The 'rest' of the app that I am trying to host 'locally' (at the moment, just the clone of the completeftp-filemanager repo with url rewrite/reverse proxy to send index.jss to the CompleteFTP server) throws javascript errors and displays nothing:
TypeError: Object doesn't support property or method 'map'
at Anonymous function (http://localhost:8080/dist/angular-filemanager.min.js:3:12523)
at Anonymous function (http://localhost:8080/bower_components/angular/angular.min.js:136:450)
at m.prototype.$digest (http://localhost:8080/bower_components/angular/angular.min.js:147:403)
at m.prototype.$apply (http://localhost:8080/bower_components/angular/angular.min.js:151:111)
at l (http://localhost:8080/bower_components/angular/angular.min.js:103:84)
at s (http://localhost:8080/bower_components/angular/angular.min.js:108:107)
at y.onload (http://localhost:8080/bower_components/angular/angular.min.js:109:23) Possibly unhandled rejection: {}