Esempio n. 1
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="toxicityId"></param>
        private void PopulateForm(int?toxicityId)
        {
            if (toxicityId.HasValue)
            {
                // populate toxicity
                Toxicity biz = new Toxicity();
                biz.Get(toxicityId.Value);
                base.PopulateForm(ToxicityFields, biz);

                // Determine if SAE fields need to be displayed when records exits
                //SeriousAdverseEvent adverseEvents = new SeriousAdverseEvent();
                //adverseEvents.GetByParent(toxicityId);
                //if (adverseEvents.RecordCount > 0)
                //{
                //    ShowSAEField.Value = bool.TrueString.ToLower();
                //    base.PopulateForm(SAEFields, adverseEvents);
                //}

                SeriousAdverseEvent adverseEvent = BusinessObject.GetByParent <SeriousAdverseEvent>(toxicityId.Value).FirstOrDefault();
                if (adverseEvent != null)
                {
                    base.PopulateForm(this, adverseEvent);
                }

                int       patientItemId  = int.Parse(base.DecrypyValue(PatientItemId.Value));
                DataTable relatedRecords = RelatedRecordsDa.GetRecord("ProtocolMgr_PatientItems", patientItemId, "Toxicities", toxicityId.Value);
                if (relatedRecords.Rows.Count > 0)
                {
                    RelatedRecordId.Value = relatedRecords.Rows[0][RelatedRecord.RelatedRecordId].ToString();
                }
            }
            PopulateAttributions(toxicityId);
        }
Esempio n. 2
0
        /// <summary>
        /// Transfer to SAE Details where relevant details entered
        /// </summary>
        /// <param name="toxicityId"></param>
        private void CheckSAEDetails(int toxicityId)
        {
            Toxicity tox = new Toxicity();

            tox.Get(toxicityId);
            // if is SAE, transfer
            if (!tox.IsNull(Toxicity.ToxSAE) && PageUtil.IsTrueString(tox[Toxicity.ToxSAE] + ""))
            {
                TransferToSAEDetails(toxicityId);
            }
        }