diff options
Diffstat (limited to 'app')
-rw-r--r-- | app/AppKernel.php | 1 | ||||
-rw-r--r-- | app/DoctrineMigrations/.gitkeep | 0 | ||||
-rw-r--r-- | app/Resources/CraueConfigBundle/translations/CraueConfigBundle.en.yml | 19 | ||||
-rw-r--r-- | app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fr.yml | 19 | ||||
-rw-r--r-- | app/Resources/CraueConfigBundle/views/Settings/modify.html.twig | 43 | ||||
-rw-r--r-- | app/config/config.yml | 31 | ||||
-rw-r--r-- | app/config/parameters.yml.dist | 38 | ||||
-rw-r--r-- | app/config/routing.yml | 9 | ||||
-rw-r--r-- | app/config/security.yml | 1 | ||||
-rw-r--r-- | app/config/tests/parameters.yml.dist.mysql | 38 | ||||
-rw-r--r-- | app/config/tests/parameters.yml.dist.pgsql | 38 | ||||
-rw-r--r-- | app/config/tests/parameters.yml.dist.sqlite | 38 |
12 files changed, 110 insertions, 165 deletions
diff --git a/app/AppKernel.php b/app/AppKernel.php index 7e76a9e9..82d3aa38 100644 --- a/app/AppKernel.php +++ b/app/AppKernel.php | |||
@@ -33,6 +33,7 @@ class AppKernel extends Kernel | |||
33 | new KPhoen\RulerZBundle\KPhoenRulerZBundle(), | 33 | new KPhoen\RulerZBundle\KPhoenRulerZBundle(), |
34 | new Wallabag\ImportBundle\WallabagImportBundle(), | 34 | new Wallabag\ImportBundle\WallabagImportBundle(), |
35 | new Doctrine\Bundle\MigrationsBundle\DoctrineMigrationsBundle(), | 35 | new Doctrine\Bundle\MigrationsBundle\DoctrineMigrationsBundle(), |
36 | new Craue\ConfigBundle\CraueConfigBundle(), | ||
36 | ]; | 37 | ]; |
37 | 38 | ||
38 | if (in_array($this->getEnvironment(), ['dev', 'test'], true)) { | 39 | if (in_array($this->getEnvironment(), ['dev', 'test'], true)) { |
diff --git a/app/DoctrineMigrations/.gitkeep b/app/DoctrineMigrations/.gitkeep new file mode 100644 index 00000000..e69de29b --- /dev/null +++ b/app/DoctrineMigrations/.gitkeep | |||
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.en.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.en.yml new file mode 100644 index 00000000..6d86eab6 --- /dev/null +++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.en.yml | |||
@@ -0,0 +1,19 @@ | |||
1 | download_pictures: Download pictures on your server | ||
2 | carrot: Enable share to Carrot | ||
3 | diaspora_url: Diaspora URL, if the service is enabled | ||
4 | export_epub: Enable ePub export | ||
5 | export_mobi: Enable .mobi export | ||
6 | export_pdf: Enable PDF export | ||
7 | export_csv: Enable CSV export | ||
8 | export_json: Enable JSON export | ||
9 | export_txt: Enable TXT export | ||
10 | export_xml: Enable XML export | ||
11 | pocket_consumer_key: Consumer key for Pocket to import contents (https://getpocket.com/developer/docs/authentication) | ||
12 | shaarli_url: Shaarli URL, if the service is enabled | ||
13 | share_diaspora: Enable share to Diaspora | ||
14 | share_mail: Enable share by email | ||
15 | share_shaarli: Enable share to Shaarli | ||
16 | share_twitter: Enable share to Twitter | ||
17 | show_printlink: Display a link to print content | ||
18 | wallabag_support_url: Support URL for wallabag | ||
19 | wallabag_url: URL of *your* wallabag instance | ||
diff --git a/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fr.yml b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fr.yml new file mode 100644 index 00000000..cdd56acd --- /dev/null +++ b/app/Resources/CraueConfigBundle/translations/CraueConfigBundle.fr.yml | |||
@@ -0,0 +1,19 @@ | |||
1 | download_pictures: Télécharger les images sur le serveur | ||
2 | carrot: Activer le partage vers Carrot | ||
3 | diaspora_url: URL de Diaspora, si le service Diaspora est activé | ||
4 | export_epub: Activer l'export ePub | ||
5 | export_mobi: Activer l'export .mobi | ||
6 | export_pdf: Activer l'export PDF | ||
7 | export_csv: Activer l'export CSV | ||
8 | export_json: Activer l'export JSON | ||
9 | export_txt: Activer l'export TXT | ||
10 | export_xml: Activer l'export XML | ||
11 | pocket_consumer_key: Clé d'authentification Pocket pour importer les données (https://getpocket.com/developer/docs/authentication) | ||
12 | shaarli_url: URL de Shaarli, si le service Shaarli est activé | ||
13 | share_diaspora: Activer le partage vers Diaspora | ||
14 | share_mail: Activer le partage par email | ||
15 | share_shaarli: Activer le partage vers Shaarli | ||
16 | share_twitter: Activer le partage vers Twitter | ||
17 | show_printlink: Afficher un lien pour imprimer | ||
18 | wallabag_support_url: URL de support de wallabag | ||
19 | wallabag_url: URL de *votre* instance de wallabag | ||
diff --git a/app/Resources/CraueConfigBundle/views/Settings/modify.html.twig b/app/Resources/CraueConfigBundle/views/Settings/modify.html.twig new file mode 100644 index 00000000..f44db420 --- /dev/null +++ b/app/Resources/CraueConfigBundle/views/Settings/modify.html.twig | |||
@@ -0,0 +1,43 @@ | |||
1 | {% extends "WallabagCoreBundle::layout.html.twig" %} | ||
2 | |||
3 | {% block title %}{% trans %}internal settings{% endtrans %}{% endblock %} | ||
4 | |||
5 | {% block content %} | ||
6 | <div class="row"> | ||
7 | <div class="col s12"> | ||
8 | <div class="card-panel settings"> | ||
9 | {{ form_start(form, {'attr': {'class': 'craue_config_settings_modify'}}) }} | ||
10 | {{ form_errors(form) }} | ||
11 | |||
12 | <div class="row"> | ||
13 | <div class="div_tabs col s12"> | ||
14 | <ul class="tabs"> | ||
15 | {% for section in sections | craue_sortSections %} | ||
16 | <li class="tab col s3"><a href="#set-{{ section }}">{{ section | trans({}, 'CraueConfigBundle') }}</a></li> | ||
17 | {% endfor %} | ||
18 | </ul> | ||
19 | </div> | ||
20 | |||
21 | {% for section in sections | craue_sortSections %} | ||
22 | <div id="set-{{ section }}" class="col s12"> | ||
23 | {% for setting in form.settings if setting.section.vars.value == section %} | ||
24 | {{ form_row(setting.name) }} | ||
25 | {{ form_row(setting.section) }} | ||
26 | {{ form_row(setting.value, { | ||
27 | 'label': setting.name.vars.value | trans({}, 'CraueConfigBundle'), | ||
28 | }) }} | ||
29 | {% endfor %} | ||
30 | </div> | ||
31 | {% endfor %} | ||
32 | </div> | ||
33 | |||
34 | <button class="btn waves-effect waves-light" type="submit" name="action"> | ||
35 | {{ 'modify_settings' | trans({}, 'CraueConfigBundle') }} | ||
36 | </button> | ||
37 | |||
38 | {{ form_rest(form) }} | ||
39 | {{ form_end(form) }} | ||
40 | </div> | ||
41 | </div> | ||
42 | </div> | ||
43 | {% endblock %} | ||
diff --git a/app/config/config.yml b/app/config/config.yml index a6cfc67d..7dac4d3b 100644 --- a/app/config/config.yml +++ b/app/config/config.yml | |||
@@ -28,11 +28,17 @@ framework: | |||
28 | assets: ~ | 28 | assets: ~ |
29 | 29 | ||
30 | wallabag_core: | 30 | wallabag_core: |
31 | version: 2.0.0-alpha.2 | ||
32 | paypal_url: "https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=9UBA65LG3FX9Y&lc=gb" | ||
31 | languages: | 33 | languages: |
32 | en: 'English' | 34 | en: 'English' |
33 | fr: 'Français' | 35 | fr: 'Français' |
34 | de: 'Deutsch' | 36 | de: 'Deutsch' |
35 | tr: 'Türkçe' | 37 | tr: 'Türkçe' |
38 | items_on_page: 12 | ||
39 | theme: material | ||
40 | language: en | ||
41 | rss_limit: 50 | ||
36 | 42 | ||
37 | wallabag_import: | 43 | wallabag_import: |
38 | allow_mimetypes: ['application/octet-stream', 'application/json', 'text/plain'] | 44 | allow_mimetypes: ['application/octet-stream', 'application/json', 'text/plain'] |
@@ -42,29 +48,6 @@ wallabag_import: | |||
42 | twig: | 48 | twig: |
43 | debug: "%kernel.debug%" | 49 | debug: "%kernel.debug%" |
44 | strict_variables: "%kernel.debug%" | 50 | strict_variables: "%kernel.debug%" |
45 | globals: | ||
46 | share_twitter: %share_twitter% | ||
47 | share_mail: %share_mail% | ||
48 | share_shaarli: %share_shaarli% | ||
49 | shaarli_url: %shaarli_url% | ||
50 | share_diaspora: %share_diaspora% | ||
51 | diaspora_url: %diaspora_url% | ||
52 | flattr: %flattr% | ||
53 | flattrable: 1 | ||
54 | flattred: 2 | ||
55 | carrot: %carrot% | ||
56 | show_printlink: %show_printlink% | ||
57 | export_epub: %export_epub% | ||
58 | export_mobi: %export_mobi% | ||
59 | export_pdf: %export_pdf% | ||
60 | export_csv: %export_csv% | ||
61 | export_json: %export_json% | ||
62 | export_txt: %export_txt% | ||
63 | export_xml: %export_xml% | ||
64 | version: %app.version% | ||
65 | twofactor_auth: %twofactor_auth% | ||
66 | warning_message: %warning_message% | ||
67 | paypal_url: "https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=9UBA65LG3FX9Y&lc=gb" | ||
68 | form_themes: | 51 | form_themes: |
69 | - "LexikFormFilterBundle:Form:form_div_layout.html.twig" | 52 | - "LexikFormFilterBundle:Form:form_div_layout.html.twig" |
70 | 53 | ||
@@ -185,7 +168,7 @@ fos_user: | |||
185 | user_class: Wallabag\UserBundle\Entity\User | 168 | user_class: Wallabag\UserBundle\Entity\User |
186 | registration: | 169 | registration: |
187 | confirmation: | 170 | confirmation: |
188 | enabled: true | 171 | enabled: %fosuser_confirmation% |
189 | from_email: | 172 | from_email: |
190 | address: %from_email% | 173 | address: %from_email% |
191 | sender_name: wallabag | 174 | sender_name: wallabag |
diff --git a/app/config/parameters.yml.dist b/app/config/parameters.yml.dist index ac4a4cc8..7c7413fb 100644 --- a/app/config/parameters.yml.dist +++ b/app/config/parameters.yml.dist | |||
@@ -37,43 +37,11 @@ parameters: | |||
37 | # A secret key that's used to generate certain security-related tokens | 37 | # A secret key that's used to generate certain security-related tokens |
38 | secret: ovmpmAWXRCabNlMgzlzFXDYmCFfzGv | 38 | secret: ovmpmAWXRCabNlMgzlzFXDYmCFfzGv |
39 | 39 | ||
40 | # wallabag misc | 40 | # two factor stuff |
41 | app.version: 2.0.0-alpha | ||
42 | twofactor_auth: true | 41 | twofactor_auth: true |
43 | twofactor_sender: no-reply@wallabag.org | 42 | twofactor_sender: no-reply@wallabag.org |
44 | 43 | ||
45 | # message to display at the bottom of the page | 44 | # fosuser stuff |
46 | warning_message: > | 45 | fosuser_confirmation: true |
47 | You're trying wallabag v2, which is in alpha version. If you find a bug, please have a look to <a href="https://github.com/wallabag/wallabag/issues">our issues list</a> and <a href="https://github.com/wallabag/wallabag/issues/new">open a new if necessary</a> | ||
48 | 46 | ||
49 | download_pictures: false # if true, pictures will be stored into data/assets for each article | ||
50 | |||
51 | # Entry view | ||
52 | share_twitter: true | ||
53 | share_mail: true | ||
54 | share_shaarli: true | ||
55 | shaarli_url: http://myshaarli.com | ||
56 | share_diaspora: true | ||
57 | diaspora_url: http://diasporapod.com | ||
58 | flattr: true | ||
59 | carrot: true | ||
60 | show_printlink: true | ||
61 | export_epub: true | ||
62 | export_mobi: true | ||
63 | export_pdf: true | ||
64 | export_csv: true | ||
65 | export_json: true | ||
66 | export_txt: true | ||
67 | export_xml: true | ||
68 | wallabag_url: http://v2.wallabag.org | ||
69 | wallabag_support_url: 'https://www.wallabag.org/pages/support.html' | ||
70 | |||
71 | # default user config | ||
72 | items_on_page: 12 | ||
73 | theme: material | ||
74 | language: en | ||
75 | from_email: no-reply@wallabag.org | 47 | from_email: no-reply@wallabag.org |
76 | rss_limit: 50 | ||
77 | |||
78 | # pocket import | ||
79 | pocket_consumer_key: xxxxxxxx | ||
diff --git a/app/config/routing.yml b/app/config/routing.yml index 84b98d23..c491d35d 100644 --- a/app/config/routing.yml +++ b/app/config/routing.yml | |||
@@ -22,7 +22,9 @@ rest : | |||
22 | 22 | ||
23 | homepage: | 23 | homepage: |
24 | path: "/{page}" | 24 | path: "/{page}" |
25 | defaults: { _controller: WallabagCoreBundle:Entry:showUnread, page : 1 } | 25 | defaults: |
26 | _controller: WallabagCoreBundle:Entry:showUnread | ||
27 | page : 1 | ||
26 | requirements: | 28 | requirements: |
27 | page: \d+ | 29 | page: \d+ |
28 | 30 | ||
@@ -31,3 +33,8 @@ fos_user: | |||
31 | 33 | ||
32 | fos_oauth_server_token: | 34 | fos_oauth_server_token: |
33 | resource: "@FOSOAuthServerBundle/Resources/config/routing/token.xml" | 35 | resource: "@FOSOAuthServerBundle/Resources/config/routing/token.xml" |
36 | |||
37 | craue_config_settings_modify: | ||
38 | path: /settings | ||
39 | defaults: | ||
40 | _controller: CraueConfigBundle:Settings:modify | ||
diff --git a/app/config/security.yml b/app/config/security.yml index a99a7d80..7c10889f 100644 --- a/app/config/security.yml +++ b/app/config/security.yml | |||
@@ -57,4 +57,5 @@ security: | |||
57 | - { path: ^/register, role: IS_AUTHENTICATED_ANONYMOUSLY } | 57 | - { path: ^/register, role: IS_AUTHENTICATED_ANONYMOUSLY } |
58 | - { path: ^/resetting, role: IS_AUTHENTICATED_ANONYMOUSLY } | 58 | - { path: ^/resetting, role: IS_AUTHENTICATED_ANONYMOUSLY } |
59 | - { path: /(unread|starred|archive).xml$, roles: IS_AUTHENTICATED_ANONYMOUSLY } | 59 | - { path: /(unread|starred|archive).xml$, roles: IS_AUTHENTICATED_ANONYMOUSLY } |
60 | - { path: ^/settings, roles: ROLE_SUPER_ADMIN } | ||
60 | - { path: ^/, roles: ROLE_USER } | 61 | - { path: ^/, roles: ROLE_USER } |
diff --git a/app/config/tests/parameters.yml.dist.mysql b/app/config/tests/parameters.yml.dist.mysql index 3b9262bb..1951f021 100644 --- a/app/config/tests/parameters.yml.dist.mysql +++ b/app/config/tests/parameters.yml.dist.mysql | |||
@@ -27,43 +27,11 @@ parameters: | |||
27 | # A secret key that's used to generate certain security-related tokens | 27 | # A secret key that's used to generate certain security-related tokens |
28 | secret: ThisTokenIsNotSoSecretChangeIt | 28 | secret: ThisTokenIsNotSoSecretChangeIt |
29 | 29 | ||
30 | # wallabag misc | 30 | # two factor stuff |
31 | app.version: 2.0.0-alpha | ||
32 | twofactor_auth: true | 31 | twofactor_auth: true |
33 | twofactor_sender: no-reply@wallabag.org | 32 | twofactor_sender: no-reply@wallabag.org |
34 | 33 | ||
35 | # message to display at the bottom of the page | 34 | # fosuser stuff |
36 | warning_message: > | 35 | fosuser_confirmation: true |
37 | You're trying wallabag v2, which is in alpha version. If you find a bug, please have a look to <a href="https://github.com/wallabag/wallabag/issues">our issues list</a> and <a href="https://github.com/wallabag/wallabag/issues/new">open a new if necessary</a> | ||
38 | 36 | ||
39 | download_pictures: false # if true, pictures will be stored into data/assets for each article | ||
40 | |||
41 | # Entry view | ||
42 | share_twitter: true | ||
43 | share_mail: true | ||
44 | share_shaarli: true | ||
45 | shaarli_url: http://myshaarli.com | ||
46 | share_diaspora: true | ||
47 | diaspora_url: http://diasporapod.com | ||
48 | flattr: true | ||
49 | carrot: true | ||
50 | show_printlink: true | ||
51 | export_epub: true | ||
52 | export_mobi: true | ||
53 | export_pdf: true | ||
54 | export_csv: true | ||
55 | export_json: true | ||
56 | export_txt: true | ||
57 | export_xml: true | ||
58 | wallabag_url: http://v2.wallabag.org | ||
59 | wallabag_support_url: 'https://www.wallabag.org/pages/support.html' | ||
60 | |||
61 | # default user config | ||
62 | items_on_page: 12 | ||
63 | theme: material | ||
64 | language: en_US | ||
65 | from_email: no-reply@wallabag.org | 37 | from_email: no-reply@wallabag.org |
66 | rss_limit: 50 | ||
67 | |||
68 | # pocket import | ||
69 | pocket_consumer_key: xxxxxxxx | ||
diff --git a/app/config/tests/parameters.yml.dist.pgsql b/app/config/tests/parameters.yml.dist.pgsql index a5aef028..36ad6cde 100644 --- a/app/config/tests/parameters.yml.dist.pgsql +++ b/app/config/tests/parameters.yml.dist.pgsql | |||
@@ -27,43 +27,11 @@ parameters: | |||
27 | # A secret key that's used to generate certain security-related tokens | 27 | # A secret key that's used to generate certain security-related tokens |
28 | secret: ThisTokenIsNotSoSecretChangeIt | 28 | secret: ThisTokenIsNotSoSecretChangeIt |
29 | 29 | ||
30 | # wallabag misc | 30 | # two factor stuff |
31 | app.version: 2.0.0-alpha | ||
32 | twofactor_auth: true | 31 | twofactor_auth: true |
33 | twofactor_sender: no-reply@wallabag.org | 32 | twofactor_sender: no-reply@wallabag.org |
34 | 33 | ||
35 | # message to display at the bottom of the page | 34 | # fosuser stuff |
36 | warning_message: > | 35 | fosuser_confirmation: true |
37 | You're trying wallabag v2, which is in alpha version. If you find a bug, please have a look to <a href="https://github.com/wallabag/wallabag/issues">our issues list</a> and <a href="https://github.com/wallabag/wallabag/issues/new">open a new if necessary</a> | ||
38 | 36 | ||
39 | download_pictures: false # if true, pictures will be stored into data/assets for each article | ||
40 | |||
41 | # Entry view | ||
42 | share_twitter: true | ||
43 | share_mail: true | ||
44 | share_shaarli: true | ||
45 | shaarli_url: http://myshaarli.com | ||
46 | share_diaspora: true | ||
47 | diaspora_url: http://diasporapod.com | ||
48 | flattr: true | ||
49 | carrot: true | ||
50 | show_printlink: true | ||
51 | export_epub: true | ||
52 | export_mobi: true | ||
53 | export_pdf: true | ||
54 | export_csv: true | ||
55 | export_json: true | ||
56 | export_txt: true | ||
57 | export_xml: true | ||
58 | wallabag_url: http://v2.wallabag.org | ||
59 | wallabag_support_url: 'https://www.wallabag.org/pages/support.html' | ||
60 | |||
61 | # default user config | ||
62 | items_on_page: 12 | ||
63 | theme: material | ||
64 | language: en_US | ||
65 | from_email: no-reply@wallabag.org | 37 | from_email: no-reply@wallabag.org |
66 | rss_limit: 50 | ||
67 | |||
68 | # pocket import | ||
69 | pocket_consumer_key: xxxxxxxx | ||
diff --git a/app/config/tests/parameters.yml.dist.sqlite b/app/config/tests/parameters.yml.dist.sqlite index cdafb1b1..6564014a 100644 --- a/app/config/tests/parameters.yml.dist.sqlite +++ b/app/config/tests/parameters.yml.dist.sqlite | |||
@@ -27,43 +27,11 @@ parameters: | |||
27 | # A secret key that's used to generate certain security-related tokens | 27 | # A secret key that's used to generate certain security-related tokens |
28 | secret: ThisTokenIsNotSoSecretChangeIt | 28 | secret: ThisTokenIsNotSoSecretChangeIt |
29 | 29 | ||
30 | # wallabag misc | 30 | # two factor stuff |
31 | app.version: 2.0.0-alpha | ||
32 | twofactor_auth: true | 31 | twofactor_auth: true |
33 | twofactor_sender: no-reply@wallabag.org | 32 | twofactor_sender: no-reply@wallabag.org |
34 | 33 | ||
35 | # message to display at the bottom of the page | 34 | # fosuser stuff |
36 | warning_message: > | 35 | fosuser_confirmation: true |
37 | You're trying wallabag v2, which is in alpha version. If you find a bug, please have a look to <a href="https://github.com/wallabag/wallabag/issues">our issues list</a> and <a href="https://github.com/wallabag/wallabag/issues/new">open a new if necessary</a> | ||
38 | 36 | ||
39 | download_pictures: false # if true, pictures will be stored into data/assets for each article | ||
40 | |||
41 | # Entry view | ||
42 | share_twitter: true | ||
43 | share_mail: true | ||
44 | share_shaarli: true | ||
45 | shaarli_url: http://myshaarli.com | ||
46 | share_diaspora: true | ||
47 | diaspora_url: http://diasporapod.com | ||
48 | flattr: true | ||
49 | carrot: true | ||
50 | show_printlink: true | ||
51 | export_epub: true | ||
52 | export_mobi: true | ||
53 | export_pdf: true | ||
54 | export_csv: true | ||
55 | export_json: true | ||
56 | export_txt: true | ||
57 | export_xml: true | ||
58 | wallabag_url: http://v2.wallabag.org | ||
59 | wallabag_support_url: 'https://www.wallabag.org/pages/support.html' | ||
60 | |||
61 | # default user config | ||
62 | items_on_page: 12 | ||
63 | theme: material | ||
64 | language: en_US | ||
65 | from_email: no-reply@wallabag.org | 37 | from_email: no-reply@wallabag.org |
66 | rss_limit: 50 | ||
67 | |||
68 | # pocket import | ||
69 | pocket_consumer_key: xxxxxxxx | ||