fe 0.0.4 → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (218) hide show
  1. checksums.yaml +4 -4
  2. data/Rakefile +16 -36
  3. data/app/assets/javascripts/fe/admin.js +0 -1
  4. data/app/assets/javascripts/fe/fe.admin.js +40 -16
  5. data/app/assets/javascripts/fe/fe.common.js +48 -14
  6. data/app/assets/javascripts/fe/fe.public.js +1 -414
  7. data/app/assets/javascripts/fe/fe.public.nojquery.js +450 -0
  8. data/app/assets/javascripts/fe/jquery.validate.pack.js +3 -15
  9. data/app/assets/stylesheets/360front.css +0 -0
  10. data/app/assets/stylesheets/fe/fe.screen.css.scss.erb +69 -10
  11. data/app/controllers/fe/admin/elements_controller.rb +64 -48
  12. data/app/controllers/fe/admin/email_templates_controller.rb +2 -2
  13. data/app/controllers/fe/admin/question_pages_controller.rb +1 -1
  14. data/app/controllers/fe/admin/question_sheets_controller.rb +2 -103
  15. data/app/controllers/fe/concerns/admin/question_sheets_controller_concern.rb +112 -0
  16. data/app/controllers/fe/concerns/answer_pages_controller_concern.rb +2 -1
  17. data/app/controllers/fe/concerns/answer_sheets_controller_concern.rb +1 -1
  18. data/app/controllers/fe/concerns/application_controller_concern.rb +13 -0
  19. data/app/controllers/fe/reference_sheets_controller.rb +2 -0
  20. data/app/controllers/fe/references_controller.rb +1 -0
  21. data/app/helpers/fe/application_helper.rb +5 -0
  22. data/app/mailers/fe/notifier.rb +11 -4
  23. data/app/models/answer_sheet.rb +2 -0
  24. data/app/models/fe/application.rb +2 -1
  25. data/app/models/fe/concerns/answer_pages_presenter_concern.rb +10 -1
  26. data/app/models/fe/concerns/answer_sheet_concern.rb +38 -8
  27. data/app/models/fe/concerns/choice_field_concern.rb +17 -10
  28. data/app/models/fe/date_field.rb +1 -1
  29. data/app/models/fe/element.rb +105 -31
  30. data/app/models/fe/page.rb +52 -20
  31. data/app/models/fe/page_element.rb +6 -1
  32. data/app/models/fe/page_link.rb +6 -3
  33. data/app/models/fe/person.rb +11 -8
  34. data/app/models/fe/question.rb +2 -6
  35. data/app/models/fe/question_grid.rb +1 -1
  36. data/app/models/fe/question_grid_with_total.rb +15 -0
  37. data/app/models/fe/question_set.rb +1 -1
  38. data/app/models/fe/question_sheet.rb +15 -13
  39. data/app/models/fe/reference_question.rb +0 -10
  40. data/app/models/fe/reference_sheet.rb +17 -13
  41. data/app/models/staff.rb +2 -0
  42. data/app/validators/email_validator.rb +11 -0
  43. data/app/views/fe/admin/elements/create.js.erb +1 -0
  44. data/app/views/fe/admin/elements/drop.js.erb +1 -0
  45. data/app/views/fe/admin/elements/duplicate.js.erb +1 -0
  46. data/app/views/fe/admin/panels/_advanced_options.html.erb +9 -3
  47. data/app/views/fe/admin/panels/_common_fields.html.erb +19 -5
  48. data/app/views/fe/admin/panels/_page.html.erb +1 -1
  49. data/app/views/fe/admin/panels/_prop_choice_field.html.erb +20 -11
  50. data/app/views/fe/admin/panels/_prop_element.html.erb +2 -9
  51. data/app/views/fe/admin/panels/_prop_page.html.erb +8 -3
  52. data/app/views/fe/admin/panels/_prop_paragraph.html.erb +38 -24
  53. data/app/views/fe/admin/panels/_prop_section.html.erb +8 -2
  54. data/app/views/fe/admin/panels/_prop_sheet.html.erb +4 -1
  55. data/app/views/fe/admin/question_pages/_element.html.erb +11 -1
  56. data/app/views/fe/answer_pages/_answer_page.html.erb +9 -8
  57. data/app/views/fe/answer_pages/_element.html.erb +6 -7
  58. data/app/views/fe/answer_pages/_page_name.html.erb +1 -0
  59. data/app/views/fe/answer_pages/update.js.erb +3 -3
  60. data/app/views/fe/answer_sheets/_answer_sheet.html.erb +3 -3
  61. data/app/views/fe/answer_sheets/_element.html.erb +52 -34
  62. data/app/views/fe/answer_sheets/_incomplete.html.erb +1 -1
  63. data/app/views/fe/answer_sheets/_page_link.html.erb +2 -2
  64. data/app/views/fe/answer_sheets/_pages_list.html.erb +3 -3
  65. data/app/views/fe/answer_sheets/_submit_to.html.erb +1 -0
  66. data/app/views/fe/answer_sheets/edit.html.erb +14 -14
  67. data/app/views/fe/answer_sheets/incomplete.js.erb +3 -0
  68. data/app/views/fe/answer_sheets/index.html.erb +3 -3
  69. data/app/views/fe/answer_sheets/show.html.erb +1 -1
  70. data/app/views/fe/applications/_logout.html.erb +1 -0
  71. data/app/views/fe/applications/show.html.erb +1 -0
  72. data/app/views/fe/questions/fe/_acceptance.html.erb +3 -3
  73. data/app/views/fe/questions/fe/_attachment_field.html.erb +7 -3
  74. data/app/views/fe/questions/fe/_checkbox_field.html.erb +26 -24
  75. data/app/views/fe/questions/fe/_date_field.html.erb +1 -2
  76. data/app/views/fe/questions/fe/_date_field_mmyy.html.erb +2 -2
  77. data/app/views/fe/questions/fe/_drop_down_field.html.erb +3 -2
  78. data/app/views/fe/questions/fe/_paragraph.html.erb +1 -1
  79. data/app/views/fe/questions/fe/_question_grid.html.erb +14 -9
  80. data/app/views/fe/questions/fe/_question_grid_with_total.html.erb +21 -14
  81. data/app/views/fe/questions/fe/_questions.html.erb +2 -2
  82. data/app/views/fe/questions/fe/_radio_button_field.html.erb +12 -11
  83. data/app/views/fe/questions/fe/_rating.html.erb +9 -8
  84. data/app/views/fe/questions/fe/_reference_discipler.html.erb +1 -1
  85. data/app/views/fe/questions/fe/_reference_friend.html.erb +1 -1
  86. data/app/views/fe/questions/fe/_reference_parent.html.erb +1 -1
  87. data/app/views/fe/questions/fe/_reference_peer.html.erb +1 -1
  88. data/app/views/fe/questions/fe/_reference_question.html.erb +22 -15
  89. data/app/views/fe/questions/fe/_reference_roommate.html.erb +1 -1
  90. data/app/views/fe/questions/fe/_reference_spiritual.html.erb +1 -1
  91. data/app/views/fe/questions/fe/_reference_staff.html.erb +1 -1
  92. data/app/views/fe/questions/fe/_section.html.erb +1 -1
  93. data/app/views/fe/questions/fe/_text_area_field.html.erb +10 -3
  94. data/app/views/fe/questions/fe/_text_field.html.erb +1 -1
  95. data/app/views/fe/questions/fe/_yes_no_field.erb +3 -3
  96. data/app/views/fe/reference_pages/_reference.html.erb +11 -11
  97. data/app/views/fe/reference_pages/edit.html.erb +7 -7
  98. data/app/views/fe/reference_sheets/done.html.erb +2 -2
  99. data/app/views/fe/reference_sheets/not_found.html.erb +4 -4
  100. data/app/views/fe/references/edit.html.erb +6 -6
  101. data/app/views/fe/references/show.html.erb +7 -7
  102. data/app/views/fe/references/submit.js.erb +1 -1
  103. data/app/views/fe/submit_pages/_thankyou.html.erb +1 -1
  104. data/app/views/fe/submit_pages/edit.html.erb +9 -9
  105. data/app/views/layouts/fe/_error_messages_for.html.erb +7 -0
  106. data/app/views/layouts/fe/application.html.erb +1 -1
  107. data/config/routes.rb +0 -36
  108. data/db/migrate/20131003044250_create_reference_sheets.rb +1 -0
  109. data/db/migrate/20140623153424_create_fe_people.rb +1 -1
  110. data/db/migrate/20140624180246_create_fe_addresses.rb +1 -1
  111. data/db/migrate/20140624182216_create_fe_phone_numbers.rb +16 -0
  112. data/db/migrate/20140625160545_create_fe_users.rb +1 -1
  113. data/db/migrate/20150504221439_add_all_element_ids_to_pages.rb +5 -0
  114. data/db/migrate/20150713022326_add_locale_columns.rb +9 -0
  115. data/db/migrate/20150714220730_add_locale_to_answer_sheet.rb +5 -0
  116. data/db/migrate/20150928085325_change_pages_all_element_ids_to_text.rb +5 -0
  117. data/db/migrate/20150930191538_add_locale_to_reference_sheets.rb +5 -0
  118. data/lib/access_key_generator.rb +12 -0
  119. data/lib/distinct_distinct_patch.rb +20 -0
  120. data/lib/fe.rb +4 -0
  121. data/lib/fe/engine.rb +16 -4
  122. data/lib/fe/version.rb +1 -1
  123. data/spec/controllers/fe/admin/elements_controller_spec.rb +201 -1
  124. data/spec/controllers/fe/admin/email_templates_controller_spec.rb +26 -1
  125. data/spec/controllers/fe/admin/question_pages_controller_spec.rb +8 -1
  126. data/spec/controllers/fe/admin/question_sheets_controller_spec.rb +48 -1
  127. data/spec/controllers/fe/answer_pages_controller_spec.rb +73 -1
  128. data/spec/controllers/fe/answer_sheets_controller_spec.rb +80 -1
  129. data/spec/controllers/fe/reference_pages_controller.rb +4 -0
  130. data/spec/controllers/fe/references_controller_spec.rb +4 -0
  131. data/spec/controllers/fe/submit_pages_controller_spec.rb +4 -0
  132. data/spec/dummy/app/controllers/application_controller.rb +5 -0
  133. data/spec/dummy/app/helpers/application_helper.rb +9 -0
  134. data/spec/dummy/app/models/application.rb +3 -0
  135. data/spec/dummy/app/models/person.rb +11 -0
  136. data/spec/dummy/app/models/user.rb +3 -0
  137. data/spec/dummy/config/application.rb +2 -1
  138. data/spec/dummy/config/database.yml +20 -17
  139. data/spec/dummy/config/environments/production.rb +1 -5
  140. data/spec/dummy/config/environments/test.rb +3 -1
  141. data/spec/dummy/config/initializers/fast_gettext.rb +5 -0
  142. data/spec/dummy/config/secrets.yml +2 -2
  143. data/spec/dummy/db/migrate/20141203214017_core.fe_engine.rb +92 -0
  144. data/spec/dummy/db/migrate/20141203214018_create_reference_sheets.fe_engine.rb +25 -0
  145. data/spec/dummy/db/migrate/20141203214019_add_element_and_answer_fields.fe_engine.rb +11 -0
  146. data/spec/dummy/db/migrate/20141203214020_create_email_templates.fe_engine.rb +18 -0
  147. data/spec/dummy/db/migrate/20141203214021_add_max_lengths.fe_engine.rb +9 -0
  148. data/spec/dummy/db/migrate/20141203214022_create_join_table.fe_engine.rb +12 -0
  149. data/spec/dummy/db/migrate/20141203214023_remove_question_id_from_element.fe_engine.rb +10 -0
  150. data/spec/dummy/db/migrate/20141203214024_create_fe_people.fe_engine.rb +13 -0
  151. data/spec/dummy/db/migrate/20141203214025_create_fe_addresses.fe_engine.rb +21 -0
  152. data/{db/migrate/20140624182216_create_create_fe_phone_numbers.rb → spec/dummy/db/migrate/20141203214026_create_create_fe_phone_numbers.fe_engine.rb} +1 -0
  153. data/spec/dummy/db/migrate/20141203214027_create_fe_users.fe_engine.rb +13 -0
  154. data/spec/dummy/db/migrate/20141203214028_add_conditional_type_to_elements.fe_engine.rb +6 -0
  155. data/spec/dummy/db/migrate/20141203214029_add_conditional_answer_to_elements.fe_engine.rb +6 -0
  156. data/spec/dummy/db/migrate/20141203214030_remove_short_value_column.fe_engine.rb +6 -0
  157. data/spec/dummy/db/migrate/20141203214031_move_conditional_ids_used_for_choice_field_to_their_own_column.fe_engine.rb +8 -0
  158. data/spec/dummy/db/migrate/20150123215803_create_users.rb +9 -0
  159. data/spec/dummy/db/migrate/20150504222619_add_all_element_ids_to_pages.fe_engine.rb +6 -0
  160. data/spec/dummy/db/migrate/20150930190001_create_fe_phone_numbers.fe_engine.rb +20 -0
  161. data/spec/dummy/db/migrate/20150930190002_add_locale_columns.fe_engine.rb +10 -0
  162. data/spec/dummy/db/migrate/20150930190003_add_locale_to_answer_sheet.fe_engine.rb +6 -0
  163. data/spec/dummy/db/migrate/20150930190004_change_pages_all_element_ids_to_text.fe_engine.rb +6 -0
  164. data/spec/dummy/db/migrate/20150930191756_add_locale_to_reference_sheets.fe_engine.rb +6 -0
  165. data/spec/dummy/db/schema.rb +50 -20
  166. data/spec/dummy/log/development.log +5 -0
  167. data/spec/factories/applications.rb +0 -1
  168. data/spec/factories/dummy_applications.rb +6 -0
  169. data/spec/factories/dummy_people.rb +6 -0
  170. data/spec/factories/dummy_users.rb +6 -0
  171. data/spec/factories/elements.rb +28 -3
  172. data/spec/factories/email_templates.rb +5 -0
  173. data/spec/factories/fe_email_templates.rb +9 -0
  174. data/spec/factories/fe_people.rb +0 -2
  175. data/spec/factories/fe_user.rb +6 -0
  176. data/spec/factories/question_sheet.rb +1 -1
  177. data/spec/factories/reference_sheets.rb +9 -0
  178. data/spec/mailers/fe/notifier_spec.rb +39 -0
  179. data/spec/models/fe/choice_field_spec.rb +20 -0
  180. data/spec/models/fe/element_spec.rb +185 -0
  181. data/spec/models/fe/page_spec.rb +112 -0
  182. data/spec/models/fe/question_sheet_spec.rb +106 -0
  183. data/spec/models/fe/reference_sheet_spec.rb +20 -0
  184. data/spec/rails_helper.rb +41 -13
  185. data/spec/support/choices.xml +6 -0
  186. metadata +136 -48
  187. data/app/assets/javascripts/fe/rails.extra.js +0 -6
  188. data/app/controllers/fe/applications_controller.rb +0 -183
  189. data/app/controllers/fe/payments_controller.rb +0 -184
  190. data/app/models/fe/payment.rb +0 -77
  191. data/app/models/fe/payment_question.rb +0 -22
  192. data/app/views/fe/admin/panels/_prop_payment_question.html.erb +0 -1
  193. data/app/views/fe/application/_logout.html.erb +0 -1
  194. data/app/views/fe/payment_pages/_credit.html.erb +0 -47
  195. data/app/views/fe/payment_pages/_mail.html.erb +0 -27
  196. data/app/views/fe/payment_pages/_payment.html.erb +0 -6
  197. data/app/views/fe/payment_pages/_staff.html.erb +0 -25
  198. data/app/views/fe/payment_pages/_staff_results.html.erb +0 -17
  199. data/app/views/fe/payment_pages/edit.html.erb +0 -75
  200. data/app/views/fe/payment_pages/staff_search.js.erb +0 -2
  201. data/app/views/fe/payments/_credit.html.erb +0 -47
  202. data/app/views/fe/payments/_errors.html.erb +0 -1
  203. data/app/views/fe/payments/_payment.html.erb +0 -13
  204. data/app/views/fe/payments/_staff.html.erb +0 -21
  205. data/app/views/fe/payments/_staff_results.html.erb +0 -18
  206. data/app/views/fe/payments/approve.js.erb +0 -3
  207. data/app/views/fe/payments/create.js.erb +0 -19
  208. data/app/views/fe/payments/destroy.js.erb +0 -7
  209. data/app/views/fe/payments/edit.html.erb +0 -56
  210. data/app/views/fe/payments/error.js.erb +0 -3
  211. data/app/views/fe/payments/no_access.html.erb +0 -7
  212. data/app/views/fe/payments/staff_search.js.erb +0 -1
  213. data/app/views/fe/payments/update.html.erb +0 -24
  214. data/app/views/fe/questions/fe/_payment_question.html.erb +0 -70
  215. data/db/migrate/20140828045339_create_payments.rb +0 -13
  216. data/spec/dummy/db/test.sqlite3 +0 -0
  217. data/spec/factories/payments.rb +0 -7
  218. data/spec/models/fe/payment_question_spec.rb +0 -65
