Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
gy4443
chemotion_eln_server
Commits
5251f259
Commit
5251f259
authored
Sep 25, 2017
by
PiTrem
Browse files
do not use sum formula for mol name in report
parent
d9998689
Changes
2
Show whitespace changes
Inline
Side-by-side
app/models/sample.rb
View file @
5251f259
...
...
@@ -363,7 +363,7 @@ class Sample < ActiveRecord::Base
def
molecule_name_hash
mn
=
molecule_name
mn
?
{
label:
mn
.
name
,
value:
mn
.
id
}
:
{}
mn
?
{
label:
mn
.
name
,
value:
mn
.
id
,
desc:
mn
.
description
}
:
{}
end
private
...
...
lib/reporter/docx/detail_reaction.rb
View file @
5251f259
...
...
@@ -438,7 +438,7 @@ module Reporter
def
sample_molecule_name_delta
(
sample
)
mnh
=
sample
[
:molecule_name_hash
]
smn
=
mnh
?
mnh
[
:label
]
:
nil
smn
=
mnh
&&
mnh
[
:desc
]
!=
'sum_formular'
?
mnh
[
:label
]
:
nil
iupac
=
sample
[
:molecule
]
?
sample
[
:molecule
][
:iupac_name
]
:
nil
if
smn
.
present?
[{
'insert'
=>
smn
.
to_s
}]
...
...
Write
Preview
Supports
Markdown
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