コード例 #1
0
        public async Task <ActionResult> DeleteConfirmed(int id)
        {
            ICD_10_CM_CodeRange iCD_10_CM_CodeRange = await db.ICD_10_CM_CodeRange.FindAsync(id);

            db.ICD_10_CM_CodeRange.Remove(iCD_10_CM_CodeRange);
            await db.SaveChangesAsync();

            return(RedirectToAction("Index"));
        }
コード例 #2
0
        public async Task <ActionResult> Edit([Bind(Include = "ID,CodeRange,Description")] ICD_10_CM_CodeRange iCD_10_CM_CodeRange)
        {
            if (ModelState.IsValid)
            {
                db.Entry(iCD_10_CM_CodeRange).State = EntityState.Modified;
                await db.SaveChangesAsync();

                return(RedirectToAction("Index"));
            }
            return(View(iCD_10_CM_CodeRange));
        }
コード例 #3
0
        public async Task <ActionResult> Create([Bind(Include = "ID,CodeRange,Description")] ICD_10_CM_CodeRange iCD_10_CM_CodeRange)
        {
            if (ModelState.IsValid)
            {
                db.ICD_10_CM_CodeRange.Add(iCD_10_CM_CodeRange);
                await db.SaveChangesAsync();

                return(RedirectToAction("Index"));
            }

            return(View(iCD_10_CM_CodeRange));
        }
コード例 #4
0
        // GET: ICD_10_CM_CodeRange/Delete/5
        public async Task <ActionResult> Delete(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            ICD_10_CM_CodeRange iCD_10_CM_CodeRange = await db.ICD_10_CM_CodeRange.FindAsync(id);

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