@@ -8,4 +8,24 @@ describe Fe::ReferenceSheet do
8
8
  # it { expect validate_presence_of :phone } # need to add started_at column
9
9
  # it { expect validate_presence_of :email } # need to add started_at column
10
10
  # it { expect validate_presence_of :relationship } # need to add started_at column
11
+
12
+ context '#access_key' do
13
+ it 'should generate two different in the same second' do
14
+ # there's a small chance the first and second access keys generated will be in different seconds
15
+ # doing it 5 times should make it extremely to pass despite there being a bug
16
+ 5.times do
17
+ r = Fe::ReferenceSheet.new email: 'tester@test.com'
18
+ k1 = r.generate_access_key
19
+ k2 = r.generate_access_key
20
+ expect(k1).to_not eq(k2)
21
+ end
22
+ end
23
+ end
24
+
25
+ it 'returns the user for applicant' do
26
+ p = create(:fe_person)
27
+ a = create(:answer_sheet, applicant_id: p.id)
28
+ r = create(:reference_sheet, applicant_answer_sheet: a)
29
+ expect(r.applicant).to eq(a.applicant)
30
+ end
11
31
  end
@@ -8,13 +8,21 @@ Spork.prefork do
8
8
  require 'rspec'
9
9
  require 'shoulda'
