Sorry to hear this Bob.
Make sure that you have a good written reference letter signed by the employer on company letterhead.
Also be sure the reference letter is to your liking.
As for training your replacement, you will have to tread the waters carefully and use good discretion. If you are going to look for gainful employment elsewhere, a well written reference letter is invaluable.
Best of luck.