houston-core 0.8.4 → 0.9.0.rc1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (225) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile +1 -0
  3. data/Gemfile.lock +72 -78
  4. data/app/assets/javascripts/houston/app/models/role.coffee +4 -0
  5. data/app/assets/javascripts/houston/app/views/nested_resources.coffee +44 -0
  6. data/app/assets/javascripts/houston/app/views/team_roles_view.coffee +10 -0
  7. data/app/assets/javascripts/houston/application.js +3 -1
  8. data/app/assets/javascripts/houston/core/ajax_helpers.coffee +26 -0
  9. data/app/assets/javascripts/houston/core/app.coffee +0 -45
  10. data/app/assets/javascripts/houston/core/errors.coffee +1 -12
  11. data/app/assets/javascripts/houston/core/handlebars_helpers.coffee +8 -70
  12. data/app/assets/javascripts/houston/core/jquery_extensions.coffee +0 -138
  13. data/app/assets/javascripts/houston/core/timeline_helpers.coffee +44 -0
  14. data/app/assets/javascripts/houston/core/uploader_helpers.coffee +99 -0
  15. data/app/assets/javascripts/houston/vendor.js +26 -9
  16. data/app/assets/stylesheets/houston/application/actions.scss +22 -0
  17. data/app/assets/stylesheets/houston/application/navigation.scss +2 -2
  18. data/app/assets/stylesheets/houston/application/{freight_train.css.scss → nested_resources.scss} +1 -0
  19. data/app/assets/stylesheets/houston/core/alerts.scss +0 -4
  20. data/app/assets/stylesheets/houston/core/timeline.scss +204 -0
  21. data/app/assets/templates/houston/teams/roles/index.hbs +1 -0
  22. data/app/assets/templates/houston/teams/roles/show.hbs +19 -0
  23. data/app/channels/events_channel.rb +1 -1
  24. data/app/concerns/houston/props.rb +3 -2
  25. data/app/controllers/actions_controller.rb +8 -3
  26. data/app/controllers/application_controller.rb +9 -12
  27. data/app/controllers/authorizations_controller.rb +41 -14
  28. data/app/controllers/errors_controller.rb +3 -3
  29. data/app/controllers/project_follows_controller.rb +23 -0
  30. data/app/controllers/project_options_controller.rb +1 -1
  31. data/app/controllers/user_options_controller.rb +1 -1
  32. data/app/helpers/actions_helper.rb +12 -0
  33. data/app/helpers/application_helper.rb +0 -10
  34. data/app/helpers/layout_helper.rb +20 -0
  35. data/app/helpers/markdown_helper.rb +2 -10
  36. data/app/helpers/navigation_helper.rb +5 -5
  37. data/app/helpers/project_helper.rb +6 -0
  38. data/app/helpers/url_helper.rb +4 -4
  39. data/app/helpers/view_extensions_helper.rb +20 -0
  40. data/app/models/action.rb +61 -44
  41. data/app/models/authorization.rb +55 -10
  42. data/app/models/follow.rb +6 -0
  43. data/app/models/persistent_trigger.rb +11 -1
  44. data/app/models/project.rb +5 -27
  45. data/app/models/user.rb +15 -59
  46. data/app/presenters/project_presenter.rb +2 -2
  47. data/app/views/actions/_actions.html.erb +8 -5
  48. data/app/views/actions/index.html.erb +1 -1
  49. data/app/views/actions/running.html.erb +9 -15
  50. data/app/views/actions/show.html.erb +6 -3
  51. data/app/views/actions/unqueued.html.erb +41 -0
  52. data/app/views/authorizations/_form.html.erb +28 -16
  53. data/app/views/authorizations/index.html.erb +9 -4
  54. data/app/views/{oauth/providers/edit.html.erb → authorizations/oauth2_callback.html.erb} +3 -2
  55. data/app/views/devise/sessions/new.html.erb +0 -8
  56. data/app/views/errors/index.html.erb +9 -5
  57. data/app/views/layouts/_navigation.html.erb +9 -0
  58. data/app/views/layouts/application.html.erb +11 -6
  59. data/app/views/layouts/dashboard.html.erb +9 -0
  60. data/app/views/projects/_form.html.erb +7 -18
  61. data/app/views/projects/_header.html.erb +2 -6
  62. data/app/views/projects/index.html.erb +4 -4
  63. data/app/views/teams/_form.html.erb +7 -17
  64. data/app/views/teams/index.html.erb +1 -1
  65. data/app/views/users/_form.html.erb +1 -38
  66. data/config/application.rb +8 -5
  67. data/config/initializers/devise.rb +0 -14
  68. data/config/initializers/secret_token.rb +8 -13
  69. data/config/routes.rb +12 -28
  70. data/db/migrate/20130706141443_drop_deprecated_project_roles.rb +5 -1
  71. data/db/migrate/20170118005958_remove_antecedents_from_versions_of_tickets.rb +1 -1
  72. data/db/migrate/20170130011016_drop_users_environments_subscribed_to.rb +9 -0
  73. data/db/migrate/20170205004452_drop_settings.rb +12 -0
  74. data/db/migrate/20170206002030_drop_extension_hstore.rb +9 -0
  75. data/db/migrate/20170206002732_drop_legacy_columns_from_users.rb +10 -0
  76. data/db/migrate/20170209022159_rename_projects_color_to_color_name.rb +5 -0
  77. data/db/migrate/20170213001453_change_providers_from_models_to_extensions.rb +27 -0
  78. data/db/migrate/20170215012012_add_props_to_authorizations.rb +5 -0
  79. data/db/migrate/20170216041034_add_user_to_persistent_triggers.rb +5 -0
  80. data/db/migrate/20170226201504_create_follows.rb +20 -0
  81. data/db/migrate/20170301014051_drop_name_from_authorizations.rb +9 -0
  82. data/db/migrate/20170307032041_add_created_at_to_actions.rb +11 -0
  83. data/db/migrate/20170307035755_allow_actions_started_at_to_be_null.rb +5 -0
  84. data/db/migrate/20170310024505_replace_authorizations_provider_name_with_type.rb +12 -0
  85. data/db/migrate/20170329030329_drop_consumer_tokens.rb +9 -0
  86. data/db/structure.sql +187 -212
  87. data/houston-core.gemspec +10 -13
  88. data/lib/houston/boot.rb +1 -4
  89. data/lib/houston/boot/actions.rb +24 -21
  90. data/lib/houston/boot/configuration.rb +46 -113
  91. data/lib/houston/boot/extensions.rb +54 -341
  92. data/lib/houston/boot/extensions/deprecated.rb +194 -0
  93. data/lib/houston/boot/extensions/dsl.rb +99 -0
  94. data/lib/houston/boot/extensions/events.rb +81 -0
  95. data/lib/houston/boot/extensions/features.rb +42 -0
  96. data/lib/houston/boot/extensions/layout.rb +70 -0
  97. data/lib/houston/boot/extensions/navigation.rb +42 -0
  98. data/lib/houston/boot/extensions/oauth.rb +62 -0
  99. data/lib/houston/boot/extensions/serializers.rb +29 -0
  100. data/lib/houston/boot/extensions/view.rb +34 -0
  101. data/lib/houston/boot/observer.rb +10 -5
  102. data/{app/models/oauth → lib/houston/boot}/provider.rb +7 -5
  103. data/lib/houston/boot/running_as.rb +0 -5
  104. data/lib/houston/boot/serializer.rb +12 -6
  105. data/lib/houston/boot/{active_record_serializer.rb → serializers/active_record_serializer.rb} +0 -2
  106. data/lib/houston/boot/{readonly_hash_serializer.rb → serializers/readonly_hash_serializer.rb} +0 -2
  107. data/lib/houston/boot/timer.rb +10 -0
  108. data/lib/houston/boot/triggers.rb +27 -8
  109. data/lib/houston/version.rb +1 -1
  110. data/templates/new-instance/.gitignore +0 -4
  111. data/templates/new-instance/config/main.rb +8 -10
  112. data/templates/new-module/test/dummy/houston.rb +1 -0
  113. data/test/acceptance/layout_test.rb +58 -0
  114. data/test/acceptance/updating_props_test.rb +72 -0
  115. data/test/support/config.rb +1 -0
  116. data/test/unit/extensions/events_extension_test.rb +33 -0
  117. data/test/unit/extensions/layout_extension_test.rb +74 -0
  118. data/test/unit/extensions/navigation_extension_test.rb +62 -0
  119. data/test/unit/extensions/oauth_extension_test.rb +91 -0
  120. data/test/unit/extensions/project_features_extension_test.rb +79 -0
  121. data/test/unit/extensions/serializers_extension_test.rb +47 -0
  122. data/test/unit/extensions/view_extension_test.rb +98 -0
  123. data/test/unit/models/actions_test.rb +11 -5
  124. data/test/unit/models/configuration_test.rb +0 -8
  125. data/test/unit/models/observer_test.rb +16 -0
  126. data/test/unit/models/persistent_trigger_test.rb +29 -2
  127. data/test/unit/models/serializer_test.rb +6 -0
  128. data/test/unit/models/timer_test.rb +88 -0
  129. metadata +87 -168
  130. data/app/assets/font/octicons.eot +0 -0
  131. data/app/assets/font/octicons.svg +0 -198
  132. data/app/assets/font/octicons.ttf +0 -0
  133. data/app/assets/font/octicons.woff +0 -0
  134. data/app/assets/font/roboto-black-webfont.eot +0 -0
  135. data/app/assets/font/roboto-black-webfont.svg +0 -675
  136. data/app/assets/font/roboto-black-webfont.ttf +0 -0
  137. data/app/assets/font/roboto-black-webfont.woff +0 -0
  138. data/app/assets/font/roboto-blackitalic-webfont.eot +0 -0
  139. data/app/assets/font/roboto-blackitalic-webfont.svg +0 -677
  140. data/app/assets/font/roboto-blackitalic-webfont.ttf +0 -0
  141. data/app/assets/font/roboto-blackitalic-webfont.woff +0 -0
  142. data/app/assets/font/roboto-bold-webfont.eot +0 -0
  143. data/app/assets/font/roboto-bold-webfont.svg +0 -675
  144. data/app/assets/font/roboto-bold-webfont.ttf +0 -0
  145. data/app/assets/font/roboto-bold-webfont.woff +0 -0
  146. data/app/assets/font/roboto-bolditalic-webfont.eot +0 -0
  147. data/app/assets/font/roboto-bolditalic-webfont.svg +0 -677
  148. data/app/assets/font/roboto-bolditalic-webfont.ttf +0 -0
  149. data/app/assets/font/roboto-bolditalic-webfont.woff +0 -0
  150. data/app/assets/font/roboto-italic-webfont.eot +0 -0
  151. data/app/assets/font/roboto-italic-webfont.svg +0 -668
  152. data/app/assets/font/roboto-italic-webfont.ttf +0 -0
  153. data/app/assets/font/roboto-italic-webfont.woff +0 -0
  154. data/app/assets/font/roboto-light-webfont.eot +0 -0
  155. data/app/assets/font/roboto-light-webfont.svg +0 -666
  156. data/app/assets/font/roboto-light-webfont.ttf +0 -0
  157. data/app/assets/font/roboto-light-webfont.woff +0 -0
  158. data/app/assets/font/roboto-lightitalic-webfont.eot +0 -0
  159. data/app/assets/font/roboto-lightitalic-webfont.svg +0 -668
  160. data/app/assets/font/roboto-lightitalic-webfont.ttf +0 -0
  161. data/app/assets/font/roboto-lightitalic-webfont.woff +0 -0
  162. data/app/assets/font/roboto-medium-webfont.eot +0 -0
  163. data/app/assets/font/roboto-medium-webfont.svg +0 -675
  164. data/app/assets/font/roboto-medium-webfont.ttf +0 -0
  165. data/app/assets/font/roboto-medium-webfont.woff +0 -0
  166. data/app/assets/font/roboto-mediumitalic-webfont.eot +0 -0
  167. data/app/assets/font/roboto-mediumitalic-webfont.svg +0 -677
  168. data/app/assets/font/roboto-mediumitalic-webfont.ttf +0 -0
  169. data/app/assets/font/roboto-mediumitalic-webfont.woff +0 -0
  170. data/app/assets/font/roboto-regular-webfont.eot +0 -0
  171. data/app/assets/font/roboto-regular-webfont.svg +0 -666
  172. data/app/assets/font/roboto-regular-webfont.ttf +0 -0
  173. data/app/assets/font/roboto-regular-webfont.woff +0 -0
  174. data/app/assets/font/roboto-thin-webfont.eot +0 -0
  175. data/app/assets/font/roboto-thin-webfont.svg +0 -666
  176. data/app/assets/font/roboto-thin-webfont.ttf +0 -0
  177. data/app/assets/font/roboto-thin-webfont.woff +0 -0
  178. data/app/assets/font/roboto-thinitalic-webfont.eot +0 -0
  179. data/app/assets/font/roboto-thinitalic-webfont.svg +0 -668
  180. data/app/assets/font/roboto-thinitalic-webfont.ttf +0 -0
  181. data/app/assets/font/roboto-thinitalic-webfont.woff +0 -0
  182. data/app/assets/images/bug-fixed-128.png +0 -0
  183. data/app/assets/images/bug-fixed-32.png +0 -0
  184. data/app/assets/images/bug-fixed-48.png +0 -0
  185. data/app/assets/images/bug-new-128.png +0 -0
  186. data/app/assets/images/bug-new-32.png +0 -0
  187. data/app/assets/images/bug-new-48.png +0 -0
  188. data/app/assets/images/bug-open-32.png +0 -0
  189. data/app/assets/images/bug-zero-128.png +0 -0
  190. data/app/assets/images/bug-zero-48.png +0 -0
  191. data/app/assets/images/drag-grip.png +0 -0
  192. data/app/assets/javascripts/houston/core/burndown_chart.coffee +0 -111
  193. data/app/assets/javascripts/houston/core/stacked_area_graph.coffee +0 -113
  194. data/app/assets/javascripts/houston/core/stacked_bar_graph.coffee +0 -108
  195. data/app/assets/stylesheets/houston/application/project_tiles.scss +0 -26
  196. data/app/assets/stylesheets/houston/application/tips.scss +0 -5
  197. data/app/assets/stylesheets/houston/core/octicons-icons.scss +0 -221
  198. data/app/assets/stylesheets/houston/core/octicons.scss.erb +0 -9
  199. data/app/assets/stylesheets/houston/core/roboto.scss.erb +0 -131
  200. data/app/concerns/historical_weekly_stats.rb +0 -15
  201. data/app/concerns/nosync.rb +0 -21
  202. data/app/controllers/oauth/providers_controller.rb +0 -45
  203. data/app/controllers/project_roles_controller.rb +0 -22
  204. data/app/controllers/settings_controller.rb +0 -14
  205. data/app/controllers/tester_bar_controller.rb +0 -12
  206. data/app/controllers/user_credentials_controller.rb +0 -24
  207. data/app/models/role.rb +0 -33
  208. data/app/models/setting.rb +0 -10
  209. data/app/models/settings.rb +0 -38
  210. data/app/models/slackdown.rb +0 -23
  211. data/app/models/user_credentials.rb +0 -27
  212. data/app/views/errors/_actions.html.erb +0 -17
  213. data/app/views/layouts/_tester_bar.html.erb +0 -6
  214. data/app/views/layouts/minimal.html.erb +0 -50
  215. data/app/views/layouts/naked.html.erb +0 -47
  216. data/app/views/layouts/naked_dashboard.html.erb +0 -50
  217. data/app/views/oauth/providers/_form.html.erb +0 -54
  218. data/app/views/oauth/providers/index.html.erb +0 -41
  219. data/app/views/oauth/providers/new.html.erb +0 -7
  220. data/config/initializers/add_navigation_renderers.rb +0 -5
  221. data/config/initializers/vestal_versions.rb +0 -9
  222. data/db/migrate/20130519163615_create_user_credentials.rb +0 -18
  223. data/lib/houston/boot/events.rb +0 -10
  224. data/lib/tasks/keypair.rake +0 -17
  225. data/vendor/assets/javascripts/jquery.pjax.js +0 -817
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: bb13d5eecf56a92b97bf57602f08952d35e5c939
4
- data.tar.gz: 657f17128b2853f46c5dc1133bd2ee2afd61d42a
3
+ metadata.gz: e4e1d6c3985ae5161a50c0466746cae431ad3714
4
+ data.tar.gz: 26c7ef3631e87aff62d30fc043bb01f85112f35e
5
5
  SHA512:
