Migration to the gem high_voltage: « Easily include static pages in your Rails app»

This replaces the "application" directory where were stored some common static pages
This commit is contained in:
echarp 2016-10-31 23:44:44 +01:00
parent ded6147ba5
commit 2fae5c09a4
19 changed files with 115 additions and 254 deletions

View File

@ -4,6 +4,8 @@ source 'https://rubygems.org'
gem 'simple_calendar' gem 'simple_calendar'
# The recurrence management library # The recurrence management library
gem 'ice_cube' gem 'ice_cube'
# Rails engine for static pages
gem 'high_voltage'
gem 'rails' gem 'rails'
# Later versions require a new ruby version, which is not yet in production # Later versions require a new ruby version, which is not yet in production

View File

@ -108,7 +108,7 @@ GEM
railties (>= 4.1.0, < 5.1) railties (>= 4.1.0, < 5.1)
responders responders
warden (~> 1.2.3) warden (~> 1.2.3)
devise-i18n (1.1.0) devise-i18n (1.1.1)
differ (0.1.2) differ (0.1.2)
docile (1.1.5) docile (1.1.5)
domain_name (0.5.20161021) domain_name (0.5.20161021)
@ -174,7 +174,7 @@ GEM
haml (>= 4.0.6, < 5.0) haml (>= 4.0.6, < 5.0)
html2haml (>= 1.0.1) html2haml (>= 1.0.1)
railties (>= 4.0.1) railties (>= 4.0.1)
haml_lint (0.18.3) haml_lint (0.18.4)
haml (~> 4.0) haml (~> 4.0)
rake (>= 10, < 12) rake (>= 10, < 12)
rubocop (>= 0.36.0) rubocop (>= 0.36.0)
@ -182,6 +182,7 @@ GEM
has_scope (0.6.0) has_scope (0.6.0)
actionpack (>= 3.2, < 5) actionpack (>= 3.2, < 5)
activesupport (>= 3.2, < 5) activesupport (>= 3.2, < 5)
high_voltage (3.0.0)
html2haml (2.0.0) html2haml (2.0.0)
erubis (~> 2.7.0) erubis (~> 2.7.0)
haml (~> 4.0.0) haml (~> 4.0.0)
@ -315,7 +316,7 @@ GEM
request_store (1.3.1) request_store (1.3.1)
responders (2.3.0) responders (2.3.0)
railties (>= 4.2.0, < 5.1) railties (>= 4.2.0, < 5.1)
rubocop (0.44.1) rubocop (0.45.0)
parser (>= 2.3.1.1, < 3.0) parser (>= 2.3.1.1, < 3.0)
powerpack (~> 0.1) powerpack (~> 0.1)
rainbow (>= 1.99.1, < 3.0) rainbow (>= 1.99.1, < 3.0)
@ -428,6 +429,7 @@ DEPENDENCIES
haml-rails haml-rails
haml_lint haml_lint
has_scope (< 0.7) has_scope (< 0.7)
high_voltage
http_accept_language http_accept_language
i18n-active_record! i18n-active_record!
ice_cube ice_cube

View File

@ -1,8 +1,8 @@
# Cleans up filter submission, for cleaner URL # Cleans up filter submission, for cleaner URL
$(document).on 'turbolinks:load', -> $(document).on 'turbolinks:load', ->
$('body.filter form :input').prop 'disabled', false $('body.pages form :input').prop 'disabled', false
$('body.filter form').submit -> $('body.pages form').submit ->
$('input[name=utf8]').prop 'disabled', true $('input[name=utf8]').prop 'disabled', true
$(':input', this).filter -> $(':input', this).filter ->
this.value.length == 0 this.value.length == 0

View File

@ -17,19 +17,5 @@
@import font-awesome-sprockets @import font-awesome-sprockets
@import font-awesome @import font-awesome
body.application body.pages main h4
&.infos h4 text-align: left
text-align: left
&.infos, &.contact, &.rules
main h2:first-child:before
+fa-icon()
margin-right: 0.4em
&.infos main h2:first-child:before
content: $fa-var-info
&.contact main h2:first-child:before
content: $fa-var-envelope
&.rules main h2:first-child:before
content: $fa-var-gavel

View File

