Made table size dynamic

Added ability to initialize size of table through a controller
attribute in the template.
Added ability to react to a $scope value changing by setting a $watch
in a controller.
Called a controller function from the template.