In 1232, when the Mongol Empire attacked the Jin dynasty, Emperor Aizong abandoned the capital, Bianjing (汴京; present-day Kaifeng, Henan Province), and fled to Caizhou (蔡州; present-day Runan County, Henan Province). Wanyan Chenglin accompanied the emperor and stayed with him throughout the journey, while many ministers and officers deserted the emperor along the way. Upon arriving in Caizhou, Wanyan Chenglin advised Emperor Aizong to establish a central command and actively prepare defences for an attack by the Mongols.