Let $X$ be a semisimple module, i.e., $X=\bigoplus_{i\in I}X_i$ where $(X_i)_{i\in I}$ is a family of simple submodules of $X$, and let $W$ be a submodule of $X$.
Then there is a subset $J$ of $I$ that is maximal with respect to the property $W\cap\sum_{i\in J}X_i = \{0\}$, and it follows that $X$ and $W$ satisfy \begin{equation*} X = W\oplus\bigoplus_{i\in J}X_i. \end{equation*} (See e.g. page 438 in Hungerford's book "Algebra".)
But is it also true that \begin{equation*} W = \bigoplus_{i\in K}X_i \end{equation*} for some subset $K$ of $I$ (e.g. $K=I\setminus J$)?
I believe the answer is "no", and that the following provides a counterexample.
For simplicity, let $X$ be a free module over the ring $\mathbb{R}$, let $\{x_1,x_2\}$ be a basis of $X$, and let $X_1=\mathbb{R}x_1$ and $X_2=\mathbb{R}x_2$. Then $X$ is semisimple and satisfies \begin{equation*} X = \bigoplus_{i=1,2}X_i. \end{equation*} Let $W=\mathbb{R}(x_1+x_2)$. Then $W$ is a submodule of $X$, but for no subset $K$ of $\{1,2\}$ does it satisfy \begin{equation*} W = \bigoplus_{i\in K}X_i. \end{equation*}