Fix to the manifest reader

Manifest reader was trying to always read the barcode
from the application by sample['Tube Barcode']. This
obviously did not work for things that were no tubes
e.g. filter papers. The manifest object now looks at
the templates for the sample in order to determine its
type, so that it can extract the barcode
Merge pull request #425 from jbeast/reader_fix

Fix to the manifest reader