Fix bug 3875 Lost location hash and token on table add field

The bug was due to missing inclusion of JS files.