6
- metadata.gz: fcecec80ae7c7a153d232d4db2f01a7ee31b95dc4918091df07dd34755b62b6a4d45dab3bae64c5a02833b5606285f1dc6a71aee7a95268c3b9db1fbe46fd42b
7
- data.tar.gz: 6e2e4e806e8eaef10afd1eeffa3df4a4a007c8091c3c046cb5b10721d00b4f8b8d261f6b2e322c958727fa442216ae5789bba26027ed21d03e563209fc9618e2
6
+ metadata.gz: f72089a72bfec7d3941bc2c603b12860db583c1979e2f49b07d44faf6f4cf56d94d209e0d0952feff7f05d966b623a60d959b6e86515e97be17607d3bec74aaa
7
+ data.tar.gz: 895c8c494072732ecfc593e5422628dc712c612d5811b0b189d26d3f9d37c683361bee6fd243ecb74f46d245a9d595ff58da63da86e99691375a4f3eb2d673a5
data/Gemfile CHANGED
@@ -15,6 +15,7 @@ group :test do
15
15
  gem "rr"
16
16
  gem "webmock", require: "webmock/minitest"
17
17
  gem "factory_girl_rails"
18
+ gem "launchy"
18
19
 
19
20
  # For Jenkins
20
21
  gem "simplecov-json", require: false
