public PatientVisitObj(int pvIdx, PatientObj po) { _index = 0; _ds = new PatientVisitDataSet(); _ds.V_PATIENT_VISIT.AddV_PATIENT_VISITRow( 0, //StationID (po.PatientVisitList[pvIdx] as VisitObj).PatientID, //PatientID po.FirstName, // FirstName po.MiddleInitial, // MiddleInitial po.LastName, // LastName po.Gender, // Gender po.Height, po.Weight, po.BirthDate, // BirthDate po.MedicalRecordNumber, // MedRecNumber 0, //SiteID po.Physician, // Physician (po.PatientVisitList[pvIdx] as VisitObj).PatientVisitId, //PatientVisitId (po.PatientVisitList[pvIdx] as VisitObj).AdmitDate, //AdmitDate (po.PatientVisitList[pvIdx] as VisitObj).DischargeDate, //DischargeDate (po.PatientVisitList[pvIdx] as VisitObj).CareUnitId, //CareUnitId (po.PatientVisitList[pvIdx] as VisitObj).Room, // Room (po.PatientVisitList[pvIdx] as VisitObj).Bed, // Bed (po.PatientVisitList[pvIdx] as VisitObj).AccountNumber, // AccountNumber (po.PatientVisitList[pvIdx] as VisitObj).Barcode, // Barcode false, (po.PatientVisitList[pvIdx] as VisitObj).HospitalService // Hospital Service ); }
public void Remove(object value) { PatientObj objPatient = value as PatientObj; if (_ds.V_PATIENT.Rows.Count > 0) { foreach (PatientDataSet.V_PATIENTRow row in _ds.V_PATIENT.Rows) { if (row.PatientID == objPatient.PatientId) { _ds.V_PATIENT.RemoveV_PATIENTRow(row); break; } } } }
public int Add(object value) { PatientObj objPatient = value as PatientObj; _ds.V_PATIENT.AddV_PATIENTRow( objPatient.PatientId, // PatientID objPatient.FirstName, // FirstName objPatient.MiddleInitial, // MiddleInitial objPatient.LastName, // LastName objPatient.BirthDate, // BirthDate objPatient.Gender, // Gender objPatient.Height, // Height objPatient.Weight, // Weight objPatient.Alias, // Alias objPatient.MedicalRecordNumber, // MedRedNumber objPatient.Physician, // Physician objPatient.PatientType, // PatientType objPatient.PatientFacilityID, // PatientFaciltyID objPatient.MDSiteName // SiteName ); return(1); }