public AppointmentType UpdateAppointmentType(AppointmentType tmpAppointmentType)
        {
            DataTable       dt = new DataTable();
            AppointmentType appointmentType = new AppointmentType();

            using (SqlCommand command = new SqlCommand())
            {
                dt = GetMultipleQuery(AppointmentTypeStrings.UpdateAppointmentType(tmpAppointmentType));
            }

            foreach (DataRow ms in dt.Rows)
            {
                appointmentType = AppointmentType.ToObject(ms);
            }

            return(appointmentType);
        }
        public List <AppointmentType> GetAllAppointmentTypes()
        {
            DataTable dt = new DataTable();
            List <AppointmentType> arrAppointmentTypes = new List <AppointmentType>();

            using (SqlCommand command = new SqlCommand())
            {
                dt = GetMultipleQuery(AppointmentTypeStrings.GetAllAppointmentTypes());
            }

            foreach (DataRow ms in dt.Rows)
            {
                arrAppointmentTypes.Add(AppointmentType.ToObject(ms));
            }

            return(arrAppointmentTypes);
        }
        public AppointmentType GetOneAppointmentType(int appointmentTypeId)
        {
            if (appointmentTypeId < 0)
            {
                throw new ArgumentOutOfRangeException();
            }
            DataTable       dt = new DataTable();
            AppointmentType appointmentType = new AppointmentType();

            using (SqlCommand command = new SqlCommand())
            {
                dt = GetMultipleQuery(AppointmentTypeStrings.GetOneAppointmentType(appointmentTypeId));
            }

            foreach (DataRow ms in dt.Rows)
            {
                appointmentType = AppointmentType.ToObject(ms);
            }

            return(appointmentType);
        }