Modifying the JSON loader in dahuapp.viewer.js

Creation of viewer module, with skeleton and next and previous events.