This war was so typical of Chinese military intervention abroad, in a strategic sense at least.
The PLA would go in fact and hard, crush all resistance and pull back to where they started once a pre-determined point has been reached or goal achieved. This way they take full advantage of the initial momentum of the attack to appear far stronger then they might actually be by avoiding showing fallibility as would happen if they pressed too far for too long, loose the momentum and get bogged down.
This demonstrates the PLA's superiority most spectacularly and beyond all doubt while China suffers the least political fall out because of its voluntary pull back and also minimize losses to its armed forces.
What more, by stopping when the PLA had a massive advantage, it is crystal clear that the PLA stopped because they chose to stop and not because of enemy resistance, that will deliver a heavy blow to enemy moral and make them less inclined to seek a re-match.
This was the case here, and with India in 62 (who is still smarting even today and will probably continue to do so for many many years to come), and would have been the case in Korea had the PLA pulled back to the Chinese boarder when they overran their supply lines and stopped their initial advance instead of staying on to continue the fight. Hundreds of thousands of deaths and years later, the boarder was settled further north then when the PLA first stopped. But then hindsight is a wonderful thing.
Korea is an abject lesson in what could happen if China overplays its hand.
The PLA has traditionally been a defensive force, and its power projection capabilities are disproportionately weak compared to its fighting strength. That means the PLA is not best suited to long-term, long-range combat operations away from home support.
That is changing now, but back in 79, especially against the force that worn down the Americans, staying on and trying to hold ground would have been a terrible idea. It would have cost China hugely politically, financially and most importantly, in lives. And there would have been little to no gain.
The terrain was strategically valuable, but only if you wanted to annex all of Vietnam. Its advantages in defensibility would more then be cancelled out by inciting the Vietnamese to continuously attack in order to regain lost territory.
The main reason this war did not have the kind of effect as usual was probably a combination of the tactical ineptitude the PLA displayed and also from the high the Vietnamese were still on after driving out the Americans. As such, the victory was not as crushing as it could have been, and the Vietnamese also had enough to not loose heart and feel they can 'take China' in the long term and wear the PLA down as they did the Americans.