コード例 #1
0
ファイル: BillingTests.cs プロジェクト: the-char-stars/EMS2
 public void Functional_AddNewRecord()
 {
     try
     {
         b.AddNewRecord("1234567", "123456789", "a003");
     }
     catch (Exception e)
     {
         Assert.Fail(e.Message);
     }
 }
コード例 #2
0
        /**
         * \brief <b>Brief Description</b> - AddBillingCode <b><i>class method</i></b> - This method adds a billing code to a patient
         * \details <b>Details</b>
         *
         * This takes in the appointment ID, the id of the patient and the billing library
         *
         * \return <b>int</b> - status flag
         */
        private int AddBillingCode(string aptID, string patientID, Billing billing)
        {
            // ask for a billing code
            Container.DisplayContent(new List <Pair <string, string> >()
            {
                { new Pair <string, string>("Enter the billing code: ", "") }
            },
                                     0, 1, MenuCodes.SCHEDULING, "Scheduling", Description);

            // set cursor
            Console.CursorTop  = 6;
            Console.CursorLeft = 55;

            // ask the user to enter a billing code
            Pair <InputRetCode, string> inputReturn = Input.GetInput("", 4, InputType.Ints | InputType.Strings);

            // check if the user saved the billing code
            if ((inputReturn.First & InputRetCode.SAVE) != 0 &&
                inputReturn.Second.Length == 4)
            {
                // add billing code to record
                if (billing.AddNewRecord(aptID, patientID, inputReturn.Second))
                {
                    return(1);
                }
                return(0);
            }

            return(-1);
        }
コード例 #3
0
        private void BtnOk_Click(object sender, RoutedEventArgs e)
        {
            Logging.Log("Okay button pressed in Appointment Scheduler");
            foreach (Chip c in wpBillingCodesPrimary.Children)
            {
                if (c.Tag != null)
                {
                    billing.AddNewRecord(appointment.AppointmentID.ToString(), appointment.PatientID.ToString(), ((BillingRecord)c.Content).BillingCode);
                }
            }

            foreach (Chip c in wpBillingCodesSecondary.Children)
            {
                if (c.Tag != null)
                {
                    billing.AddNewRecord(appointment.AppointmentID.ToString(), appointment.DependantID.ToString(), ((BillingRecord)c.Content).BillingCode);
                }
            }
            updateDisplay(selectedDate);
            DialogHost.CloseDialogCommand.Execute(null, null);
        }