Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
hh1966
chemotion_eln_server
Commits
72f1d29d
Commit
72f1d29d
authored
Aug 13, 2019
by
hh1966
Browse files
Fix ResearchPlanDetailsFieldTableColumnNameModal
parent
56347288
Changes
1
Hide whitespace changes
Inline
Side-by-side
app/assets/javascripts/components/research_plan/ResearchPlanDetailsFieldTableColumnNameModal.js
View file @
72f1d29d
...
...
@@ -7,14 +7,28 @@ class ResearchPlanDetailsFieldTableColumnNameModal extends Component {
constructor
(
props
)
{
super
(
props
);
const
{
columnName
}
=
this
.
props
this
.
state
=
{
columnNameValue
:
columnName
?
columnName
:
''
,
columnNameValue
:
''
,
columnNameError
:
''
}
}
componentDidUpdate
(
prevProps
)
{
if
(
this
.
props
!=
prevProps
)
{
const
{
modal
,
columns
}
=
this
.
props
let
columnNameValue
=
''
if
(
modal
.
action
==
'
rename
'
)
{
columnNameValue
=
columns
[
modal
.
idx
].
name
}
this
.
setState
({
columnNameValue
:
columnNameValue
,
columnNameError
:
''
})
}
}
handleColumnNameChange
(
event
)
{
this
.
setState
({
columnNameValue
:
event
.
target
.
value
});
}
...
...
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