NBA, players sign off on final terms for restarted season