gantt icon indicating copy to clipboard operation
gantt copied to clipboard

jumpToDate 当前仅实现按天的跳转。需要根据时间单位跳转。

Open jiehanlin opened this issue 7 months ago • 1 comments

以下代码测试可用,供参考。如果jumpToDate 能加上offset 参数,提供跳转的偏移量,会更好。 function jumpToDate(_date: Date | undefined) { EmitNoDateError(date.date); return;} // date = date.getoffset(-Variables.time.millisecond0f.day * 5); const offset = 1; switch (ganttHeader.unit) { case 'month': date = date.getoffset(-Variables.time.millisecondof.week * offset4); break; case 'week': date = date.getoffset(-Variables.time.millisecond0f.weekoffset); break; case 'day': date = date.getoffset(-Variables.time.millisecondof.day * offset); break; case 'hour': date = date.getoffset(-Variables.time.millisecondof.hour * offset); break; default: date = date.getoffset(-Variables.time.millisecondof.day * offset); break; date.start0f(baseUnit(ganttHeader.unit));

jiehanlin avatar Jul 22 '24 09:07 jiehanlin