data/Gemfile.lock CHANGED
@@ -1,13 +1,13 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- houston-core (0.8.4)
4
+ houston-core (0.9.0.rc1)
5
5
  activerecord-import
6
6
  activerecord-pluck_in_batches (~> 0.2.0)
7
7
  addressable (~> 2.3.8)
8
- attentive (>= 0.3.6)
8
+ attentive (>= 0.3.9)
9
9
  browser (~> 2.3.0)
10
- cancan (~> 1.6.10)
10
+ cancancan (~> 1.16.0)
11
11
  coffee-rails (~> 4.1.0)
12
12
  concurrent-ruby (~> 1.0.2)
13
13
  devise
@@ -17,67 +17,64 @@ PATH
17
17
  faraday-raise-errors (~> 0.2.0)
18
18
  gemoji (~> 2.1.0)
19
19
  handlebars_assets (~> 0.23.0)
20
- houston-devise_ldap_authenticatable
21
- houston-vestal_versions
22
- neat-rails
23
- nested_editor_for
20
+ kramdown
21
+ neat-rails (~> 0.5.1)
24
22
  nokogiri (~> 1.7)
25
23
  oauth2
26
24
  oj (~> 2.18)
27
25
  openxml-xlsx (>= 0.2.0)
28
26
  pg (~> 0.19.0)
