In my lecture notes, there are two frames S and S'. The prime frame moves with uniform velocity with respect to the unprimed frame. In this frame, she derives the time dilation equation in the following way:
She assigns $t$ as time in S and distance as $x$. Now from inverse transformations:
$$t_1= \gamma (t_1' + \frac{vx_1'}{c^2})$$
$$t_2 = \gamma (t_2' + \frac{vx_1'}{c^2})$$
Now, if the both the positions are the same, how is S' moving?