Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue 2487 - 4.14.0 bug fixes #2492

Merged
merged 3 commits into from
Feb 24, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion backend/routes/model.js
Original file line number Diff line number Diff line change
Expand Up @@ -1709,7 +1709,8 @@ function createModel(req, res, next) {
data.userPermissions = req.session.user.permissions;

let createModelPromise;
if (req.body.subModels) {
const isFed = !!req.body.subModels;
if (isFed) {
createModelPromise = ModelHelpers.createNewFederation(account, modelName, username, data);
} else {
createModelPromise = ModelHelpers.createNewModel(account, modelName, data);
Expand All @@ -1719,6 +1720,12 @@ function createModel(req, res, next) {
const modelData = result.modelData;
modelData.setting = result.settings;

if (isFed) {
// hack: we need to wire federations properly onto the queue and follow the same process as model uploads. But it's
// not happening right now.
modelData.setting.timestamp = new Date();
}

responseCodes.respond(responsePlace, req, res, next, responseCodes.OK, modelData);
}).catch(err => {
responseCodes.respond(responsePlace, req, res, next, err.resCode || utils.mongoErrorToResCode(err), err.resCode ? {} : err);
Expand Down
4 changes: 1 addition & 3 deletions frontend/modules/tree/treeProcessing/processing.ts
Original file line number Diff line number Diff line change
Expand Up @@ -277,9 +277,7 @@ export class Processing {
const nodeID = nodesIds[nodeIdx];
const currentState = this.visibilityMap[nodeID];

const desiredState = ifcSpacesHidden ? this.defaultVisibilityMap[nodeID] : VISIBILITY_STATES.VISIBLE;

if (currentState !== desiredState) {
if (currentState !== VISIBILITY_STATES.VISIBLE) {
const node = this.nodesList[this.nodesIndexesMap[nodeID]];
filteredNodes.push(node);
}
Expand Down
4 changes: 2 additions & 2 deletions frontend/services/viewer/multiSelect.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,8 +118,8 @@ export class MultiSelectService {
canvasIcon = panelIcon = this.cursorIcons.decumMode;
}

if (document.getElementById('#canvas')) {
document.getElementById('#canvas').style.cursor = canvasIcon;
if (document.getElementById('unityViewer')) {
document.getElementById('unityViewer').style.cursor = canvasIcon;
}

const groupElements: any = document.getElementsByClassName('groups-list');
Expand Down