This is a "shelf system"? These typically are not great systems, so you could be at a point where it is time to look for a replacement (cheaper/easier than a repair).
There are generally just a few reasons the CD drawers would become problematic on any drawer style CD player.
1) The tray tracks are dirty or out of alignment. Cleaning the tracks with rubbing alcohol could help if the tracks are dirty. Misalignment may be a bigger headache, and if it has developed play due to wear and tear, then the tray mechanism may be at the end of life. Either of these could be the case for the drawer that only works halfway.
2) The belt that connects the drive motor to the tray broke. This is by far the most common problem! This is very likely for the tray that does not move at all. Can you hear the motor trying to move the tray? Finding the exact replacement belt is unlikely, but a search of McMaster Carr may turn up a belt that would work.
3) The drive motor is bad. Due to your descriptions, this is the least likely root cause at this point. This would likely mean time for new gear.
4) The PCB that controls the motors could have gone bad. Again, this is not very likely based on your description, but possible. If this is the case, time for new gear.