Full and final Settlement

Hi, I was working with a firm,where my notice period was 2 months notice or 2 months basic salary if notice not served. Here I served notice period of 5 days and rest they deduct my salary. Now, when I was working with that firm I took advance of Rs. 40,000/- as advances salary due to some financial distress and my father was suffering from cancer so for their treatment. My boss gave me 40,000/- and when I asked to repay the same, he told me that no need to worry,we are waiving off 25,000/- as you worked with dedication in my firm and rest 15,000/-will consider your incremental salary retrospectively. At that time my salary was 15,000/- hence they adjust balance 15,000/-out of my loan as 3 months increased salary i.e (15,000+5000) (15,000+5000) (15,000+5000) from retrospective effect, now my salary was 20,000/- and I got appraisal letter of that 20,000/-.and out of courtesy I didn't asked for any written proof of 25,000/- which was waived off by my employer as out of good faith I believed on his words. Now at the time of resigning he is asking me to pay back that 40,000/- which was already been settled as mentioned above. I said to my boss that I did faith on your words and didn't ask for any written document and out of courtesy I didn't ask for any document just because you told me that as appreciation award we are waiving off 25,000 and adjusting 15,000 as appraisal. Now he become very rud and asking me to pay back that 40,000/-. However, they already adjusted my salary in lieu of notice period. What should I do now.