Recall that $p\to q$ is logically equivalent to $\lnot p\lor q$. Thus, $\big(\forall x P(x)\big)\to q$ is logically equivalent to $\lnot\big(\forall x P(x)\big)\lor q$, which you already know is logically equivalent to $\exists x\big(\lnot P(x)\big)\lor q$. Similarly, $\exists x\big(P(x)\to q\big)$ is logically equivalent to $\exists x\big(\lnot P(x)\lor q\big)$. Thus, the claim is that
$\exists x\big(\lnot P(x)\big)\lor q\;\equiv\; \exists x\big(\lnot P(x)\lor q\big)\;.\tag{1}$
This is intuitively reasonable, because $q$ says nothing about $x$: intuitively, $q$ and $\exists x (q)$ say the same thing.
A little less informally, if there’s an $x$ that does not have property $P$, then both expressions are true regardless of $q$, and if there is no such $x$, then each is true if and only if $q$ is true. Thus, in all cases they are either both true or both false.
Alternatively, if $q$ is true, $\lnot P(x)\lor q$ is true no matter what $x$ might be, so both sides of $(1)$ are true. If $q$ is false, then $\exists x\big(\lnot P(x)\big)\lor q$ is true if and only if $\exists x\big(\lnot P(x)\big)$ is true, i.e., if and only if some $x$ does not have property $P$. But $\exists x\big(\lnot P(x)\lor q\big)$ is also true if and only if $\exists x\big(\lnot P(x)\big)$ is true, so in all cases the two sides of $(1)$ are both true or both false.