Ejemplo n.º 1
0
        public async Task <IActionResult> Edit(int id, [Bind("TaskRunnerId,TaskRunnerName,ActiveYn,Status,MaxConcurrentTasks")] FrameworkTaskRunner frameworkTaskRunner)
        {
            if (id != frameworkTaskRunner.TaskRunnerId)
            {
                return(NotFound());
            }

            if (ModelState.IsValid)
            {
                try
                {
                    _context.Update(frameworkTaskRunner);
                    await _context.SaveChangesAsync();
                }
                catch (DbUpdateConcurrencyException)
                {
                    if (!FrameworkTaskRunnerExists(frameworkTaskRunner.TaskRunnerId))
                    {
                        return(NotFound());
                    }
                    else
                    {
                        throw;
                    }
                }
                return(RedirectToAction(nameof(IndexDataTable)));
            }
            return(View(frameworkTaskRunner));
        }
Ejemplo n.º 2
0
        // GET: FrameworkTaskRunner/Create
        public IActionResult Create()
        {
            FrameworkTaskRunner frameworkTaskRunner = new FrameworkTaskRunner();

            frameworkTaskRunner.ActiveYn = true;
            return(View(frameworkTaskRunner));
        }
Ejemplo n.º 3
0
        public async Task <IActionResult> Create([Bind("TaskRunnerId,TaskRunnerName,ActiveYn,Status,MaxConcurrentTasks")] FrameworkTaskRunner frameworkTaskRunner)
        {
            if (ModelState.IsValid)
            {
                _context.Add(frameworkTaskRunner);
                await _context.SaveChangesAsync();

                return(RedirectToAction(nameof(IndexDataTable)));
            }
            return(View(frameworkTaskRunner));
        }