Merge remote-tracking branch 'upstream/master' into multiple-recurring-tasks
Conflicts: config/locales/de.yml
This commit is contained in:
commit
46b07a6136
257 changed files with 5408 additions and 1931 deletions
|
|
@ -29,7 +29,10 @@ default: &defaults
|
|||
homepage: http://www.fctest.de
|
||||
|
||||
# foodsoft documentation URL
|
||||
help_url: http://foodsoft.fcschinke09.de/trac/wiki/FoodsoftDoku
|
||||
help_url: https://github.com/bennibu/foodsoft/wiki/Doku
|
||||
|
||||
# documentation URL for the apples&pears work system
|
||||
applepear_url: https://github.com/bennibu/foodsoft/wiki/%C3%84pfel-u.-Birnen
|
||||
|
||||
# price markup in percent
|
||||
price_markup: 2.0
|
||||
|
|
@ -89,4 +92,4 @@ test:
|
|||
<<: *defaults
|
||||
|
||||
production:
|
||||
<<: *defaults
|
||||
<<: *defaults
|
||||
|
|
|
|||
|
|
@ -29,8 +29,8 @@ module Foodsoft
|
|||
# Run "rake -D time" for a list of tasks for finding time zone names. Default is UTC.
|
||||
# config.time_zone = 'Central Time (US & Canada)'
|
||||
|
||||
# The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.
|
||||
# config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
|
||||
# Internationalization.
|
||||
config.i18n.load_path += Dir[Rails.root.join('config', 'locales', '**', '*.{rb,yml}')]
|
||||
config.i18n.default_locale = :de
|
||||
|
||||
# Configure the default encoding used in templates for Ruby 1.9.
|
||||
|
|
|
|||
41
config/database.yml.MySQL_SAMPLE
Normal file
41
config/database.yml.MySQL_SAMPLE
Normal file
|
|
@ -0,0 +1,41 @@
|
|||
# MySQL. Versions 4.1 and 5.0 are recommended.
|
||||
#
|
||||
# Install the MYSQL driver
|
||||
# gem install mysql2
|
||||
#
|
||||
# Ensure the MySQL gem is defined in your Gemfile
|
||||
# gem 'mysql2'
|
||||
#
|
||||
# And be sure to use new-style password hashing:
|
||||
# http://dev.mysql.com/doc/refman/5.0/en/old-client.html
|
||||
development:
|
||||
adapter: mysql2
|
||||
encoding: utf8
|
||||
reconnect: false
|
||||
database: foodsoft_development
|
||||
pool: 5
|
||||
host: localhost
|
||||
# socket: /tmp/mysql.sock
|
||||
|
||||
# Warning: The database defined as "test" will be erased and
|
||||
# re-generated from your development database when you run "rake".
|
||||
# Do not set this db to the same as development or production.
|
||||
test:
|
||||
adapter: mysql2
|
||||
encoding: utf8
|
||||
reconnect: false
|
||||
database: foodsoft_test
|
||||
pool: 5
|
||||
host: localhost
|
||||
# socket: /tmp/mysql.sock
|
||||
|
||||
production:
|
||||
adapter: mysql2
|
||||
encoding: utf8
|
||||
reconnect: false
|
||||
database: foodsoft_production
|
||||
pool: 5
|
||||
host: localhost
|
||||
username: root
|
||||
password: password
|
||||
# socket: /tmp/mysql.sock
|
||||
|
|
@ -5,16 +5,6 @@ development:
|
|||
pool: 5
|
||||
timeout: 5000
|
||||
|
||||
# Mysql config instead
|
||||
# database: foodsoft_development
|
||||
# username: root
|
||||
# password:
|
||||
# host: localhost
|
||||
# encoding: utf8
|
||||
# Define a socket, if youre not using standard linux socket, like lampp..
|
||||
# socket: /opt/lampp/var/mysql/mysql.sock
|
||||
|
||||
|
||||
# Warning: The database defined as "test" will be erased and
|
||||
# re-generated from your development database when you run "rake".
|
||||
# Do not set this db to the same as development or production.
|
||||
43
config/deploy.rb.SAMPLE
Normal file
43
config/deploy.rb.SAMPLE
Normal file
|
|
@ -0,0 +1,43 @@
|
|||
require 'bundler/setup'
|
||||
require 'common_deploy'
|
||||
|
||||
set :application, 'foodsoft'
|
||||
set :domain, 'foodsoft.com'
|
||||
set :user, 'foodsoft'
|
||||
set :default_stage, 'staging' # staging and production are available via (set :stages, ["staging", "production"])
|
||||
set :keep_releases, 5
|
||||
set :repository, 'git://github.com/foodcoops/foodsoft.git'
|
||||
set(:deploy_to) { "/mnt/apps/#{application}_#{stage}" }
|
||||
|
||||
|
||||
# resque worker
|
||||
role :resque_worker, domain
|
||||
role :resque_scheduler, domain
|
||||
set :workers, { "foodsoft_notifier" => 1 }
|
||||
|
||||
|
||||
# rvm
|
||||
# set :rvm_ruby_string, :local
|
||||
|
||||
|
||||
server domain, :web, :app, :db
|
||||
|
||||
# Loads all needed capistrano extensions
|
||||
load_extensions :bundler,
|
||||
# :rvm, # if you are using rvm on your server uncomment this line
|
||||
:passenger,
|
||||
:multistage,
|
||||
:resque,
|
||||
:whenever,
|
||||
:assets
|
||||
|
||||
|
||||
# clean up old releases on each deploy
|
||||
after "deploy:restart", "deploy:cleanup"
|
||||
|
||||
# restart resque
|
||||
after "deploy:restart", "resque:restart"
|
||||
|
||||
# install rvm and ruby on every deploy
|
||||
# before 'deploy', 'rvm:install_rvm' # update RVM
|
||||
# before 'deploy', 'rvm:install_ruby' # install Ruby and create gemset (both if missing)
|
||||
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
|
|
@ -1,26 +0,0 @@
|
|||
en:
|
||||
simple_form:
|
||||
"yes": 'Yes'
|
||||
"no": 'No'
|
||||
required:
|
||||
text: 'required'
|
||||
mark: '*'
|
||||
# You can uncomment the line below if you need to overwrite the whole required html.
|
||||
# When using html, text and mark won't be used.
|
||||
# html: '<abbr title="required">*</abbr>'
|
||||
error_notification:
|
||||
default_message: "Please review the problems below:"
|
||||
# Labels and hints examples
|
||||
# labels:
|
||||
# defaults:
|
||||
# password: 'Password'
|
||||
# user:
|
||||
# new:
|
||||
# email: 'E-mail to sign in.'
|
||||
# edit:
|
||||
# email: 'E-mail.'
|
||||
# hints:
|
||||
# defaults:
|
||||
# username: 'User name to sign in.'
|
||||
# password: 'No special characters, please.'
|
||||
|
||||
|
|
@ -1,50 +1,51 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# Configures your navigation
|
||||
|
||||
SimpleNavigation::Configuration.run do |navigation|
|
||||
|
||||
navigation.items do |primary|
|
||||
primary.dom_class = 'nav'
|
||||
|
||||
primary.item :dashboard_nav_item, 'Dashboard', root_path(anchor: '')
|
||||
primary.item :dashboard_nav_item, I18n.t('navigation.dashboard'), root_path(anchor: '')
|
||||
|
||||
primary.item :foodcoop, 'Foodcoop', '#', id: nil do |subnav|
|
||||
subnav.item :members, 'Mitglieder', foodcoop_users_path, id: nil
|
||||
subnav.item :workgroups, 'Arbeitsgruppen', foodcoop_workgroups_path, id: nil
|
||||
subnav.item :ordergroups, 'Bestellgruppen', foodcoop_ordergroups_path, id: nil
|
||||
subnav.item :messages, 'Nachrichten', messages_path, id: nil
|
||||
subnav.item :tasks, 'Aufgaben', tasks_path, id: nil
|
||||
primary.item :foodcoop, I18n.t('navigation.foodcoop'), '#', id: nil do |subnav|
|
||||
subnav.item :members, I18n.t('navigation.members'), foodcoop_users_path, id: nil
|
||||
subnav.item :workgroups, I18n.t('navigation.workgroups'), foodcoop_workgroups_path, id: nil
|
||||
subnav.item :ordergroups, I18n.t('navigation.ordergroups'), foodcoop_ordergroups_path, id: nil
|
||||
subnav.item :messages, I18n.t('navigation.messages'), messages_path, id: nil
|
||||
subnav.item :tasks, I18n.t('navigation.tasks'), tasks_path, id: nil
|
||||
end
|
||||
|
||||
primary.item :wiki, 'Wiki', '#', id: nil do |subnav|
|
||||
subnav.item :wiki_home, 'Startseite', wiki_path, id: nil
|
||||
subnav.item :all_pages, 'Alle Seiten', all_pages_path, id: nil
|
||||
primary.item :wiki, I18n.t('navigation.wiki.title'), '#', id: nil do |subnav|
|
||||
subnav.item :wiki_home, I18n.t('navigation.wiki.home'), wiki_path, id: nil
|
||||
subnav.item :all_pages, I18n.t('navigation.wiki.all_pages'), all_pages_path, id: nil
|
||||
end
|
||||
|
||||
primary.item :orders, 'Bestellungen', '#', id: nil do |subnav|
|
||||
subnav.item :ordering, 'Bestellen!', group_orders_path, id: nil
|
||||
subnav.item :ordering_archive, 'Meine Bestellungen', archive_group_orders_path, id: nil
|
||||
subnav.item :orders, 'Bestellverwaltung', orders_path, if: Proc.new { current_user.role_orders? }, id: nil
|
||||
primary.item :orders, I18n.t('navigation.orders.title'), '#', id: nil do |subnav|
|
||||
subnav.item :ordering, I18n.t('navigation.orders.ordering'), group_orders_path, id: nil
|
||||
subnav.item :ordering_archive, I18n.t('navigation.orders.archive'), archive_group_orders_path, id: nil
|
||||
subnav.item :orders, I18n.t('navigation.orders.manage'), orders_path, if: Proc.new { current_user.role_orders? }, id: nil
|
||||
end
|
||||
|
||||
primary.item :articles, 'Artikel', '#', id: nil,
|
||||
primary.item :articles, I18n.t('navigation.articles.title'), '#', id: nil,
|
||||
if: Proc.new { current_user.role_article_meta? or current_user.role_suppliers? } do |subnav|
|
||||
subnav.item :suppliers, 'Lieferanten/Artikel', suppliers_path, id: nil
|
||||
subnav.item :stockit, 'Lager', stock_articles_path, id: nil
|
||||
subnav.item :categories, 'Kategorien', article_categories_path, id: nil
|
||||
subnav.item :suppliers, I18n.t('navigation.articles.suppliers'), suppliers_path, id: nil
|
||||
subnav.item :stockit, I18n.t('navigation.articles.stock'), stock_articles_path, id: nil
|
||||
subnav.item :categories, I18n.t('navigation.articles.categories'), article_categories_path, id: nil
|
||||
end
|
||||
|
||||
primary.item :finance, 'Finanzen', '#', id: nil, if: Proc.new { current_user.role_finance? } do |subnav|
|
||||
subnav.item :finance_home, 'Übersicht', finance_root_path
|
||||
subnav.item :accounts, 'Konten verwalten', finance_ordergroups_path, id: nil
|
||||
subnav.item :balancing, 'Bestellungen abrechnen', finance_order_index_path, id: nil
|
||||
subnav.item :invoices, 'Rechnungen', finance_invoices_path, id: nil
|
||||
primary.item :finance, I18n.t('navigation.finances.title'), '#', id: nil, if: Proc.new { current_user.role_finance? } do |subnav|
|
||||
subnav.item :finance_home, I18n.t('navigation.finances.home'), finance_root_path
|
||||
subnav.item :accounts, I18n.t('navigation.finances.accounts'), finance_ordergroups_path, id: nil
|
||||
subnav.item :balancing, I18n.t('navigation.finances.balancing'), finance_order_index_path, id: nil
|
||||
subnav.item :invoices, I18n.t('navigation.finances.invoices'), finance_invoices_path, id: nil
|
||||
end
|
||||
|
||||
primary.item :admin, 'Administration', '#', id: nil, if: Proc.new { current_user.role_admin? } do |subnav|
|
||||
subnav.item :admin_home, 'Übersicht', admin_root_path
|
||||
subnav.item :users, 'Benutzerinnen', admin_users_path, id: nil
|
||||
subnav.item :ordergroups, 'Bestellgruppen', admin_ordergroups_path, id: nil
|
||||
subnav.item :workgroups, 'Arbeitsgruppen', admin_workgroups_path, id: nil
|
||||
primary.item :admin, I18n.t('navigation.admin.title'), '#', id: nil, if: Proc.new { current_user.role_admin? } do |subnav|
|
||||
subnav.item :admin_home, I18n.t('navigation.admin.home'), admin_root_path
|
||||
subnav.item :users, I18n.t('navigation.admin.users'), admin_users_path, id: nil
|
||||
subnav.item :ordergroups, I18n.t('navigation.admin.ordergroups'), admin_ordergroups_path, id: nil
|
||||
subnav.item :workgroups, I18n.t('navigation.admin.workgroups'), admin_workgroups_path, id: nil
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
|||
|
|
@ -1,20 +0,0 @@
|
|||
begin
|
||||
require "rubygems"
|
||||
require "bundler"
|
||||
rescue LoadError
|
||||
raise "Could not load the bundler gem. Install it with `gem install bundler`."
|
||||
end
|
||||
|
||||
if Gem::Version.new(Bundler::VERSION) <= Gem::Version.new("0.9.24")
|
||||
raise RuntimeError, "Your bundler version is too old for Rails 2.3." +
|
||||
"Run `gem install bundler` to upgrade."
|
||||
end
|
||||
|
||||
begin
|
||||
# Set up load paths for all bundled gems
|
||||
ENV["BUNDLE_GEMFILE"] = File.expand_path("../../Gemfile", __FILE__)
|
||||
Bundler.setup
|
||||
rescue Bundler::GemNotFound
|
||||
raise RuntimeError, "Bundler couldn't find some gems." +
|
||||
"Did you run `bundle install`?"
|
||||
end
|
||||
|
|
@ -17,6 +17,7 @@ Foodsoft::Application.routes.draw do
|
|||
|
||||
match '/login' => 'sessions#new', :as => 'login'
|
||||
match '/logout' => 'sessions#destroy', :as => 'logout'
|
||||
get '/login/forgot_password' => 'login#forgot_password', as: :forgot_password
|
||||
get '/login/new_password' => 'login#new_password', as: :new_password
|
||||
match '/login/accept_invitation/:token' => 'login#accept_invitation', as: :accept_invitation
|
||||
resources :sessions, :only => [:new, :create, :destroy]
|
||||
|
|
@ -116,6 +117,7 @@ Foodsoft::Application.routes.draw do
|
|||
get :shared
|
||||
get :import
|
||||
post :sync
|
||||
post :update_synchronized
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
@ -129,6 +131,7 @@ Foodsoft::Application.routes.draw do
|
|||
|
||||
resources :order, controller: 'balancing', path: 'balancing' do
|
||||
member do
|
||||
get :update_summary
|
||||
get :edit_note
|
||||
put :update_note
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue