I was told I couldn’t just come in and out as I pleased

I worked for my employer for nearly 20 years in a leadership role. I was pregnant with my first child and the attitude towards me completely changed. Before I went on maternity leave I put in a request to change my hours on my return. I worked shifts including unsociable hours 9pm finishes etc. I have to use nursery childcare and of course would not have been able to get childcare at that hour, nor did I want my child out until after 9 at night. I requested to do a 30hour week of set day shifts mon to fri plus weekend shifts as per rotation with other staff. I was told no way that I couldn’t just do what I wanted and come in and out as I pleased.I was devastated, worried but…. I was pregnant, in poor health from pregnancy complications, vulnerable, exhausted and did not have the energy to fight them. Acas advise me to appeal and said I would have a case against them. However whilst on maternity leave I decided to cut my losses and found a new job. Awful way to finish almost two decades of loyal employment.  I now work somewhere who embrace working mothers ,part time hours ,flexible work etc. I love it and just regret not leaving my other job years ago. It’s left me very bitter though and this was a few years ago!