Validations for dialogs

We developed a behavior, that presents warnings in the lower part of the dialog, in case that exists, after hitting the dialog button. The user can move forward with the warning. However, in some case the warning is known when the dialog is opened, e.g. the user gets a warning while trying to move entities with status x. In the current behavior, the user will open the dialog, select the entities and while hitting the button, the warning will be presented. Another option for the user is to first select the entities from a grid and then open the dialog, meaning that the warning, if exist, is already known. What is the best practice in this case? opening the dialog with the warnings already presented/ only showing the warnings after hitting the dialog button?

The first picture is the dialog, the second is what happens after clicking on 'perform operation' when there are warnings. My question is if this is acceptable to open the dialog as in the second picture when the warnings are known in advance.

enter image description here

enter image description here