init detail function