attorney 0.0.0 → 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/Rakefile +19 -3
- data/app/assets/config/attorney_manifest.js +2 -0
- data/app/assets/javascripts/attorney/application.js +16 -0
- data/app/assets/javascripts/attorney/form_errors.js +13 -0
- data/app/assets/javascripts/attorney/rich_editor.js +19 -0
- data/app/assets/stylesheets/attorney/application.css +16 -0
- data/app/controllers/attorney/admin/documents_controller.rb +49 -0
- data/app/controllers/attorney/application_controller.rb +5 -0
- data/app/controllers/attorney/documents_controller.rb +11 -0
- data/app/helpers/attorney/application_helper.rb +13 -0
- data/app/helpers/attorney/documents_helper.rb +11 -0
- data/app/jobs/attorney/application_job.rb +4 -0
- data/app/mailers/attorney/application_mailer.rb +6 -0
- data/app/models/attorney/application_record.rb +5 -0
- data/app/models/attorney/document.rb +19 -0
- data/app/views/attorney/admin/documents/_form.html.erb +49 -0
- data/app/views/attorney/admin/documents/edit.html.erb +3 -0
- data/app/views/attorney/admin/documents/index.html.erb +37 -0
- data/app/views/attorney/admin/documents/new.html.erb +3 -0
- data/app/views/attorney/admin/documents/show.html.erb +13 -0
- data/app/views/attorney/documents/show.html.erb +1 -0
- data/app/views/layouts/attorney/application.html.erb +25 -0
- data/config/routes.rb +9 -0
- data/db/migrate/20180205173208_create_attorney_documents.rb +13 -0
- data/lib/attorney.rb +12 -2
- data/lib/attorney/engine.rb +14 -0
- data/lib/attorney/version.rb +1 -1
- data/lib/tasks/attorney_tasks.rake +4 -0
- data/spec/controllers/attorney/admin/documents_controller_spec.rb +130 -0
- data/spec/controllers/attorney/documents_controller_spec.rb +26 -0
- data/spec/features/attorney/admin/documents_spec.rb +87 -0
- data/spec/features/attorney/documents_spec.rb +19 -0
- data/spec/helpers/documents_helper_spec.rb +21 -0
- data/spec/lib/attorney_spec.rb +6 -0
- data/spec/models/attorney/document_spec.rb +28 -0
- data/spec/rails_helper.rb +109 -0
- data/spec/spec_helper.rb +96 -0
- data/spec/support/capybara.rb +1 -0
- data/spec/support/dummy/rails5_0/Rakefile +6 -0
- data/spec/support/dummy/rails5_0/app/assets/config/manifest.js +5 -0
- data/spec/support/dummy/rails5_0/app/assets/images/.keep +0 -0
- data/spec/support/dummy/rails5_0/app/assets/javascripts/application.js +13 -0
- data/spec/support/dummy/rails5_0/app/assets/javascripts/cable.js +13 -0
- data/spec/support/dummy/rails5_0/app/assets/javascripts/channels/.keep +0 -0
- data/spec/support/dummy/rails5_0/app/assets/stylesheets/application.css +15 -0
- data/spec/support/dummy/rails5_0/app/channels/application_cable/channel.rb +4 -0
- data/spec/support/dummy/rails5_0/app/channels/application_cable/connection.rb +4 -0
- data/spec/support/dummy/rails5_0/app/controllers/application_controller.rb +3 -0
- data/spec/support/dummy/rails5_0/app/controllers/concerns/.keep +0 -0
- data/spec/support/dummy/rails5_0/app/helpers/application_helper.rb +2 -0
- data/spec/support/dummy/rails5_0/app/jobs/application_job.rb +2 -0
- data/spec/support/dummy/rails5_0/app/mailers/application_mailer.rb +4 -0
- data/spec/support/dummy/rails5_0/app/models/application_record.rb +3 -0
- data/spec/support/dummy/rails5_0/app/models/concerns/.keep +0 -0
- data/spec/support/dummy/rails5_0/app/views/layouts/application.html.erb +15 -0
- data/spec/support/dummy/rails5_0/app/views/layouts/mailer.html.erb +13 -0
- data/spec/support/dummy/rails5_0/app/views/layouts/mailer.text.erb +1 -0
- data/spec/support/dummy/rails5_0/bin/bundle +3 -0
- data/spec/support/dummy/rails5_0/bin/rails +4 -0
- data/spec/support/dummy/rails5_0/bin/rake +4 -0
- data/spec/support/dummy/rails5_0/bin/setup +34 -0
- data/spec/support/dummy/rails5_0/bin/update +29 -0
- data/spec/support/dummy/rails5_0/config.ru +5 -0
- data/spec/support/dummy/rails5_0/config/application.rb +15 -0
- data/spec/support/dummy/rails5_0/config/boot.rb +5 -0
- data/spec/support/dummy/rails5_0/config/cable.yml +9 -0
- data/spec/support/dummy/rails5_0/config/database.yml +25 -0
- data/spec/support/dummy/rails5_0/config/environment.rb +5 -0
- data/spec/support/dummy/rails5_0/config/environments/development.rb +54 -0
- data/spec/support/dummy/rails5_0/config/environments/production.rb +86 -0
- data/spec/support/dummy/rails5_0/config/environments/test.rb +42 -0
- data/spec/support/dummy/rails5_0/config/initializers/application_controller_renderer.rb +8 -0
- data/spec/support/dummy/rails5_0/config/initializers/assets.rb +11 -0
- data/spec/support/dummy/rails5_0/config/initializers/backtrace_silencers.rb +7 -0
- data/spec/support/dummy/rails5_0/config/initializers/cookies_serializer.rb +5 -0
- data/spec/support/dummy/rails5_0/config/initializers/filter_parameter_logging.rb +4 -0
- data/spec/support/dummy/rails5_0/config/initializers/inflections.rb +16 -0
- data/spec/support/dummy/rails5_0/config/initializers/mime_types.rb +4 -0
- data/spec/support/dummy/rails5_0/config/initializers/new_framework_defaults.rb +26 -0
- data/spec/support/dummy/rails5_0/config/initializers/session_store.rb +3 -0
- data/spec/support/dummy/rails5_0/config/initializers/wrap_parameters.rb +14 -0
- data/spec/support/dummy/rails5_0/config/locales/en.yml +23 -0
- data/spec/support/dummy/rails5_0/config/puma.rb +47 -0
- data/spec/support/dummy/rails5_0/config/routes.rb +3 -0
- data/spec/support/dummy/rails5_0/config/secrets.yml +22 -0
- data/spec/support/dummy/rails5_0/config/spring.rb +6 -0
- data/spec/support/dummy/rails5_0/db/schema.rb +24 -0
- data/spec/support/dummy/rails5_0/lib/assets/.keep +0 -0
- data/spec/support/dummy/rails5_0/log/.keep +0 -0
- data/spec/support/dummy/rails5_0/public/404.html +67 -0
- data/spec/support/dummy/rails5_0/public/422.html +67 -0
- data/spec/support/dummy/rails5_0/public/500.html +66 -0
- data/spec/support/dummy/rails5_0/public/apple-touch-icon-precomposed.png +0 -0
- data/spec/support/dummy/rails5_0/public/apple-touch-icon.png +0 -0
- data/spec/support/dummy/rails5_0/public/favicon.ico +0 -0
- data/spec/support/dummy/rails5_1/Rakefile +6 -0
- data/spec/support/dummy/rails5_1/app/assets/config/manifest.js +5 -0
- data/spec/support/dummy/rails5_1/app/assets/images/.keep +0 -0
- data/spec/support/dummy/rails5_1/app/assets/javascripts/application.js +13 -0
- data/spec/support/dummy/rails5_1/app/assets/javascripts/cable.js +13 -0
- data/spec/support/dummy/rails5_1/app/assets/javascripts/channels/.keep +0 -0
- data/spec/support/dummy/rails5_1/app/assets/stylesheets/application.css +15 -0
- data/spec/support/dummy/rails5_1/app/channels/application_cable/channel.rb +4 -0
- data/spec/support/dummy/rails5_1/app/channels/application_cable/connection.rb +4 -0
- data/spec/support/dummy/rails5_1/app/controllers/application_controller.rb +4 -0
- data/spec/support/dummy/rails5_1/app/controllers/concerns/.keep +0 -0
- data/spec/support/dummy/rails5_1/app/helpers/application_helper.rb +2 -0
- data/spec/support/dummy/rails5_1/app/jobs/application_job.rb +2 -0
- data/spec/support/dummy/rails5_1/app/mailers/application_mailer.rb +4 -0
- data/spec/support/dummy/rails5_1/app/models/application_record.rb +3 -0
- data/spec/support/dummy/rails5_1/app/models/concerns/.keep +0 -0
- data/spec/support/dummy/rails5_1/app/views/layouts/mailer.html.erb +13 -0
- data/spec/support/dummy/rails5_1/app/views/layouts/mailer.text.erb +1 -0
- data/spec/support/dummy/rails5_1/app/views/layouts/main.html.erb +15 -0
- data/spec/support/dummy/rails5_1/bin/bundle +3 -0
- data/spec/support/dummy/rails5_1/bin/rails +4 -0
- data/spec/support/dummy/rails5_1/bin/rake +4 -0
- data/spec/support/dummy/rails5_1/bin/setup +38 -0
- data/spec/support/dummy/rails5_1/bin/update +29 -0
- data/spec/support/dummy/rails5_1/bin/yarn +11 -0
- data/spec/support/dummy/rails5_1/config.ru +5 -0
- data/spec/support/dummy/rails5_1/config/application.rb +18 -0
- data/spec/support/dummy/rails5_1/config/boot.rb +5 -0
- data/spec/support/dummy/rails5_1/config/cable.yml +10 -0
- data/spec/support/dummy/rails5_1/config/database.yml +25 -0
- data/spec/support/dummy/rails5_1/config/environment.rb +5 -0
- data/spec/support/dummy/rails5_1/config/environments/development.rb +54 -0
- data/spec/support/dummy/rails5_1/config/environments/production.rb +91 -0
- data/spec/support/dummy/rails5_1/config/environments/test.rb +42 -0
- data/spec/support/dummy/rails5_1/config/initializers/application_controller_renderer.rb +8 -0
- data/spec/support/dummy/rails5_1/config/initializers/assets.rb +14 -0
- data/spec/support/dummy/rails5_1/config/initializers/attorney.rb +1 -0
- data/spec/support/dummy/rails5_1/config/initializers/backtrace_silencers.rb +7 -0
- data/spec/support/dummy/rails5_1/config/initializers/cookies_serializer.rb +5 -0
- data/spec/support/dummy/rails5_1/config/initializers/filter_parameter_logging.rb +4 -0
- data/spec/support/dummy/rails5_1/config/initializers/inflections.rb +16 -0
- data/spec/support/dummy/rails5_1/config/initializers/mime_types.rb +4 -0
- data/spec/support/dummy/rails5_1/config/initializers/wrap_parameters.rb +14 -0
- data/spec/support/dummy/rails5_1/config/locales/en.yml +33 -0
- data/spec/support/dummy/rails5_1/config/puma.rb +56 -0
- data/spec/support/dummy/rails5_1/config/routes.rb +3 -0
- data/spec/support/dummy/rails5_1/config/secrets.yml +32 -0
- data/spec/support/dummy/rails5_1/config/spring.rb +6 -0
- data/spec/support/dummy/rails5_1/db/schema.rb +24 -0
- data/spec/support/dummy/rails5_1/lib/assets/.keep +0 -0
- data/spec/support/dummy/rails5_1/log/.keep +0 -0
- data/spec/support/dummy/rails5_1/package.json +5 -0
- data/spec/support/dummy/rails5_1/public/404.html +67 -0
- data/spec/support/dummy/rails5_1/public/422.html +67 -0
- data/spec/support/dummy/rails5_1/public/500.html +66 -0
- data/spec/support/dummy/rails5_1/public/apple-touch-icon-precomposed.png +0 -0
- data/spec/support/dummy/rails5_1/public/apple-touch-icon.png +0 -0
- data/spec/support/dummy/rails5_1/public/favicon.ico +0 -0
- data/spec/support/helpers/auth.rb +12 -0
- data/spec/support/shoulda_matchers.rb +8 -0
- data/vendor/assets/javascripts/attorney/bootstrap.bundle.min.js +7 -0
- data/vendor/assets/stylesheets/attorney/bootstrap.min.css +7 -0
- metadata +401 -28
- data/.gitignore +0 -13
- data/.rspec +0 -3
- data/.travis.yml +0 -5
- data/Gemfile +0 -6
- data/LICENSE.txt +0 -21
- data/README.md +0 -39
- data/attorney.gemspec +0 -25
- data/bin/console +0 -14
- data/bin/setup +0 -8
data/.gitignore
DELETED
data/.rspec
DELETED
data/.travis.yml
DELETED
data/Gemfile
DELETED
data/LICENSE.txt
DELETED
@@ -1,21 +0,0 @@
|
|
1
|
-
The MIT License (MIT)
|
2
|
-
|
3
|
-
Copyright (c) 2018 Gonzalo
|
4
|
-
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
7
|
-
in the Software without restriction, including without limitation the rights
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
10
|
-
furnished to do so, subject to the following conditions:
|
11
|
-
|
12
|
-
The above copyright notice and this permission notice shall be included in
|
13
|
-
all copies or substantial portions of the Software.
|
14
|
-
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
-
THE SOFTWARE.
|
data/README.md
DELETED
@@ -1,39 +0,0 @@
|
|
1
|
-
# Attorney
|
2
|
-
|
3
|
-
Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/attorney`. To experiment with that code, run `bin/console` for an interactive prompt.
|
4
|
-
|
5
|
-
TODO: Delete this and the text above, and describe your gem
|
6
|
-
|
7
|
-
## Installation
|
8
|
-
|
9
|
-
Add this line to your application's Gemfile:
|
10
|
-
|
11
|
-
```ruby
|
12
|
-
gem 'attorney'
|
13
|
-
```
|
14
|
-
|
15
|
-
And then execute:
|
16
|
-
|
17
|
-
$ bundle
|
18
|
-
|
19
|
-
Or install it yourself as:
|
20
|
-
|
21
|
-
$ gem install attorney
|
22
|
-
|
23
|
-
## Usage
|
24
|
-
|
25
|
-
TODO: Write usage instructions here
|
26
|
-
|
27
|
-
## Development
|
28
|
-
|
29
|
-
After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
|
30
|
-
|
31
|
-
To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
|
32
|
-
|
33
|
-
## Contributing
|
34
|
-
|
35
|
-
Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/attorney.
|
36
|
-
|
37
|
-
## License
|
38
|
-
|
39
|
-
The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
|
data/attorney.gemspec
DELETED
@@ -1,25 +0,0 @@
|
|
1
|
-
|
2
|
-
lib = File.expand_path("../lib", __FILE__)
|
3
|
-
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
-
require "attorney/version"
|
5
|
-
|
6
|
-
Gem::Specification.new do |spec|
|
7
|
-
spec.name = "attorney"
|
8
|
-
spec.version = Attorney::VERSION
|
9
|
-
spec.authors = ["Gonzalo"]
|
10
|
-
spec.email = ["grzuy0@gmail.com"]
|
11
|
-
|
12
|
-
spec.summary = %q{Easily manage Terms & Conditions for your Rails app}
|
13
|
-
spec.license = "MIT"
|
14
|
-
|
15
|
-
spec.files = `git ls-files -z`.split("\x0").reject do |f|
|
16
|
-
f.match(%r{^(test|spec|features)/})
|
17
|
-
end
|
18
|
-
spec.bindir = "exe"
|
19
|
-
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
20
|
-
spec.require_paths = ["lib"]
|
21
|
-
|
22
|
-
spec.add_development_dependency "bundler", "~> 1.16"
|
23
|
-
spec.add_development_dependency "rake", "~> 10.0"
|
24
|
-
spec.add_development_dependency "rspec", "~> 3.0"
|
25
|
-
end
|
data/bin/console
DELETED
@@ -1,14 +0,0 @@
|
|
1
|
-
#!/usr/bin/env ruby
|
2
|
-
|
3
|
-
require "bundler/setup"
|
4
|
-
require "attorney"
|
5
|
-
|
6
|
-
# You can add fixtures and/or initialization code here to make experimenting
|
7
|
-
# with your gem easier. You can also use a different console, if you like.
|
8
|
-
|
9
|
-
# (If you use this, don't forget to add pry to your Gemfile!)
|
10
|
-
# require "pry"
|
11
|
-
# Pry.start
|
12
|
-
|
13
|
-
require "irb"
|
14
|
-
IRB.start(__FILE__)
|