Minkowski functionals and the nonlinear perturbation theory in the large-scale structure: Second-order effects