How to extract Business Hours between two different times values

前端 未结 3 1377
走了就别回头了
走了就别回头了 2021-02-06 19:19

For the evaluation of tickets processed by a help desk I would like to know how many business hours an ticket is active. I can easily subtract the times and get the total amount

3条回答
  •  梦毁少年i
    2021-02-06 19:54

    I ran into similar needs recently and created a package based on @mvan 's script above. https://github.com/janzzon/difftimeOffice
    Input needs to be as POSIX time.
    Output is in seconds.
    Specify helpdesk open hours by argument working_hours = c(8.5, 18).
    Additional holliday days is not implemented (yet).

提交回复
热议问题