Change recording of task progress by plot.
bgenere opened this issue · 0 comments
bgenere commented
Need to change what has been developed for 0.4.
We need to keep track of who has spent time in order to progress the task and the plot status.
So table plot_taskprogress should be linked to a timespent record in an unique way.
table structure should be :
```
-- object keys
rowid INTEGER AUTO_INCREMENT PRIMARY KEY,
entity INTEGER DEFAULT 1 NOT NULL, -- multi company id
-- link attributes
fk_plot INTEGER NOT NULL,
fk_tasktime INTEGER NOT NULL,
progress INTEGER,
-- record date time & user
tms timestamp,
datec datetime, -- creation date
fk_user_author INTEGER NOT NULL,
fk_user_modif INTEGER NOT NULL
then the object class should be modified to fit the new structure.
then the update when entering a new time spent should be modified.
When the user enter a time spend the following data are required :
a date : this is when the time spent is entered or the day the time was spent (in this case the user should enter each working day).
a time spent : this is the time spent by each contributors
a list of contributors : each contributor is supposed to have spend the time entered.
_So if you have time = 8h and 3 contributors total time spend will be 24hours and 3 time spent lines will be created, one per contributor._
a list of plots with their current status : For each plot which status has changed, each contributor is supposed to have contributed equally.
_So if plot 1 has moved from 0 to 100%; contributor 1 and 2 will have contributed 33% and last contributor 100-66 = 34%. And 3 plot-progress lines will be created for plot 1 each one attached to the proper contributor._
_If plot 2 has moved from 50 to 100%; 1 & 2 will have 16% and 3 will have 50 - 32 = 18%_In total the 2 plots will create 6 lines of plot progress.