Exemplo n.º 1
0
def get_new_event():
        donation_event_actual = DonationEvent()
        donation_event_actual.date_of_event_string = donation_event_reg.get_date_of_event_string()
        donation_event_actual.donation_start_time = donation_event_reg.get_donation_start_time()
        donation_event_actual.donation_end_time = donation_event_reg.get_donation_end_time()
        donation_event_actual.address = donation_event_reg.get_address()
        donation_event_actual.zip_code = donation_event_reg.get_zip_code()
        donation_event_actual.city = donation_event_reg.get_city()
        donation_event_actual.bed_count = donation_event_reg.get_bed_count()
        donation_event_actual.donor_number = donation_event_reg.get_planned_donor_number()
        return donation_event_actual
Exemplo n.º 2
0
        donor_datas.last_donation = donor_register_get_user_data.get_last_donation_date()
        donor_datas.was_sick_last_month = donor_register_get_user_data.get_sick_response_string()
        donor_datas.identifier = donor_register_get_user_data.get_unique_indentifier_string()
        donor_datas.id_expire = donor_register_get_user_data.get_id_expiration_date()
        donor_datas.blood_type = donor_register_get_user_data.get_donor_blood_type_string()
        donor_datas.e_mail = donor_register_get_user_data.get_email_string()
        donor_datas.mobile_number = donor_register_get_user_data.get_mobile_string()
        print(donor_datas.__repr__())
        sleep(15)
        os.system('cls' if os.name == 'nt' else 'clear')



    elif Answer == "2":
        donation_event_actual = DonationEvent()
        donation_event_actual.date_of_event_string = donation_event_reg.get_date_of_event_string()
        donation_event_actual.donation_start_time = donation_event_reg.get_donation_start_time()
        donation_event_actual.donation_end_time = donation_event_reg.get_donation_end_time()
        donation_event_actual.address = donation_event_reg.get_address()
        donation_event_actual.zip_code = donation_event_reg.get_zip_code()
        donation_event_actual.city = donation_event_reg.get_city()
        donation_event_actual.bed_count = donation_event_reg.get_bed_count()
        donation_event_actual.donor_number = donation_event_reg.get_planned_donor_number()
        if donation_event_actual.check_min_period and donation_event_actual.not_weekend():
            donation_event_actual.actual_donor_number = input("How many succesful donation was?")
            print(donation_event_actual.get_donation_success_rate())
            sleep(5)
    elif Answer == "x":
        Switch = False
    else:
        print("Answer invalid.")