//Get Sent Newsletter Info
    public IQueryable <mic_sendletter> getSendNewsletter()
    {
        hospitalDataContext objNews = new hospitalDataContext();
        var allNews = objNews.mic_sendletters.Select(x => x);

        return(allNews);
    }
Ejemplo n.º 2
0
    public IQueryable <mic_services_lady_minto> getServiceLadyMintoById(int _id)  // GET a single Lady Minto service
    {
        hospitalDataContext objHospital = new hospitalDataContext();
        var serviceLadyMinto            = objHospital.mic_services_lady_mintos.Where(x => x.id == _id).Select(x => x);

        return(serviceLadyMinto);
    }
Ejemplo n.º 3
0
    public IQueryable <mic_advice> getAdviceByLevel(int _level)
    {
        hospitalDataContext objHospital = new hospitalDataContext();
        var allAdvice = objHospital.mic_advices.Where(x => x.level == _level).Select(x => x);

        return(allAdvice);
    }
Ejemplo n.º 4
0
    public IQueryable <mic_services_anson> getServicesAnson()  // GET all Anson services
    {
        hospitalDataContext objHospital = new hospitalDataContext();
        var allServicesAnson            = objHospital.mic_services_ansons.Select(x => x);

        return(allServicesAnson);
    }
Ejemplo n.º 5
0
    public IQueryable <mic_services_bingham> getServiceBinghamById(int _id)  // GET a single Bingham service
    {
        hospitalDataContext objHospital = new hospitalDataContext();
        var serviceBingham = objHospital.mic_services_binghams.Where(x => x.id == _id).Select(x => x);

        return(serviceBingham);
    }
    //Get All Careers
    public IQueryable <mic_career_application> getCareer()
    {
        hospitalDataContext objCareer = new hospitalDataContext();
        var allCareer = objCareer.mic_career_applications.Select(x => x);

        return(allCareer);
    }
Ejemplo n.º 7
0
    public IQueryable <mic_job_posting> getJobPostingById(int _id)  // GET a single job posting by Id
    {
        hospitalDataContext objHospital = new hospitalDataContext();
        var allJobPostings = objHospital.mic_job_postings.Where(x => x.Id == _id).Select(x => x);

        return(allJobPostings);
    }
Ejemplo n.º 8
0
    public IQueryable <mic_book_appointment> getAppointmentsByDateNotBooked(DateTime _date_only)
    {
        hospitalDataContext objHospital = new hospitalDataContext();
        var appointments = objHospital.mic_book_appointments.Where(x => x.date_only == _date_only && x.booked == false).OrderBy(x => x.date).Select(x => x);

        return(appointments);
    }
Ejemplo n.º 9
0
    public IQueryable <mic_specialization> getSpecialization()
    {
        hospitalDataContext objSpecialization = new hospitalDataContext();
        var allSpecialization = objSpecialization.mic_specializations.Select(x => x);

        return(allSpecialization);
    }
Ejemplo n.º 10
0
    //****** QUERY CLAUDIA ******//



    //******** INSERT *******//

    public bool commitInsert(string _title, string _content, string _img, string _category, string _short_cont)
    {
        // to ensure all data will be disposed when finished
        hospitalDataContext objHospitalDC = new hospitalDataContext();

        using (objHospitalDC)
        {
            //create an instance of the table
            mic_news_event objNewEvent = new mic_news_event();

            //set table columns to new values being pass from *.aspx page
            DateTime dateEvent = DateTime.Now;
            objNewEvent.date = dateEvent;

            objNewEvent.title      = _title;
            objNewEvent.content    = _content;
            objNewEvent.img        = _img;
            objNewEvent.category   = _category;
            objNewEvent.short_cont = _short_cont;

            //insert comand
            objHospitalDC.mic_news_events.InsertOnSubmit(objNewEvent);

            //commit insert against database
            objHospitalDC.SubmitChanges();
            return(true);
        }
    }
Ejemplo n.º 11
0
    public IQueryable <mic_book_appointment> getAppointmentsByID(int _id)
    {
        hospitalDataContext objHospital = new hospitalDataContext();
        var appointment = objHospital.mic_book_appointments.Where(x => x.Id == _id).Select(x => x);

        return(appointment);
    }
