public IActionResult New() { var item = new FuzzyParameterDataEntryModel(); item.GrowthStages = _model.GetLookup(); return(View("Form", item)); }
public IActionResult Edit(int id) { var item = new FuzzyParameterDataEntryModel { FuzzyParameter = _model.GetById(id), GrowthStages = _model.GetLookup() }; return(View("Form", item)); }
public IActionResult Save(FuzzyParameterDataEntryModel item) { if (item.FuzzyParameter.Id == 0) { _model.New(item.FuzzyParameter); } else { _model.Update(item.FuzzyParameter); } return(View("Index", _model.GetAll())); }