29
27
  pg_search (~> 1.0.5)
30
- premailer (~> 1.8.6)
28
+ premailer (~> 1.10.0)
31
29
  progressbar (~> 0.21.0)
32
30
  rack-utf8_sanitizer (~> 1.3.1)
33
31
  rails (~> 5.0.0)
34
- redcarpet (~> 3.3.2)
35
- rufus-scheduler (~> 3.2.0)
32
+ rufus-scheduler (~> 3.3.4)
36
33
  sass-rails (~> 5.0)
37
- strongbox (~> 0.7.2)
34
+ slackdown (>= 0.2.1)
38
35
  thor
39
36
  uglifier (>= 2.7.2)
40
37
 
41
38
  GEM
42
39
  remote: https://rubygems.org/
43
40
  specs:
44
- actioncable (5.0.1)
45
- actionpack (= 5.0.1)
46
- nio4r (~> 1.2)
41
+ actioncable (5.0.2)
42
+ actionpack (= 5.0.2)
43
+ nio4r (>= 1.2, < 3.0)
47
44
  websocket-driver (~> 0.6.1)
48
- actionmailer (5.0.1)
49
- actionpack (= 5.0.1)
50
- actionview (= 5.0.1)
51
- activejob (= 5.0.1)
45
+ actionmailer (5.0.2)
46
+ actionpack (= 5.0.2)
47
+ actionview (= 5.0.2)
48
+ activejob (= 5.0.2)
52
49
  mail (~> 2.5, >= 2.5.4)