10
10
  require 'database_cleaner'
11
- require 'factory_girl_rails'
12
11
  require 'simplecov'
13
12
  SimpleCov.start 'rails' do
14
13
  add_filter "vendor"
15
14
  end
16
15
  Rails.backtrace_cleaner.remove_silencers!
17
16
 
17
+ # load concerns and decorators here now that code coverage has started
18
+ Dir.glob(File.join(Fe::Engine.root + 'app/**/*_concern.rb')).each do |c|
19
+ require_dependency(c)
20
+ end
21
+ Dir.glob(File.join(Rails.root + 'app/decorators/**/*_decorator.rb')).each do |c|
22
+ require_dependency(c)
23
+ end
24
+ require 'factory_girl_rails'
25
+
18
26
  ENGINE_RAILS_ROOT = File.join( File.dirname(__FILE__), '../' )
19
27
 
20
28
  # Requires supporting ruby files with custom matchers and macros, etc,
@@ -25,17 +33,33 @@ Spork.prefork do
25
33
  RSpec.configure do |config|
26
34
 
27
35
  config.include FactoryGirl::Syntax::Methods
28
- #
29
- #config.before(:suite) do
30
- # DatabaseCleaner.strategy = :transaction
31
- # DatabaseCleaner.clean_with(:truncation)
32
- #end
33
- #config.before(:each) do
34
- # DatabaseCleaner.start
35
- #end
36
- #config.after(:each) do
37
- # DatabaseCleaner.clean
38
- #end
36
+
37
+ config.before(:suite) do
38
+ DatabaseCleaner.strategy = :truncation
39
+
40
+ # this usually would go in the app/decorators folder but there's some load order issues with the dummy app
41
+ # and it's just way easier to do it here
42
+ Fe::Application.class_eval do
43
+ belongs_to :applicant, foreign_key: 'applicant_id', class_name: 'Fe::Person'
44
+ end
45
+ Fe::Person.class_eval do
46
+ # defining apps will implement phone
47
+ def phone
48
+ "123-456-7890"
49
+ end
50
+ # defining apps will implement email
51
+ def email
52
+ "email@email.com"
53
+ end
54
+ end
55
+
56
+ end
57
+ config.before(:each) do
58
+ DatabaseCleaner.start
59
+ end
60
+ config.after(:each) do
61
+ DatabaseCleaner.clean
62
+ end
39
63
 
