Flaring Activity in Accretion Flows of Young Stellar Objects