File tree Expand file tree Collapse file tree 2 files changed +17
-3
lines changed
services/static-webserver/client/source/class/osparc Expand file tree Collapse file tree 2 files changed +17
-3
lines changed Original file line number Diff line number Diff line change @@ -44,6 +44,17 @@ qx.Class.define("osparc.store.Conversations", {
4444 . catch ( err => osparc . FlashMessenger . logError ( err ) ) ;
4545 } ,
4646
47+ getConversation : function ( studyId , conversationId ) {
48+ const params = {
49+ url : {
50+ studyId,
51+ conversationId,
52+ }
53+ } ;
54+ return osparc . data . Resources . fetch ( "conversations" , "getConversation" , params )
55+ . catch ( err => osparc . FlashMessenger . logError ( err ) ) ;
56+ } ,
57+
4758 addConversation : function ( studyId , name = "new 1" , type = osparc . study . Conversations . TYPES . PROJECT_STATIC ) {
4859 const params = {
4960 url : {
Original file line number Diff line number Diff line change @@ -1238,8 +1238,7 @@ qx.Class.define("osparc.workbench.WorkbenchUI", {
12381238 this . __setSelectedAnnotations ( [ annotation ] ) ;
12391239 switch ( annotation . getType ( ) ) {
12401240 case osparc . workbench . Annotation . TYPES . CONVERSATION : {
1241- const studyData = this . getStudy ( ) . serialize ( ) ;
1242- osparc . study . Conversations . popUpInWindow ( studyData , annotation . getAttributes ( ) [ "conversationId" ] ) ;
1241+ this . __popUpConversation ( annotation . getAttributes ( ) [ "conversationId" ] ) ;
12431242 break ;
12441243 }
12451244 default : {
@@ -1994,7 +1993,7 @@ qx.Class.define("osparc.workbench.WorkbenchUI", {
19941993 serializeData . attributes . conversationId = conversationData [ "conversationId" ] ;
19951994 serializeData . attributes . text = conversationData [ "name" ] ;
19961995 this . __addAnnotation ( serializeData ) ;
1997- osparc . study . Conversations . popUpInWindow ( this . getStudy ( ) . serialize ( ) , conversationData [ "conversationId" ] ) ;
1996+ this . __popUpConversation ( conversationData [ "conversationId" ] ) ;
19981997 } ) ;
19991998 break ;
20001999 }
@@ -2035,6 +2034,10 @@ qx.Class.define("osparc.workbench.WorkbenchUI", {
20352034 }
20362035 } ,
20372036
2037+ __popUpConversation : function ( conversationId ) {
2038+ osparc . study . Conversations . popUpInWindow ( this . getStudy ( ) . serialize ( ) , conversationId ) ;
2039+ } ,
2040+
20382041 __dropFile : async function ( e ) {
20392042 this . __draggingFile ( e , false ) ;
20402043
You can’t perform that action at this time.
0 commit comments