Franklin ends New Zealand career with Middlesex move