aboutsummaryrefslogtreecommitdiffhomepage
path: root/app
diff options
context:
space:
mode:
Diffstat (limited to 'app')
-rw-r--r--app/DoctrineMigrations/Version20160410190541.php46
-rw-r--r--app/DoctrineMigrations/Version20160812120952.php25
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.da.yml1
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.de.yml1
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.en.yml1
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.es.yml1
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fa.yml6
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fr.yml1
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.it.yml1
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.oc.yml1
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.pl.yml6
-rw-r--r--app/Resources/CraueConfigBundle/translations/CraueConfigBundle.ro.yml6
-rw-r--r--app/config/security.yml1
13 files changed, 93 insertions, 4 deletions
diff --git a/app/DoctrineMigrations/Version20160410190541.php b/app/DoctrineMigrations/Version20160410190541.php
new file mode 100644
index 00000000..4014857b
--- /dev/null
+++ b/app/DoctrineMigrations/Version20160410190541.php
@@ -0,0 +1,46 @@
1<?php
2
3namespace Application\Migrations;
4
5use Doctrine\DBAL\Migrations\AbstractMigration;
6use Doctrine\DBAL\Schema\Schema;
7use Symfony\Component\DependencyInjection\ContainerAwareInterface;
8use Symfony\Component\DependencyInjection\ContainerInterface;
9
10class Version20160410190541 extends AbstractMigration implements ContainerAwareInterface
11{
12 /**
13 * @var ContainerInterface
14 */
15 private $container;
16
17 public function setContainer(ContainerInterface $container = null)
18 {
19 $this->container = $container;
20 }
21
22 private function getTable($tableName)
23 {
24 return $this->container->getParameter('database_table_prefix') . $tableName;
25 }
26
27 /**
28 * @param Schema $schema
29 */
30 public function up(Schema $schema)
31 {
32 $this->addSql('ALTER TABLE `'.$this->getTable('entry').'` ADD `uuid` LONGTEXT DEFAULT NULL');
33 $this->addSql("INSERT INTO `".$this->getTable('craue_config_setting')."` (`name`, `value`, `section`) VALUES ('share_public', '1', 'entry')");
34 }
35
36 /**
37 * @param Schema $schema
38 */
39 public function down(Schema $schema)
40 {
41 $this->abortIf($this->connection->getDatabasePlatform()->getName() != 'sqlite', 'This down migration can\'t be executed on SQLite databases, because SQLite don\'t support DROP COLUMN.');
42
43 $this->addSql('ALTER TABLE `'.$this->getTable('entry').'` DROP `uuid`');
44 $this->addSql("DELETE FROM `".$this->getTable('craue_config_setting')."` WHERE `name` = 'share_public'");
45 }
46}
diff --git a/app/DoctrineMigrations/Version20160812120952.php b/app/DoctrineMigrations/Version20160812120952.php
index 58f070c7..9adfdc8b 100644
--- a/app/DoctrineMigrations/Version20160812120952.php
+++ b/app/DoctrineMigrations/Version20160812120952.php
@@ -4,15 +4,32 @@ namespace Application\Migrations;
4 4
5use Doctrine\DBAL\Migrations\AbstractMigration; 5use Doctrine\DBAL\Migrations\AbstractMigration;
6use Doctrine\DBAL\Schema\Schema; 6use Doctrine\DBAL\Schema\Schema;
7use Symfony\Component\DependencyInjection\ContainerAwareInterface;
8use Symfony\Component\DependencyInjection\ContainerInterface;
7 9
8class Version20160812120952 extends AbstractMigration 10class Version20160812120952 extends AbstractMigration implements ContainerAwareInterface
9{ 11{
10 /** 12 /**
13 * @var ContainerInterface
14 */
15 private $container;
16
17 public function setContainer(ContainerInterface $container = null)
18 {
19 $this->container = $container;
20 }
21
22 private function getTable($tableName)
23 {
24 return $this->container->getParameter('database_table_prefix') . $tableName;
25 }
26
27 /**
11 * @param Schema $schema 28 * @param Schema $schema
12 */ 29 */
13 public function up(Schema $schema) 30 public function up(Schema $schema)
14 { 31 {
15 $this->addSql('ALTER TABLE wallabag_oauth2_clients ADD name CLOB DEFAULT NULL COLLATE BINARY'); 32 $this->addSql('ALTER TABLE '.$this->getTable('oauth2_clients').' ADD name longtext COLLATE \'utf8_unicode_ci\' DEFAULT NULL');
16 } 33 }
17 34
18 /** 35 /**
@@ -21,7 +38,7 @@ class Version20160812120952 extends AbstractMigration
21 public function down(Schema $schema) 38 public function down(Schema $schema)
22 { 39 {
23 $this->abortIf($this->connection->getDatabasePlatform()->getName() == 'sqlite', 'Migration can only be executed safely on \'mysql\' or \'postgresql\'.'); 40 $this->abortIf($this->connection->getDatabasePlatform()->getName() == 'sqlite', 'Migration can only be executed safely on \'mysql\' or \'postgresql\'.');
24 $this->addSql('ALTER TABLE wallabag_oauth2_clients DROP COLUMN name; 41
25'); 42 $this->addSql('ALTER TABLE '.$this->getTable('oauth2_clients').' DROP COLUMN name');
26 } 43 }
27} 44}
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.da.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.da.yml
index c46fdb14..3478d638 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.da.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.da.yml
@@ -27,3 +27,4 @@ piwik_site_id: ID for din side hos Piwik
27piwik_enabled: Aktiver Piwik 27piwik_enabled: Aktiver Piwik
28demo_mode_enabled: "Aktiver demo-indstilling? (anvendes kun til wallabags offentlige demo)" 28demo_mode_enabled: "Aktiver demo-indstilling? (anvendes kun til wallabags offentlige demo)"
29demo_mode_username: "Demobruger" 29demo_mode_username: "Demobruger"
30# share_public: Allow public url for entries
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.de.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.de.yml
index fa2093b5..f655a27f 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.de.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.de.yml
@@ -27,3 +27,4 @@ piwik_site_id: ID deiner Webseite in Piwik
27piwik_enabled: Piwik aktivieren 27piwik_enabled: Piwik aktivieren
28demo_mode_enabled: "Test-Modus aktivieren? (nur für die öffentliche wallabag-Demo genutzt)" 28demo_mode_enabled: "Test-Modus aktivieren? (nur für die öffentliche wallabag-Demo genutzt)"
29demo_mode_username: "Test-Benutzer" 29demo_mode_username: "Test-Benutzer"
30# share_public: Allow public url for entries
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.en.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.en.yml
index b627376e..48d0ec4b 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.en.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.en.yml
@@ -27,3 +27,4 @@ piwik_site_id: ID of your website in Piwik
27piwik_enabled: Enable Piwik 27piwik_enabled: Enable Piwik
28demo_mode_enabled: "Enable demo mode ? (only used for the wallabag public demo)" 28demo_mode_enabled: "Enable demo mode ? (only used for the wallabag public demo)"
29demo_mode_username: "Demo user" 29demo_mode_username: "Demo user"
30share_public: Allow public url for entries
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.es.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.es.yml
index af1657e4..7aac9adf 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.es.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.es.yml
@@ -27,3 +27,4 @@ piwik_site_id: ID de tu website de Piwik
27piwik_enabled: Activar Piwik 27piwik_enabled: Activar Piwik
28demo_mode_enabled: "Activar modo demo (sólo usado para la demo de wallabag)" 28demo_mode_enabled: "Activar modo demo (sólo usado para la demo de wallabag)"
29demo_mode_username: "Nombre de usuario demo" 29demo_mode_username: "Nombre de usuario demo"
30# share_public: Allow public url for entries
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fa.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fa.yml
index 7cb4e833..613cf86d 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fa.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fa.yml
@@ -22,3 +22,9 @@ export: "برون‌سپاری"
22import: "درون‌ریزی" 22import: "درون‌ریزی"
23misc: "غیره" 23misc: "غیره"
24modify_settings: "اعمال" 24modify_settings: "اعمال"
25# piwik_host: Host of your website in Piwik
26# piwik_site_id: ID of your website in Piwik
27# piwik_enabled: Enable Piwik
28# demo_mode_enabled: "Enable demo mode ? (only used for the wallabag public demo)"
29# demo_mode_username: "Demo user"
30# share_public: Allow public url for entries
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fr.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fr.yml
index 084eb6df..f21f2439 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fr.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fr.yml
@@ -27,3 +27,4 @@ piwik_site_id: ID de votre site dans Piwik
27piwik_enabled: Activer Piwik 27piwik_enabled: Activer Piwik
28demo_mode_enabled: "Activer le mode démo ? (utiliser uniquement pour la démo publique de wallabag)" 28demo_mode_enabled: "Activer le mode démo ? (utiliser uniquement pour la démo publique de wallabag)"
29demo_mode_username: "Utilisateur de la démo" 29demo_mode_username: "Utilisateur de la démo"
30share_public: Autoriser une URL publique pour les articles
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.it.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.it.yml
index e4417139..1202edd5 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.it.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.it.yml
@@ -27,3 +27,4 @@ piwik_site_id: ID del tuo sito in Piwik
27piwik_enabled: Abilita Piwik 27piwik_enabled: Abilita Piwik
28demo_mode_enabled: "Abilita modalità demo ? (usato solo per la demo pubblica di wallabag)" 28demo_mode_enabled: "Abilita modalità demo ? (usato solo per la demo pubblica di wallabag)"
29demo_mode_username: "Utente Demo" 29demo_mode_username: "Utente Demo"
30# share_public: Allow public url for entries
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.oc.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.oc.yml
index 67880b8b..dd91ee49 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.oc.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.oc.yml
@@ -27,3 +27,4 @@ piwik_site_id: ID de vòstre site dins Piwik
27piwik_enabled: Activar Piwik 27piwik_enabled: Activar Piwik
28demo_mode_enabled: "Activar lo mode demostracion ? (utilizar solament per la demostracion publica de wallabag)" 28demo_mode_enabled: "Activar lo mode demostracion ? (utilizar solament per la demostracion publica de wallabag)"
29demo_mode_username: "Utilizaire de la demostracion" 29demo_mode_username: "Utilizaire de la demostracion"
30# share_public: Allow public url for entries
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.pl.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.pl.yml
index 87ca5060..93b36c8f 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.pl.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.pl.yml
@@ -22,3 +22,9 @@ export: "eksport"
22import: "import" 22import: "import"
23misc: "różne" 23misc: "różne"
24modify_settings: "zatwierdz" 24modify_settings: "zatwierdz"
25# piwik_host: Host of your website in Piwik
26# piwik_site_id: ID of your website in Piwik
27# piwik_enabled: Enable Piwik
28# demo_mode_enabled: "Enable demo mode ? (only used for the wallabag public demo)"
29# demo_mode_username: "Demo user"
30# share_public: Allow public url for entries
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.ro.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.ro.yml
index f5ff8c6a..326c9f90 100644
--- a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.ro.yml
+++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.ro.yml
@@ -22,3 +22,9 @@ export: "exportă"
22import: "importă" 22import: "importă"
23misc: "diverse" 23misc: "diverse"
24modify_settings: "aplică" 24modify_settings: "aplică"
25# piwik_host: Host of your website in Piwik
26# piwik_site_id: ID of your website in Piwik
27# piwik_enabled: Enable Piwik
28# demo_mode_enabled: "Enable demo mode ? (only used for the wallabag public demo)"
29# demo_mode_username: "Demo user"
30# share_public: Allow public url for entries
diff --git a/app/config/security.yml b/app/config/security.yml
index e24e03df..1f30e58b 100644
--- a/app/config/security.yml
+++ b/app/config/security.yml
@@ -60,6 +60,7 @@ security:
60 - { path: ^/register, role: IS_AUTHENTICATED_ANONYMOUSLY } 60 - { path: ^/register, role: IS_AUTHENTICATED_ANONYMOUSLY }
61 - { path: ^/resetting, role: IS_AUTHENTICATED_ANONYMOUSLY } 61 - { path: ^/resetting, role: IS_AUTHENTICATED_ANONYMOUSLY }
62 - { path: /(unread|starred|archive).xml$, roles: IS_AUTHENTICATED_ANONYMOUSLY } 62 - { path: /(unread|starred|archive).xml$, roles: IS_AUTHENTICATED_ANONYMOUSLY }
63 - { path: ^/share, roles: IS_AUTHENTICATED_ANONYMOUSLY }
63 - { path: ^/settings, roles: ROLE_SUPER_ADMIN } 64 - { path: ^/settings, roles: ROLE_SUPER_ADMIN }
64 - { path: ^/annotations, roles: ROLE_USER } 65 - { path: ^/annotations, roles: ROLE_USER }
65 - { path: ^/, roles: ROLE_USER } 66 - { path: ^/, roles: ROLE_USER }