Commit graph

9578 commits

Author SHA1 Message Date
Paul Chavard
d2811bdf73
Merge pull request #4996 from betagouv/feat/user-search-inside-dossiers
#2191 - Permettre aux usagers de rechercher dans le contenu de leurs dossiers
2020-04-09 09:52:24 +02:00
clemkeirua
590cee050f add tests for dossier_search_service 2020-04-09 09:42:31 +02:00
clemkeirua
46e14f4033 add test for users/list_dossiers_spec 2020-04-09 09:42:31 +02:00
clemkeirua
8ff3d9ea47 update existing tests 2020-04-09 09:42:31 +02:00
clemkeirua
fbcf3de74c ajout du motif recherché dans l'écran de résultats 2020-04-09 09:42:31 +02:00
clemkeirua
76139dbc71 recherche usager full-text avec plusieurs resultats 2020-04-09 09:42:31 +02:00
clemkeirua
98337f2334 recherche usager full-text avec 1 resultat 2020-04-09 09:42:31 +02:00
clemkeirua
9eafeac622 extract layouts/search_dossiers_form partial 2020-04-09 09:42:31 +02:00
clemkeirua
34188c432c refactor _new_header so that user and instructeur search share similar signature 2020-04-09 09:42:31 +02:00
Paul Chavard
695fd13e77
Merge pull request #5021 from tchak/groupe-instructeur-dossiers
[GraphQL] allow to query dossiers by groupe instructeur
2020-04-09 09:40:26 +02:00
Paul Chavard
32f783142c [GraphQL] allow to query dossiers by groupe instructeur 2020-04-09 09:29:28 +02:00
Keirua
7e806f191c
Merge pull request #5020 from tchak/fix-graphql-groupe-instructeur-type
[GraphQL] fix groupe instructeur type definition
2020-04-09 09:26:22 +02:00
Paul Chavard
e28c05bb92 [GraphQL] fix groupe instructeur type definition 2020-04-08 18:36:09 +02:00
Pierre de La Morinerie
0b16ca006a
Merge pull request #5014 from betagouv/js-bump-kind-of
Javascript : mise à jour des dépendances de Webpacker
2020-04-08 18:20:56 +02:00
Pierre de La Morinerie
fd319fb2ef javascript: bump dependancies of webpacker
Bump dependancies of webpacker, without bumping webpacker itself.

```
yarn upgrade @rails/webpacker@4.2.2
```

This fixes a moderate security vulnerability in kind-of <= 6.0.2.
2020-04-08 18:14:09 +02:00
Pierre de La Morinerie
40728f1046
Merge pull request #5017 from betagouv/revert-5012-fix-attachments-controller
Revert "Fix middle-click on "Delete attachment" button"
2020-04-08 17:52:00 +02:00
Pierre de La Morinerie
6e8bd6957f
Revert "Fix middle-click on "Delete attachment" button" 2020-04-08 17:40:58 +02:00
Pierre de La Morinerie
b290564df2
Merge pull request #5013 from betagouv/auto-upload-fix-retry
Usager : améliorations sur le bouton "Réessayer l'envoi" des pièces justificatives
2020-04-08 17:00:58 +02:00
Pierre de La Morinerie
72d003b62c javascript: fix missign argument to catch
Some browers complain about this.
2020-04-08 16:54:31 +02:00
Pierre de La Morinerie
444732b117 javascript: don't allow to retry on direct upload 422
When the authenticity token is invalid, the creation of the blob before
the direct upload returns a 422.

In that case, the token will never become valid again, and it is useless
to try again. Don’t show the "Retry" button in this case.

NB: of course the real fix is to understand why the authenticity token
is so often invalid – but this will be for later.
2020-04-08 15:48:23 +02:00
Pierre de La Morinerie
38b0bd645c javascript: fix clicking on the icon of the auto-upload Retry button
When clicking on the icon, `event target` would be the icon, not
the button.

However delegates configures `this` to be the requested event target.
2020-04-08 15:48:23 +02:00
Pierre de La Morinerie
aa2d99ef33
Merge pull request #5012 from betagouv/fix-attachments-controller
Usager : affiche une page de redirection quand le bouton "Supprimer la pièce jointe" est ouvert dans un nouvel onglet
2020-04-08 15:47:34 +02:00
Pierre de La Morinerie
b748e9773f attachments: fix opening the delete link directly
When cliking on the "Delete attachment" link, and opening the URL
in a new tab, the `DELETE /attachements/:id` will become
`GET /attachments/:id` – which will cause the `show` action to be
routed with an html format (instead of JS).

In that case, we don't want to throw an error at the user face.
Instead simply re-render the dossier page (if any).

