diff --git a/WebGUI/js/SubsystemLaunch.js b/WebGUI/js/SubsystemLaunch.js
index 65458014..89a81de6 100755
--- a/WebGUI/js/SubsystemLaunch.js
+++ b/WebGUI/js/SubsystemLaunch.js
@@ -22,6 +22,7 @@
var SubsystemLaunch = SubsystemLaunch || {}; //define SubsystemLaunch namespace
+SubsystemLaunch._pendingWriteToEcl = false;
if (typeof Debug == 'undefined')
throw('ERROR: Debug is undefined! Must include Debug.js before SubsystemLaunch.js');
@@ -1619,7 +1620,7 @@ SubsystemLaunch.create = function() {
if (isFormControl) {
label.setAttribute('for', 'fsm-dropdown');
}
- label.textContent = 'FSM:';
+ label.textContent = 'Run Type:';
label.style.cssText = 'float: left; margin: 3px 0 0 0;';
dropdownContainer.appendChild(label);
@@ -2685,17 +2686,25 @@ SubsystemLaunch.create = function() {
if(lastLogEntry && lastLogEntry != "")
lastLogEntry = decodeURIComponent(lastLogEntry);
+ var writeToEcl = false; // updated by checkbox onchange before popup is cleared
+ SubsystemLaunch._pendingWriteToEcl = false; // reset each time popup opens
+
DesktopContent.popUpVerification(
/* prompt */
- "Please enter a logbook entry summarizing the run:"
+ "Please enter a logbook entry summarizing the run:" +
+ "
"
,
/* continueFunc [optional] */
function (entry) {
Debug.log("User entered logbook entry " + entry);
+ var writeToEcl = SubsystemLaunch._pendingWriteToEcl || false;
+ Debug.log("writeToEcl = " + writeToEcl);
+
//save last entry
lastLogEntry = entry;
- localStop(entry);
+ localStop(entry, writeToEcl);
} //end continueFunc handlere
,
/* val [optional] */ undefined,
@@ -2724,7 +2733,7 @@ SubsystemLaunch.create = function() {
//===========
- function localStop(logEntry) {
+ function localStop(logEntry, writeToEcl) {
Debug.log("localStop()");
Debug.logv({logEntry});
@@ -2742,7 +2751,8 @@ SubsystemLaunch.create = function() {
DesktopContent.XMLHttpRequest("StateMachineXgiHandler?" +
"&fsmName=" + _fsmName +
"&StateMachine=Stop", //end get data
- "logEntry=" + encodeURIComponent(logEntry), //end post data
+ "logEntry=" + encodeURIComponent(logEntry) +
+ "&writeToEcl=" + (writeToEcl ? "1" : "0"), //end post data
function(req) //start handler
{
Debug.log("stop() FSM handler");
diff --git a/otsdaq-utilities/ECLWriter/ECLSupervisor.cc b/otsdaq-utilities/ECLWriter/ECLSupervisor.cc
index 9f120eb9..5ba43eb7 100644
--- a/otsdaq-utilities/ECLWriter/ECLSupervisor.cc
+++ b/otsdaq-utilities/ECLWriter/ECLSupervisor.cc
@@ -1048,11 +1048,13 @@ xoap::MessageReference ECLSupervisor::MakeSystemLogEntry(xoap::MessageReference
{
SOAPParameters parameters("EntryText");
parameters.addParameter("SubjectText");
+ parameters.addParameter("SkipFooter");
SOAPUtilities::receive(msg, parameters);
std::string EntryText =
StringMacros::decodeURIComponent(parameters.getValue("EntryText"));
std::string SubjectText =
StringMacros::decodeURIComponent(parameters.getValue("SubjectText"));
+ bool skipFooter = parameters.getValue("SkipFooter") == "1";
__COUT__ << "Received External Supervisor System Entry " << EntryText << std::endl;
__COUTV__(SubjectText);
@@ -1087,15 +1089,22 @@ xoap::MessageReference ECLSupervisor::MakeSystemLogEntry(xoap::MessageReference
{
std::stringstream ss;
- ss << "Message: " << __E__ << EntryText << __E__ << __E__;
- ss << "This was a System Generated Log Entry from '" << CategoryName_
- << "' at host '" << __ENV__("THIS_HOST") << "'" << __E__;
- ss << "Active ots users: " << users << __E__;
- ss << "USER_DATA: " << __ENV__("USER_DATA") << __E__;
- ss << "Uptime: "
- << StringMacros::getTimeDurationString(
- CorePropertySupervisorBase::getSupervisorUptime())
- << __E__;
+ if(skipFooter)
+ {
+ ss << EntryText;
+ }
+ else
+ {
+ ss << "Message: " << __E__ << EntryText << __E__ << __E__;
+ ss << "This was a System Generated Log Entry from '" << CategoryName_
+ << "' at host '" << __ENV__("THIS_HOST") << "'" << __E__;
+ ss << "Active ots users: " << users << __E__;
+ ss << "USER_DATA: " << __ENV__("USER_DATA") << __E__;
+ ss << "Uptime: "
+ << StringMacros::getTimeDurationString(
+ CorePropertySupervisorBase::getSupervisorUptime())
+ << __E__;
+ }
field = Field_t(StringMacros::escapeString(ss.str(), true /* keep white space */),
"text");
fields.push_back(field);