Agreement in place over the "need" for A&E at Ayr Hospital a