Hint: The triple product rule: $$ \left(\frac{\partial q}{\partial Q}\right)_t\left(\frac{\partial Q}{\partial t}\right)_q \left(\frac{\partial t}{\partial q}\right)_Q~=~-1.$$$$ \left(\frac{\partial q}{\partial Q}\right)_t\left(\frac{\partial Q}{\partial t}\right)_q ~=~-\left(\frac{\partial q}{\partial t}\right)_Q.$$