Sec. 7. If a defendant is sentenced to a term of imprisonment in the Texas Department of Criminal Justice but is not transferred to the department under Section 3 or 4, the court, before the date on which it would lose jurisdiction under Article 42A.202(a), shall send to the department a document containing a statement of the date on which the defendant's sentence was pronounced and credits earned by the defendant under Article 42.03 as of the date of the statement.