Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
VILLASweb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
17
Issues
17
List
Boards
Labels
Service Desk
Milestones
Iterations
Merge Requests
2
Merge Requests
2
Requirements
Requirements
List
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Operations
Operations
Incidents
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
Code Review
Insights
Issue
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
ACS
P
Public
VILLASframework
VILLASweb
Commits
2ceb6d5b
Commit
2ceb6d5b
authored
Feb 18, 2020
by
Sonja Happ
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
remove typos and add some TODOs
parent
6fe522fe
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
4 deletions
+6
-4
src/widget/edit-widget.js
src/widget/edit-widget.js
+1
-1
src/widget/widget.js
src/widget/widget.js
+5
-3
No files found.
src/widget/edit-widget.js
View file @
2ceb6d5b
...
...
@@ -58,7 +58,7 @@ class EditWidgetDialog extends React.Component {
assignAspectRatio
(
changeObject
,
fileId
)
{
// get aspect ratio of file
const
file
=
this
.
props
.
files
.
find
(
element
=>
element
.
_
id
===
fileId
);
const
file
=
this
.
props
.
files
.
find
(
element
=>
element
.
id
===
fileId
);
// scale width to match aspect
const
aspectRatio
=
file
.
dimensions
.
width
/
file
.
dimensions
.
height
;
...
...
src/widget/widget.js
View file @
2ceb6d5b
...
...
@@ -89,10 +89,12 @@ class Widget extends React.Component {
param: '?objectID=1&objectType=widget'
});*/
// TODO no not load simulation models here, since they are loaded via the scenario, pass them as props
AppDispatcher
.
dispatch
({
type
:
'
simulationModels/start-load
'
,
token
:
this
.
state
.
sessionToken
,
param
:
'
?scenarioID=1
'
param
:
'
?scenarioID=1
'
// TODO do not hardcode scenarioID!
});
}
...
...
@@ -101,7 +103,7 @@ class Widget extends React.Component {
let
simulationModel
=
null
;
for
(
let
model
of
this
.
state
.
simulationModels
)
{
if
(
model
.
_
id
!==
widget
.
simulationModel
)
{
if
(
model
.
id
!==
widget
.
simulationModel
)
{
continue
;
}
...
...
@@ -120,7 +122,7 @@ class Widget extends React.Component {
let
simulationModel
=
null
;
for
(
let
model
of
this
.
state
.
simulationModels
)
{
if
(
model
.
_
id
!==
widget
.
simulationModel
)
{
if
(
model
.
id
!==
widget
.
simulationModel
)
{
continue
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment