Barnsley levelled a minute later when Jon Macken scored from close range and they were ahead at half-time thanks to Anderson da Silva's 25-yard screamer.
The Tykes fell behind to a Steven Fletcher strike but hit back 60 seconds later through Jon Macken and then in first-half stoppage time with a spectacular strike from Anderson De Silva.