Both destinations are served by Dharamsala (DHM). Since there's no flight route between them, the best way to travel is by road.
Pathankot
Fly to Dharamsala (DHM), then travel by road to Pathankot. Taxis, buses, and private cabs are available from the airport.
Dharamshala
Fly to Gaggal (DHM), then travel by road to Dharamshala. Local transport options include taxis, auto-rickshaws, and state buses.