From 45fdba85f880bf9564f75a0d9938a2adcb87b11e Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 14 Jan 2026 21:31:48 +0000 Subject: [PATCH 001/322] Initial plan From 16c8ffe769af123a6e5d33d4df250b4db36f1335 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 14 Jan 2026 21:44:08 +0000 Subject: [PATCH 002/322] docs: Add comprehensive JavaDoc documentation to EmailLog.java - Added detailed class-level documentation with healthcare context - Documented all three inner enums (EmailStatus, ChartDisplayOption, TransactionType) - Added JavaDoc for all public constructors with @param tags - Documented all getter/setter methods with @param and @return tags - Added @since tag with accurate date (2026-01-14) - Added @see tags for related classes (EmailConfig, EmailAttachment, Demographic, Provider) - Documented compareTo method with @param and @return tags Co-authored-by: yingbull <8680161+yingbull@users.noreply.github.com> --- .../openosp/openo/commn/model/EmailLog.java | 297 ++++++++++++++++++ 1 file changed, 297 insertions(+) diff --git a/src/main/java/ca/openosp/openo/commn/model/EmailLog.java b/src/main/java/ca/openosp/openo/commn/model/EmailLog.java index 22efd2c1000..83ff7567bb2 100644 --- a/src/main/java/ca/openosp/openo/commn/model/EmailLog.java +++ b/src/main/java/ca/openosp/openo/commn/model/EmailLog.java @@ -10,18 +10,61 @@ import java.util.Date; import java.util.List; +/** + * Entity representing an email communication log in the healthcare system. + * + *
This class tracks all email communications sent through the OpenO EMR system, + * including clinical communications, patient correspondence, consultation requests, + * and other healthcare-related notifications. It provides comprehensive audit trail + * capabilities for regulatory compliance (HIPAA/PIPEDA) and supports encrypted + * messaging for protected health information (PHI).
+ * + *Key features:
+ *The email body and encrypted messages are stored as Base64-encoded byte arrays + * to ensure proper handling of special characters and to maintain data integrity + * across different character encodings.
+ * + * @see EmailConfig Email configuration settings for SMTP/API providers + * @see EmailAttachment File attachments associated with email logs + * @see Demographic Patient demographic information + * @see Provider Healthcare provider information + * @since 2026-01-14 + */ @Entity @Table(name = "emailLog") public class EmailLog extends AbstractModelThis interface represents psychosocial risk factors and concerns assessed during + * pregnancy care as part of the British Columbia Antenatal Record (BCAR) form system. + * It captures critical social determinants of health that may impact maternal and fetal + * outcomes, including social support, mental health, substance use, and family dynamics.
+ * + *Psychosocial assessments are essential components of comprehensive prenatal care, + * helping healthcare providers identify patients who may benefit from additional support + * services, mental health interventions, or social work consultations during pregnancy + * and postpartum periods.
+ * + *This interface is part of the AR2005 (Antenatal Record 2005) package and follows + * the Apache XMLBeans framework for XML data binding. It provides getter, setter, and + * factory methods for managing psychosocial assessment data in a type-safe manner.
+ * + * @see YesNoNullType + * @see org.apache.xmlbeans.XmlObject + * @since 2026-01-18 + */ public interface PsychosocialType extends XmlObject { public static final SchemaType type = (SchemaType)XmlBeans.typeSystemForClassLoader(PsychosocialType.class.getClassLoader(), "schemaorg_apache_xmlbeans.system.s9C023B7D67311A3187802DA7FD51EA38").resolveHandle("psychosocialtype93f2type"); - + + /** + * Gets the poor social support indicator value. + * + *Assesses whether the patient has inadequate social support networks during pregnancy. + * Poor social support is a significant risk factor for maternal depression, anxiety, and + * adverse pregnancy outcomes. This assessment helps identify patients who may benefit from + * community resources, support groups, or social work interventions.
+ * + * @return YesNoNullType the poor social support indicator, or null if not set + */ YesNoNullType getPoortSocialSupport(); - + + /** + * Sets the poor social support indicator value. + * + * @param p0 YesNoNullType the poor social support indicator to set + */ void setPoortSocialSupport(final YesNoNullType p0); - + + /** + * Creates and adds a new poor social support indicator. + * + *This factory method creates a new YesNoNullType instance and sets it as the + * poor social support value for this psychosocial assessment.
+ * + * @return YesNoNullType the newly created poor social support indicator + */ YesNoNullType addNewPoortSocialSupport(); + /** + * Gets the relationship problems indicator value. + * + *Assesses whether the patient is experiencing relationship difficulties with their partner + * or other significant relationships. Relationship problems during pregnancy can contribute to + * maternal stress, mental health issues, and may impact prenatal care adherence and birth outcomes. + * This assessment helps identify patients who may benefit from couples counseling or family therapy.
+ * + * @return YesNoNullType the relationship problems indicator, or null if not set + */ YesNoNullType getRelationshipProblems(); - + + /** + * Sets the relationship problems indicator value. + * + * @param p0 YesNoNullType the relationship problems indicator to set + */ void setRelationshipProblems(final YesNoNullType p0); - + + /** + * Creates and adds a new relationship problems indicator. + * + *This factory method creates a new YesNoNullType instance and sets it as the + * relationship problems value for this psychosocial assessment.
+ * + * @return YesNoNullType the newly created relationship problems indicator + */ YesNoNullType addNewRelationshipProblems(); + /** + * Gets the emotional depression indicator value. + * + *Assesses whether the patient is experiencing symptoms of depression during pregnancy. + * Perinatal depression affects up to 20% of pregnant individuals and is associated with + * adverse maternal and fetal outcomes. Early identification enables timely interventions + * including counseling, therapy, or medication management when appropriate. This assessment + * is critical for maternal mental health screening and prevention of postpartum depression.
+ * + * @return YesNoNullType the emotional depression indicator, or null if not set + */ YesNoNullType getEmotionalDepression(); - + + /** + * Sets the emotional depression indicator value. + * + * @param p0 YesNoNullType the emotional depression indicator to set + */ void setEmotionalDepression(final YesNoNullType p0); - + + /** + * Creates and adds a new emotional depression indicator. + * + *This factory method creates a new YesNoNullType instance and sets it as the + * emotional depression value for this psychosocial assessment.
+ * + * @return YesNoNullType the newly created emotional depression indicator + */ YesNoNullType addNewEmotionalDepression(); + /** + * Gets the substance abuse indicator value. + * + *Assesses whether the patient has current or recent substance use concerns during pregnancy, + * including alcohol, tobacco, recreational drugs, or misuse of prescription medications. Substance + * use during pregnancy poses significant risks to fetal development and maternal health. Identification + * enables appropriate intervention, referral to addiction services, and enhanced monitoring throughout + * pregnancy. This assessment is conducted in a non-judgmental manner to facilitate honest disclosure + * and appropriate support.
+ * + * @return YesNoNullType the substance abuse indicator, or null if not set + */ YesNoNullType getSubstanceAbuse(); - + + /** + * Sets the substance abuse indicator value. + * + * @param p0 YesNoNullType the substance abuse indicator to set + */ void setSubstanceAbuse(final YesNoNullType p0); - + + /** + * Creates and adds a new substance abuse indicator. + * + *This factory method creates a new YesNoNullType instance and sets it as the + * substance abuse value for this psychosocial assessment.
+ * + * @return YesNoNullType the newly created substance abuse indicator + */ YesNoNullType addNewSubstanceAbuse(); + /** + * Gets the family violence indicator value. + * + *Assesses whether the patient is experiencing domestic violence, intimate partner violence, + * or other forms of family violence. Pregnancy is a time of increased risk for domestic violence, + * which poses serious threats to both maternal and fetal health. Routine screening enables early + * identification, safety planning, and referral to specialized domestic violence services, counseling, + * and legal resources. This sensitive assessment is conducted privately and confidentially to ensure + * patient safety.
+ * + * @return YesNoNullType the family violence indicator, or null if not set + */ YesNoNullType getFamilyViolence(); - + + /** + * Sets the family violence indicator value. + * + * @param p0 YesNoNullType the family violence indicator to set + */ void setFamilyViolence(final YesNoNullType p0); - + + /** + * Creates and adds a new family violence indicator. + * + *This factory method creates a new YesNoNullType instance and sets it as the + * family violence value for this psychosocial assessment.
+ * + * @return YesNoNullType the newly created family violence indicator + */ YesNoNullType addNewFamilyViolence(); + /** + * Gets the parenting concerns indicator value. + * + *Assesses whether the patient has concerns, anxiety, or uncertainty about their ability to + * parent or care for the newborn. This may include worries about parenting skills, financial + * resources, childcare arrangements, or management of other children in the household. Identifying + * parenting concerns allows healthcare providers to offer prenatal education, parenting classes, + * community resources, and psychosocial support to build parental confidence and competence.
+ * + * @return YesNoNullType the parenting concerns indicator, or null if not set + */ YesNoNullType getParentingConcerns(); - + + /** + * Sets the parenting concerns indicator value. + * + * @param p0 YesNoNullType the parenting concerns indicator to set + */ void setParentingConcerns(final YesNoNullType p0); - + + /** + * Creates and adds a new parenting concerns indicator. + * + *This factory method creates a new YesNoNullType instance and sets it as the + * parenting concerns value for this psychosocial assessment.
+ * + * @return YesNoNullType the newly created parenting concerns indicator + */ YesNoNullType addNewParentingConcerns(); + /** + * Gets the religious/cultural concerns indicator value. + * + *Assesses whether the patient has religious or cultural considerations that may impact + * their pregnancy care, birth planning, or postpartum care. This may include dietary restrictions, + * modesty requirements, preferences for same-gender providers, ritual practices, or traditional + * beliefs about pregnancy and childbirth. Identifying these concerns enables culturally competent, + * patient-centered care that respects individual values and beliefs while ensuring safe medical + * management.
+ * + * @return YesNoNullType the religious/cultural concerns indicator, or null if not set + */ YesNoNullType getReligiousCultural(); - + + /** + * Sets the religious/cultural concerns indicator value. + * + * @param p0 YesNoNullType the religious/cultural concerns indicator to set + */ void setReligiousCultural(final YesNoNullType p0); - + + /** + * Creates and adds a new religious/cultural concerns indicator. + * + *This factory method creates a new YesNoNullType instance and sets it as the + * religious/cultural concerns value for this psychosocial assessment.
+ * + * @return YesNoNullType the newly created religious/cultural concerns indicator + */ YesNoNullType addNewReligiousCultural(); - + + /** + * Factory class for creating and parsing PsychosocialType instances. + * + *This nested factory class provides static methods for instantiating PsychosocialType + * objects and parsing XML content into PsychosocialType instances. It follows the Apache + * XMLBeans factory pattern for type-safe XML data binding.
+ * + *The factory supports multiple input sources including strings, files, URLs, streams, + * readers, DOM nodes, and XML stream readers. Some methods are deprecated in favor of + * newer XML processing approaches.
+ */ public static final class Factory { + /** + * Creates a new empty PsychosocialType instance. + * + * @return PsychosocialType a new instance with default XML options + */ public static PsychosocialType newInstance() { return (PsychosocialType)XmlBeans.getContextTypeLoader().newInstance(PsychosocialType.type, (XmlOptions)null); } - + + /** + * Creates a new empty PsychosocialType instance with custom XML options. + * + * @param options XmlOptions the XML parsing and validation options to apply + * @return PsychosocialType a new instance with the specified options + */ public static PsychosocialType newInstance(final XmlOptions options) { return (PsychosocialType)XmlBeans.getContextTypeLoader().newInstance(PsychosocialType.type, options); } + /** + * Parses an XML string into a PsychosocialType instance. + * + * @param xmlAsString String the XML content to parse + * @return PsychosocialType the parsed instance + * @throws XmlException if the XML is malformed or doesn't match the schema + */ public static PsychosocialType parse(final String xmlAsString) throws XmlException { return (PsychosocialType)XmlBeans.getContextTypeLoader().parse(xmlAsString, PsychosocialType.type, (XmlOptions)null); } - + + /** + * Parses an XML string into a PsychosocialType instance with custom options. + * + * @param xmlAsString String the XML content to parse + * @param options XmlOptions the XML parsing and validation options to apply + * @return PsychosocialType the parsed instance + * @throws XmlException if the XML is malformed or doesn't match the schema + */ public static PsychosocialType parse(final String xmlAsString, final XmlOptions options) throws XmlException { return (PsychosocialType)XmlBeans.getContextTypeLoader().parse(xmlAsString, PsychosocialType.type, options); } - + + /** + * Parses an XML file into a PsychosocialType instance. + * + * @param file File the XML file to parse + * @return PsychosocialType the parsed instance + * @throws XmlException if the XML is malformed or doesn't match the schema + * @throws IOException if the file cannot be read + */ public static PsychosocialType parse(final File file) throws XmlException, IOException { return (PsychosocialType)XmlBeans.getContextTypeLoader().parse(file, PsychosocialType.type, (XmlOptions)null); } - + + /** + * Parses an XML file into a PsychosocialType instance with custom options. + * + * @param file File the XML file to parse + * @param options XmlOptions the XML parsing and validation options to apply + * @return PsychosocialType the parsed instance + * @throws XmlException if the XML is malformed or doesn't match the schema + * @throws IOException if the file cannot be read + */ public static PsychosocialType parse(final File file, final XmlOptions options) throws XmlException, IOException { return (PsychosocialType)XmlBeans.getContextTypeLoader().parse(file, PsychosocialType.type, options); } - + + /** + * Parses XML from a URL into a PsychosocialType instance. + * + * @param u URL the URL pointing to the XML content + * @return PsychosocialType the parsed instance + * @throws XmlException if the XML is malformed or doesn't match the schema + * @throws IOException if the URL content cannot be retrieved + */ public static PsychosocialType parse(final URL u) throws XmlException, IOException { return (PsychosocialType)XmlBeans.getContextTypeLoader().parse(u, PsychosocialType.type, (XmlOptions)null); } - + + /** + * Parses XML from a URL into a PsychosocialType instance with custom options. + * + * @param u URL the URL pointing to the XML content + * @param options XmlOptions the XML parsing and validation options to apply + * @return PsychosocialType the parsed instance + * @throws XmlException if the XML is malformed or doesn't match the schema + * @throws IOException if the URL content cannot be retrieved + */ public static PsychosocialType parse(final URL u, final XmlOptions options) throws XmlException, IOException { return (PsychosocialType)XmlBeans.getContextTypeLoader().parse(u, PsychosocialType.type, options); } + /** + * Parses XML from an input stream into a PsychosocialType instance. + * + * @param is InputStream the input stream containing XML content + * @return PsychosocialType the parsed instance + * @throws XmlException if the XML is malformed or doesn't match the schema + * @throws IOException if the stream cannot be read + */ public static PsychosocialType parse(final InputStream is) throws XmlException, IOException { return (PsychosocialType)XmlBeans.getContextTypeLoader().parse(is, PsychosocialType.type, (XmlOptions)null); } - + + /** + * Parses XML from an input stream into a PsychosocialType instance with custom options. + * + * @param is InputStream the input stream containing XML content + * @param options XmlOptions the XML parsing and validation options to apply + * @return PsychosocialType the parsed instance + * @throws XmlException if the XML is malformed or doesn't match the schema + * @throws IOException if the stream cannot be read + */ public static PsychosocialType parse(final InputStream is, final XmlOptions options) throws XmlException, IOException { return (PsychosocialType)XmlBeans.getContextTypeLoader().parse(is, PsychosocialType.type, options); } - + + /** + * Parses XML from a character reader into a PsychosocialType instance. + * + * @param r Reader the reader containing XML content + * @return PsychosocialType the parsed instance + * @throws XmlException if the XML is malformed or doesn't match the schema + * @throws IOException if the reader cannot be read + */ public static PsychosocialType parse(final Reader r) throws XmlException, IOException { return (PsychosocialType)XmlBeans.getContextTypeLoader().parse(r, PsychosocialType.type, (XmlOptions)null); } - + + /** + * Parses XML from a character reader into a PsychosocialType instance with custom options. + * + * @param r Reader the reader containing XML content + * @param options XmlOptions the XML parsing and validation options to apply + * @return PsychosocialType the parsed instance + * @throws XmlException if the XML is malformed or doesn't match the schema + * @throws IOException if the reader cannot be read + */ public static PsychosocialType parse(final Reader r, final XmlOptions options) throws XmlException, IOException { return (PsychosocialType)XmlBeans.getContextTypeLoader().parse(r, PsychosocialType.type, options); } - + + /** + * Parses XML from an XML stream reader into a PsychosocialType instance. + * + * @param sr XMLStreamReader the stream reader positioned at the start of the XML content + * @return PsychosocialType the parsed instance + * @throws XmlException if the XML is malformed or doesn't match the schema + */ public static PsychosocialType parse(final XMLStreamReader sr) throws XmlException { return (PsychosocialType)XmlBeans.getContextTypeLoader().parse(sr, PsychosocialType.type, (XmlOptions)null); } - + + /** + * Parses XML from an XML stream reader into a PsychosocialType instance with custom options. + * + * @param sr XMLStreamReader the stream reader positioned at the start of the XML content + * @param options XmlOptions the XML parsing and validation options to apply + * @return PsychosocialType the parsed instance + * @throws XmlException if the XML is malformed or doesn't match the schema + */ public static PsychosocialType parse(final XMLStreamReader sr, final XmlOptions options) throws XmlException { return (PsychosocialType)XmlBeans.getContextTypeLoader().parse(sr, PsychosocialType.type, options); } - + + /** + * Parses XML from a DOM node into a PsychosocialType instance. + * + * @param node Node the DOM node containing the XML content + * @return PsychosocialType the parsed instance + * @throws XmlException if the XML is malformed or doesn't match the schema + */ public static PsychosocialType parse(final Node node) throws XmlException { return (PsychosocialType)XmlBeans.getContextTypeLoader().parse(node, PsychosocialType.type, (XmlOptions)null); } - + + /** + * Parses XML from a DOM node into a PsychosocialType instance with custom options. + * + * @param node Node the DOM node containing the XML content + * @param options XmlOptions the XML parsing and validation options to apply + * @return PsychosocialType the parsed instance + * @throws XmlException if the XML is malformed or doesn't match the schema + */ public static PsychosocialType parse(final Node node, final XmlOptions options) throws XmlException { return (PsychosocialType)XmlBeans.getContextTypeLoader().parse(node, PsychosocialType.type, options); } + /** + * Parses XML from a legacy XMLInputStream into a PsychosocialType instance. + * + * @param xis XMLInputStream the XML input stream (deprecated API) + * @return PsychosocialType the parsed instance + * @throws XmlException if the XML is malformed or doesn't match the schema + * @throws XMLStreamException if there is an error processing the XML stream + * @deprecated Use {@link #parse(InputStream)} or {@link #parse(XMLStreamReader)} instead + */ @Deprecated public static PsychosocialType parse(final XMLInputStream xis) throws XmlException, XMLStreamException { return (PsychosocialType)XmlBeans.getContextTypeLoader().parse(xis, PsychosocialType.type, (XmlOptions)null); } - + + /** + * Parses XML from a legacy XMLInputStream into a PsychosocialType instance with custom options. + * + * @param xis XMLInputStream the XML input stream (deprecated API) + * @param options XmlOptions the XML parsing and validation options to apply + * @return PsychosocialType the parsed instance + * @throws XmlException if the XML is malformed or doesn't match the schema + * @throws XMLStreamException if there is an error processing the XML stream + * @deprecated Use {@link #parse(InputStream, XmlOptions)} or {@link #parse(XMLStreamReader, XmlOptions)} instead + */ @Deprecated public static PsychosocialType parse(final XMLInputStream xis, final XmlOptions options) throws XmlException, XMLStreamException { return (PsychosocialType)XmlBeans.getContextTypeLoader().parse(xis, PsychosocialType.type, options); } - + + /** + * Creates a validating XMLInputStream wrapper for schema validation. + * + * @param xis XMLInputStream the XML input stream to wrap with validation (deprecated API) + * @return XMLInputStream a validating wrapper around the input stream + * @throws XmlException if there is an error setting up validation + * @throws XMLStreamException if there is an error processing the XML stream + * @deprecated Use modern StAX-based validation approaches instead + */ @Deprecated public static XMLInputStream newValidatingXMLInputStream(final XMLInputStream xis) throws XmlException, XMLStreamException { return XmlBeans.getContextTypeLoader().newValidatingXMLInputStream(xis, PsychosocialType.type, (XmlOptions)null); } - + + /** + * Creates a validating XMLInputStream wrapper for schema validation with custom options. + * + * @param xis XMLInputStream the XML input stream to wrap with validation (deprecated API) + * @param options XmlOptions the XML parsing and validation options to apply + * @return XMLInputStream a validating wrapper around the input stream + * @throws XmlException if there is an error setting up validation + * @throws XMLStreamException if there is an error processing the XML stream + * @deprecated Use modern StAX-based validation approaches instead + */ @Deprecated public static XMLInputStream newValidatingXMLInputStream(final XMLInputStream xis, final XmlOptions options) throws XmlException, XMLStreamException { return XmlBeans.getContextTypeLoader().newValidatingXMLInputStream(xis, PsychosocialType.type, options); } - + + /** + * Private constructor to prevent instantiation of the factory class. + * + *All factory methods are static and should be accessed directly through the Factory class.
+ */ private Factory() { } } From cc1075079c65b6b4075ecfd3c1279bedf38c6cf5 Mon Sep 17 00:00:00 2001 From: LiamStanziani| + value="<%= provider.getLastName() == null ? "" : provider.getLastName() %>" maxlength="30"> | |
| @@ -202,7 +204,7 @@ | + value="<%= provider.getFirstName() == null ? "" : provider.getFirstName() %>" maxlength="30"> |
@@ -260,7 +262,7 @@
List|
+ value="<%= provider.getSpecialty() == null ? "" : provider.getSpecialty() %>" maxlength="40">
|
+ value="<%= provider.getTeam() == null ? "" : provider.getTeam() %>" maxlength="20">
|
@@ -437,7 +439,7 @@
if (ll != null) {
for (LookupListItem llItem : ll.getItems()) {
String selected = "";
- if (provider.getPractitionerNoType().equals(llItem.getValue())) {
+ if (llItem.getValue() != null && llItem.getValue().equals(provider.getPractitionerNoType())) {
selected = " selected=\"selected\" ";
}
%>
@@ -606,9 +608,6 @@
| |