40
64
  config.mock_with :rspec
41
65
  # muted to allow database_cleaner to work
@@ -43,7 +67,7 @@ Spork.prefork do
43
67
  # If you're not using ActiveRecord, or you'd prefer not to run each of your
44
68
  # examples within a transaction, remove the following line or assign false
45
69
  # instead of true.
46
- config.use_transactional_fixtures = true
70
+ config.use_transactional_fixtures = false
47
71
 
48
72
  # set to true (embrace the future)
49
73
  #
@@ -57,6 +81,10 @@ Spork.prefork do
57
81
  # the seed, which is printed after each run.
58
82
  # --seed 1234
59
83
  config.order = "random"
84
+
85
+ # always render views. the more view code that gets run the more likely we are to
86
+ # discover crashes in testing than in production
87
+ config.render_views
60
88
  end
61
89
  end
62
90
 
@@ -0,0 +1,6 @@
1
+ <choices>
2
+ <choice>A</choice>
3
+ <value>1</value>
4
+ <choice>B</choice>
5
+ <value>0</value>
6
+ </choices>
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fe
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.4
4
+ version: 1.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - CruGlobal
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-11-17 00:00:00.000000000 Z
11
+ date: 2015-10-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -30,14 +30,14 @@ dependencies:
30
30
  requirements:
31
31
  - - '='
32
32
  - !ruby/object:Gem::Version
33
- version: 0.4.0
33
+ version: 0.7.2
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - '='
39
39
  - !ruby/object:Gem::Version
40
- version: 0.4.0
40
+ version: 0.7.2
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: aasm
43
43
  requirement: !ruby/object:Gem::Requirement
@@ -95,7 +95,21 @@ dependencies:
95
95
  - !ruby/object:Gem::Version
96
96
  version: '0'
97
97
  - !ruby/object:Gem::Dependency
98
- name: activemerchant
98
+ name: carmen
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - "~>"
102
+ - !ruby/object:Gem::Version
103
+ version: 0.2.12
104
+ type: :runtime
105
+ prerelease: false
106
+ version_requirements: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - "~>"
109
+ - !ruby/object:Gem::Version
110
+ version: 0.2.12
111
+ - !ruby/object:Gem::Dependency
112
+ name: validates_email_format_of
99
113
  requirement: !ruby/object:Gem::Requirement
100
114
  requirements:
101
115
  - - ">="
@@ -109,21 +123,21 @@ dependencies:
109
123
  - !ruby/object:Gem::Version
110
124
  version: '0'
111
125
  - !ruby/object:Gem::Dependency
112
- name: carmen
126
+ name: liquid
113
127
  requirement: !ruby/object:Gem::Requirement
114
128
  requirements:
115
- - - "~>"
129
+ - - ">="
116
130
  - !ruby/object:Gem::Version
117
- version: 0.2.12
131
+ version: '0'
118
132
  type: :runtime
119
133
  prerelease: false
120
134
  version_requirements: !ruby/object:Gem::Requirement
121
135
  requirements:
122
- - - "~>"
136
+ - - ">="
123
137
  - !ruby/object:Gem::Version
124
- version: 0.2.12
138
+ version: '0'
125
139
  - !ruby/object:Gem::Dependency
126
- name: validates_email_format_of
140
+ name: sass
127
141
  requirement: !ruby/object:Gem::Requirement
128
142
  requirements:
129
143
  - - ">="
@@ -136,6 +150,20 @@ dependencies:
136
150
  - - ">="
137
151
  - !ruby/object:Gem::Version
138
152
  version: '0'
153
+ - !ruby/object:Gem::Dependency
154
+ name: gettext_i18n_rails
155
+ requirement: !ruby/object:Gem::Requirement
156
+ requirements:
157
+ - - "~>"
158
+ - !ruby/object:Gem::Version
159
+ version: 1.2.3
160
+ type: :runtime
161
+ prerelease: false
162
+ version_requirements: !ruby/object:Gem::Requirement
163
+ requirements:
164
+ - - "~>"
165
+ - !ruby/object:Gem::Version
166
+ version: 1.2.3
139
167
  - !ruby/object:Gem::Dependency
140
168
  name: mysql2
141
169
  requirement: !ruby/object:Gem::Requirement
@@ -270,12 +298,13 @@ files:
270
298
  - app/assets/javascripts/fe/fe.admin.js
271
299
  - app/assets/javascripts/fe/fe.common.js
272
300
  - app/assets/javascripts/fe/fe.public.js
301
+ - app/assets/javascripts/fe/fe.public.nojquery.js
273
302
  - app/assets/javascripts/fe/jquery.metadata.js
274
303
  - app/assets/javascripts/fe/jquery.scrollTo-min.js
275
304
  - app/assets/javascripts/fe/jquery.uploadify.v2.1.0.js
276
305
  - app/assets/javascripts/fe/jquery.validate.pack.js
277
- - app/assets/javascripts/fe/rails.extra.js
278
306
  - app/assets/javascripts/fe/swfobject.js
307
+ - app/assets/stylesheets/360front.css
279
308
  - app/assets/stylesheets/fe/fe.screen.css.scss.erb
280
309
  - app/assets/stylesheets/fe/reset.css
281
310
  - app/assets/stylesheets/fe/validation.css
@@ -285,11 +314,10 @@ files:
285
314
  - app/controllers/fe/admin/question_sheets_controller.rb
286
315
  - app/controllers/fe/answer_pages_controller.rb
287
316
  - app/controllers/fe/answer_sheets_controller.rb
288
- - app/controllers/fe/applications_controller.rb
317
+ - app/controllers/fe/concerns/admin/question_sheets_controller_concern.rb
289
318
  - app/controllers/fe/concerns/answer_pages_controller_concern.rb
290
319
  - app/controllers/fe/concerns/answer_sheets_controller_concern.rb
291
320
  - app/controllers/fe/concerns/application_controller_concern.rb
292
- - app/controllers/fe/payments_controller.rb
293
321
  - app/controllers/fe/reference_pages_controller.rb
294
322
  - app/controllers/fe/reference_sheets_controller.rb
295
323
  - app/controllers/fe/references_controller.rb
@@ -297,6 +325,7 @@ files:
297
325
  - app/helpers/fe/answer_pages_helper.rb
298
326
  - app/helpers/fe/application_helper.rb
299
327
  - app/mailers/fe/notifier.rb
328
+ - app/models/answer_sheet.rb
300
329
  - app/models/fe/address.rb
301
330
  - app/models/fe/answer.rb
302
331
  - app/models/fe/answer_pages_presenter.rb
@@ -321,8 +350,6 @@ files:
321
350
  - app/models/fe/page_element.rb
322
351
  - app/models/fe/page_link.rb
323
352
  - app/models/fe/paragraph.rb
324
- - app/models/fe/payment.rb
325
- - app/models/fe/payment_question.rb
326
353
  - app/models/fe/person.rb
327
354
  - app/models/fe/phone_number.rb
328
355
  - app/models/fe/presenter.rb
@@ -338,6 +365,7 @@ files:
338
365
  - app/models/fe/text_field.rb
339
366
  - app/models/fe/user.rb
340
367
  - app/models/staff.rb
368
+ - app/validators/email_validator.rb
341
369
  - app/views/fe/admin/elements/_errors.html.erb
342
370
  - app/views/fe/admin/elements/create.js.erb
343
371
  - app/views/fe/admin/elements/destroy.js.erb
@@ -365,7 +393,6 @@ files:
365
393
  - app/views/fe/admin/panels/_prop_element.html.erb
366
394
  - app/views/fe/admin/panels/_prop_page.html.erb
367
395
  - app/views/fe/admin/panels/_prop_paragraph.html.erb
368
- - app/views/fe/admin/panels/_prop_payment_question.html.erb
369
396
  - app/views/fe/admin/panels/_prop_question_grid.html.erb
370
397
  - app/views/fe/admin/panels/_prop_question_grid_with_total.html.erb
371
398
  - app/views/fe/admin/panels/_prop_reference_question.html.erb
@@ -392,41 +419,24 @@ files:
392
419
  - app/views/fe/admin/question_sheets/update.js.erb
393
420
  - app/views/fe/answer_pages/_answer_page.html.erb
394
421
  - app/views/fe/answer_pages/_element.html.erb
422
+ - app/views/fe/answer_pages/_page_name.html.erb
395
423
  - app/views/fe/answer_pages/update.js.erb
396
424
  - app/views/fe/answer_sheets/_answer_sheet.html.erb
397
425
  - app/views/fe/answer_sheets/_element.html.erb
398
426
  - app/views/fe/answer_sheets/_incomplete.html.erb
399
427
  - app/views/fe/answer_sheets/_page_link.html.erb
400
428
  - app/views/fe/answer_sheets/_pages_list.html.erb
429
+ - app/views/fe/answer_sheets/_submit_to.html.erb
401
430
  - app/views/fe/answer_sheets/_title.html.erb
402
431
  - app/views/fe/answer_sheets/edit.html.erb
403
432
  - app/views/fe/answer_sheets/incomplete.js.erb
404
433
  - app/views/fe/answer_sheets/index.html.erb
405
434
  - app/views/fe/answer_sheets/send_reference_invite.js.erb
406
435
  - app/views/fe/answer_sheets/show.html.erb
