Commit graph

6209 commits

Author SHA1 Message Date
kara Diaby
a710116371 add expert profile to api 2021-03-18 11:27:51 +01:00
kara Diaby
d47fde3fcb add polymorphic relation to claimant on avis table 2021-03-18 11:27:51 +01:00
kara Diaby
d2ab2debb6 add expert logic 2021-03-18 11:27:51 +01:00
Paul Chavard
d59867c73b Exposer plus d’informations dans l’interface pour certains champs 2021-03-17 16:28:05 +01:00
Paul Chavard
e96d2fb083 Return empty strings for incomplete api entreprise adresses 2021-03-17 12:12:21 +01:00
Paul Chavard
a6fe1df201 update graphql schema 2021-03-17 11:53:48 +01:00
Paul Chavard
4efc5ff273 Update app/graphql/schema.graphql
Co-authored-by: Pierre de La Morinerie <kemenaran@gmail.com>
2021-03-17 11:53:48 +01:00
Paul Chavard
046b36d386 Update app/graphql/schema.graphql
Co-authored-by: Pierre de La Morinerie <kemenaran@gmail.com>
2021-03-17 11:53:48 +01:00
Paul Chavard
866ae256a3 Add revision dossiers filters 2021-03-17 11:53:48 +01:00
Christophe Robillard
f47e2e62cd add button role to supprimer link 2021-03-17 11:31:51 +01:00
Christophe Robillard
6026793c1d focus to target after toggle 2021-03-17 11:31:51 +01:00
Christophe Robillard
df3bd3a1d2 handle focus during and after upload 2021-03-17 11:31:51 +01:00
Christophe Robillard
43039d1755 add aria-value min, max and now for progressbar upload 2021-03-17 11:31:51 +01:00
Christophe Robillard
dfed8f32ae update link to download dossier and all pjs 2021-03-16 15:13:17 +01:00
Christophe Robillard
858bbde2d6 remove dead code 2021-03-16 15:13:17 +01:00
Christophe Robillard
60cc4d3697 add pdf to pjs export 2021-03-16 15:13:17 +01:00
Paul Chavard
76aa7bdfe3 Add default nil value for numero_tva_intracommunautaire 2021-03-16 12:57:10 +01:00
Pierre de La Morinerie
75a1046315 active_storage: refactor concerns
Follow-up of #5953.

Refactor the concerns with two goals:

- Getting closer from the way ActiveStorage adds its own hooks.
  Usually ActiveStorage does this using an `Attachment#after_create`
  hook, which then delegates to the blob to enqueue the job.
- Enqueuing each job only once. By hooking on `Attachment#after_create`,
  we guarantee each job will be added only once.

We then let the jobs themselves check if they are relevant or not, and
retry or discard themselves if necessary.

We also need to update the tests a bit, because Rails'
`perform_enqueued_jobs(&block)` test helper doesn't honor the `retry_on`
clause of jobs. Instead it forwards the exception to the caller – which
makes the test fail.

Instead we use the inline version of `perform_enqueued_jobs()`, without
a block, which properly ignores errors catched by retry_on.
2021-03-16 11:49:14 +01:00
Pierre de La Morinerie
08094e5384 jobs: retry on ActiveStorage::IntegrityError during virus scan
This is the same setting than what ActiveStorage::AnalyzeJob uses.
2021-03-16 10:52:12 +01:00
Paul Chavard
6f543d3770 Handle invalid GeoJSON in the editor 2021-03-11 15:51:09 +01:00
Paul Chavard
a7fb7bf1ef Add geo json validation 2021-03-11 15:51:09 +01:00
Paul Chavard
d24ee27cac Try to reduce the number of external data fetches
Only fetch external data if the external_id is the current one and data is not yet fetched
2021-03-11 14:56:37 +01:00
Paul Chavard
21d5da379f remove unused job 2021-03-11 14:56:37 +01:00
Paul Chavard
bee66d41c4 capital_social and numero_tva_intracommunautaire can be null 2021-03-11 11:13:50 +01:00
kara Diaby
6383e6b9e7 Revert "Revert "Claimant type to avis table""
This reverts commit f4fd220d43.
2021-03-10 08:48:55 +01:00
Paul Chavard
70500e3d56 Groupe instructeur selector default blank 2021-03-09 14:47:23 +01:00
Paul Chavard
9c3e72c84a Use revision instead of groupe instructeur as dossier procedure link 2021-03-09 14:47:23 +01:00
Kara Diaby
f4fd220d43
Revert "Claimant type to avis table" 2021-03-09 13:40:10 +01:00
kara Diaby
0211d1f105 modify create_avis_concern 2021-03-07 22:47:53 +01:00
kara Diaby
af4a27f4e0 add claimant type on avis table 2021-03-07 22:47:24 +01:00
Paul Chavard
82fca8be0b Make more association fields nullable 2021-03-05 10:13:22 +01:00
Christophe Robillard
6169399a6b fix limit date for notice validation 2021-03-05 08:34:39 +01:00
Pierre de La Morinerie
b0735aafe0 config: fix DynamicSmtpSettingsInterceptor warning again
This warning re-appeared when running mailer tests:

```
DISABLE_SPRING=1 bin/rspec spec/mailers/administration_mailer_spec.rb
```

It is now fixed properly, in a way recommanded by the documentation.
2021-03-04 22:52:19 +01:00
Paul Chavard
47e232f439 Some associations have no date_creation 2021-03-04 16:28:20 +01:00
Christophe Robillard
7f496c43e5 no validation for old procedures 2021-03-04 16:13:19 +01:00
Pierre de La Morinerie
2f948f7e46 active_storage: fix blob update hooks
For some reason on Rails 6.1 the `after_update_commit` hook is properly
registered – but disappears from the record later, and in the end is
never run.

Fix it by using the general `after_commit` hook instead.
2021-03-04 14:30:38 +01:00
Paul Chavard
f31096b33e When procedure is reset delete only draft revision dossiers 2021-03-04 13:10:58 +01:00
Paul Chavard
79606e8696 Some addresses have no street_address 2021-03-04 12:52:01 +01:00
Paul Chavard
600f49a0ff Hide groupe instructeur selector when routage is done via API 2021-03-04 11:06:04 +01:00
Paul Chavard
1c811083c0 Cleanup feature flags usage 2021-03-04 11:06:04 +01:00
Pierre de La Morinerie
9537342c06 procedure: fix query for finding champs without stable_id
It would break on ActiveRecord 6.1.
2021-03-04 09:54:22 +00:00
Paul Chavard
5d4f025be0 Rename for consistency with defaut_groupe_instructeur 2021-03-04 10:45:02 +01:00
Paul Chavard
89ec3923f2 Defaut groupe instructeur ordered by label 2021-03-04 10:35:44 +01:00
Paul Chavard
9f8c55969d Add proper external data API errors handling 2021-03-04 10:16:06 +01:00
Paul Chavard
e7ba380d95 Fix JSON.parse crashing on empty values 2021-03-03 17:31:05 +01:00
Paul Chavard
96a832bc19 Add SerializerService 2021-03-02 12:42:22 +01:00
Paul Chavard
bb072ba9e9 Add id argument to most collections on dossier 2021-03-02 12:42:22 +01:00
Paul Chavard
0bd8721776 Add a way to authoraize any query through context 2021-03-02 12:35:47 +01:00
Paul Chavard
ac5a860e1b remove unused print.css reference 2021-02-25 17:20:11 +01:00
Paul Chavard
ff8ccbd088 Try to parse SIB email date when it is a string 2021-02-25 15:20:14 +01:00