53
50
  rails-dom-testing (~> 2.0)
54
- actionpack (5.0.1)
55
- actionview (= 5.0.1)
56
- activesupport (= 5.0.1)
51
+ actionpack (5.0.2)
52
+ actionview (= 5.0.2)
53
+ activesupport (= 5.0.2)
57
54
  rack (~> 2.0)
58
55
  rack-test (~> 0.6.3)
59
56
  rails-dom-testing (~> 2.0)
60
57
  rails-html-sanitizer (~> 1.0, >= 1.0.2)
61
- actionview (5.0.1)
62
- activesupport (= 5.0.1)
58
+ actionview (5.0.2)
59
+ activesupport (= 5.0.2)
63
60
  builder (~> 3.1)
64
61
  erubis (~> 2.7.0)
65
62
  rails-dom-testing (~> 2.0)
66
- rails-html-sanitizer (~> 1.0, >= 1.0.2)
67
- activejob (5.0.1)
68
- activesupport (= 5.0.1)
63
+ rails-html-sanitizer (~> 1.0, >= 1.0.3)
64
+ activejob (5.0.2)
65
+ activesupport (= 5.0.2)
69
66
  globalid (>= 0.3.6)
70
- activemodel (5.0.1)
71
- activesupport (= 5.0.1)
72
- activerecord (5.0.1)
73
- activemodel (= 5.0.1)
74
- activesupport (= 5.0.1)
67
+ activemodel (5.0.2)
68
+ activesupport (= 5.0.2)
69
+ activerecord (5.0.2)
70
+ activemodel (= 5.0.2)
71
+ activesupport (= 5.0.2)
75
72
  arel (~> 7.0)
76
- activerecord-import (0.17.1)
73
+ activerecord-import (0.17.2)
77
74
  activerecord (>= 3.2)
78
75
  activerecord-pluck_in_batches (0.2.0)
79
76
  activerecord (>= 4.2.7, < 5.1.0)
