Custom Duration in Lightbox

Hi, I was wondering if it would be possible to input something in duration like 2w and it would output the task to have 14 days? Is there any way I can modify the code associated with this?

where do you want to put this value? Are you talking about dhtmlxGantt and this control ?
If so - then yes, it’s possible to implement. In order to do so, you’ll have to redefine the built-in duration control … t.js#L7537 … t.js#L7548

So basically all I need to do is whenever I add “w” at the end of the input (i.e. 4w = 28 days) in the lightbox the duration will be multiplied by 7. Otherwise it should just be how it is, by days.

I’ll try it out thanks. So I might need to add an if statement in the original code right? Would there be an easier way to implement this without editing dhtmlxgantt.js?