Our Products:   CompleteFTP  edtFTPnet/Free  edtFTPnet/PRO  edtFTPj/Free  edtFTPj/PRO
0 votes
51 views
asked in General by (220 points)

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: {}

1 Answer

+1 vote
answered by (44.2k points)
We'd forgotten to push the final changes for CompleteFTP 12.0.0 to Github, but have done so just now.  Can you please pull them and then try again?
commented by (220 points)
That did the trick thanks. If I had a penny every time I did that....

Categories

...