added method assignTask to TaskDAO without Lost Updates problem