Let $R_1, \ldots, R_n$ be rings and consider the ring $R:=R_1\times \cdots\times R_n$. How can I show every $R$-module $M$ is isomorphic to a product $M_1\times \cdots\times M_n$ where each $M_i$ is a $R_i$-module?
Obs: By module I always mean left module.
Hint: Let $M_i = e_i M$, where $e_i = (0,\dotsc,1,\dotsc,0) \in R$ with $1$ in the $i$th entry. Use that $e_i$ are pairwise orthogonal idempotents with $\sum_i e_i = 1$ to show $M = \oplus_i M_i$.