80
- activesupport (5.0.1)
77
+ activesupport (5.0.2)
81
78
  concurrent-ruby (~> 1.0, >= 1.0.2)
82
79
  i18n (~> 0.7)
83
80
  minitest (~> 5.1)
@@ -85,13 +82,13 @@ GEM
85
82
  addressable (2.3.8)
86
83
  ansi (1.5.0)
87
84
  arel (7.1.4)
88
- attentive (0.3.8)
89
- thread_safe
85
+ attentive (0.3.9)
86
+ concurrent-ruby
90
87
  bcrypt (3.1.11)
91
88
  browser (2.3.0)
92
89
  builder (3.2.3)
93
- cancan (1.6.10)
94
- capybara (2.12.1)
90
+ cancancan (1.16.0)
91
+ capybara (2.13.0)
95
92
  addressable
96
93
  mime-types (>= 1.16)
97
94
  nokogiri (>= 1.3.3)
@@ -106,18 +103,18 @@ GEM
106
103
  coffee-script-source
107
104
  execjs
108
105
  coffee-script-source (1.12.2)
109
- concurrent-ruby (1.0.4)
106
+ concurrent-ruby (1.0.5)
110
107
  crack (0.4.3)
111
108
  safe_yaml (~> 1.0.0)
112
- css_parser (1.4.8)
109
+ css_parser (1.4.10)
113
110
  addressable
114
- devise (4.2.0)
111
+ devise (4.2.1)
115
112
  bcrypt (~> 3.0)
116
113
  orm_adapter (~> 0.1)
117
114
  railties (>= 4.1.0, < 5.1)
118
115
  responders
119
116
  warden (~> 1.2.3)
120
- devise_invitable (1.7.1)
117
+ devise_invitable (1.7.2)
121
118
  actionmailer (>= 4.1.0)
122
119
  devise (>= 4.0.0)
123
120
  docile (1.1.5)
@@ -143,16 +140,13 @@ GEM
143
140
  sprockets (>= 2.0.0)
144
141
  tilt (>= 1.2)
145
142
  hashdiff (0.3.2)
146
- houston-devise_ldap_authenticatable (0.7.1)
147
- devise (>= 3.0.0)
148
- net-ldap (~> 0.12.1)
149
- houston-vestal_versions (2.0.1)
150
- activerecord (>= 3, < 6)
151
- activesupport (>= 3, < 6)
152
143
  htmlentities (4.3.4)
153
- i18n (0.8.0)
144
+ i18n (0.8.1)
154
145
  json (2.0.3)
155
146
  jwt (1.5.6)
147
+ kramdown (1.13.2)
148
+ launchy (2.4.3)
149
+ addressable (~> 2.3)
156
150
  loofah (2.0.3)
157
151
  nokogiri (>= 1.5.9)
158
152
  mail (2.6.4)
@@ -173,19 +167,17 @@ GEM
173
167
  multi_json (1.12.1)
174
168
  multi_xml (0.6.0)
175
169
  multipart-post (2.0.0)
176
- neat-rails (0.5.0)
177
- nested_editor_for (0.1.1)
178
- net-ldap (0.12.1)
179
- nio4r (1.2.1)
170
+ neat-rails (0.5.1)
171
+ nio4r (2.0.0)
180
172
  nokogiri (1.7.1)
181
173
  mini_portile2 (~> 2.1.0)
182
- oauth2 (1.3.0)
183
- faraday (>= 0.8, < 0.11)
174
+ oauth2 (1.3.1)
175
+ faraday (>= 0.8, < 0.12)
184
176
  jwt (~> 1.0)
185
177
  multi_json (~> 1.3)
186
178
  multi_xml (~> 0.5)
187
179
  rack (>= 1.2, < 3)
188
- oj (2.18.1)
180
+ oj (2.18.5)
189
181
  openxml-package (0.2.7)
190
182
  nokogiri
191
183
  ox
@@ -194,14 +186,15 @@ GEM
194
186
  nokogiri
195
187
  openxml-package (>= 0.2.0)
196
188
  orm_adapter (0.5.0)
197
- ox (2.4.9)
189
+ ox (2.4.11)
198
190
  pg (0.19.0)
199
191
  pg_search (1.0.6)
200
192
  activerecord (>= 3.1)
201
193
  activesupport (>= 3.1)
202
194
  arel
203
- premailer (1.8.7)
204
- css_parser (>= 1.4.5)
195
+ premailer (1.10.2)
196
+ addressable
197
+ css_parser (>= 1.4.10)
205
198
  htmlentities (>= 4.0.0)
206
199
  progressbar (0.21.0)
207
200
  pry (0.10.4)
@@ -213,37 +206,37 @@ GEM
213
206
  rack (>= 1.0)
