There are many things that have helped turn my mind around from the depression I first felt after losing my favorite thing (yoga) and incurring the serious setback to my career, as a college professor, that came with all that. I can certainly understand not feeling up to graduate school, as I was there not long ago, and I can tell you it's even worse as a teacher.
Oh, the two things.
First: You have to seek out pleasure. There are sources of pleasure all around you, and you have to give yourself permission to take advantage of them. 'As sufferers,' we become attached to our condition and often stop ourselves from taking pleasure in little things, because 'we are suffering.' Most of us don't want to admit this, but it is true. I deny it daily but also make an effort to overcome it. The best way is through pleasure. If that means eating a half pint of ice cream, then do it. If that means taking in a breath of fresh air, do it. It is most important to gaining a sense of perspective, especially with chronic pain, to experience pleasure. Even if you can't afford good ice cream there are always things near at hand to take pleasure in. This is extremely important advice that for some reason doesn't get said much. For a society supposedly fixated on hedonism we certainly don't talk much about pleasure.
Second: along with taking pleasure in the moment, the more intellectual process of thinking about past and future has to be addressed. Fixate and remind yourself of progress. Of course, you have to be making progress to do this. But most of us can see long term results if we have been faithfully and honestly applying ourselves to a treatment. I had an attachment to thinking 'nothing works' and especially to telling my doctors that. In fact, when I finally committed to making progress with a treatment, I eventually completely cured myself of pf. Now I have only tarsal tunnel syndrome left, which is extremely difficult to make progress with. But it does happen, if you take into account large spans of time.
So, the second important thing is to remind yourself of progress over the long haul. If you have made no progress at all (highly unlikely if one is being faithful and honest about treatment), then you must fixate on finding a way to make progress. Not a way to be cured, but find something, anything, that works just a little. Then, realizing that time marches on all too quickly, you can see that one day will come all too soon enough, and you will be healed.