I agree it's not an ideal place for your dd to be while someone is having end of life care and some days are probably going to be worse than others without warning.
Giving him a very generous benefit of the doubt if he's been reasonably consistent up to now, is it possible that his mum isn't coping with the level of care she's found herself providing and is relying on him being there? Some of it can be quite physically demanding so if she's not up to it he might need to step in for certain tasks.
HOWEVER. He is still a parent and he still has responsibilities so he needs to provide other arrangements as end of life care can often take much longer than anticipated. That could be taking your dd out for the day, minding her at yours on those days as you've already suggested, or he contributes to a childminder. I know you can't easily force him to do any of those things, but my point is just that your frustration is valid and its not OK for him to prioritise this to the point where your job is at risk as a result.
Do you work for an employer or are you self employed? Is there anything they could offer you such as temporarily part time hours like half days or similar or do they offer paid carers leave? Are you able to do any hairdressing in your home where your dd could be about without being about?
It also might be worth linking in with a local food bank if you're worried about money in the meantime. Many people who are working and earning use them so while it may feel strange to you, it certainly won't look strange to anyone else. It's just a reflection on the times we're living in.
I'd also contact a local advice service such as citizens advice. I'm a lone parent and even though my ex does currently provide maintenance I'm still entitled to some UC for a percentage of childcare costs although I'm not sure whether this is applicable where you live, so it would be good to know you're getting all the financial support you're entitled to.
I think at the minute you need to rule him out and make alternative arrangements. I'd also be inclined to report him for the cash in hand work. Djs can earn a fair bit in a night depending on the type of work he's doing, so no reason why he couldn't be contributing to his children. He's choosing not to. None of this is fair for your dd and I understand not wanting her to miss out on her dad, but ultimately he's letting her down and disappointing her and a child that age finds that hard to understand. So I'd actually put that to him in writing, that it's putting your job at risk and its distressing for your dd when he cancel at short notice. I'd remind him that you've offered him to mind her at your house or at weekends and he's declined all reasonable offers so your only alternative is to seek other childcare and she will no longer be available for contact during the week. I say put it in writing so you can use it if he tries to take you to court for parental alienation, I'd keep screenshot and a record of all the times you've offered him alternative ways to facilitate contact.
He's an arse.