Yes. For purposes of OSHA recordkeeping injuries and illnesses occurring in the work environment are considered work-related. Punching in and out with a time clock (or signing in and out) does not affect the outcome for determining work-relatedness. If the employee experienced a work-related injury or illness, and it meets one or more of the general recording criteria under section 1904.7, it must be entered on the employer's OSHA 300 log.
For more information, explore OSHA's Recordkeeping Requirements.