Skip to content

[FIX] Update import for mensinator own export-files #255

Description

@EmmaTellblom

We now have constraints on the database so dates are unique in periods and ovulations. This means that there cannot be duplicate rows in these tables.

We need to redo the MensinatorImport functionality because currently it will first delete data in periods/ovulations before importing new data. This is now unnecessary and will risk that the user loose data.

Todo:

  • Make sure Mensinator import uses addDateToPeriod db-function instead of raw inserts
  • Create new db-functions for ovulation inserts/deletes. Currently we only have one, updateOvulationDate which first checks if date exists, if it doesn't it inserts, if it does, it deletes. We should have a add/remove function instead? (we have add/remove functions for periods)
  • Remove deletion of periods/ovulations

Metadata

Metadata

Assignees

Labels

ImprovementIt works but could be improved.

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions