It’s true. One lesson from the 2013 government shutdown is that no one really remembered it when it came time to vote in the 2014 midterms. It might have even helped the Republicans by satisfying their base that they were fighting. So, whatever the short term fallout might be from the current shutdown, it might not have any impact on the upcoming elections.
It could be that some ultimate compromise helps Trump by proving he can split from his base and cut a deal with the Democrats. Or, a deal could hurt him by demoralizing his base.
I think the lesson is that it’s better to focus on getting the best outcome on substance than worrying about how it’s playing in the polls.