Example #1
0
        public async Task <IActionResult> Create([Bind("task_ID,task_name,task_instructions,task_createdate,task_prioritystatus,task_completionstatus,task_duedate")] task task)
        {
            if (ModelState.IsValid)
            {
                _context.Add(task);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(task));
        }
Example #2
0
        public async Task <IActionResult> Create([Bind("service_id,service_name,service_description,service_datetime,service_venue,service_createddate")] service service)
        {
            if (ModelState.IsValid)
            {
                _context.Add(service);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(service));
        }
Example #3
0
        public async Task <IActionResult> Create([Bind("order_id,order_name,order_createddate,order_status,order_description,order_quantity,order_prioritystatus")] order order)
        {
            if (ModelState.IsValid)
            {
                _context.Add(order);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(order));
        }
Example #4
0
        public async Task <IActionResult> Create([Bind("teamleader_ID")] teamLeader teamLeader)
        {
            if (ModelState.IsValid)
            {
                _context.Add(teamLeader);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(teamLeader));
        }
Example #5
0
        public async Task <IActionResult> Create([Bind("checklist_ID,checklist_description,checklist_createddate")] checklist checklist)
        {
            if (ModelState.IsValid)
            {
                _context.Add(checklist);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(checklist));
        }
Example #6
0
        public async Task <IActionResult> Create([Bind("orderitem_ID")] orderItems orderItems)
        {
            if (ModelState.IsValid)
            {
                _context.Add(orderItems);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(orderItems));
        }
Example #7
0
        public async Task <IActionResult> Create([Bind("boxresource_id")] boxResource boxResource)
        {
            if (ModelState.IsValid)
            {
                _context.Add(boxResource);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(boxResource));
        }
Example #8
0
        public async Task <IActionResult> Create([Bind("team_ID,team_name,team_datecreated")] team team)
        {
            if (ModelState.IsValid)
            {
                _context.Add(team);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(team));
        }
Example #9
0
        public async Task <IActionResult> Create([Bind("user_ID,user_type,user_firstname,user_lastname,user_emailaddress,user_password,user_datecreated,user_status")] user user)
        {
            if (ModelState.IsValid)
            {
                _context.Add(user);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(user));
        }
Example #10
0
        public async Task <IActionResult> Create([Bind("resource_ID,resource_type,resource_name,resource_description,resource_datebought,resource_datecreated,resource_datelastmodified,resource_conditionstatus,resource_availabilitystatus,resource_bookedfordate")] resource resource)
        {
            if (ModelState.IsValid)
            {
                _context.Add(resource);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(resource));
        }
        public async Task <IActionResult> Create([Bind("checklistresource_ID")] checklistResource checklistResource)
        {
            if (ModelState.IsValid)
            {
                _context.Add(checklistResource);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(checklistResource));
        }
Example #12
0
        public async Task <IActionResult> Create([Bind("box_id,box_name,box_row,box_column,box_createddate")] box box)
        {
            if (ModelState.IsValid)
            {
                _context.Add(box);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(box));
        }
Example #13
0
        public async Task <IActionResult> Create([Bind("repair_ID,repair_description,repair_prioritystatus,repair_completionstatus,repair_createddate")] repair repair)
        {
            if (ModelState.IsValid)
            {
                _context.Add(repair);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(Index)));
            }
            return(View(repair));
        }