public F*g CreateFag(F*g model) { model.CreatedAt = DateTime.Now; _context.Fags.Add(model); _context.SaveChanges(); return(model); }
// Start is called before the first frame update void Start() { f*g = FindObjectOfType <F*g>(); powerUps = FindObjectOfType <PowerUps>(); distanceToFag = transform.position - f*g.transform.position; rb = GetComponent <Rigidbody2D>(); }
public ActionResult CreateFag(F*g CreatedFag) { CreatedFag.Id = Guid.NewGuid(); CreatedFag.Fk_class = Currentuser.Fk_AssignedClass; DB.F*g.Add(CreatedFag); DB.SaveChanges(); return(RedirectToAction("Index")); }
public void UpdateFag(F*g fagToUpdate, F*g model) { fagToUpdate.Status = model.Status; fagToUpdate.Question = model.Question; fagToUpdate.Answer = model.Answer; fagToUpdate.ModifiedBy = model.ModifiedBy; fagToUpdate.ModifiedAt = DateTime.Now; _context.SaveChanges(); }
// Start is called before the first frame update void Start() { gameState = FindObjectOfType <GameState>(); powerUps = FindObjectOfType <PowerUps>(); f*g = FindObjectOfType <F*g>(); rb = GetComponent <Rigidbody2D>(); audioSource = GetComponent <AudioSource>(); distanceToFag = transform.position - f*g.transform.position; currentSpeed = initialSpeed; }
public IActionResult Delete(int id) { F*g f*g = _fagRepository.GetFagById(id); if (f*g == null) { return(NotFound()); } _fagRepository.DeleteFag(f*g); return(RedirectToAction("index")); }
public IActionResult Create(FagViewModel f*g) { if (ModelState.IsValid) { F*g model = _mapper.Map <FagViewModel, F*g>(f*g); model.CreatedBy = _admin.FullName; _fagRepository.CreateFag(model); return(RedirectToAction("index")); } return(View(f*g)); }
public IActionResult Edit(int id) { F*g f*g = _fagRepository.GetFagById(id); if (f*g == null) { return(NotFound()); } var model = _mapper.Map <F*g, FagViewModel>(f*g); return(View(model)); }
public IActionResult Edit(FagViewModel f*g) { if (ModelState.IsValid) { F*g model = _mapper.Map <FagViewModel, F*g>(f*g); model.ModifiedBy = _admin.FullName; F*g fagToUpdate = _fagRepository.GetFagById(f*g.Id); if (fagToUpdate == null) { return(NotFound()); } _fagRepository.UpdateFag(fagToUpdate, model); return(RedirectToAction("index")); } return(View(f*g)); }
// Start is called before the first frame update void Start() { ball = FindObjectOfType <Ball>(); f*g = FindObjectOfType <F*g>(); }
public void DeleteFag(F*g f*g) { _context.Fags.Remove(f*g); _context.SaveChanges(); }