public async Task <ActionResult> DeleteConfirmed(int id)
        {
            StatusDokumenta statusDokumenta = await db.StatusDokumenta.FindAsync(id);

            db.StatusDokumenta.Remove(statusDokumenta);
            await db.SaveChangesAsync();

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

                return(RedirectToAction("Index"));
            }
            return(View(statusDokumenta));
        }
        public async Task <ActionResult> Create([Bind(Include = "ID,Naziv")] StatusDokumenta statusDokumenta)
        {
            if (ModelState.IsValid)
            {
                db.StatusDokumenta.Add(statusDokumenta);
                await db.SaveChangesAsync();

                return(RedirectToAction("Index"));
            }

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

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