Commit graph

11400 commits

Author SHA1 Message Date
Pierre de La Morinerie
b46a148a4c
Merge pull request #5458 from betagouv/annotate 2020-08-12 12:04:13 +02:00
Pierre de La Morinerie
6d28069539 models: generate annotations 2020-08-12 11:45:53 +02:00
Pierre de La Morinerie
e6d8581b06 app: add annotate
Annotations will be generated only for models, and sorted (to avoid differences
depending on the order in which migrations are ran).

The annotations will be automatically updated every time `rails db:migrate`
is run on a development environment.
2020-08-12 11:45:53 +02:00
krichtof
667d3c0cb7
Merge pull request #5467 from betagouv/dev
2020-08-10-01
2020-08-10 18:27:07 +02:00
krichtof
10fe9020ea
Merge pull request #5465 from betagouv/corrige-mise-en-forme-commentaire
corrige mise en forme commentaire
2020-08-10 17:53:24 +02:00
Christophe Robillard
eea5fd66ad corrige mise en forme commentaire 2020-08-10 17:36:23 +02:00
krichtof
971ca18082
Merge pull request #5466 from betagouv/fix-helpscout
skip verify authenticity token for helpscout
2020-08-10 17:35:31 +02:00
Christophe Robillard
0b35619322 skip verify authenticity token for helpscout
Co-authored-by: LeSim <mail@simon.lehericey.net>
2020-08-10 17:19:22 +02:00
Kara Diaby
f0d2898993
Merge pull request #5464 from betagouv/dev
2020-08-07-01
2020-08-07 16:53:59 +02:00
Kara Diaby
406a31fda9
Merge pull request #5457 from betagouv/feat/3661
feat/3661 - Adapt configuration email view to the new UI
2020-08-07 11:50:26 +02:00
kara Diaby
9b66c894b2 Adapt configuration email view to the new UI 2020-08-06 16:56:24 +02:00
Pierre de La Morinerie
837cfd5606
Merge pull request #5455 from betagouv/dev 2020-08-06 16:14:01 +02:00
Pierre de La Morinerie
759298ddfa
Merge pull request #5454 from adullact/5453_fix_syntax_mailLayout_APPLICATION_NAME
Emails : correction du alt-text sur le logo en en-tête de l'email
2020-08-06 16:06:00 +02:00
Fabrice Gangler
cf7a4437e5 Fix syntax for using APPLICATION_NAME in mailers/layout
Refs: #5453
2020-08-06 12:45:19 +02:00
Pierre de La Morinerie
ea38d22205
Merge pull request #5449 from betagouv/rails-6.0-config 2020-08-06 10:57:59 +02:00
Pierre de La Morinerie
527a330c7a config: use Rails 6.0 config defaults
We already flipped the new defaults, so this is a no-op.
2020-08-05 17:22:46 +02:00
Pierre de La Morinerie
bc0244456c config: explicitely use the classic autoloader
I'm sure we can use zeitwerk in the future, but let's retain the classic
loader until the config issues are proved to be safe.
2020-08-05 17:22:46 +02:00
Pierre de La Morinerie
fbbcd97463 config: flip config.active_record.collection_cache_versioning
This is related to internal cache implementation, and doesn't affect us.
2020-08-05 16:48:36 +02:00
Pierre de La Morinerie
4a9f081cfc config: flip config.action_mailer.delivery_job
This is safe in all cases – except that it prevents a downgrade to
Rails 5. We don't intend to downgrade now, so this is fine.
2020-08-05 16:48:36 +02:00
Pierre de La Morinerie
b556e2a99a config: flip config.active_storage.replace_on_assign_to_many
We don't have any `has_many_attached` relations in the code base, so
this is safe.
2020-08-05 16:48:36 +02:00
Pierre de La Morinerie
54a4db1c47 config: flip config.active_storage.queues
ActiveStorage jobs are now moved to their own queue.

For consistency, we also move our own analysis jobs (VirusScannerJob)
on the same `:active_storage_analysis` queue.
2020-08-05 16:48:36 +02:00
Pierre de La Morinerie
c6cdd08373 config: flip config.active_job.return_false_on_aborted_enqueue
We don't have any instance of aborting inside a job in the code base,
so this setting is safe to flip.
2020-08-05 16:48:36 +02:00
Pierre de La Morinerie
65809f8ea0 config: flip action_dispatch_return_only_media_type_on_content_type
This makes `ActionDispatch::Controller#content_type` return not only
the MIME type, but also in some circumstances the charset.

Example:

```ruby
reponse.content_type == 'text/html; charset=utf-8'
```

The MIME type-only fragment can now be accessed using `#media_type`.

Changes to the tests are not stricly necessary (because no charset is
present in the actual value), but represent the intent better.
2020-08-05 16:48:36 +02:00
Pierre de La Morinerie
8427f0eb75 config: flip config.action_dispatch.use_cookies_with_metadata
This makes cookies more secure, by adding an automatic "purpose" field
to each cookie.