Ejemplo n.º 12
0
    //******** Query showing the rows by category... CLAUDIA ******//
    public IQueryable <mic_news_event> getEventByCategory(string _category)
    {
        hospitalDataContext objHospitalDC = new hospitalDataContext();
        var allrow = objHospitalDC.mic_news_events.Where(x => x.category == _category).Select(x => x);

        return(allrow);
    }
Ejemplo n.º 13
0
    public IQueryable <mic_pay_bill> getTransactiobByID(int _id)
    {
        hospitalDataContext objTransaction = new hospitalDataContext();
        var Transaction = objTransaction.mic_pay_bills.Where(x => x.Id == _id).Select(x => x);

        return(Transaction);
    }
Ejemplo n.º 14
0
    public IQueryable <mic_pay_bill> getTransactions()
    {
        hospitalDataContext objTransaction = new hospitalDataContext();
        var allTransactions = objTransaction.mic_pay_bills.Select(x => x);

        return(allTransactions);
    }
    //Get Specific Career
    public IQueryable <mic_career_application> getCareerByID(int _id)
    {
        hospitalDataContext objCareer = new hospitalDataContext();
        var allCareer = objCareer.mic_career_applications.Where(x => x.career_id == _id).Select(x => x);

        return(allCareer);
    }
Ejemplo n.º 16
0
    public IQueryable <mic_emergency_time> getDetails(int _id)
    {
        hospitalDataContext objemergency = new hospitalDataContext();
        var allDetails = objemergency.mic_emergency_times.Where(x => x.Id == _id).Select(x => x);

        return(allDetails);
    }
    //Update Career
    public bool commitUpdate(int _id, string _fname, string _lname, string _email, string _address, int _country, int _province, string _city, string _zip, string _phone, int _ques_status, int _ques_crime, int _ques_certificate, int _skill_proficiency, int _skill_experience, string _resume, string _coverletter, string _reason, string _comment, int _consent)
    {
        hospitalDataContext objCareer = new hospitalDataContext();

        using (objCareer)
        {
            var objUpCareer = objCareer.mic_career_applications.Single(x => x.career_id == _id);
            objUpCareer.fname             = _fname;
            objUpCareer.lname             = _lname;
            objUpCareer.email             = _email;
            objUpCareer.address           = _address;
            objUpCareer.country           = _country;
            objUpCareer.province          = _province;
            objUpCareer.city              = _city;
            objUpCareer.zip               = _zip;
            objUpCareer.phone             = _phone;
            objUpCareer.ques_status       = _ques_status;
            objUpCareer.ques_crime        = _ques_crime;
            objUpCareer.ques_certificate  = _ques_certificate;
            objUpCareer.skill_proficiency = _skill_proficiency;
            objUpCareer.skill_experience  = _skill_experience;
            objUpCareer.resume            = _resume;
            objUpCareer.coverletter       = _coverletter;
            objUpCareer.reason            = _reason;
            objUpCareer.comment           = _comment;
            objUpCareer.consent           = _consent;
            objCareer.SubmitChanges();
            return(true);
        }
    }
    public IQueryable <mic_volunteer> getApplications()
    {
        hospitalDataContext objVolunteer = new hospitalDataContext();
        var allApplications = objVolunteer.mic_volunteers.Select(x => x);

        return(allApplications);
    }
Ejemplo n.º 19
0
    //******** INSERT *******//

    public bool commitInsert(string _img, string _name, string _link)
    {
        // to ensure all data will be disposed when finished

        hospitalDataContext objHospitalDC = new hospitalDataContext();

        using (objHospitalDC)
        {
            //create an instance of the table
            mic_slider objNewImages = new mic_slider();

            //set table columns to new values being pass from *.aspx page

            objNewImages.img  = _img;
            objNewImages.name = _name;
            objNewImages.name = _link;


            //insert comand
            objHospitalDC.mic_sliders.InsertOnSubmit(objNewImages);

            //commit insert against database
            objHospitalDC.SubmitChanges();
            return(true);
        }
    }
    public IQueryable <mic_volunteer> getApplicationByID(int _id)
    {
        hospitalDataContext objVolunteer = new hospitalDataContext();
        var application = objVolunteer.mic_volunteers.Where(x => x.Id == _id).Select(x => x);

        return(application);
    }
