I've flown LHR-JFK-ORD-LAX-LHR in F: TATL on BA metal and domestics on AA metal all with BA flight numbers. I was credited with 300% mileage (as it was then) on all flights.
Don't know what the mileage would have been if the TATL flights had have been booked in J.