AI-generated code still requires software engineers to build, test, debug, deploy, secure, monitor, be on-call, support, handle incidents, and so on. That's very expensive. It is much cheaper to pay a small monthly fee to a SaaS company.
The alternatives before were propose the case to IT, and if lucky it gets put on the planning, outsourced to consultants, and delivered 18 months from now for an astronomical investment in both time and cost. Or go at it yourself with Excell and VBA.
The AI thing will be a just 'good enough' barely working clutch of ugly code. Then again, so was most of the consultant produced code.