//[ValidateAntiForgeryToken] public IActionResult Create(PowerSupplyMotherBoardInterfaceViewModel model) { var powerSupplyMotherBoardInterface = new PowerSupplyMotherBoardInterface() { Name = model.Name }; var result = _powerSupplyMotherBoardInterfaceService.CreatePowerSupplyMotherBoardInterface(powerSupplyMotherBoardInterface); if (result.Succedeed) { return(Json(powerSupplyMotherBoardInterface)); } return(Json(result)); }
public OperationDetails CreatePowerSupplyMotherBoardInterface(PowerSupplyMotherBoardInterface powerSupplyMotherBoardInterface) { Database.PowerSupplyMotherBoardInterfaces.Create(powerSupplyMotherBoardInterface); Database.Save(); return(new OperationDetails(true, "Ok", "")); }