I've been having the same issue. Already done all the standard stuff up to and including getting a replacement s7 edge. I've narrowed it down to the charging cord. If I use my old cord from my note 3, it will keep restarting itself. Use the supplied cord or no cord at all and everything is good.