th_simple_content_management 0.1.1 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- ZjVmODRiOWNiMThiYTYxZTA3ZWNiY2NiZDBiY2U5ZmMyM2ZiZTA1Nw==
4
+ NzAxOTJkNjExMzMwNDg4YTVmNjI1YzdmMDM2MThkNjE5NzQxNmMxNA==
5
5
  data.tar.gz: !binary |-
6
- Yjg0YTQyZDE5NDJhMGE2MDgxMDUzOWQxNWJiMGU4N2RiZTllZWI4ZA==
6
+ NjBiNmM1MzMyNTRkYjQwNmNkZDg4OGFhNzBkNDRkMTYxNTQ0NTg5MQ==
7
7
  !binary "U0hBNTEy":
8
8
  metadata.gz: !binary |-
9
- YWU4MjAyMGQyOGFhNzRlM2FhYjdlZWQyMDJkZWY2M2U0MGE1ODU2YmZjNmJk
10
- MDAwOTM0M2VjMTA4NmQxM2IwNmM1YmY2NTgwZWMzYjkwMGU3YjZlNGZhZGFj
11
- MTJiNzgxYjg4M2E1Y2JiMGUzMmE0NjlhODQzN2JiMzU0NWEzYzE=
9
+ MzMzZDYyNGE5NzAyNjVmZjA3MjkyNGMzMjcyN2NkNzYxMGVhMjRjMGVjODQ1
10
+ OWYzNTg2ZGZmYmM4ODQxOGQzMjk1YWIxMjI4NDkyNGJhZTM4ZjBiNWY2MDJh
11
+ ZjA1NDExNjNiYjM0ZTZjNGUxNWEwMDg2YWQxOTc2OTFhM2M0Yzk=
12
12
  data.tar.gz: !binary |-
13
- ZDM3Zjk0ZDFmNzY0NzIwYmI5NmFiODhlYmIxZmY3NGExOTQ0MDg0ZTI5ZDU4
14
- N2VmNjM3ZWFlZjBmMzEwMmFiMWNmMDEwODhlYWFmOTQ4YjA2MTBlMzUzNDk2
15
- YmY4ZDY1Y2JiOTBmMDdlZTdhOGQ2OGFkYzgyYjNkZWQ0YjJlMzQ=
13
+ ZjQyN2IyY2YwYjE2MGY5OGU3YzZlM2FjMTkzNWZiYTM2MDYxZGUzZDNlMDBj
14
+ M2YwOWE3YTkwNmIyMGM5NDBlZDQ3OTYwYWRmYzBkNjE4MmIzZTJlZGVjNDJj
15
+ MmEwNGFhZWViOTQ1NDQ4ZDZiYmVhZWM0MGRlZmM2Yjc0OWRlYjQ=
@@ -1,9 +1,9 @@
1
1
  class SimpleContentManagement::SimplePage < ActiveRecord::Base
2
- has_many :simple_routes, conditions: { is_deleted: false }, class_name: "SimpleContentManagement::SimpleRoute"
2
+ has_many :simple_routes, conditions: { deleted: false }, class_name: "SimpleContentManagement::SimpleRoute"
3
3
 
4
4
  attr_accessible :name, :title, :content_html, :simple_routes_list
5
5
 
6
- scope :active, where(is_deleted: false)
6
+ scope :active, where(deleted: false)
7
7
 
8
8
  def simple_routes_list
9
9
  path_names.join ","
@@ -20,7 +20,7 @@ class SimpleContentManagement::SimplePage < ActiveRecord::Base
20
20
  # ensure any existing routes are set active to the current page.
21
21
  SimpleContentManagement::SimpleRoute.where(path: path_names).each do |simple_route|
22
22
  simple_route.simple_page = self
23
- simple_route.is_deleted = false
23
+ simple_route.deleted = false
24
24
  simple_route.save
25
25
  path_names.delete simple_route.path
26
26
  end
@@ -40,6 +40,6 @@ class SimpleContentManagement::SimplePage < ActiveRecord::Base
40
40
  end
41
41
 
42
42
  def destroy
43
- update_attribute :is_deleted, true
43
+ update_attribute :deleted, true
44
44
  end
45
45
  end
@@ -7,10 +7,10 @@ class SimpleContentManagement::SimpleRoute < ActiveRecord::Base
7
7
 
8
8
  after_save :inform_simple_pages_constraint
9
9
 
10
- scope :active, where(is_deleted: false)
10
+ scope :active, where(deleted: false)
11
11
 
12
12
  def destroy
13
- update_attribute :is_deleted, true
13
+ update_attribute :deleted, true
14
14
  end
15
15
 
16
16
  private
@@ -1,3 +1,3 @@
1
1
  module SimpleContentManagement
2
- VERSION = "0.1.1"
2
+ VERSION = "0.1.2"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: th_simple_content_management
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Toby Hinloopen
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-05-12 00:00:00.000000000 Z
11
+ date: 2013-05-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails