You mention:
we are not able to open the folder which holds DWT layouts
But looking at the error, I think that statement isn't entirely true, since the Folder you are unable to open does not only contain DWT layouts, but seems to contain an undefined Template Type.
When you upgrade your system you need to make sure you complete the entire upgrade, which means you also need to install/enable all customizations which you had on the other system, and you need to make sure the configurations are identical on all of your out-scaled environments.
In the comments on the other answers you mention you didn't install the Razor mediator yet, but the templates can be opened on one of your CME server and not on another. This seems to indicate that the Razor mediator (or at least an additional Template Type with the ID 8) is configured on the CME server that is working, and not on the other where you are getting the error.
Your question does not contain enough information to fully answer your question, but I think with the information given in mine and the other answers, you should have enough pointers to solve your problem.