ask 0.5.0 → 0.5.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -10,7 +10,7 @@ class Answer < ActiveRecord::Base
10
10
 
11
11
  mount_uploader :uploaded_file, UploadedFileUploader
12
12
 
13
- default_scope joins(:question).order('questions.position')
13
+ default_scope joins(:question).order('questions.position').readonly(false) # This scope prevents updating answers unless readonly is set to false.
14
14
  scope :for_answerer, lambda{|answerer| where(:answerer_type => answerer.class.to_s, :answerer_id => answerer.id)}
15
15
  scope :for_question, lambda{|question| where(:question_id => question.id)}
16
16
 
@@ -6,7 +6,7 @@
6
6
  <textarea disabled = "disabled" name = "undefined" type = "text" value = "Their answer" class = "askwidget-disabledpreview"></textarea>
7
7
  </div>
8
8
 
9
- <div class = "question-type UploadQuestion">
9
+ <div class = "question-type UploadQuestion start-hidden">
10
10
  <input type = "file" disabled = "disabled" name = "undefined" value = "Their answer" class = "askwidget-disabledpreview"></input>
11
11
  </div>
12
12
 
@@ -1,3 +1,3 @@
1
1
  module Ask
2
- VERSION = "0.5.0"
2
+ VERSION = "0.5.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ask
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.5.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: