public static SurveyCompany CreateSurveyCompany(string surveyCompanyId)
        {
            SurveyCompany surveyCompany = new SurveyCompany();

            surveyCompany.SurveyCompanyId = surveyCompanyId;
            return(surveyCompany);
        }
        public async Task <ActionResult> DeleteConfirmed(int id)
        {
            SurveyCompany surveyCompany = await db.SurveyCompany.FindAsync(id);

            db.SurveyCompany.Remove(surveyCompany);
            await db.SaveChangesAsync();

            return(RedirectToAction("Index"));
        }
        public async Task <ActionResult> Edit([Bind(Include = "Id,Name")] SurveyCompany surveyCompany)
        {
            if (ModelState.IsValid)
            {
                db.Entry(surveyCompany).State = EntityState.Modified;
                await db.SaveChangesAsync();

                return(RedirectToAction("Index"));
            }
            return(View(surveyCompany));
        }
        public async Task <ActionResult> Create([Bind(Include = "Id,Name")] SurveyCompany surveyCompany)
        {
            if (ModelState.IsValid)
            {
                db.SurveyCompany.Add(surveyCompany);
                await db.SaveChangesAsync();

                return(RedirectToAction("Index"));
            }

            return(View(surveyCompany));
        }
        // GET: SurveyCompanies/Delete/5
        public async Task <ActionResult> Delete(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            SurveyCompany surveyCompany = await db.SurveyCompany.FindAsync(id);

            if (surveyCompany == null)
            {
                return(HttpNotFound());
            }
            return(View(surveyCompany));
        }