File tree Expand file tree Collapse file tree
modules/final_radiological_review/php Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -139,6 +139,7 @@ class NDB_Form_final_radiological_review extends NDB_Form
139139 * information from the final_radiological_review table for
140140 * smarty
141141 *
142+ * @throws LorisException
142143 * @return array defaults for smarty to use
143144 */
144145 function _getDefaults ()
@@ -171,6 +172,13 @@ class NDB_Form_final_radiological_review extends NDB_Form
171172 );
172173 }
173174
175+ if ($ DB ->tableExists ('radiology_review ' ) === false ) {
176+ throw new LorisException (
177+ "Table 'radiology_review' does not exist. "
178+ . " Please have this instrument set up in order to use this module properly. "
179+ );
180+ }
181+
174182 $ original_review = $ DB ->pselectRow (
175183 "SELECT r.Scan_done as Original_Scan_Done,
176184 r.review_results as Original_Review_Results,
Original file line number Diff line number Diff line change @@ -139,6 +139,14 @@ class NDB_Menu_Filter_final_radiological_review extends NDB_Menu_Filter
139139 WHEN r.PVS <> r.PVS2 THEN 'prim_second'
140140 ELSE 'false' END) " ;
141141
142+ $ DB = Database::singleton ();
143+ if ($ DB ->tableExists ('radiology_review ' ) === false ) {
144+ throw new LorisException (
145+ "Table 'radiology_review' does not exist. "
146+ . " Please have this instrument set up in order to use this module properly. "
147+ );
148+ }
149+
142150 $ this ->query = " FROM radiology_review orig
143151 LEFT JOIN final_radiological_review r ON (r.CommentID=orig.CommentID)
144152 JOIN flag f ON (f.CommentID=orig.CommentID)
You can’t perform that action at this time.
0 commit comments