Skip to content

Commit

Permalink
Add solutions category
Browse files Browse the repository at this point in the history
  • Loading branch information
ka-sarthak committed Sep 30, 2024
1 parent 860c8b3 commit 6973a92
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions src/nomad_material_processing/solution/general.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
from nomad.datamodel.data import (
ArchiveSection,
EntryData,
EntryDataCategory,
)
from nomad.datamodel.metainfo.annotations import (
ELNAnnotation,
Expand All @@ -21,6 +22,7 @@
SystemComponent,
)
from nomad.metainfo import (
Category,
Datetime,
MEnum,
Quantity,
Expand Down Expand Up @@ -52,6 +54,17 @@
)


class SolutionCategory(EntryDataCategory):
"""
Category for entry schemas related to solutions.
"""

m_def = Category(
label='Solutions',
categories=[EntryDataCategory],
)


class MolarConcentration(ArchiveSection):
"""
The molar concentration of a component in a solution.
Expand Down Expand Up @@ -298,6 +311,7 @@ class Solution(CompositeSystem, EntryData):

# TODO make the solvents, solutes, and elemental_composition subsection noneditable.
m_def = Section(
categories=[SolutionCategory],
description='A homogeneous liquid mixture composed of two or more substances.',
a_eln=ELNAnnotation(
properties=SectionProperties(
Expand Down Expand Up @@ -827,6 +841,7 @@ class SolutionPreparation(Process, EntryData):

# TODO populate the instruments section based on the steps.methodology.instrument
m_def = Section(
categories=[SolutionCategory],
description='Section for describing steps of solution preparation.',
a_eln=ELNAnnotation(
properties=SectionProperties(
Expand Down

0 comments on commit 6973a92

Please sign in to comment.