yes, you can either loop across files or parallel the runs.
for bam in $(ls *.bam)
do
samtools fastq $bam > my_converted_$bam_file.fastq
done
or
parallel -j 4 'samtools fastq {} > {.}.fastq ' ::: *.bam # where 4 is the number of jobs you want to run in parallel