使用promise修饰,在方法1 和方法2 都请求成功时再进行操作。 Promise.all([methods1, methods2]).then(res => { //在方法1 和方法2 都请求成功时再进行操作。 })