Cookies generated by Rails 5 are still forward-compatible. However
from now on the generated cookies will not be backward-compatible with
Rails 6.
2020-08-05 16:48:36 +02:00
Pierre de La Morinerie
e8fa65f79d config: flip config.action_view.default_enforce_utf8
This prevents charset workaround on IE 8 and lower. We don't support
these browsers anyway, so we can flip the feature off.
2020-08-05 16:48:36 +02:00
Pierre de La Morinerie
a1be888f7c config: use Rails 5.2 config defaults 2020-08-05 16:48:29 +02:00
Pierre de La Morinerie
634a78bad4
Merge pull request #5448 from betagouv/dev 2020-08-05 14:00:53 +02:00
Pierre de La Morinerie
31cc9de498
Merge pull request #5446 from betagouv/rails-5.1-config
Utilisation de la configuration Rails 5.1 par défaut
2020-08-05 13:51:07 +02:00
Pierre de La Morinerie
0d55919fab config: use Rails 5.1 defaults
New or changed defaults are:

- config.assets.unknown_asset_fallback: false
- config.action_view.form_with_generates_remote_forms: true
2020-08-05 13:02:56 +02:00
Pierre de La Morinerie
7708dbbc71 views: explicitely marks form_with as non-remote forms
Starting from Rails 5.1, `form_with` behavior is to generate remote
forms by default.

However with Turbolinks disabled, the form gets sent, but nothing is set
up to handle the server response (like replacing the content of the
page).

So we have two choices: either enable a global config option that makes
`form_with` generate non-remote forms, or do it explicitely on each
form. I chose the explicit way, so that developers expecting the usual
remote behavior of `form_with` are not surprised.
2020-08-05 13:02:56 +02:00
jpoulvel
2234d22b96
Merge pull request #5447 from betagouv/dev
2020-08-05-01
2020-08-05 12:41:59 +02:00
Pierre de La Morinerie
1e9da059d3
Merge pull request #5445 from betagouv/fix-attestation-rendering
Attestations : correction du rendu des PDFs
2020-08-05 12:25:30 +02:00
Pierre de La Morinerie
8962db38cc models: render attestations in a simpler way
The older method of instanciating an entire new rendering stack can be
made simpler using Rails >= 5.0 methods.

See https://api.rubyonrails.org/classes/ActionController/Renderer.html#method-i-render
2020-08-04 16:53:46 +02:00
Pierre de La Morinerie
a088b240e0
Merge pull request #5317 from betagouv/confirm-token
Usager : amélioration de l'accessibilité de la page de confirmation de l'adresse email
2020-08-04 15:57:10 +02:00
clemkeirua
21221a7c49 fix missing alt 2020-08-04 13:41:10 +00:00
clemkeirua
101acafb65 fix hidden label 2020-08-04 13:41:10 +00:00
clemkeirua
cc9341a83c fix missing header for account creation 2020-08-04 13:41:10 +00:00
Pierre de La Morinerie
bc3e0eb76c
Merge pull request #5438 from betagouv/dependabot/npm_and_yarn/elliptic-6.5.3
Mise à jour d'elliptic de la version 6.5.2 à la version 6.5.3
2020-08-04 15:40:32 +02:00
dependabot[bot]
502d2b5606
Bump elliptic from 6.5.2 to 6.5.3
Bumps [elliptic](https://github.com/indutny/elliptic) from 6.5.2 to 6.5.3.
- [Release notes](https://github.com/indutny/elliptic/releases)
- [Commits](https://github.com/indutny/elliptic/compare/v6.5.2...v6.5.3)

Signed-off-by: dependabot[bot] <support@github.com>
2020-08-04 13:30:26 +00:00
Kara Diaby
4da6213f96
Merge pull request #5444 from betagouv/fix-new-design-attestation
Fixe l'affichage  concernant l'affichage des attestations sur l'interface administrateur (détail d'une démarche)
2020-08-04 11:15:03 +02:00
kara Diaby
c983622805 fix attestation template boolean on procedure detail page (new admin interface) 2020-08-04 10:56:48 +02:00
jpoulvel
4b9e446971
Merge pull request #5442 from betagouv/dev
2020-08-03-01
2020-08-03 11:39:48 +02:00
Kara Diaby
4afc07c677
Merge pull request #5403 from tchak/add-carte-ign
Add carte ign
2020-08-03 11:04:32 +02:00
jpoulvel
bf94cc021b
Merge pull request #5424 from betagouv/new_design_edit_attestation
New design page admin/attestation_templates/edit
2020-07-31 11:18:22 +02:00
Paul Chavard
4c87e547b3 Put IGN map behind a feature flag 2020-07-30 17:22:28 +02:00
Paul Chavard
f1cbc9846e Add carte ign 2020-07-30 16:58:20 +02:00
Kara Diaby
e41bc76e6a
Merge pull request #5437 from betagouv/dev
2020-07-30-01
2020-07-30 14:31:51 +02:00
Kara Diaby
c83a085d6a
Merge pull request #5436 from betagouv/fix/5402
fix/5402 - clone button to closed procedures
2020-07-30 14:00:36 +02:00
kara Diaby
db3e40ebf8 Fixe la non possibilité de cloner une démarche pour une procédure archivée (nouvelle interface administrateur) 2020-07-30 12:00:43 +02:00
Keirua
efca6745d6
Merge pull request #5435 from betagouv/fix-5288-commentaires
last_commentaire_updated_at does not take system email into account
2020-07-30 11:59:47 +02:00