(1) When, in any proceeding under the laws of this state for the commitment or certification of a person alleged to have a mental health disorder or otherwise be in need of confinement in a hospital or other institution for his or her proper care, it is determined after such adjudication of the status of such person as may be required by law that commitment or certification to a hospital for treatment of mental health disorders or other institution is necessary for safekeeping or treatment and it appears that the person is eligible for care or treatment by the veterans administration, the court, upon receipt of a certificate from the veterans administration showing that facilities are available and that the person is eligible for care or treatment therein, may commit or certify the person to the veterans administration. Upon commitment or certification, the person, when admitted to any facility operated by such agency within or without this state, is subject to the rules and regulations of the veterans administration. The chief officer of any facility of the veterans administration to which the person is committed or certified, with respect to the person committed or certified, is vested with the same powers as superintendents of state hospitals for mental health disorders within this state with respect to retention of custody, transfer, parole, or discharge as restored to reason.
(2) The judgment or order of commitment by a court of competent jurisdiction of another state or of the District of Columbia committing a person to the veterans administration for care or treatment has the same force and effect as to the committed person while in this state as in the jurisdiction in which the court entering the judgment or making the order is situated; and the courts of the committing state or of the District of Columbia shall be deemed to have retained jurisdiction of the person so committed for the purpose of inquiring into the mental condition of such person and of determining the necessity for continuance of his or her restraint. Consent is given to the application of the law of the committing state or district in respect to the authority of the chief officer of any facility of the veterans administration to retain custody or transfer, parole, or discharge the committed person.
(3) Upon receipt of a certificate of the veterans administration that facilities are available for the care or treatment of any person committed or certified to any hospital for persons with mental health disorders or other institution for the care or treatment of persons similarly afflicted and that the person is eligible for care or treatment, the court having jurisdiction may cause him or her to be transferred to the veterans administration for care or treatment. Any person transferred as provided in this section is deemed to be committed or certified to the veterans administration for all purposes as provided in subsection (1) of this section as on original commitment or certification.