TMDM-7372 Auto set FK when it render in the main tab and auto add a new one in grid when it render in tab panel.