Switch from simply_stored to simply_couch
- All models: SimplyStored::Couch → SimplyCouch::Model - Gemfile: simply_stored → simply_couch - devise_simply_stored → devise_simply_couch - Remove stale couch_potato require (not used)
This commit is contained in:
@@ -135,7 +135,7 @@ module Cmtool
|
||||
def edit_td(obj, options = {})
|
||||
path = options[:path] || case obj
|
||||
when Array then edit_polymorphic_path(obj)
|
||||
when SimplyStored::Couch then edit_polymorphic_path([options[:scope] || cmtool, obj])
|
||||
when SimplyCouch::Model then edit_polymorphic_path([options[:scope] || cmtool, obj])
|
||||
else obj
|
||||
end
|
||||
content_tag(
|
||||
@@ -148,7 +148,7 @@ module Cmtool
|
||||
def destroy_td(obj, options = {})
|
||||
path = options[:path] || case obj
|
||||
when Array then polymorphic_path(obj)
|
||||
when SimplyStored::Couch then polymorphic_path([options[:scope] || cmtool, obj])
|
||||
when SimplyCouch::Model then polymorphic_path([options[:scope] || cmtool, obj])
|
||||
else obj
|
||||
end
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
module Cmtool
|
||||
class ContactForm
|
||||
include SimplyStored::Couch
|
||||
include SimplyCouch::Model
|
||||
property :gender
|
||||
property :name
|
||||
property :email
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
module Cmtool
|
||||
class Directory
|
||||
include SimplyStored::Couch
|
||||
include SimplyCouch::Model
|
||||
|
||||
property :name
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
module Cmtool
|
||||
class Faq
|
||||
include SimplyStored::Couch
|
||||
include SimplyCouch::Model
|
||||
|
||||
property :question
|
||||
property :answer
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
module Cmtool
|
||||
class Image
|
||||
include SimplyStored::Couch
|
||||
include SimplyCouch::Model
|
||||
include Paperclip::Glue
|
||||
# TODO: Replace Paperclip with SimplyStored::HasAttachment
|
||||
# 1. Change `include Paperclip::Glue` to `include SimplyStored::HasAttachment`
|
||||
# TODO: Replace Paperclip with SimplyCouch::HasAttachment
|
||||
# 1. Change `include Paperclip::Glue` to `include SimplyCouch::HasAttachment`
|
||||
# 2. Replace `has_attached_file :file, styles: {...}` with `has_attachment :file, styles: {...}`
|
||||
# 3. Replace `validates_attachment` with standard Rails validations
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
module Cmtool
|
||||
class Keyword
|
||||
include SimplyStored::Couch
|
||||
include SimplyCouch::Model
|
||||
|
||||
property :name
|
||||
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
module Cmtool
|
||||
class News
|
||||
include SimplyStored::Couch
|
||||
include SimplyCouch::Model
|
||||
include Paperclip::Glue
|
||||
# TODO: Replace Paperclip with SimplyStored::HasAttachment
|
||||
# 1. Change `include Paperclip::Glue` to `include SimplyStored::HasAttachment`
|
||||
# TODO: Replace Paperclip with SimplyCouch::HasAttachment
|
||||
# 1. Change `include Paperclip::Glue` to `include SimplyCouch::HasAttachment`
|
||||
# 2. Replace `has_attached_file :image, styles: {...}` with `has_attachment :image, styles: {...}`
|
||||
|
||||
property :title
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
module Cmtool
|
||||
class NewsletterSubscription
|
||||
include SimplyStored::Couch
|
||||
include SimplyCouch::Model
|
||||
|
||||
# PROPERTIES
|
||||
property :email
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
module Cmtool
|
||||
class Quote
|
||||
include SimplyStored::Couch
|
||||
include SimplyCouch::Model
|
||||
include Paperclip::Glue
|
||||
# TODO: Replace Paperclip with SimplyStored::HasAttachment
|
||||
# 1. Change `include Paperclip::Glue` to `include SimplyStored::HasAttachment`
|
||||
# TODO: Replace Paperclip with SimplyCouch::HasAttachment
|
||||
# 1. Change `include Paperclip::Glue` to `include SimplyCouch::HasAttachment`
|
||||
# 2. Replace `has_attached_file :image, styles: {...}` with `has_attachment :image, styles: {...}`
|
||||
|
||||
property :owner
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
module Cmtool
|
||||
class YmlFile
|
||||
include SimplyStored::Couch
|
||||
include SimplyCouch::Model
|
||||
|
||||
property :name
|
||||
property :body
|
||||
|
||||
Reference in New Issue
Block a user