407
- - app/views/fe/application/_logout.html.erb
436
+ - app/views/fe/applications/_logout.html.erb
437
+ - app/views/fe/applications/show.html.erb
408
438
  - app/views/fe/help/builder.html
409
439
  - app/views/fe/help/question_grid.html
410
- - app/views/fe/payment_pages/_credit.html.erb
411
- - app/views/fe/payment_pages/_mail.html.erb
412
- - app/views/fe/payment_pages/_payment.html.erb
413
- - app/views/fe/payment_pages/_staff.html.erb
414
- - app/views/fe/payment_pages/_staff_results.html.erb
415
- - app/views/fe/payment_pages/edit.html.erb
416
- - app/views/fe/payment_pages/staff_search.js.erb
417
- - app/views/fe/payments/_credit.html.erb
418
- - app/views/fe/payments/_errors.html.erb
419
- - app/views/fe/payments/_payment.html.erb
420
- - app/views/fe/payments/_staff.html.erb
421
- - app/views/fe/payments/_staff_results.html.erb
422
- - app/views/fe/payments/approve.js.erb
423
- - app/views/fe/payments/create.js.erb
424
- - app/views/fe/payments/destroy.js.erb
425
- - app/views/fe/payments/edit.html.erb
426
- - app/views/fe/payments/error.js.erb
427
- - app/views/fe/payments/no_access.html.erb
428
- - app/views/fe/payments/staff_search.js.erb
429
- - app/views/fe/payments/update.html.erb
430
440
  - app/views/fe/questions/fe/_acceptance.html.erb
431
441
  - app/views/fe/questions/fe/_attachment_field.html.erb
432
442
  - app/views/fe/questions/fe/_checkbox_field.html.erb
@@ -435,7 +445,6 @@ files:
435
445
  - app/views/fe/questions/fe/_date_field_mmyy.html.erb
436
446
  - app/views/fe/questions/fe/_drop_down_field.html.erb
437
447
  - app/views/fe/questions/fe/_paragraph.html.erb
438
- - app/views/fe/questions/fe/_payment_question.html.erb
439
448
  - app/views/fe/questions/fe/_question_grid.html.erb
440
449
  - app/views/fe/questions/fe/_question_grid_with_total.html.erb
441
450
  - app/views/fe/questions/fe/_questions.html.erb
@@ -469,6 +478,7 @@ files:
469
478
  - app/views/fe/submit_pages/edit.html.erb
470
479
  - app/views/fe/submit_pages/error.js.erb
471
480
  - app/views/fe/submit_pages/submit.js.erb
481
+ - app/views/layouts/fe/_error_messages_for.html.erb
472
482
  - app/views/layouts/fe/application.html.erb
473
483
  - app/views/layouts/fe/fe.admin.html.erb
474
484
  - config/locales/en.yml
@@ -482,14 +492,20 @@ files:
482
492
  - db/migrate/20131016162128_remove_question_id_from_element.rb
483
493
  - db/migrate/20140623153424_create_fe_people.rb
484
494
  - db/migrate/20140624180246_create_fe_addresses.rb
485
- - db/migrate/20140624182216_create_create_fe_phone_numbers.rb
495
+ - db/migrate/20140624182216_create_fe_phone_numbers.rb
486
496
  - db/migrate/20140625160545_create_fe_users.rb
487
497
  - db/migrate/20140808202507_add_conditional_type_to_elements.rb
488
498
  - db/migrate/20140808203609_add_conditional_answer_to_elements.rb
489
- - db/migrate/20140828045339_create_payments.rb
490
499
  - db/migrate/20141103204704_remove_short_value_column.rb
491
500
  - db/migrate/20141109154522_move_conditional_ids_used_for_choice_field_to_their_own_column.rb
501
+ - db/migrate/20150504221439_add_all_element_ids_to_pages.rb
502
+ - db/migrate/20150713022326_add_locale_columns.rb
503
+ - db/migrate/20150714220730_add_locale_to_answer_sheet.rb
504
+ - db/migrate/20150928085325_change_pages_all_element_ids_to_text.rb
505
+ - db/migrate/20150930191538_add_locale_to_reference_sheets.rb
492
506
  - db/seeds.rb
507
+ - lib/access_key_generator.rb
508
+ - lib/distinct_distinct_patch.rb
493
509
  - lib/fe.rb
494
510
  - lib/fe/engine.rb
495
511
  - lib/fe/version.rb
@@ -500,13 +516,19 @@ files:
500
516
  - spec/controllers/fe/admin/question_sheets_controller_spec.rb
501
517
  - spec/controllers/fe/answer_pages_controller_spec.rb
502
518
  - spec/controllers/fe/answer_sheets_controller_spec.rb
519
+ - spec/controllers/fe/reference_pages_controller.rb
503
520
  - spec/controllers/fe/reference_sheets_controller_spec.rb
521
+ - spec/controllers/fe/references_controller_spec.rb
522
+ - spec/controllers/fe/submit_pages_controller_spec.rb
504
523
  - spec/dummy/README.rdoc
505
524
  - spec/dummy/Rakefile
506
525
  - spec/dummy/app/assets/javascripts/application.js
507
526
  - spec/dummy/app/assets/stylesheets/application.css
508
527
  - spec/dummy/app/controllers/application_controller.rb
509
528
  - spec/dummy/app/helpers/application_helper.rb
529
+ - spec/dummy/app/models/application.rb
530
+ - spec/dummy/app/models/person.rb
531
+ - spec/dummy/app/models/user.rb
510
532
  - spec/dummy/app/views/layouts/application.html.erb
511
533
  - spec/dummy/bin/bundle
512
534
  - spec/dummy/bin/rails
@@ -522,6 +544,7 @@ files:
522
544
  - spec/dummy/config/initializers/assets.rb
523
545
  - spec/dummy/config/initializers/backtrace_silencers.rb
524
546
  - spec/dummy/config/initializers/cookies_serializer.rb
547
+ - spec/dummy/config/initializers/fast_gettext.rb
525
548
  - spec/dummy/config/initializers/filter_parameter_logging.rb
526
549
  - spec/dummy/config/initializers/inflections.rb
