A question on a problem on localization from Atiyah (3.8) I was having trouble with the following problem from Chapter $3$ of Atiyah-MacDonald
Let $S, T$ be multiplicatively closed sets in the ring $A$, such that $S\subseteq T$.
Let $\varphi : S^{−1}A \to T^{−1}A$ be the homomorphism which maps each $r/s \in S^{−1}A$ to $r/s$  viewed as an element of $T^{−1}A$. Show that the following are equivalent:

(i) $\varphi$ is a bijection;
(ii) $t/1$ is a unit in $S^{−1}A$ for all $t\in T$;

My Attempts
I am assuming $\varphi$ is bijective
I first tried to show this directly by noting that since $\varphi$ is bijective we have that $\varphi(a/s)=t/1$   .
This means we have that $a/s=t/1$ and therefore there is a $w \in T$ where $w(a-st)=0$. I am stuck at this point.
Another approach, I saw recommended was to consider to universal property associated to localization. I am confused on how to apply it, do I consider this with respect to $A \rightarrow T^{-1}A$ where $S$ is the closed mult. set being considered in which case there should be a map from $S^{-1}A$ to $T^{-1}A$. I'm not sure how that relates to $\varphi$ being bijective.
Any help would be appreciated.

For the forward direction: Let $\phi$ be a bijection and let $t\in T$.  Since $t\in T$, $1/t\in T^{-1}A$.  Since $\phi$ is a bijection, there is some $a/s\in S^{-1}A$ such that $\phi(a/s)=1/t$.  Consider $\phi(at/s)=(a/s)t=(1/t)t=1$.  Since $\phi$ is a bijection and $\phi(at/s)=1$, it follows that $at/s=1$.
On the other hand, suppose that for all $t\in T$, $t/1$ is a unit in $S^{-1}R$.  Let $a/b,c/d\in S^{-1}T$ such that $\phi(a/b)=\phi(c/d)$.  Then there is some $t\in T$ such that $t(ad-bc)=0$.  Now, the statement $t(ad-bc)=0$ is true in $A$ as well as in $S^{-1}A$.  Since $t\in T$, there is some $e/f\in S^{-1}A$ such that $(e/f)t=1$ in $S^{-1}A$.  Therefore, $(e/f)t(ad-bc)=ad-bc=0$ in $S^{-1}A$.  Now, since $(ad-bc)/1=0/1$ in $S^{-1}A$, there is some $s\in S$ such that $s(ad-bc)=0$.  Hence $a/b=c/d$.  Therefore, $\phi$ is injective.
Finally, to show that $\phi$ is surjective.  Let $a/t\in T^{-1}A$.  Since $t\in T$, $t$ is a unit in $S^{-1}A$, so there is some $b/c$ such that $(b/c)t=1$ in $S^{-1}A$.  In other words, there is some $s\in S$ such that $s(bt-c)=0$.  Since $S\subseteq T$, $s\in T$.  Now, consider $\phi(ab/c)=ab/c$.  I claim that $ab/c=a/t$ in $T^{-1}A$.  This follows from $sa(bt-c)=0$.