@ -107,7 +107,7 @@ a#banner
margin-left: 5% margin-left: 5%
padding-left: 2px padding-left: 2px
body.events.show, body.orgas.show, body.tags.show, body.filter body.events.show, body.orgas.show, body.tags.show, body.pages
main main
padding: 1em padding: 1em
max-width: 60em max-width: 60em

View File

@ -1,7 +1,7 @@
@import font-awesome-sprockets @import font-awesome-sprockets
@import font-awesome @import font-awesome
.events form, .moderations form, .orgas, .digests form, .filter form .events form, .moderations form, .orgas, .digests form, .pages form
.field, .actions .field, .actions
max-width: 70em max-width: 70em
text-align: left text-align: left

View File

@ -50,7 +50,7 @@
\- \-
= link_to application_filter_path do = link_to page_path('filter') do
%em.fa.fa-filter %em.fa.fa-filter
= t '.filter' = t '.filter'

View File

@ -62,13 +62,13 @@
= link_to versions_path do = link_to versions_path do
%em.fa.fa-exchange %em.fa.fa-exchange
= t 'versions.index.title' = t 'versions.index.title'
= link_to application_infos_path do = link_to page_path('infos') do
%em.fa.fa-info %em.fa.fa-info
= t '.infos' = t '.infos'
= link_to stats_path do = link_to stats_path do
%em.fa.fa-signal %em.fa.fa-signal
= t '.stats' = t '.stats'
= link_to application_contact_path do = link_to page_path('contact') do
%em.fa.fa-envelope %em.fa.fa-envelope
= t '.contact' = t '.contact'
= link_to moderations_path do = link_to moderations_path do

View File

@ -162,7 +162,7 @@ it more readable or agreable.
index: index:
title: Events to moderate title: Events to moderate
rules: Moderators, thanks for reading and taking notice of [moderation rules: Moderators, thanks for reading and taking notice of [moderation
recommandations](/application/rules). recommandations](/pages/rules).
actions: Actions actions: Actions
posted_by: Created by %{author} on %{date} posted_by: Created by %{author} on %{date}
date: Date date: Date
@ -419,7 +419,7 @@ reason:
destroy_html: <em class='fa fa-trash'></em> destroy_html: <em class='fa fa-trash'></em>
feed: RSS feed feed: RSS feed
application: pages:
filter: filter:
title: Advanced filtering title: Advanced filtering
helper: Choose one or more filters to display events or integrate them in helper: Choose one or more filters to display events or integrate them in

View File

@ -159,7 +159,7 @@ fr:
index: index:
title: Événements à modérer title: Événements à modérer
rules: Modérateurs, merci de lire et de tenir compte des [recommandations rules: Modérateurs, merci de lire et de tenir compte des [recommandations
de modération](/application/rules). de modération](/pages/rules).
actions: Actions actions: Actions
posted_by: Posté par %{author} le %{date} posted_by: Posté par %{author} le %{date}
date: Date date: Date
@ -423,7 +423,7 @@ l'adresse:"
destroy_html: <em class='fa fa-trash'></em> destroy_html: <em class='fa fa-trash'></em>
feed: Flux RSS feed: Flux RSS
application: pages:
filter: filter:
title: Filtrage avancé title: Filtrage avancé
helper: Choisissez un ou plusieurs filtres pour afficher les événements helper: Choisissez un ou plusieurs filtres pour afficher les événements

View File

@ -163,7 +163,7 @@ completa, deixando o texto mais legível e agradável.
index: index:
title: Eventos para moderar title: Eventos para moderar
rules: Moderadores, obrigado por ler e tomar conhecimento das [recomendações rules: Moderadores, obrigado por ler e tomar conhecimento das [recomendações
de moderação](/application/rules). de moderação](/pages/rules).
actions: Ações actions: Ações
posted_by: Criado por %{author} em %{date} posted_by: Criado por %{author} em %{date}
date: Data date: Data
@ -455,7 +455,7 @@ do evento no seguinte endereço:"
destroy_html: <em class='fa fa-trash'></em> destroy_html: <em class='fa fa-trash'></em>
feed: feed RSS feed: feed RSS
application: pages:
filter: filter:
title: Busca Avançada title: Busca Avançada
helper: Os parâmetros podem ser usados na agenda para consulta, ou integração em outro site helper: Os parâmetros podem ser usados na agenda para consulta, ou integração em outro site

