Ex-Catalan leader Carles Puigdemont can be extradited from Germany to Spain for misuse of public funds, a court has ruled.