Hadith.1341 - Abd al-Rahman ibn Abi Abdullah reported from Imam Jafar ibn Muhammad Al-Sadiq (as) regarding the prayer during advancing troops (battle or combat).
Imam (as) said
"You say the takbir (proclaiming 'Allahu Akbar') and tahleel (proclaiming 'La ilaha illAllah (swt)').
Allah (swt), the Mighty and Majestic, says: 'But if you fear [an enemy], then [pray] on foot or while riding' (Surah Al-Baqarah 2:239)”.