214
207
  rack-utf8_sanitizer (1.3.2)
215
208
  rack (>= 1.0, < 3.0)
216
- rails (5.0.1)
217
- actioncable (= 5.0.1)
218
- actionmailer (= 5.0.1)
219
- actionpack (= 5.0.1)
220
- actionview (= 5.0.1)
221
- activejob (= 5.0.1)
222
- activemodel (= 5.0.1)
223
- activerecord (= 5.0.1)
224
- activesupport (= 5.0.1)
209
+ rails (5.0.2)
210
+ actioncable (= 5.0.2)
211
+ actionmailer (= 5.0.2)
212
+ actionpack (= 5.0.2)
213
+ actionview (= 5.0.2)
214
+ activejob (= 5.0.2)
215
+ activemodel (= 5.0.2)
216
+ activerecord (= 5.0.2)
217
+ activesupport (= 5.0.2)
225
218
  bundler (>= 1.3.0, < 2.0)
226
- railties (= 5.0.1)
219
+ railties (= 5.0.2)
227
220
  sprockets-rails (>= 2.0.0)
228
221
  rails-dom-testing (2.0.2)
229
222
  activesupport (>= 4.2.0, < 6.0)
230
223
  nokogiri (~> 1.6)
231
224
  rails-html-sanitizer (1.0.3)
232
225
  loofah (~> 2.0)
233
- railties (5.0.1)
234
- actionpack (= 5.0.1)
235
- activesupport (= 5.0.1)
226
+ railties (5.0.2)
227
+ actionpack (= 5.0.2)
228
+ activesupport (= 5.0.2)
236
229
  method_source
237
230
  rake (>= 0.8.7)
238
231
  thor (>= 0.18.1, < 2.0)
239
232
  rake (12.0.0)
240
- redcarpet (3.3.4)
241
233
  responders (2.3.0)
242
234
  railties (>= 4.2.0, < 5.1)
243
235
  rr (1.2.0)
244
236
  ruby-progressbar (1.8.1)
245
237
  rubyzip (1.2.1)
246
- rufus-scheduler (3.2.2)
238
+ rufus-scheduler (3.3.4)
239
+ tzinfo
247
240
  safe_yaml (1.0.4)
248
241
  sass (3.4.23)
249
242
  sass-rails (5.0.6)
@@ -261,6 +254,8 @@ GEM
261
254
  simplecov-json (0.2)
262
255
  json
263
256
  simplecov
257
+ slackdown (0.2.2)
258
+ kramdown (~> 1.13.2)
264
259
  slop (3.6.0)
265
260
  sprockets (3.7.1)
266
261
  concurrent-ruby (~> 1.0)
@@ -269,15 +264,13 @@ GEM
269
264
  actionpack (>= 4.0)
270
265
  activesupport (>= 4.0)
271
266
  sprockets (>= 3.0.0)
272
- strongbox (0.7.2)
273
- activerecord
274
267
  thor (0.19.4)
275
- thread_safe (0.3.5)
276
- tilt (2.0.6)
268
+ thread_safe (0.3.6)
269
+ tilt (2.0.7)
277
270
  timecop (0.8.1)
278
271
  tzinfo (1.2.2)
279
272
  thread_safe (~> 0.1)
280
- uglifier (3.0.4)
273
+ uglifier (3.1.11)
281
274
  execjs (>= 0.3.0, < 3)
282
275
  warden (1.2.7)
283
276
  rack (>= 1.0)
@@ -298,6 +291,7 @@ DEPENDENCIES
298
291
  capybara
299
292
  factory_girl_rails
300
293
  houston-core!
294
+ launchy
301
295
  minitest
302
296
  minitest-reporters
303
297
  minitest-reporters-turn_reporter
