Skip to content

Commit 6862a22

Browse files
committed
Own window
1 parent 3b91038 commit 6862a22

File tree

2 files changed

+4
-35
lines changed

2 files changed

+4
-35
lines changed

services/static-webserver/client/source/class/osparc/dashboard/CardBase.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -950,8 +950,10 @@ qx.Class.define("osparc.dashboard.CardBase", {
950950
},
951951

952952
openData: function() {
953-
const moreOpts = this.__openMoreOptions();
954-
moreOpts.openData();
953+
const resourceData = this.getResourceData();
954+
const studyDataManager = new osparc.widget.StudyDataManager(resourceData["uuid"], null);
955+
const title = osparc.product.Utils.getStudyAlias({firstUpperCase: true}) + this.tr(" Files");
956+
osparc.ui.window.Window.popUpInWindow(studyDataManager, title, osparc.dashboard.ResourceDetails.WIDTH, osparc.dashboard.ResourceDetails.HEIGHT);
955957
},
956958

957959
openBilling: function() {

services/static-webserver/client/source/class/osparc/dashboard/ResourceDetails.js

Lines changed: 0 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,6 @@ qx.Class.define("osparc.dashboard.ResourceDetails", {
9393
__resourceData: null,
9494
__resourceModel: null,
9595
__infoPage: null,
96-
__dataPage: null,
9796
__servicesUpdatePage: null,
9897
__permissionsPage: null,
9998
__tagsPage: null,
@@ -216,10 +215,6 @@ qx.Class.define("osparc.dashboard.ResourceDetails", {
216215
this._openPage(this.__infoPage);
217216
},
218217

219-
openData: function() {
220-
this._openPage(this.__dataPage);
221-
},
222-
223218
openUpdateServices: function() {
224219
this._openPage(this.__servicesUpdatePage);
225220
},
@@ -306,7 +301,6 @@ qx.Class.define("osparc.dashboard.ResourceDetails", {
306301
this.__getBillingPage,
307302
this.__getServicesUpdatePage,
308303
this.__getServicesBootOptionsPage,
309-
this.__getDataPage,
310304
this.__getCommentsPage,
311305
this.__getPermissionsPage,
312306
this.__getSaveAsTemplatePage,
@@ -486,33 +480,6 @@ qx.Class.define("osparc.dashboard.ResourceDetails", {
486480
return page;
487481
},
488482

489-
__getDataPage: function() {
490-
const resourceData = this.__resourceData;
491-
if (osparc.utils.Resources.isService(resourceData)) {
492-
return null;
493-
}
494-
495-
const id = "Data";
496-
const title = osparc.product.Utils.getStudyAlias({firstUpperCase: true}) + this.tr(" Files");
497-
const iconSrc = "@FontAwesome5Solid/file/22";
498-
const page = this.__dataPage = new osparc.dashboard.resources.pages.BasePage(title, iconSrc, id);
499-
this.__addOpenButton(page);
500-
501-
if (this.__resourceData["resourceType"] === "study") {
502-
const studyData = this.__resourceData;
503-
const canBeOpened = osparc.study.Utils.canShowStudyData(studyData);
504-
page.setEnabled(canBeOpened);
505-
}
506-
507-
const lazyLoadContent = () => {
508-
const studyDataManager = new osparc.widget.StudyDataManager(resourceData["uuid"]);
509-
page.addToContent(studyDataManager);
510-
}
511-
page.addListenerOnce("appear", lazyLoadContent, this);
512-
513-
return page;
514-
},
515-
516483
__getPermissionsPage: function() {
517484
const id = "Permissions";
518485
const title = this.tr("Sharing");

0 commit comments

Comments
 (0)