Removed redundant association to variants ..

Variants was a concept that was discarded soon after it was introduced.
Much easier to just store used versions as a string
Merge pull request #143 from adamarla/master

Suppress individual testpaper creation for in class assignments
Merge pull request #144 from adamarla/master

Fixed call to examiner.distribute_scan (incorrect args)
Critical bug-fix in offset calculation in method page?
 Minor cosmetic change
Merge branch 'master' of https://github.com/abhinavc/web-application
New query method - received_on - defined

The method takes a string like '3rd December 2012'.
Compacted receive_on_scan code
Passing an optional array of question indices to force quiz layout

'qids' is an array of question_ids. If its NOT blank, then it means
that the passed questions have to be laid out in the order given
in the array. Do NOT count on there being too many sanity checks on
qids in the code below

Passing qids is highly NOT recommended. Do this only if you know
what you are doing
cosmetic changes
[Experiment]: Dispatching mail using Delayed::Job
 Cosmetic changes
New custom delayed job - DispatchMail - added ...

Defining a custom job - as opposed to calling .delay - allows us
to override some of the defaults - like # of re-attempts. Ordinarily, we do
not re-attempts ( what's the point ? ). But with e-mails, there is a case
for re-attempting
All mailing now done by delayed job

Unfortunately, had to undo the custom job definition - DispatchMail -
from the last commit. It wouldn't work because of the way Rails 3 mailer works

Pity, because it was so elegant. But the underlying issue has something
to do with serializing an object versus serializing a class (which is
what is happening now )
Removed redundant delayed-job tasks
[Delayed Job]: Re-try all jobs 3 times and set default_priority to 10 ...

Most delayed jobs involve mailing. And mailing should be low priority
and re-tryable

The few jobs that should be high priority - like compiling quizzes and worksheets
now have their priorities explicitly set
[Compile Quiz]: Passing just the quiz_id to delayed_job

Whatever is passed to delayed_job is serialized and stored in the DB.
Much better to pass something short and do any object retrieval in perform itself

Also, defined failure method for the task
[Compile Testpaper]: Passing id here too as is done for CompileQuiz
Routing error with receive scan fixed