Bank job

Sir,I have joined the bank on 22 Apr 2013 as agriculture officer.I was posted in Lucknow and m native of ballia district. In July I get pregnant and I had some internal problems. So from Nov I was on maternity leave.after delivery I want my transfer for only 2 years at least to my hometown so that my in-laws can look after my baby so that I would continued my job. But bank didn't consider it and I was in leave on without salary basis. On 2015 January bank transferred me to mubarakpur branch which is 60 km away from my husband work place unchahar.there I work for 1 month.but as it was far from my home and it was difficult for me to go so far as my baby was very small.again and again I request bank to please transfer me to my hometown at least for some time but they didn't. And on July they terminated me from the job. Sir what I want to know from u is that..,.is this is fare to me???? Do I can claim in court related to my job?? After filling case against bank,should I get my job back. My bank was Canara bank