Under regulations prescribed by the Governor or the department, an accused who has been sentenced by a court-martial may be required to take leave pending completion of action under this chapter if the sentence, as approved under section 5902 (relating to action by convening authority) or 5906 (relating to approval by convening authority) includes an unsuspended dismissal or an unsuspended dishonorable or bad-conduct discharge. The accused may be required to begin such leave on the date on which the sentence is approved under section 5906 or at any time after such date, and such leave may be continued until the date on which action under this chapter is completed or may be terminated at any earlier time.