The work done on a body is equal to the some of works done by all the forces acting on the body.
Suppose forces $F_1$ and $F_2$ are acting on a body. The component of displacement of the body in $F_1$'s direction is $d_1$, and in $F_2$'s direction is $d_2$. So, the work done is $$W = F_1 d_1 + F_2 d_2$$
But the same work can be calculated by the dot product of resultant force with resultant displacement. So, $$W = (F_1 + F_2) \cdot (d_1 + d_2) = F_1 d_1 + F_2 d_2 + F_1 \cdot d_2 + F_2 \cdot d_1$$ These are two different expressions of the same work and are equal only if $F_1 \cdot d_2 + F_2 \cdot d_1 = 0$ which is true only when $F_1$ and $F_2$ are perpendicular.
It is clearly stated in my book that the work done on a body is equal to the sum of the works done by the individual forces acting on the body. And this is true even when the forces act simultaneously. I've used this fact in solving problems in which gravity and friction simultaneously act on the body. In those problems, I don't calculate the dot product of the resultant of gravity and friction with the resultant displacement. Instead, I just add the works done by friction and gravity to calculate the change in kinetic energy. Why the discrepancy?