【文件属性】:
文件名称:shopping_mall:Spree的多租户
文件大小:79KB
文件格式:ZIP
更新时间:2021-05-12 13:11:04
Ruby
购物中心
使用 gem和作为数据库的Spree 3.0.x的多租户。
安装
将此行添加到Spree应用程序的Gemfile中:
gem 'shopping_mall'
然后运行bundle命令安装它:
bundle install
发电机
安装ShoppingMall后,运行生成器:
rails generate shopping_mall:install
这将在您的应用程序中添加一个shopping_mall.rb初始化程序,并在您的生产和开发环境中添加以下内容:
Rails . application . configure do | config |
...
'config.cache_store = :memory_store, { namespace: -> { ShoppingMall::Store.current } }'
...
end
配置
添加了
【文件预览】:
shopping_mall-master
----.travis.yml(151B)
----shopping_mall.gemspec(2KB)
----bin()
--------rake(364B)
--------rails(304B)
----config()
--------initializers()
----db()
--------migrate()
----Rakefile(339B)
----.rubocop.yml(3KB)
----app()
--------models()
----Gemfile(121B)
----.rspec(8B)
----spec()
--------models()
--------shopping_mall()
--------spec_helper.rb(2KB)
--------fixtures()
----.gitignore(245B)
----.hound.yml(88B)
----lib()
--------tasks()
--------shopping_mall.rb(348B)
--------shopping_mall()
--------generators()
----README.md(5KB)
----LICENSE.txt(1KB)