View File

@ -1,8 +1,4 @@
Rails.application.routes.draw do Rails.application.routes.draw do
get 'application/infos'
get 'application/contact'
get 'application/rules'
get 'application/filter'
get 'stats', to: 'stats#index' get 'stats', to: 'stats#index'
get 'versions', to: 'versions#index' get 'versions', to: 'versions#index'

View File

@ -0,0 +1,19 @@
# Migrate some i18n translations in the database to the high_voltage static
# page CMS
class MigrateI18nToHighVoltage < ActiveRecord::Migration
def up
update "
update translations
set `key` = replace(`key`, 'application', 'pages')
where `key` like 'application.%'
"
end
def down
update "
update translations
set `key` = replace(`key`, 'pages', 'application')
where `key` like 'pages.%'
"
end
end

View File

@ -76,8 +76,8 @@ Si vous soumettez souvent un événement régulier dans l'Agenda du Libre, vous
*Dans les tags, indiquez le nom de la ou des associations organisatrices. N'indiquez pas le nom de la ville ou de la région.*" }, *Dans les tags, indiquez le nom de la ou des associations organisatrices. N'indiquez pas le nom de la ville ou de la région.*" },
{ locale: 'fr', key: 'application.infos.content', { locale: 'fr', key: 'pages.infos.content',
value: "## Informations value: "## <em class='fa fa-info'></em> Informations
### Table des matières ### Table des matières
@ -361,16 +361,16 @@ Bien que le logiciel faisant fonctionner l'Agenda du Libre soit spécifique, d'a
#### 05/06/2005 #### 05/06/2005
* Lancement du site" }, * Lancement du site" },
{ locale: 'fr', key: 'application.contact.content', { locale: 'fr', key: 'pages.contact.content',
value: "## Contact value: "## <em class='fa fa-envelope'></em> Contact
Pour contacter les modérateurs du site *Agenda du Libre*: Pour contacter les modérateurs du site *Agenda du Libre*:
* Par courrier électronique, à l'adresse moderateurs@agendadulibre.org * Par courrier électronique, à l'adresse moderateurs@agendadulibre.org
* Par [IRC](http://fr.wikipedia.org/wiki/IRC), sur le canal `#agendadulibre` du réseau *Freenode*" }, * Par [IRC](http://fr.wikipedia.org/wiki/IRC), sur le canal `#agendadulibre` du réseau *Freenode*" },
{ locale: 'fr', key: 'application.rules.content', { locale: 'fr', key: 'pages.rules.content',
value: "## Recommandations sur la modération value: "## <em class='fa fa-gavel'></em> Recommandations sur la modération
Tous les événements de l'Agenda du Libre passent par une phase de modération, qui permet de s'assurer que les événements recensés rentrent bien dans la [ligne éditoriale](#ligne) et que la [qualité de la description des événements](#qualite) reste bonne. Tous les événements de l'Agenda du Libre passent par une phase de modération, qui permet de s'assurer que les événements recensés rentrent bien dans la [ligne éditoriale](#ligne) et que la [qualité de la description des événements](#qualite) reste bonne.

View File

@ -1,215 +1,71 @@
-- MySQL dump 10.13 Distrib 5.5.33, for debian-linux-gnu (x86_64) CREATE TABLE "schema_migrations" ("version" varchar NOT NULL);
-- CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version");
-- Host: localhost Database: adl_fr CREATE TABLE "active_admin_comments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "namespace" varchar(255), "body" text(65535), "resource_id" varchar(255) NOT NULL, "resource_type" varchar(255) NOT NULL, "author_id" integer(4), "author_type" varchar(255), "created_at" datetime, "updated_at" datetime);
-- ------------------------------------------------------ CREATE INDEX "index_active_admin_comments_on_author_type_and_author_id" ON "active_admin_comments" ("author_type", "author_id");
-- Server version 5.5.33-1 CREATE INDEX "index_active_admin_comments_on_namespace" ON "active_admin_comments" ("namespace");
CREATE INDEX "index_active_admin_comments_on_resource_type_and_resource_id" ON "active_admin_comments" ("resource_type", "resource_id");
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; CREATE TABLE "admin_users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "email" varchar(255) DEFAULT '' NOT NULL, "encrypted_password" varchar(255) DEFAULT '' NOT NULL, "reset_password_token" varchar(255), "reset_password_sent_at" datetime, "remember_created_at" datetime, "sign_in_count" integer(4) DEFAULT 0 NOT NULL, "current_sign_in_at" datetime, "last_sign_in_at" datetime, "current_sign_in_ip" varchar(255), "last_sign_in_ip" varchar(255), "created_at" datetime, "updated_at" datetime);
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; CREATE UNIQUE INDEX "index_admin_users_on_email" ON "admin_users" ("email");
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; CREATE UNIQUE INDEX "index_admin_users_on_reset_password_token" ON "admin_users" ("reset_password_token");
/*!40101 SET NAMES utf8 */; CREATE TABLE "cities" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255) DEFAULT '' NOT NULL, "majname" varchar(255) DEFAULT '' NOT NULL, "postalcode" integer(4), "inseecode" integer(4), "regioncode" integer(4), "latitude" float(24), "longitude" float(24));
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */; CREATE INDEX "cities_name" ON "cities" ("name");
/*!40103 SET TIME_ZONE='+00:00' */; CREATE TABLE "events" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255) DEFAULT '' NOT NULL, "description" text(65535) NOT NULL, "start_time" datetime NOT NULL, "end_time" datetime NOT NULL, "city" varchar(255) DEFAULT '', "region_id" integer(4) DEFAULT 0 NOT NULL, "locality" integer(4) DEFAULT 0 NOT NULL, "url" varchar(255) DEFAULT '' NOT NULL, "contact" varchar(255) DEFAULT '' NOT NULL, "submitter" varchar(255) DEFAULT '' NOT NULL, "moderated" integer(4) DEFAULT 0 NOT NULL, "tags" varchar(255) DEFAULT '' NOT NULL, "secret" varchar(255) DEFAULT '' NOT NULL, "decision_time" datetime, "submission_time" datetime, "moderator_mail_id" varchar(32), "submitter_mail_id" varchar(32), "address" text(65535), "latitude" float(24), "longitude" float(24), "lock_version" integer(4) DEFAULT 0 NOT NULL, "place_name" varchar(255), "count" integer DEFAULT 1, "repeat" integer DEFAULT 0, "rule" text, "event_id" integer);
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; CREATE INDEX "index_events_on_event_id" ON "events" ("event_id");
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */; CREATE INDEX "events_date" ON "events" ("start_time", "end_time");
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */; CREATE TABLE "kinds" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar NOT NULL, "icon" varchar, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL);
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */; CREATE TABLE "notes" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "contents" text(65535) NOT NULL, "date" datetime NOT NULL, "event_id" integer(4), "author_id" integer(4));
CREATE TABLE "orgas" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "region_id" integer(4) DEFAULT 0 NOT NULL, "department" varchar(4) DEFAULT '0' NOT NULL, "name" varchar(255) DEFAULT '' NOT NULL, "url" varchar(255) DEFAULT '' NOT NULL, "city" varchar(255) DEFAULT '', "kind_id" integer(4), "feed" varchar(255), "contact" varchar(255), "submitter" varchar(255), "moderated" boolean(1) DEFAULT 'f', "submission_time" datetime, "decision_time" datetime, "secret" varchar(255), "deleted" boolean(1) DEFAULT 'f' NOT NULL, "active" boolean DEFAULT 't' NOT NULL, "description" text, "created_at" datetime, "updated_at" datetime, "tag" text, "tags" text DEFAULT '', "diaspora" text, "object_changes" text, "place_name" text, "address" text, "latitude" float, "longitude" float);
-- CREATE INDEX "index_orgas_on_kind_id" ON "orgas" ("kind_id");
-- Table structure for table `active_admin_comments` CREATE TABLE "regions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255) DEFAULT '' NOT NULL);
-- CREATE TABLE "taggings" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "tag_id" integer, "taggable_id" integer, "taggable_type" varchar(255), "tagger_id" integer, "tagger_type" varchar(255), "context" varchar(128), "created_at" datetime);
CREATE UNIQUE INDEX "taggings_idx" ON "taggings" ("tag_id", "taggable_id", "taggable_type", "context", "tagger_id", "tagger_type");
DROP TABLE IF EXISTS `active_admin_comments`; CREATE INDEX "index_taggings_on_taggable_id_and_taggable_type_and_context" ON "taggings" ("taggable_id", "taggable_type", "context");
/*!40101 SET @saved_cs_client = @@character_set_client */; CREATE TABLE "tags" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "taggings_count" integer DEFAULT 0);
/*!40101 SET character_set_client = utf8 */; CREATE UNIQUE INDEX "index_tags_on_name" ON "tags" ("name");
CREATE TABLE `active_admin_comments` ( CREATE TABLE "translations" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "locale" varchar(255), "key" varchar(255), "value" text(65535), "interpolations" text(65535), "is_proc" boolean(1) DEFAULT 'f');
`id` int(11) NOT NULL AUTO_INCREMENT, CREATE TABLE "users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "login" varchar(255) DEFAULT '' NOT NULL, "password" varchar(255) DEFAULT '' NOT NULL, "email" varchar(255) DEFAULT '' NOT NULL, "lastname" varchar(255) DEFAULT '' NOT NULL, "firstname" varchar(255) DEFAULT '' NOT NULL, "confirmation_token" varchar, "confirmed_at" datetime, "confirmation_sent_at" datetime, "remember_created_at" datetime);
`namespace` varchar(255) DEFAULT NULL, CREATE UNIQUE INDEX "index_users_on_confirmation_token" ON "users" ("confirmation_token");
`body` text, CREATE TABLE "versions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "item_type" varchar NOT NULL, "item_id" integer NOT NULL, "event" varchar NOT NULL, "whodunnit" varchar, "object" text, "created_at" datetime, "object_changes" text(1073741823));
`resource_id` varchar(255) NOT NULL, CREATE INDEX "index_versions_on_item_type_and_item_id" ON "versions" ("item_type", "item_id");
`resource_type` varchar(255) NOT NULL,
`author_id` int(11) DEFAULT NULL,
`author_type` varchar(255) DEFAULT NULL,
`created_at` datetime DEFAULT NULL,
`updated_at` datetime DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `index_active_admin_comments_on_namespace` (`namespace`),
KEY `index_active_admin_comments_on_author_type_and_author_id` (`author_type`,`author_id`),
KEY `index_active_admin_comments_on_resource_type_and_resource_id` (`resource_type`,`resource_id`)
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `admin_users`
--
DROP TABLE IF EXISTS `admin_users`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `admin_users` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`email` varchar(255) NOT NULL DEFAULT '',
`encrypted_password` varchar(255) NOT NULL DEFAULT '',
`reset_password_token` varchar(255) DEFAULT NULL,
`reset_password_sent_at` datetime DEFAULT NULL,
`remember_created_at` datetime DEFAULT NULL,
`sign_in_count` int(11) NOT NULL DEFAULT '0',
`current_sign_in_at` datetime DEFAULT NULL,
`last_sign_in_at` datetime DEFAULT NULL,
`current_sign_in_ip` varchar(255) DEFAULT NULL,
`last_sign_in_ip` varchar(255) DEFAULT NULL,
`created_at` datetime DEFAULT NULL,
`updated_at` datetime DEFAULT NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `index_admin_users_on_email` (`email`),
UNIQUE KEY `index_admin_users_on_reset_password_token` (`reset_password_token`)
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `cities`
--
DROP TABLE IF EXISTS `cities`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `cities` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`name` varchar(255) NOT NULL DEFAULT '',
`majname` varchar(255) NOT NULL DEFAULT '',
`postalcode` int(11) DEFAULT NULL,
`inseecode` int(11) DEFAULT NULL,
`regioncode` int(11) DEFAULT NULL,
`latitude` float DEFAULT NULL,
`longitude` float DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `cities_name` (`name`)
) ENGINE=MyISAM AUTO_INCREMENT=51637 DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `events`
--
DROP TABLE IF EXISTS `events`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `events` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`title` varchar(255) NOT NULL DEFAULT '',
`description` text NOT NULL,
`start_time` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
`end_time` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
`city` varchar(255) NOT NULL DEFAULT '',
`region` int(11) NOT NULL DEFAULT '0',
`locality` int(11) NOT NULL DEFAULT '0',
`url` varchar(255) NOT NULL DEFAULT '',
`contact` varchar(255) NOT NULL DEFAULT '',
`submitter` varchar(255) NOT NULL DEFAULT '',
`moderated` int(11) NOT NULL DEFAULT '0',
`tags` varchar(255) NOT NULL DEFAULT '',
`secret` varchar(255) NOT NULL DEFAULT '',
`decision_time` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
`submission_time` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
`moderator_mail_id` varchar(32) DEFAULT NULL,
`submitter_mail_id` varchar(32) DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `events_date` (`start_time`,`end_time`)
) ENGINE=MyISAM AUTO_INCREMENT=8113 DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `lugs`
--
DROP TABLE IF EXISTS `lugs`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `lugs` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`region` int(11) NOT NULL DEFAULT '0',
`department` int(11),
`name` varchar(255) NOT NULL DEFAULT '',
`url` varchar(255) NOT NULL DEFAULT '',
`city` varchar(255) NOT NULL DEFAULT '',
PRIMARY KEY (`id`)
) ENGINE=MyISAM AUTO_INCREMENT=3444 DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `notes`
--
DROP TABLE IF EXISTS `notes`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `notes` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`contents` text NOT NULL,
`date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
`event_id` int(11) DEFAULT NULL,
`author_id` int(11) DEFAULT NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM AUTO_INCREMENT=662 DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `regions`
--
DROP TABLE IF EXISTS `regions`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `regions` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`name` varchar(255) NOT NULL DEFAULT '',
PRIMARY KEY (`id`)
) ENGINE=MyISAM AUTO_INCREMENT=28 DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `schema_migrations`
--
DROP TABLE IF EXISTS `schema_migrations`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `schema_migrations` (
`version` varchar(255) NOT NULL,
UNIQUE KEY `unique_schema_migrations` (`version`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Table structure for table `users`
--
DROP TABLE IF EXISTS `users`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `users` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`login` varchar(255) NOT NULL DEFAULT '',
`password` varchar(255) NOT NULL DEFAULT '',
`email` varchar(255) NOT NULL DEFAULT '',
`lastname` varchar(255) NOT NULL DEFAULT '',
`firstname` varchar(255) NOT NULL DEFAULT '',
PRIMARY KEY (`id`)
) ENGINE=MyISAM AUTO_INCREMENT=12 DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
-- Dump completed on 2013-11-24 15:40:00
INSERT INTO schema_migrations (version) VALUES ('0');
INSERT INTO schema_migrations (version) VALUES ('20131114103118'); INSERT INTO schema_migrations (version) VALUES ('20131114103118');
INSERT INTO schema_migrations (version) VALUES ('20131114103121'); INSERT INTO schema_migrations (version) VALUES ('20131114103121');
INSERT INTO schema_migrations (version) VALUES ('20140403204748');
INSERT INTO schema_migrations (version) VALUES ('20140823111115');
INSERT INTO schema_migrations (version) VALUES ('20141011100700');
INSERT INTO schema_migrations (version) VALUES ('20150215121248');
INSERT INTO schema_migrations (version) VALUES ('20150215151059');
INSERT INTO schema_migrations (version) VALUES ('20150215172000');
INSERT INTO schema_migrations (version) VALUES ('20150215172739');
INSERT INTO schema_migrations (version) VALUES ('20150301223829');
INSERT INTO schema_migrations (version) VALUES ('20150711164423');
INSERT INTO schema_migrations (version) VALUES ('20151225194836');
INSERT INTO schema_migrations (version) VALUES ('20151226223947');
INSERT INTO schema_migrations (version) VALUES ('20160102152958');
INSERT INTO schema_migrations (version) VALUES ('20160103141244');
INSERT INTO schema_migrations (version) VALUES ('20160107203117');
INSERT INTO schema_migrations (version) VALUES ('20160109203136');
INSERT INTO schema_migrations (version) VALUES ('20160111124855');
INSERT INTO schema_migrations (version) VALUES ('20160409131029');
INSERT INTO schema_migrations (version) VALUES ('20160616190823');
INSERT INTO schema_migrations (version) VALUES ('20161031215120');