How does closing down a department affect a PhD student? How does closing down a department affect the value of a PhD and your later academic career?

If someone has joined a university for a PhD in transportation, and that department is closed down, and everyone is moved to / absorbed by management engineering , does this have any ill effect on the quality of education that you will recieve, possible research opportunities, publications and academic career in general?

I have read this related QA, but it's about an undergrad student. PhD students have very fewer and much more specialised courses. In addition, a PhD student is supposed to assist in teaching some courses, how is someone with completely unrelated background (transportation/rural/survey engineering) teach management courses? I'm guessing that this curriculum will have some engineering courses as well, but it sounds to me too generic to be of any use to a student (I have never heard of management engineering before today, pardon my complete ignorance).

Given that some of the faculty will either lose their jobs, or quit, I do not expect their courses to be available, thus the available courses for a PhD student will be much worse (irrelevant to the field of transportation). Given that undergrad students have more generic courses, it is possible for someone to teach those, in contrast with the very niche courses of a PhD curriculum.

I should mention that I am posting this in behalf of someone else, who is only 3 months in that university. The person of interest, claims that it matters more to collaborate with a certain supervisor (who is a Computer Engineer, specialising in machine learning), as they had a great relationship and collaboration in the past; furthermore, since computational science courses are available, the lack of transportation courses seems acceptable to that person, but I am afraid about the fact that they are completely unrelated (computational science can be used in any field, from biology to sociology and statistics).
I will try to address some specific questions/concerns you pose. My comments are based on observations I made (and continue to make) as an MA and PhD student, and administrative staff member at a research center. I haven't seen this exact situation happen, but I've seen and contributed to many other restructuring events (advisor moving to another university, founding new department/lab/research center...).

In academia, the most important indicator of the value of your PhD is the quality and quantity of the research you do. While factors like your advisor, the team at your lab, the facilities available, etc. can affect this indicator, the name of the department you graduate from probably will not. In fact, it is not uncommon for researchers who have studied one field to be employed in a differently-named field. One example is Don Norman, who studied engineering and then psychology, and works in the field of design. The decision to close or merge departments most likely will have no bearing on the value of a PhD.

It is common for people doing work in a specific field (e.g. transportation) to have credentials or employment in a more general field (e.g. management, computational science), or vice versa. More generally, subject matter of your work and the discipline or methods you use to approach that subject can be different. It is normal for one's credentials or employment to relate to only one of these things. It is perfectly acceptable to be a researcher who deals with transportation (subject matter) using computational science (approach), while having credentials in management (general field).

In sum, the "person of interest" actually appears to have the right idea. While your concerns are valid, one's relationship with their advisor and lab/team is often a much more important factor, compared to the name of the deparment they belong to and the courses that are available.