This does not work on Android 8.x but I do not know if they fixed this in Android 9. The DJI GO 4 Application will turn charging back on because, as some android forums have theorized, data transfer uses the current. Apparently, people have tried severing the wire that carries the current and after doing so, the wire doesn't work to transfer data.
I dont know anything beyond that but I can tell you I have looked into this for my SG Note 9, and no matter if I do anything in the Developers options or the pulldown USB options, the charging comes back on.