Adding condition to enable / disable table row selection