527
550
  - spec/dummy/config/initializers/mime_types.rb
@@ -530,8 +553,30 @@ files:
530
553
  - spec/dummy/config/locales/en.yml
531
554
  - spec/dummy/config/routes.rb
532
555
  - spec/dummy/config/secrets.yml
556
+ - spec/dummy/db/migrate/20141203214017_core.fe_engine.rb
557
+ - spec/dummy/db/migrate/20141203214018_create_reference_sheets.fe_engine.rb
558
+ - spec/dummy/db/migrate/20141203214019_add_element_and_answer_fields.fe_engine.rb
559
+ - spec/dummy/db/migrate/20141203214020_create_email_templates.fe_engine.rb
560
+ - spec/dummy/db/migrate/20141203214021_add_max_lengths.fe_engine.rb
561
+ - spec/dummy/db/migrate/20141203214022_create_join_table.fe_engine.rb
562
+ - spec/dummy/db/migrate/20141203214023_remove_question_id_from_element.fe_engine.rb
563
+ - spec/dummy/db/migrate/20141203214024_create_fe_people.fe_engine.rb
564
+ - spec/dummy/db/migrate/20141203214025_create_fe_addresses.fe_engine.rb
565
+ - spec/dummy/db/migrate/20141203214026_create_create_fe_phone_numbers.fe_engine.rb
566
+ - spec/dummy/db/migrate/20141203214027_create_fe_users.fe_engine.rb
567
+ - spec/dummy/db/migrate/20141203214028_add_conditional_type_to_elements.fe_engine.rb
568
+ - spec/dummy/db/migrate/20141203214029_add_conditional_answer_to_elements.fe_engine.rb
569
+ - spec/dummy/db/migrate/20141203214030_remove_short_value_column.fe_engine.rb
570
+ - spec/dummy/db/migrate/20141203214031_move_conditional_ids_used_for_choice_field_to_their_own_column.fe_engine.rb
571
+ - spec/dummy/db/migrate/20150123215803_create_users.rb
572
+ - spec/dummy/db/migrate/20150504222619_add_all_element_ids_to_pages.fe_engine.rb
573
+ - spec/dummy/db/migrate/20150930190001_create_fe_phone_numbers.fe_engine.rb
574
+ - spec/dummy/db/migrate/20150930190002_add_locale_columns.fe_engine.rb
575
+ - spec/dummy/db/migrate/20150930190003_add_locale_to_answer_sheet.fe_engine.rb
576
+ - spec/dummy/db/migrate/20150930190004_change_pages_all_element_ids_to_text.fe_engine.rb
577
+ - spec/dummy/db/migrate/20150930191756_add_locale_to_reference_sheets.fe_engine.rb
533
578
  - spec/dummy/db/schema.rb
534
- - spec/dummy/db/test.sqlite3
579
+ - spec/dummy/log/development.log
535
580
  - spec/dummy/log/test.log
536
581
  - spec/dummy/public/404.html
537
582
  - spec/dummy/public/422.html
@@ -541,17 +586,24 @@ files:
541
586
  - spec/factories/answer_sheets.rb
542
587
  - spec/factories/answers.rb
543
588
  - spec/factories/applications.rb
589
+ - spec/factories/dummy_applications.rb
590
+ - spec/factories/dummy_people.rb
591
+ - spec/factories/dummy_users.rb
544
592
  - spec/factories/elements.rb
593
+ - spec/factories/email_templates.rb
545
594
  - spec/factories/fe_addresses.rb
546
595
  - spec/factories/fe_email_addresses.rb
596
+ - spec/factories/fe_email_templates.rb
547
597
  - spec/factories/fe_people.rb
548
598
  - spec/factories/fe_phone_numbers.rb
599
+ - spec/factories/fe_user.rb
549
600
  - spec/factories/page.rb
550
601
  - spec/factories/page_elements.rb
551
602
  - spec/factories/paragraphs.rb
552
- - spec/factories/payments.rb
553
603
  - spec/factories/question_sheet.rb
554
604
  - spec/factories/reference_questions.rb
605
+ - spec/factories/reference_sheets.rb
606
+ - spec/mailers/fe/notifier_spec.rb
555
607
  - spec/models/fe/answer_sheet_question_sheet_spec.rb
556
608
  - spec/models/fe/answer_spec.rb
557
609
  - spec/models/fe/application_spec.rb
@@ -567,7 +619,6 @@ files:
567
619
  - spec/models/fe/page_link_spec.rb
568
620
  - spec/models/fe/page_spec.rb
569
621
  - spec/models/fe/paragraph_spec.rb
570
- - spec/models/fe/payment_question_spec.rb
571
622
  - spec/models/fe/person_spec.rb
572
623
  - spec/models/fe/question_grid_spec.rb
573
624
  - spec/models/fe/question_grid_with_total_spec.rb
@@ -580,6 +631,7 @@ files:
580
631
  - spec/models/fe/state_chooser_spec.rb
581
632
  - spec/models/fe/text_field_spec.rb
582
633
  - spec/rails_helper.rb
634
+ - spec/support/choices.xml
583
635
  - spec/support/database.txt
584
636
  homepage: http://cru.org
585
637
  licenses: []
@@ -600,7 +652,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
600
652
  version: '0'
601
653
  requirements: []
602
654
  rubyforge_project:
603
- rubygems_version: 2.4.2
655
+ rubygems_version: 2.4.5
604
656
  signing_key:
605
657
  specification_version: 4
606
658
  summary: Form Engine
@@ -611,11 +663,17 @@ test_files:
611
663
  - spec/controllers/fe/admin/question_sheets_controller_spec.rb
612
664
  - spec/controllers/fe/answer_pages_controller_spec.rb
613
665
  - spec/controllers/fe/answer_sheets_controller_spec.rb
666
+ - spec/controllers/fe/reference_pages_controller.rb
614
667
  - spec/controllers/fe/reference_sheets_controller_spec.rb
668
+ - spec/controllers/fe/references_controller_spec.rb
669
+ - spec/controllers/fe/submit_pages_controller_spec.rb
615
670
  - spec/dummy/app/assets/javascripts/application.js