Ejemplo n.º 21
0
    public IQueryable <mic_job_posting> getJobPostings()  // GET all job postings
    {
        hospitalDataContext objHospital = new hospitalDataContext();
        var allJobPostings = objHospital.mic_job_postings.Select(x => x);

        return(allJobPostings);
    }
    public bool commitInsert(string _fname, string _lname, string _title, string _dob, string _city, string _province, string _postalCode,
                             string _home_phone, string _work_phone, string _personal_phone, string _email, string _emergency_contactName, string _emergency_contact,
                             string _education_level, string _skills, string _experience, string _location, string _reason, string _resume)
    {
        hospitalDataContext objVolunteer    = new hospitalDataContext();
        mic_volunteer       objNewVolunteer = new mic_volunteer();

        objNewVolunteer.fname                 = _fname;
        objNewVolunteer.lname                 = _lname;
        objNewVolunteer.title                 = _title;
        objNewVolunteer.dob                   = _dob;
        objNewVolunteer.city                  = _city;
        objNewVolunteer.province              = _province;
        objNewVolunteer.postalCode            = _postalCode;
        objNewVolunteer.home_phone            = _home_phone;
        objNewVolunteer.work_phone            = _work_phone;
        objNewVolunteer.personal_phone        = _personal_phone;
        objNewVolunteer.email                 = _email;
        objNewVolunteer.emergency_contactName = _emergency_contactName;
        objNewVolunteer.emergency_contact     = _emergency_contact;
        objNewVolunteer.education_level       = _education_level;
        objNewVolunteer.skills                = _skills;
        objNewVolunteer.experience            = _experience;
        objNewVolunteer.location              = _location;
        objNewVolunteer.reason                = _reason;
        objNewVolunteer.resume                = _resume;
        objVolunteer.mic_volunteers.InsertOnSubmit(objNewVolunteer);
        objVolunteer.SubmitChanges();
        return(true);
    }
Ejemplo n.º 23
0
    public IQueryable <mic_services_lady_minto> getServicesLadyMinto()  // GET all Lady Minto services
    {
        hospitalDataContext objHospital = new hospitalDataContext();
        var allServicesLadyMinto        = objHospital.mic_services_lady_mintos.Select(x => x);

        return(allServicesLadyMinto);
    }
Ejemplo n.º 24
0
    public IQueryable <mic_location> getLocation()
    {
        hospitalDataContext objLocation = new hospitalDataContext();
        var allLocations = objLocation.mic_locations.Select(x => x);

        return(allLocations);
    }
Ejemplo n.º 25
0
    public IQueryable <mic_services_anson> getServiceAnsonById(int _id)  // GET a single Anson service
    {
        hospitalDataContext objHospital = new hospitalDataContext();
        var serviceAnson = objHospital.mic_services_ansons.Where(x => x.id == _id).Select(x => x);

        return(serviceAnson);
    }
Ejemplo n.º 26
0
    //Get Specific Newsletter Info
    public IQueryable <mic_mailing_list> getNewsletterByID(int _id)
    {
        hospitalDataContext objNews = new hospitalDataContext();
        var allNews = objNews.mic_mailing_lists.Where(x => x.mailing_id == _id).Select(x => x);

        return(allNews);
    }
Ejemplo n.º 27
0
    public IQueryable <mic_services_bingham> getServicesBingham()  // GET all Bingham services
    {
        hospitalDataContext objHospital = new hospitalDataContext();
        var allServicesBingham          = objHospital.mic_services_binghams.Select(x => x);

        return(allServicesBingham);
    }
Ejemplo n.º 28
0
    //Get All Newsletter Info
    public IQueryable <mic_mailing_list> getNewsletter()
    {
        hospitalDataContext objNews = new hospitalDataContext();
        var allNews = objNews.mic_mailing_lists.Select(x => x);

        return(allNews);
    }
Ejemplo n.º 29
0
    public IQueryable <mic_advice> getAdvice() // GET all advice
    {
        hospitalDataContext objHospital = new hospitalDataContext();
        var allAdvice = objHospital.mic_advices.Select(x => x);

        return(allAdvice);
    }
Ejemplo n.º 30
0
    //Get Specific Sent Newsletter Info
    public IQueryable <mic_sendletter> getSentNewsletterByID(int _id)
    {
        hospitalDataContext objNews = new hospitalDataContext();
        var allNews = objNews.mic_sendletters.Where(x => x.sendletter_id == _id).Select(x => x);

        return(allNews);
    }