Add close action to defect view