616
671
  - spec/dummy/app/assets/stylesheets/application.css
617
672
  - spec/dummy/app/controllers/application_controller.rb
618
673
  - spec/dummy/app/helpers/application_helper.rb
674
+ - spec/dummy/app/models/application.rb
675
+ - spec/dummy/app/models/person.rb
676
+ - spec/dummy/app/models/user.rb
619
677
  - spec/dummy/app/views/layouts/application.html.erb
620
678
  - spec/dummy/bin/bundle
621
679
  - spec/dummy/bin/rails
@@ -630,6 +688,7 @@ test_files:
630
688
  - spec/dummy/config/initializers/assets.rb
631
689
  - spec/dummy/config/initializers/backtrace_silencers.rb
632
690
  - spec/dummy/config/initializers/cookies_serializer.rb
691
+ - spec/dummy/config/initializers/fast_gettext.rb
633
692
  - spec/dummy/config/initializers/filter_parameter_logging.rb
634
693
  - spec/dummy/config/initializers/inflections.rb
635
694
  - spec/dummy/config/initializers/mime_types.rb
@@ -639,8 +698,30 @@ test_files:
639
698
  - spec/dummy/config/routes.rb
640
699
  - spec/dummy/config/secrets.yml
641
700
  - spec/dummy/config.ru
701
+ - spec/dummy/db/migrate/20141203214017_core.fe_engine.rb
702
+ - spec/dummy/db/migrate/20141203214018_create_reference_sheets.fe_engine.rb
703
+ - spec/dummy/db/migrate/20141203214019_add_element_and_answer_fields.fe_engine.rb
704
+ - spec/dummy/db/migrate/20141203214020_create_email_templates.fe_engine.rb
705
+ - spec/dummy/db/migrate/20141203214021_add_max_lengths.fe_engine.rb
706
+ - spec/dummy/db/migrate/20141203214022_create_join_table.fe_engine.rb
707
+ - spec/dummy/db/migrate/20141203214023_remove_question_id_from_element.fe_engine.rb
708
+ - spec/dummy/db/migrate/20141203214024_create_fe_people.fe_engine.rb
709
+ - spec/dummy/db/migrate/20141203214025_create_fe_addresses.fe_engine.rb
710
+ - spec/dummy/db/migrate/20141203214026_create_create_fe_phone_numbers.fe_engine.rb
711
+ - spec/dummy/db/migrate/20141203214027_create_fe_users.fe_engine.rb
712
+ - spec/dummy/db/migrate/20141203214028_add_conditional_type_to_elements.fe_engine.rb
713
+ - spec/dummy/db/migrate/20141203214029_add_conditional_answer_to_elements.fe_engine.rb
714
+ - spec/dummy/db/migrate/20141203214030_remove_short_value_column.fe_engine.rb
715
+ - spec/dummy/db/migrate/20141203214031_move_conditional_ids_used_for_choice_field_to_their_own_column.fe_engine.rb
716
+ - spec/dummy/db/migrate/20150123215803_create_users.rb
717
+ - spec/dummy/db/migrate/20150504222619_add_all_element_ids_to_pages.fe_engine.rb
718
+ - spec/dummy/db/migrate/20150930190001_create_fe_phone_numbers.fe_engine.rb
719
+ - spec/dummy/db/migrate/20150930190002_add_locale_columns.fe_engine.rb
720
+ - spec/dummy/db/migrate/20150930190003_add_locale_to_answer_sheet.fe_engine.rb
721
+ - spec/dummy/db/migrate/20150930190004_change_pages_all_element_ids_to_text.fe_engine.rb
722
+ - spec/dummy/db/migrate/20150930191756_add_locale_to_reference_sheets.fe_engine.rb
642
723
  - spec/dummy/db/schema.rb
643
- - spec/dummy/db/test.sqlite3
724
+ - spec/dummy/log/development.log
644
725
  - spec/dummy/log/test.log
645
726
  - spec/dummy/public/404.html
646
727
  - spec/dummy/public/422.html
@@ -652,17 +733,24 @@ test_files:
652
733
  - spec/factories/answer_sheets.rb
653
734
  - spec/factories/answers.rb
654
735
  - spec/factories/applications.rb
736
+ - spec/factories/dummy_applications.rb
737
+ - spec/factories/dummy_people.rb
738
+ - spec/factories/dummy_users.rb
655
739
  - spec/factories/elements.rb
740
+ - spec/factories/email_templates.rb
656
741
  - spec/factories/fe_addresses.rb
657
742
  - spec/factories/fe_email_addresses.rb
743
+ - spec/factories/fe_email_templates.rb
658
744
  - spec/factories/fe_people.rb
659
745
  - spec/factories/fe_phone_numbers.rb
746
+ - spec/factories/fe_user.rb
660
747
  - spec/factories/page.rb
661
748
  - spec/factories/page_elements.rb
662
749
  - spec/factories/paragraphs.rb
663
- - spec/factories/payments.rb
664
750
  - spec/factories/question_sheet.rb
665
751
  - spec/factories/reference_questions.rb
752
+ - spec/factories/reference_sheets.rb
753
+ - spec/mailers/fe/notifier_spec.rb
666
754
  - spec/models/fe/answer_sheet_question_sheet_spec.rb
667
755
  - spec/models/fe/answer_spec.rb
668
756
  - spec/models/fe/application_spec.rb
@@ -678,7 +766,6 @@ test_files:
678
766
  - spec/models/fe/page_link_spec.rb
679
767
  - spec/models/fe/page_spec.rb
680
768
  - spec/models/fe/paragraph_spec.rb
681
- - spec/models/fe/payment_question_spec.rb
682
769
  - spec/models/fe/person_spec.rb
683
770
  - spec/models/fe/question_grid_spec.rb
684
771
  - spec/models/fe/question_grid_with_total_spec.rb
@@ -691,4 +778,5 @@ test_files:
691
778
  - spec/models/fe/state_chooser_spec.rb
692
779
  - spec/models/fe/text_field_spec.rb
693
780
  - spec/rails_helper.rb
781
+ - spec/support/choices.xml
694
782
  - spec/support/database.txt