Fix a long-standing error in Sentry.
2020-04-08 13:40:32 +02:00
Pierre de La Morinerie
0077ff4b75 attachments: refactor the controller specs 2020-04-08 12:05:55 +02:00
Pierre de La Morinerie
8ceb555941 routes: cleanup attachment routes 2020-04-08 11:57:06 +02:00
kara Diaby
473ed00b6c Revert "Revert "Revert "feat/4893 - migrate the mapReader to mapbox-gl with react"""
This reverts commit fe0b3c2215.
2020-04-07 18:14:07 +02:00
kara Diaby
fe0b3c2215 Revert "Revert "feat/4893 - migrate the mapReader to mapbox-gl with react""
This reverts commit 3e21b78142.
2020-04-07 18:11:11 +02:00
Kara Diaby
f96ee322a0
Merge pull request #5007 from betagouv/revert-4950-feat/4893
Revert "feat/4893 - migrate the mapReader to mapbox-gl with react"
2020-04-07 15:37:37 +02:00
Pierre de La Morinerie
3e21b78142
Revert "feat/4893 - migrate the mapReader to mapbox-gl with react" 2020-04-07 15:32:14 +02:00
Paul Chavard
d9015c4e3c
Merge pull request #4980 from tchak/human-readable-cron
Use human readable expressions instead of cron gibberish
2020-04-07 13:33:37 +02:00
Paul Chavard
6dc1f3e2c4 Use human readable expressions instead of cron gibberish
https://github.com/floraison/fugit#fugitnat
2020-04-07 12:44:58 +02:00
Paul Chavard
a2b50efa3b
Merge pull request #5001 from betagouv/fix-attachment-errors
javascript: ignore errors of attachments pooler
2020-04-07 12:44:42 +02:00
Pierre de La Morinerie
38c0cdc360 javascript: ignore errors of attachments pooler
Pooling for attachment status is a background operation. Errors should
not be reported to the user, who didn't even ask for this operation to
take place.

This is why we ignore all errors, whether Javascript exceptions or
network errors.
2020-04-07 12:35:54 +02:00
Pierre de La Morinerie
7d712521cf
Merge pull request #5005 from betagouv/add-button-to-avis-request
Experts : dans l'email d'invitation, le lien pour donner son avis est maintenant un grand bouton bien visible
2020-04-07 12:35:42 +02:00
Pierre de La Morinerie
dc6ff3b4ea mailers: in avis requests, replace the small CTA link by a large button
Fix #3402
2020-04-07 12:05:36 +02:00
Keirua
29a136eb10
Merge pull request #5003 from betagouv/fix_4876_copy_groupe_instructeurs_in_procedure_clone
#4876 Copy groupe instructeurs when a procedure is cloned
2020-04-07 09:37:17 +02:00
clemkeirua
ed45c88bdf do not clone groups instructeurs for admin outside the procedure 2020-04-07 09:25:40 +02:00
pedong
7806a26e2c copy groupe_instructeurs when clone 2020-04-07 09:22:33 +02:00
Pierre de La Morinerie
97dc927289
Merge pull request #5002 from betagouv/js-fix-scroll-exceptions
Usager : corrige une erreur Javascript au moment du Feedback, liée à l'utilisation de `window.scroll`
2020-04-06 18:32:11 +02:00
Pierre de La Morinerie
52afb41bab js: fix errors on browsers not supporting window.scroll options
IE and Safari only know about `window.scroll(x, y)`, and not the form
with options.
2020-04-06 18:30:15 +02:00
Pierre de La Morinerie
6dbbaf9528
Merge pull request #4994 from betagouv/add-validation-to-champ
Ajoute une validation pour vérifier la cohérence des champs (#4994)
2020-04-06 18:25:47 +02:00
Christophe Robillard
dc31f41c26 fix tests for procedure_presentation 2020-04-06 17:39:51 +02:00
Christophe Robillard
5b6044803b forbid to create champ with same type_de_champ and same row 2020-04-06 17:39:51 +02:00
Pierre de La Morinerie
0538da3fad
Merge pull request #4993 from betagouv/fix-piece-justificative-in-repetitions
Usager : correction de l'envoi automatique de pièces justificatives dans un bloc répétable
2020-04-06 12:03:49 +02:00
Pierre de La Morinerie
ded65cfdb9 dossier: fix rendering of piece_justificative in repetition
In repetitions we can't render the piece_justificative champ in the way
we do for normal champs (which was already a bit hackish).

Instead we render the whole form partial – and then extract the champ
from the form. In this way, we're sure to render the champ as it
appears in the form, without any hacks to reproduce the form structure.
2020-04-06 11:50:31 +02:00
Pierre de La Morinerie
c506402dcb dossier: remove the now unused champId in auto-upload 2020-04-06 11:50:31 +02:00
Pierre de La Morinerie
91260e2867 dossier: fix upload route of piece_justificative in repetitions
In repetitions, `form.index` doesn't make much sense. Turns out we
don't really need the index of the champ: we can just use the champ id.
2020-04-06 11:50:31 +02:00
krichtof
e869e2741e
Merge pull request #4990 from betagouv/ameliore-decouvrabilite-fichier-telecharge
instructeurs: ameliore la découvrabilité du fichier téléchargé
2020-04-06 11:05:31 +02:00
Christophe Robillard
4fcbfffec1 laisse afficher le message flash avec le fichier à télécharger 2020-04-06 10:12:00 +02:00
Christophe Robillard
290edd9e69 ameliore la découvrabilité du fichier téléchargé 2020-04-06 10:12:00 +02:00