Scaffold makes use of javascripts view variable