Skip to content

Commit 46787b6

Browse files
committed
guessTIPIcon
1 parent e065d17 commit 46787b6

File tree

1 file changed

+6
-4
lines changed
  • services/static-webserver/client/source/class/osparc/study

1 file changed

+6
-4
lines changed

services/static-webserver/client/source/class/osparc/study/Utils.js

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -385,9 +385,12 @@ qx.Class.define("osparc.study.Utils", {
385385
__guessTIPIcon: function(studyData) {
386386
// the was to guess the TI type is to check the boot mode of the ti-postpro in the pipeline
387387
const tiPostpro = Object.values(studyData["workbench"]).find(srv => srv.key.includes("ti-postpro"));
388-
if (tiPostpro) {
388+
if (tiPostpro && tiPostpro["bootOptions"]) {
389389
console.log(tiPostpro);
390-
switch (tiPostpro["bootOptions"]) {
390+
switch (tiPostpro["bootOptions"]["boot_mode"]) {
391+
case "0":
392+
// classic TI
393+
return "osparc/icons/TI.png";
391394
case "1":
392395
// multichannel
393396
return "osparc/icons/MC.png";
@@ -403,9 +406,8 @@ qx.Class.define("osparc.study.Utils", {
403406
case "5":
404407
// personalized phase-modulation
405408
return "osparc/icons/pPM.png";
406-
case "0":
407409
default:
408-
return "osparc/icons/pTI.png";
410+
return "osparc/icons/TI.png";
409411
}
410412
}
411413
return "osparc/icons/TI.png";

0 commit comments

Comments
 (0)