Author: alexey Date: 2019-08-13 22:54:23 +0000 (Tue, 13 Aug 2019) New Revision: 2810 Modified: trunk/programs/us_xpn_viewer/us_xpn_viewer_gui.cpp Log: Autoflow's live_update: * reset wavelengths && lambda range upon reattach. * make sure ExpID is coupled to RunID in autoflow record when reattaching (maybe different when same protoocl re-launched manually from Optima bypassing us_Comproject) Modified: trunk/programs/us_xpn_viewer/us_xpn_viewer_gui.cpp =================================================================== --- trunk/programs/us_xpn_viewer/us_xpn_viewer_gui.cpp 2019-08-13 20:56:22 UTC (rev 2809) +++ trunk/programs/us_xpn_viewer/us_xpn_viewer_gui.cpp 2019-08-13 22:54:23 UTC (rev 2810) @@ -1163,6 +1163,11 @@ le_runID ->setText( runID ); //le_dbhost ->setText( xpnhost + ":" + xpnport + " (" + xpndesc + ")" ); //New + //Also clear Wavelengths && Lambda ranges: + cb_pltrec ->clear(); + le_lrange ->setText(""); + + pb_loadXpn ->setEnabled( true ); pb_loadAUC ->setEnabled( true ); pb_details ->setEnabled( false ); @@ -1581,6 +1586,17 @@ msg_data_avail->accept(); //msg_data_avail->close(); //ok_msg_data->click(); + + //ALEXEY: make sure ExpID is coupled to the RunID which is already in the autoflow DB + if ( !runID_passed.isEmpty() || runID_passed != "NULL" ) + { + if ( runID_passed.toInt() != RunID_to_retrieve.toInt() ) + { + RunID_to_retrieve = runID_passed; + qDebug() << "Correcting RunID to : " << RunID_to_retrieve; + } + } + //ALEXEY: need to update 'autoflow' table with the unique RunID_to_retrieve && Start Run Time fields !!! //Conditional: Do it ONLY once !!! @@ -1984,7 +2000,7 @@ updateautoflow_record_atLiveUpdate(); //emit experiment_complete_auto( currentDir, ProtocolName, invID_passed, correctRadii ); // Updtade later: what should be passed with signal ?? - reset_auto(); + //reset_auto(); emit experiment_complete_auto( details_at_live_update ); return; @@ -2078,6 +2094,9 @@ //Query for Optima DB periodically, see if data available void US_XpnDataViewer::check_for_data( QMap < QString, QString > & protocol_details) { + //Also reset the panel before reattachement + reset_auto(); + xpn_data->setEtimOffZero(); //ALEXEY: intialize etimoff to zero for the first time experimentAborted = false; @@ -2135,7 +2154,7 @@ timer_data_init->stop(); disconnect(timer_data_init, SIGNAL(timeout()), 0, 0); //Disconnect timer from anything - reset_auto(); + //reset_auto(); emit close_program(); } @@ -2231,8 +2250,9 @@ timer_end_processes->stop(); disconnect(timer_end_processes, SIGNAL(timeout()), 0, 0); //Disconnect timer from anything - - reset_auto(); + + //ALEXEY: may not be needed + //reset_auto(); qDebug() << "LIVE UPDATE panel has been reset!"; qDebug() << "AFTER: " << in_reload_auto << ", " << in_reload_all_data << ", " << in_reload_data_init << ", " << in_reload_check_sysdata; @@ -2547,7 +2567,7 @@ export_auc_auto(); updateautoflow_record_atLiveUpdate(); - reset_auto(); + //reset_auto(); emit experiment_complete_auto( details_at_live_update ); return; } @@ -3963,7 +3983,7 @@ // QMessageBox::information( this, mtitle_complete, message_done ); updateautoflow_record_atLiveUpdate(); - reset_auto(); + //reset_auto(); in_reload_auto = false;
participants (1)
-
svn@svn.aucsolutions.com