コード例 #1
0
        public ActionResult Async(AsyncEngineModel model)
        {
            if (!ModelState.IsValid)
            {
                model.HasResult = false;
                return(PartialView("_AsyncResults", model));
            }

            var charasteristic = AsyncEngine.GetCharasteristic(
                model.NominalPower.Value,
                model.NominalVoltage.Value,
                model.Frequency.Value,
                model.UsingCoefficient.Value,
                model.Cosinus.Value,
                model.CurrentsRelation.Value,
                model.MomentsRelation.Value);

            model.SetCharacteristic(charasteristic);
            model.HasResult = true;
            return(PartialView("_AsyncResults", model));
        }
コード例 #2
0
        public ActionResult Async()
        {
            var model = new AsyncEngineModel();

            return(View(model));
        }