belenios icon indicating copy to clipboard operation
belenios copied to clipboard

Election export and import as a draft from a json file

Open mjal opened this issue 2 years ago • 4 comments

This PR address issue #65.

It adds a new tab to export an election (or a draft) as json. The election will be transformed to the draft format.

image

The file containing the election as json can then be imported to create a new draft with all the necessary informations.

image

mjal avatar Oct 20 '23 14:10 mjal

Thank you for your efforts.

  1. "Export the election" would be better
  2. It would be better to offer a file download. Copy-pasting can be error-prone in some contexts.
  3. Conversely, an "Import an election" button that offers a file upload could work.
  4. Beware that the format is not the same for draft and validated elections.

glondu avatar Oct 24 '23 05:10 glondu

This PR is ready.

mjal avatar Nov 26 '23 23:11 mjal

A first global comment: we use ocamlformat to enforce a coherent coding style. Please install it in your OPAM switch, and run dune fmt so that the style is applied everywhere.

glondu avatar Nov 27 '23 07:11 glondu

Ok!

How i18n works ? It seems that Belenios uses Weblate to manage translations.

mjal avatar Nov 27 '23 09:11 mjal