@@ -0,0 +1,4 @@
1
+ class @Houston.Role extends Backbone.Model
2
+
3
+ class @Houston.Roles extends Backbone.Collection
4
+ model: Houston.Role
@@ -0,0 +1,44 @@
1
+ class @Houston.NestedRow extends Neat.ModelEditor
2
+ tagName: 'li'
3
+ className: 'nested-row'
4
+
5
+ context: ->
6
+ context = super
7
+ context.index = @index
8
+ context
9
+
10
+ destroy: (e)->
11
+ e?.preventDefault()
12
+ @$el.addClass('hidden')
13
+ @model.set('destroyed', true)
14
+
15
+
16
+
17
+ class @Houston.NestedResources extends Neat.CollectionEditor
18
+ modelView: Houston.NestedRow
19
+ pageSize: Infinity
20
+ index: 0
21
+
22
+ initialize: (options)->
23
+ super
24
+ @collection.bind 'reset add change', @showOrHideAdd, @
25
+ $(@el).delegate 'a.add-nested-link', 'click', _.bind(@addResource, @)
26
+
27
+ afterRender: ->
28
+ super
29
+ @showOrHideAdd()
30
+
31
+ addResource: (e)->
32
+ e?.preventDefault()
33
+ @collection.add new @collection.model()
34
+
35
+ constructModelView: (options)->
36
+ view = super(options)
37
+ view.index = (@index += 1)
38
+ view
39
+
40
+ showOrHideAdd: ->
41
+ visibleLinks = @$el.find('.nested-row:visible .add-nested').toArray()
42
+ lastLink = visibleLinks.pop()
43
+ $(visibleLinks).hide()
44
+ $(lastLink).show()
@@ -0,0 +1,10 @@
1
+ class @Houston.TeamRolesView extends Houston.NestedResources
2
+ resource: 'roles'
3
+ viewPath: 'houston/teams/roles'
4
+
5
+ initialize: (options)->
6
+ @collection = new Houston.Roles(options.values, parse: true)
7
+ super
8
+ @options = options
9
+ @templateOptions.roles = @options.roles
10
+ @templateOptions.users = [{}].concat @options.users
@@ -14,8 +14,10 @@
14
14
  //= require_tree ./core
15
15
  //= require md5
16
16
  //= require_tree ../../templates
17
- //= require_tree ./app
18
17
  //= require_self
18
+ //= require_tree ./app
19
+
20
+ window.Neat.template = HandlebarsTemplates
19
21
 
20
22
  $.tablesorter.defaults.cssAsc = 'sort-asc';
21
23
  $.tablesorter.defaults.cssDesc = 'sort-desc';
@@ -0,0 +1,26 @@
1
+ $.extend
2
+
3
+ # Extend jQuery with functions for PUT and DELETE requests.
4
+ put: (url, data, callback, type)->
5
+ if jQuery.isFunction(data)
6
+ callback = data
7
+ data = {}
8
+
9
+ data = data || {}
10
+ data['_method'] = 'put'
11
+ jQuery.post(url, data, callback, type)
12
+
13
+ destroy: (url, data, callback, type)->
14
+ if jQuery.isFunction(data)
15
+ callback = data
16
+ data = {}
17
+
18
+ data = data || {}
19
+ data._method = 'delete'
20
+ jQuery.post(url, data, callback, type)
21
+
22
+
23
+
24
+ $(document).ajaxSend (e, jqxhr, settings)->
25
+ return if settings.type is 'GET'
26
+ jqxhr.setRequestHeader 'X-CSRF-Token', App.meta('csrf-token')
@@ -91,51 +91,6 @@ window.App =
91
91
  date = new Date(date.getTime())
92
92
  App.truncateDate(date)
93
93
 
94
- promptForCredentialsTo: (service)->
95
- html = """
96
- <div class="modal hide fade">
97
- <form class="form-horizontal" id="user_credentials_form">
98
- <div class="modal-header">
99
- <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
100
- <h3>Log in to #{service}</h3>
101
- </div>
102
- <div class="modal-body">
103
- <div class="control-group">
104
- <label class="control-label" for="user_credentials_login">Login</label>
105
- <div class="controls">
106
- <input type="text" id="user_credentials_login">
107
- </div>
108
- </div>
109
- <div class="control-group">
110
- <label class="control-label" for="user_credentials_password">Password</label>
111
- <div class="controls">
112
- <input type="password" id="user_credentials_password">
113
- </div>
114
- </div>
115
- </div>
116
- <div class="modal-footer">
117
- <button type="submit" class="btn btn-primary">Sign in</button>
118
- </div>
119
- </form>
120
- </div>
121
- """
122
- $modal = $(html).modal()
123
- $modal.on 'hidden', -> $(@).remove()
124
- $modal.on 'shown', (e)=>
125
- $input = $modal.find('input[type="text"]:first').select()
126
- $modal.find('button[type="submit"]').click (e)=>
127
- e.preventDefault()
128
- xhr = $.put '/credentials',
129
- service: service
130
- login: $modal.find('#user_credentials_login').val()
131
- password: $modal.find('#user_credentials_password').val()
132
- xhr.success ->
133
- $modal.modal('hide')
134
- xhr.error (response)->
135
- $form = $('#user_credentials_form')
136
- $form.find('.alert').remove()
137
- Errors.fromResponse(response).renderToAlert().prependTo $form
138
-
139
94
  confirmDelete: (options)->
140
95
  html = """
141
96
  <div class="modal hide">