Hello,
There is a 10 days task, and the daily progress is automatically increased by 10%.
Or a 20 days task, the daily progress automatically increases by 5%.
How can I do it, thank you.
Hello,
There is a 10 days task, and the daily progress is automatically increased by 10%.
Or a 20 days task, the daily progress automatically increases by 5%.
How can I do it, thank you.
Hello Kevin,
Looks like, you want to show the date progress. Please, check the following snippet to see how it might be implemented:
https://snippet.dhtmlx.com/dcb5697db
Hi ramil,
Is there any particular reason to use +
before date variable like +today
, +task.start_date
and so on?
Hello Joseph,
Is there any particular reason to use + before date variable like +today, +task.start_date and so on?
If you compare date objects, you need to convert the dates to a number. Otherwise, the comparison might be wrong.
Hello Kevin,
Thank you for the clarification, you just need to move the commands from the template to the function that controls the date change and update each task. Here is the updated snippet:
http://snippet.dhtmlx.com/764bdaeef
Update:
Here is another example of the implementation where you can change the marker date, and the task progress will be updated:
Thanks for that, is there any documentation / references somewhere I can read up more about it?
Hello Ramil,
Is it possible to automatically update the progress bar with reference to the system time?
Thank you.
Hello Joseph,
Thanks for that, is there any documentation / references somewhere I can read up more about it?
Here are the links:
https://wiki.base22.com/btg/how-to-compare-dates-in-javascript-81791002.html
Hello Kevin,
Is it possible to automatically update the progress bar with reference to the system time?
You can use setInterval
and update the marker every second:
Here are the examples:
https://snippet.dhtmlx.com/d8c95826b
http://snippet.dhtmlx.com/a8a6f3315
Hello Ramil,
It’s OK.Thank you.