Commit f2ea7c04 authored by chia-lin.lin's avatar chia-lin.lin 💬
Browse files

Copy reaction should allow loading input

When creating a reaction with polymer as starting material, the loading
value is always 0 no matter user inputs the value or not. That's the
current logic about reaction creation and will not change.

When copying a reaction with polymer as starting material, the current
logic about the loading value is to set it as null and does not bring
the value from the source one. With this patch, the loading value is
copied from the source reaction on front-end.

There is a parameter 'keepResidueInfo'. No change is applied for the case
(keepResidueInfo is ture) because a code comment said
'// only reset loading'. So, leave it as well.
parent c3b26fe9
......@@ -85,7 +85,7 @@ export default class Sample extends Element {
residue_type: 'polymer',
custom_info: {
"formula": 'CH',
"loading": null,
"loading": (residue.custom_info ? residue.custom_info.loading : null),
"polymer_type": "polystyrene",
"loading_type": "external",
"external_loading": 0.0,
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment