commontator 1.1.1 → 1.1.2
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +1 -1
- data/Rakefile +2 -20
- data/lib/commontator.rb +4 -2
- data/lib/commontator.rb~ +7 -5
- data/lib/commontator/acts_as_commontable.rb +1 -1
- data/lib/commontator/acts_as_commontable.rb~ +2 -2
- data/lib/commontator/security_transgression.rb +2 -1
- data/lib/commontator/security_transgression.rb~ +3 -0
- data/lib/commontator/version.rb +1 -1
- data/lib/commontator/version.rb~ +1 -1
- data/lib/tasks/commontator_tasks.rake +1 -0
- data/lib/tasks/commontator_tasks.rake~ +41 -0
- data/spec/app/controllers/commontator/comments_controller_spec.rb +1 -1
- data/spec/app/controllers/commontator/comments_controller_spec.rb~ +8 -8
- data/spec/app/controllers/commontator/subscriptions_controller_spec.rb +1 -1
- data/spec/app/controllers/commontator/subscriptions_controller_spec.rb~ +1 -1
- data/spec/app/controllers/commontator/threads_controller_spec.rb +1 -1
- data/spec/app/controllers/commontator/threads_controller_spec.rb~ +110 -110
- data/spec/app/helpers/commontator/application_helper_spec.rb +2 -0
- data/spec/app/helpers/commontator/application_helper_spec.rb~ +1 -1
- data/spec/app/helpers/commontator/threads_helper_spec.rb +1 -1
- data/spec/app/helpers/commontator/threads_helper_spec.rb~ +1 -1
- data/spec/app/mailers/commontator/subscriptions_mailer_spec.rb +1 -1
- data/spec/app/mailers/commontator/subscriptions_mailer_spec.rb~ +2 -2
- data/spec/app/models/commontator/comment_observer_spec.rb +1 -1
- data/spec/app/models/commontator/comment_observer_spec.rb~ +1 -1
- data/spec/app/models/commontator/comment_spec.rb +1 -1
- data/spec/app/models/commontator/comment_spec.rb~ +1 -1
- data/spec/app/models/commontator/subscription_spec.rb +1 -1
- data/spec/app/models/commontator/subscription_spec.rb~ +22 -22
- data/spec/app/models/commontator/thread_spec.rb +1 -1
- data/spec/app/models/commontator/thread_spec.rb~ +2 -2
- data/spec/dummy/README.md +1 -1
- data/spec/dummy/README.md~ +1 -1
- data/spec/dummy/Rakefile~ +7 -0
- data/spec/dummy/config/initializers/commontator.rb +1 -1
- data/spec/dummy/db/development.sqlite3 +0 -0
- data/spec/dummy/db/migrate/{0_create_dummy_models.rb → 1_create_dummy_models.rb} +0 -0
- data/spec/dummy/db/migrate/{1_create_dummy_users.rb → 2_create_dummy_users.rb} +0 -0
- data/spec/dummy/db/migrate/3_acts_as_votable_migration.rb +4 -1
- data/spec/dummy/db/schema.rb +3 -0
- data/spec/dummy/db/test.sqlite3 +0 -0
- data/spec/dummy/log/development.log +466 -15153
- data/spec/dummy/log/test.log +7183 -178543
- data/spec/lib/commontator/acts_as_commontable_spec.rb +1 -1
- data/spec/lib/commontator/acts_as_commontable_spec.rb~ +1 -1
- data/spec/lib/commontator/acts_as_commontator_spec.rb +1 -1
- data/spec/lib/commontator/acts_as_commontator_spec.rb~ +1 -1
- data/spec/lib/commontator/commontable_config_spec.rb +1 -1
- data/spec/lib/commontator/commontable_config_spec.rb~ +6 -6
- data/spec/lib/commontator/commontator_config_spec.rb +1 -1
- data/spec/lib/commontator/commontator_config_spec.rb~ +6 -6
- data/spec/lib/commontator/controller_includes_spec.rb +1 -1
- data/spec/lib/commontator/controller_includes_spec.rb~ +1 -1
- data/spec/lib/commontator/shared_helper_spec.rb +1 -1
- data/spec/lib/commontator/shared_helper_spec.rb~ +1 -1
- data/spec/lib/commontator_spec.rb +1 -1
- data/spec/lib/commontator_spec.rb~ +4 -4
- data/spec/{spec_helper.rb → minitest_helper.rb} +0 -1
- data/spec/minitest_helper.rb~ +35 -0
- data/spec/spec_helper.rb~ +7 -1
- metadata +153 -241
- data/app/assets/stylesheets/commontator/comments.css~ +0 -83
- data/app/assets/stylesheets/commontator/threads.css~ +0 -18
- data/app/controllers/commontator/application_controller.rb~ +0 -28
- data/app/controllers/commontator/comments_controller.rb~ +0 -135
- data/app/controllers/commontator/commontator_controller.rb~ +0 -22
- data/app/controllers/commontator/subscriptions_controller.rb~ +0 -33
- data/app/controllers/commontator/threads_controller.rb~ +0 -41
- data/app/helpers/commontator/comments_helper.rb~ +0 -41
- data/app/helpers/commontator/commontator_helper.rb~ +0 -7
- data/app/helpers/commontator/subscriptions_helper.rb~ +0 -8
- data/app/helpers/commontator/threads_helper.rb~ +0 -22
- data/app/mailers/commontator/subscriptions_mailer.rb~ +0 -49
- data/app/models/commontator/comment.rb~ +0 -89
- data/app/models/commontator/comment_observer.rb~ +0 -13
- data/app/models/commontator/subscription.rb~ +0 -19
- data/app/models/commontator/thread.rb~ +0 -123
- data/app/views/commontator/comments/_actions.html.erb~ +0 -30
- data/app/views/commontator/comments/_body.html.erb~ +0 -7
- data/app/views/commontator/comments/_form.html.erb~ +0 -36
- data/app/views/commontator/comments/_show.html.erb~ +0 -44
- data/app/views/commontator/comments/_votes.html.erb~ +0 -57
- data/app/views/commontator/comments/delete.js.erb~ +0 -17
- data/app/views/commontator/comments/update.js.erb~ +0 -7
- data/app/views/commontator/shared/_thread.html.erb~ +0 -20
- data/app/views/commontator/shared/_thread_link.html.erb~ +0 -16
- data/app/views/commontator/subscriptions_mailer/comment_created_email.html.erb~ +0 -6
- data/app/views/commontator/threads/_show.html.erb~ +0 -61
- data/config/initializers/commontator.rb~ +0 -164
- data/db/migrate/0_install_commontator.rb~ +0 -48
- data/lib/commontator/commontable_config.rb~ +0 -13
- data/lib/commontator/commontator_config.rb~ +0 -13
- data/lib/commontator/controller_includes.rb~ +0 -23
- data/lib/commontator/engine.rb~ +0 -7
- data/lib/commontator/shared_helper.rb~ +0 -42
- data/lib/commontator/shared_methods.rb~ +0 -24
- data/spec/app/controllers/comments_controller_spec.rb~ +0 -7
- data/spec/app/controllers/commontator/application_controller_spec.rb~ +0 -30
- data/spec/app/controllers/threads_controller_spec.rb~ +0 -12
- data/spec/dummy/Gemfile~ +0 -3
- data/spec/dummy/app/controllers/application_controller.rb~ +0 -7
- data/spec/dummy/app/controllers/dummies_controller.rb~ +0 -17
- data/spec/dummy/app/controllers/dummy_models_controller.rb~ +0 -29
- data/spec/dummy/app/helpers/application_helper.rb~ +0 -15
- data/spec/dummy/app/models/dummy.rb~ +0 -3
- data/spec/dummy/app/models/dummy_user.rb~ +0 -9
- data/spec/dummy/app/models/user.rb~ +0 -5
- data/spec/dummy/app/views/dummy_model/show.html.erb~ +0 -1
- data/spec/dummy/config/application.rb~ +0 -59
- data/spec/dummy/config/initializers/commontator.rb~ +0 -164
- data/spec/dummy/config/routes.rb~ +0 -7
- data/spec/dummy/db/migrate/0_create_dummies.rb~ +0 -48
- data/spec/dummy/db/migrate/0_create_dummy_models.rb~ +0 -7
- data/spec/dummy/db/migrate/1_create_dummy_users.rb~ +0 -7
- data/spec/dummy/db/migrate/1_create_users.rb~ +0 -7
- data/spec/dummy/db/migrate/2_install_commontator.rb +0 -49
- data/spec/dummy/db/migrate/2_install_commontator.rb~ +0 -49
- data/spec/dummy/db/schema.rb~ +0 -71
- data/spec/dummy/tmp/cache/assets/CCB/1D0/sprockets%2F02d4b791eb831cf2057bf4703a1218d1 +0 -0
- data/spec/dummy/tmp/cache/assets/CD1/510/sprockets%2Fc69ee3cc5796188d873574179290a6ef +0 -0
- data/spec/dummy/tmp/cache/assets/D01/8B0/sprockets%2F0f196a1a50363b0a076ec6e1ee5417f6 +0 -0
- data/spec/dummy/tmp/cache/assets/D06/2F0/sprockets%2Fe1f674c11941d62aac1764ef3a7134e4 +0 -0
- data/spec/dummy/tmp/cache/assets/D54/060/sprockets%2Fe85565206c3e5fdf9dfeb367c85557b1 +0 -0
- data/spec/dummy/tmp/cache/assets/D9B/550/sprockets%2Fa41c8be5379abec3c0d0d98e2f0d5609 +0 -0
- data/spec/dummy/tmp/cache/assets/E01/2E0/sprockets%2Fa3fb9025f90ff05a6fd4afc7ded2692c +0 -0
@@ -1,49 +0,0 @@
|
|
1
|
-
# This migration comes from commontator (originally 0)
|
2
|
-
class InstallCommontator < ActiveRecord::Migration
|
3
|
-
def change
|
4
|
-
create_table "commontator_comments" do |t|
|
5
|
-
t.text "body"
|
6
|
-
t.integer "creator_id"
|
7
|
-
t.string "creator_type"
|
8
|
-
t.datetime "deleted_at"
|
9
|
-
t.integer "deleter_id"
|
10
|
-
t.string "deleter_type"
|
11
|
-
t.integer "thread_id"
|
12
|
-
|
13
|
-
t.integer "cached_votes_total", :default => 0
|
14
|
-
t.integer "cached_votes_up", :default => 0
|
15
|
-
t.integer "cached_votes_down", :default => 0
|
16
|
-
|
17
|
-
t.timestamps
|
18
|
-
end
|
19
|
-
|
20
|
-
create_table "commontator_subscriptions" do |t|
|
21
|
-
t.integer "subscriber_id"
|
22
|
-
t.string "subscriber_type"
|
23
|
-
t.integer "thread_id"
|
24
|
-
t.integer "unread", :default => 0
|
25
|
-
|
26
|
-
t.timestamps
|
27
|
-
end
|
28
|
-
|
29
|
-
create_table "commontator_threads" do |t|
|
30
|
-
t.integer "commontable_id"
|
31
|
-
t.string "commontable_type"
|
32
|
-
t.datetime "closed_at"
|
33
|
-
t.integer "closer_id"
|
34
|
-
t.string "closer_type"
|
35
|
-
|
36
|
-
t.timestamps
|
37
|
-
end
|
38
|
-
|
39
|
-
add_index :commontator_comments, [:creator_id, :creator_type, :thread_id], :name => "index_c_c_on_c_id_and_c_type_and_t_id"
|
40
|
-
add_index :commontator_comments, :thread_id
|
41
|
-
add_index :commontator_subscriptions, [:subscriber_id, :subscriber_type, :thread_id], :unique => true, :name => "index_c_s_on_s_id_and_s_type_and_t_id"
|
42
|
-
add_index :commontator_subscriptions, :thread_id
|
43
|
-
add_index :commontator_threads, [:commontable_id, :commontable_type]
|
44
|
-
|
45
|
-
add_index :commontator_comments, :cached_votes_total
|
46
|
-
add_index :commontator_comments, :cached_votes_up
|
47
|
-
add_index :commontator_comments, :cached_votes_down
|
48
|
-
end
|
49
|
-
end
|
@@ -1,49 +0,0 @@
|
|
1
|
-
# This migration comes from commontator (originally 0)
|
2
|
-
class InstallCommontator < ActiveRecord::Migration
|
3
|
-
def change
|
4
|
-
create_table "commontator_comments" do |t|
|
5
|
-
t.text "body"
|
6
|
-
t.integer "creator_id"
|
7
|
-
t.string "creator_type"
|
8
|
-
t.datetime "deleted_at"
|
9
|
-
t.integer "deleter_id"
|
10
|
-
t.string "deleter_type"
|
11
|
-
t.integer "thread_id"
|
12
|
-
|
13
|
-
t.integer "cached_votes_total", :default => 0
|
14
|
-
t.integer "cached_votes_up", :default => 0
|
15
|
-
t.integer "cached_votes_down", :default => 0
|
16
|
-
|
17
|
-
t.timestamps
|
18
|
-
end
|
19
|
-
|
20
|
-
create_table "commontator_subscriptions" do |t|
|
21
|
-
t.integer "subscriber_id"
|
22
|
-
t.string "subscriber_type"
|
23
|
-
t.integer "thread_id"
|
24
|
-
t.integer "unread"
|
25
|
-
|
26
|
-
t.timestamps
|
27
|
-
end
|
28
|
-
|
29
|
-
create_table "commontator_threads" do |t|
|
30
|
-
t.integer "commontable_id"
|
31
|
-
t.string "commontable_type"
|
32
|
-
t.datetime "closed_at"
|
33
|
-
t.integer "closer_id"
|
34
|
-
t.string "closer_type"
|
35
|
-
|
36
|
-
t.timestamps
|
37
|
-
end
|
38
|
-
|
39
|
-
add_index :commontator_comments, [:creator_id, :creator_type, :thread_id], :name => "index_c_c_on_c_id_and_c_type_and_t_id"
|
40
|
-
add_index :commontator_comments, :thread_id
|
41
|
-
add_index :commontator_subscriptions, [:subscriber_id, :subscriber_type, :thread_id], :unique => true, :name => "index_c_s_on_s_id_and_s_type_and_t_id"
|
42
|
-
add_index :commontator_subscriptions, :thread_id
|
43
|
-
add_index :commontator_threads, [:commontable_id, :commontable_type]
|
44
|
-
|
45
|
-
add_index :commontator_comments, :cached_votes_total
|
46
|
-
add_index :commontator_comments, :cached_votes_up
|
47
|
-
add_index :commontator_comments, :cached_votes_down
|
48
|
-
end
|
49
|
-
end
|
data/spec/dummy/db/schema.rb~
DELETED
@@ -1,71 +0,0 @@
|
|
1
|
-
# encoding: UTF-8
|
2
|
-
# This file is auto-generated from the current state of the database. Instead
|
3
|
-
# of editing this file, please use the migrations feature of Active Record to
|
4
|
-
# incrementally modify your database, and then regenerate this schema definition.
|
5
|
-
#
|
6
|
-
# Note that this schema.rb definition is the authoritative source for your
|
7
|
-
# database schema. If you need to create the application database on another
|
8
|
-
# system, you should be using db:schema:load, not running all the migrations
|
9
|
-
# from scratch. The latter is a flawed and unsustainable approach (the more migrations
|
10
|
-
# you'll amass, the slower it'll run and the greater likelihood for issues).
|
11
|
-
#
|
12
|
-
# It's strongly recommended to check this file into your version control system.
|
13
|
-
|
14
|
-
ActiveRecord::Schema.define(:version => 2) do
|
15
|
-
|
16
|
-
create_table "commontator_comments", :force => true do |t|
|
17
|
-
t.text "body"
|
18
|
-
t.integer "creator_id"
|
19
|
-
t.string "creator_type"
|
20
|
-
t.datetime "deleted_at"
|
21
|
-
t.integer "deleter_id"
|
22
|
-
t.string "deleter_type"
|
23
|
-
t.integer "thread_id"
|
24
|
-
t.integer "cached_votes_total", :default => 0
|
25
|
-
t.integer "cached_votes_up", :default => 0
|
26
|
-
t.integer "cached_votes_down", :default => 0
|
27
|
-
t.datetime "created_at", :null => false
|
28
|
-
t.datetime "updated_at", :null => false
|
29
|
-
end
|
30
|
-
|
31
|
-
add_index "commontator_comments", ["cached_votes_down"], :name => "index_commontator_comments_on_cached_votes_down"
|
32
|
-
add_index "commontator_comments", ["cached_votes_total"], :name => "index_commontator_comments_on_cached_votes_total"
|
33
|
-
add_index "commontator_comments", ["cached_votes_up"], :name => "index_commontator_comments_on_cached_votes_up"
|
34
|
-
add_index "commontator_comments", ["creator_id", "creator_type", "thread_id"], :name => "index_c_c_on_c_id_and_c_type_and_t_id"
|
35
|
-
add_index "commontator_comments", ["thread_id"], :name => "index_commontator_comments_on_thread_id"
|
36
|
-
|
37
|
-
create_table "commontator_subscriptions", :force => true do |t|
|
38
|
-
t.integer "subscriber_id"
|
39
|
-
t.string "subscriber_type"
|
40
|
-
t.integer "thread_id"
|
41
|
-
t.boolean "is_unread"
|
42
|
-
t.datetime "created_at", :null => false
|
43
|
-
t.datetime "updated_at", :null => false
|
44
|
-
end
|
45
|
-
|
46
|
-
add_index "commontator_subscriptions", ["subscriber_id", "subscriber_type", "thread_id"], :name => "index_c_s_on_s_id_and_s_type_and_t_id", :unique => true
|
47
|
-
add_index "commontator_subscriptions", ["thread_id"], :name => "index_commontator_subscriptions_on_thread_id"
|
48
|
-
|
49
|
-
create_table "commontator_threads", :force => true do |t|
|
50
|
-
t.integer "commontable_id"
|
51
|
-
t.string "commontable_type"
|
52
|
-
t.datetime "closed_at"
|
53
|
-
t.integer "closer_id"
|
54
|
-
t.string "closer_type"
|
55
|
-
t.datetime "created_at", :null => false
|
56
|
-
t.datetime "updated_at", :null => false
|
57
|
-
end
|
58
|
-
|
59
|
-
add_index "commontator_threads", ["commontable_id", "commontable_type"], :name => "index_commontator_threads_on_commontable_id_and_commontable_type"
|
60
|
-
|
61
|
-
create_table "dummy_models", :force => true do |t|
|
62
|
-
t.datetime "created_at", :null => false
|
63
|
-
t.datetime "updated_at", :null => false
|
64
|
-
end
|
65
|
-
|
66
|
-
create_table "users", :force => true do |t|
|
67
|
-
t.datetime "created_at", :null => false
|
68
|
-
t.datetime "updated_at", :null => false
|
69
|
-
end
|
70
|
-
|
71
|
-
end
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|