InseeFrLab / InseeFrLab/edt

Output format for weeklyplanner

Open
#24 0 comments 0 reactions 1 assignee Claimed by @PaulBOURGEAIS View on GitHub
enhancement
Dominant language
TypeScript
Stars
2
Forks
2
PR merge metrics
No merged PRs in 30d

Description

It turns out that the output format for the "semainier" is not optimal for our post-collection processing tools
![image](https://user-images.githubusercontent.com/61505770/235658348-ebb8b703-c400-458c-a587-466de003907c.png)
is transformed in our processing tools in a
![image](https://user-images.githubusercontent.com/61505770/235658502-be3cce9b-2488-4ad3-9df3-1bd33ecdb96b.png)
This format is problematic for data recovery in our tools because WEEKLYPLANNER is more a wrapper than a real variable.

---

Here is another proposition to store the data in JSON

- A DATES vector containing the dates of the days of the surveyed week. (format YYYY-MM-DD)
- A DATES_STARTED vector which allows to know if the day has been started (certainly a useful variable for the front end ...)
- 96 variables : relative to the 96 possible slots per 24 hours (24 * 4 quarters of hours), with a boolean allowing to determine if the slot has been worked or not (Variable names should be defined on 5 positions "00h00","00H15","00H30",......."23H30",23H45")

That would give this JSON extract :

```
"DATES":{
"COLLECTED": [
"2023-05-01",
"2023-05-02",
"2023-05-03",
"2023-05-04",
"2023-05-05",
"2023-05-06",
"2023-05-07"
],
"EDITED": null,
"FORCED": null,
"INPUTED": null,
"PREVIOUS": null
},
"DATES_STARTED":{
"COLLECTED": [
"true",
"false",
"false",
"false",
"false",
"false",
"false"
],
"EDITED": null,
"FORCED": null,
"INPUTED": null,
"PREVIOUS": null
}
,
"00H00": {
"COLLECTED": [
"true", <= means that the slot 00H00-00H15 was worked on 2023-05-01
"false",<= means that the slot 00H00-00H15 was not worked on 2023-05-02
"false",
"false",
"false",
"false",
"false"
],
"EDITED": null,
"FORCED": null,
"INPUTED": null,
"PREVIOUS": null
},
"00H15": {
"COLLECTED": [
"false",
"false",
"false",
"false",
"true", <= means that the slot 00H15-00H30 was worked on 2023-05-05
"false",
"false"
],
"EDITED": null,
"FORCED": null,
"INPUTED": null,
"PREVIOUS": null
},....

```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.