Publish sequences

This refactors and expands the existing API for publishing ExternalActivities to accept sequences (i.e. create ExternalActivities with an Investigation as template rather than an Activity). N.B. the "update" cucumber features still use the undefined step "Then magic stuff happens" for both activities and sequences - there is (I think) an issue with the publish step definition which makes republishing difficult in Cucumber.