Created by: lcy-seso
fix #2349 (closed). fix the bug that StaticInput is not added into layers in V2 API.