Commit graph

1692 commits

Author SHA1 Message Date
Paul Chavard
5b9e534b3f chore(turbo): morph all the things 2023-01-25 13:45:26 +01:00
Sébastien Carceles
49ce255e29
feat(dossier): prefill region champ (#8442)
* make regions champ prefillable

* add possible and example value

* add external_id and value validation
2023-01-24 11:25:17 +00:00
mfo
84a667b8bd
Merge pull request #8454 from tchak/feat-epci
feat(types de champ): add EPCI champ
2023-01-23 16:56:18 +01:00
mfo
1926aa283d
Merge pull request #8425 from adullact/fix/procedure-custom-retention
Fix du support d'une durée personnalisée de conservation des dossiers
2023-01-23 12:11:29 +01:00
Damien Le Thiec
962016e32e
Schema graph_ql (#8406)
* First draft schema graph_ql

* Add tests for json schema procedures
2023-01-23 11:31:06 +01:00
Sébastien Carceles
68ddae7382
feat(demarche): prefilling stats (#8436)
* force json content type for POST / PATCH / PUT

* add specs about stats dossiers funnel

* new endpoint to render stats about a procedure
2023-01-20 13:28:02 +00:00
Paul Chavard
a4cbbe721e feat(types de champ): add EPCI champ 2023-01-20 11:32:36 +01:00
Paul Chavard
8f1ae99413 fix(graphql): remove deprecated options from introspection query 2023-01-20 09:54:50 +01:00
Martin
52380d5249 fix(api): on fixe avec avec des tests le prob de token 2023-01-19 17:40:19 +01:00
Martin
7206f1b298 bug(api): token, not checked 2023-01-19 17:33:19 +01:00
simon lehericey
84d08d4d24 fix(expert_export): an expert export excludes annotation and avis 2023-01-19 12:09:16 +01:00
Martin
f59354f787 tech(champs/repetitions#remove): ajout d'un test pour s'assurer que l'action de suppression d'un bloc repetable fonctionne 2023-01-19 10:38:30 +01:00
Martin
3dc26efc61 infra(monitoring): ajoute le webhook pour les notifier des incidents cote sib 2023-01-19 09:50:25 +01:00
Kara Diaby
063059d6f0 tests 2023-01-18 18:46:42 +01:00
Paul Chavard
b5dc71e975 fix(graphql): demarche with pj should return schema 2023-01-18 18:06:10 +01:00
Paul Chavard
cdb3ce65cb feat(graphql): expose more information on demarche descriptor 2023-01-18 13:46:40 +01:00
Sébastien Carceles
5c7b2ba1f3
feat(dossier): prefill drop down list champ (#8361)
* feat(dossier): prefill drop down list champ

* decorate the types de champ to avoid if / else

In order to avoid doing if this a drop down ? / else at several places,
we decorate the types de champ and let the decorator give the possible
and example values.

* show all possible values when there are too many

* allow to prefill 'other' option

* review: remove duplicate

* review: refactor for readability

* validate that value is in options

* review: exclude disabled options
2023-01-18 09:47:22 +01:00
simon lehericey
8e75b6ff77 fix(send_dossier): avoid leaking instructeur emails 2023-01-17 16:57:56 +01:00
Damien Le Thiec
5e26acb0e1
Make date and datetime prefillable (#8304)
* Make date and datetime prefillable

* Format in ISO8601 format
2023-01-12 17:42:02 +01:00
François Vantomme
e794d4f77b
fix(procedure): deal nicely with custom NEW_MAX_DUREE_CONSERVATION 2023-01-12 14:37:54 +01:00
Paul Chavard
b663939674 feat(graphql): add demarcheCloner mutation 2023-01-11 23:38:12 +01:00
Paul Chavard
afc1f12028 feat(graphql): implement add/remove instructeurs via API 2023-01-10 20:33:35 +01:00
Sébastien Carceles
177dec2bdb
feat(dossier): add dossier id to prefill response (#8382) 2023-01-06 13:46:27 +00:00
Martin
3918757dc9 correctif(test): desormais l'association batch_operations.groupe_instructeurs passe par le dossier. Mise a jour des tests 2023-01-05 16:20:18 +01:00
Sébastien Carceles
1de969915a
rename file to match controller name (#8371) 2023-01-05 14:38:56 +01:00
Sébastien Carceles
456be420fa
feat(demarche): describe dossier prefilling with POST (#8298)
* feat(demarche): describe dossier prefilling with POST

* show response example
2023-01-04 07:31:31 +00:00
Martin
a4d6692bc6 accessibilite(pages-authentification): evolutions des pages de connexion/creation de compte pour respecter le DSFR et supporter une meilleure accessibilite
Update app/components/dsfr/input_component/input_component.html.haml

Co-authored-by: Colin Darie <colin@darie.eu>
2023-01-03 16:26:05 +01:00
Sébastien Carceles
20136b7ac8
feat(demarche): create and prefill a dossier with POST request (#8233)
* add base controller for public api

* add dossiers controller with basic checks

* create the dossier

* ensure content-type is json

* prefill dossier with given values

* mark a dossier as prefilled

When a dossier is prefilled, it's allowed not to have a user.

Plus, we add a secure token to the dossier, which we will need later to set a
user after sign in / sign up.

* set user as owner of an orphan prefilled dossier

When a visitor comes from the dossier_url answered by the public api,
the dossier is orphan:
- when the user is already authenticated: they become the owner
- when the user is not authenticated: they can sign in / sign up / france_connect
and then they become the owner

So here is the procedure:
- allow to sign in / sign up / france connect when user is unauthenticated
- set dossier ownership when the dossier is orphan
- check dossier ownership when the dossier is not
- redirect to brouillon path when user is signed in and owner

* mark the dossier as prefilled when it's prefilled
(even with a GET request, because it will be useful later on, for
exmample in order to cleanup the unused prefilled dossiers)

* system spec: prefilling dossier with post request
2023-01-03 14:46:10 +01:00
Martin
186d4e6539 correctif(ChampDepartement): gere les departement a 3 codes 2022-12-27 14:55:57 +01:00
Martin
48c80e9387 correctif(api/v1): ajoute la methode manquante for_api sur le type de champs departement 2022-12-27 11:45:43 +01:00
Paul Chavard
4a4ce67ef6 fix(dossier): explicitly send draft notification email 2022-12-26 22:02:33 +00:00
Paul Chavard
00218fded2 fix(dossier): update spec 2022-12-21 14:03:02 +01:00
Sébastien Carceles
dd0a05c1d8
feat(prefill): add possible values (#8299)
* update layout in order to show possible values

* filter out non fillable types de champ
2022-12-20 11:04:42 +01:00
Sébastien Carceles
0a10a08c21
feat(demarche): describe procedure prefilling (#8187)
* feat(demarche): description

Show the description of an opendata procedure (published or draft),
with help about how to prefill a dossier for this procedure.

Co-authored-by: Damien Le Thiec <damien.lethiec@gmail.com>
2022-12-19 11:32:09 +00:00
Martin
2be4441a70 amelioration(attestion.et.mail): deduplique les message d'erreur, améliore les messages d'erreur, gère la pluralisation des erreurs lorsque plusieurs tags sont concernés 2022-12-19 09:28:46 +01:00
Martin
dd74834689 amelioration(attestation.et.mail): desactive les tags sur les champs conditionnés et informe l'usager que ca arrivera 2022-12-19 09:28:46 +01:00
Martin
ef389eab41 amelioration(attestation.et.mail): repositionne les messages d'erreur lié à la substitution des balises a proximité du formulaire pour faciliter la comprehension. passage des champs au DSFR 2022-12-19 09:28:46 +01:00
Christophe Robillard
f1595d1f50 wrap resultset tuples in ProcedureDetail 2022-12-16 15:51:49 +01:00
Christophe Robillard
3a660349ad export all demarches 2022-12-16 15:51:49 +01:00
Christophe Robillard
cea92c0488 perf: remove n+1 queries to count admin 2022-12-16 15:51:49 +01:00
Eric Leroy-Terquem
2645ac85f7 update wording and order in types de champ select 2022-12-16 09:30:36 +01:00
Paul Chavard
cb5b60ccda Revert "Revert "Merge pull request #7907 from tchak/feat-cond-repetitions""
This reverts commit 0d10d36cb0.

# Conflicts:
#	app/models/dossier.rb
#	app/models/dossier_preloader.rb
2022-12-15 19:09:25 +01:00
Sébastien Carceles
b8ff0ba4a2
feat(demarche): sign up when prefilling a dossier (#8247)
* store prefill params in session

Instead of using query params on /dossier/new, we assume the user comes
from /commencer/:path, which is the new prefill link.

There, we store the prefill params in session, and use them to prefill
the dossier when creating it, in /dossiers/new.

* spec: cover the case

* review: serialize with json instead of yaml

* review: rename method

* review: store only query params

* review: comment why we dont override already stored params
2022-12-15 10:58:17 +01:00
Lisa Durand
89730b485b add bulk action feature for 'passer_en_instruction' 2022-12-15 10:04:25 +01:00
Colin Darie
3a9a71079a
Merge branch 'main' into pj-en-construction-replace 2022-12-14 16:59:48 +01:00
Paul Chavard
1b95809f14 refactor(dossier): flatten champ attributes 2022-12-14 13:03:06 +01:00
Paul Chavard
0d10d36cb0 Revert "Merge pull request #7907 from tchak/feat-cond-repetitions"
This reverts commit 1900f8ff4c, reversing
changes made to febffc2d64.

# Conflicts:
#	app/models/dossier.rb
2022-12-14 11:25:45 +01:00
Colin Darie
4049240c2c
feat(piece_justificative): allow user to replace a PJ for dossier en_construction 2022-12-14 09:58:15 +01:00
sebastiencarceles
cdd790e3d3 review: document prefilling with json or array injection 2022-12-08 15:27:39 +01:00
sebastiencarceles
bf03e3b35a review: prefix typed ids with 'champ_' 2022-12-08 15:27:39 +01:00