moved barcode into a idiomatic rails resource controller