public JsonResult SettingsSavePricingModelScenario(long scenarioID, string model)
        {
            PricingModelModel inputModel = JsonConvert.DeserializeObject <PricingModelModel>(model);

            this.serviceClient.Instance.SavePricingModelSettings(this._context.UserId, scenarioID, inputModel);
            return(SettingsPricingModelForScenario(scenarioID));
        }
예제 #2
0
        public GetPricingModelModel(int customerId, PricingCalcuatorScenarioNames name)
        {
            this.customerId         = customerId;
            this.scenarioName       = name.DescriptionAttr();
            LoadFromLastCashRequest = true;

            Model = new PricingModelModel();
            Error = null;
        }         // constructor
예제 #3
0
        public PricingModelCalculator(int customerId, PricingModelModel model)
        {
            ThrowExceptionOnError = true;
            TargetLoanSource      = null;
            CalculateApr          = true;

            Model = model;

            this.customerId = customerId;

            this.tag = string.Format("{0}_{1}", this.customerId, Guid.NewGuid().ToString("N").ToLowerInvariant());

            LogModel("at its initial state");
        }         // constructor
예제 #4
0
        }         // GetPricingModelScenarios

        public PricingModelModelActionResult PricingModelCalculate(
            int customerId,
            int underwriterId,
            PricingModelModel model
            )
        {
            PricingModelCalculator instance;

            ActionMetaData result = ExecuteSync(out instance, customerId, underwriterId, customerId, model);

            return(new PricingModelModelActionResult {
                MetaData = result,
                Value = instance.Model,
            });
        }         // PricingModelCalculate
예제 #5
0
        public JsonResult Calculate(int customerId, string pricingModelModel)
        {
            var oLog = new SafeILog(this);

            oLog.Debug("Model received: {0}", pricingModelModel);

            PricingModelModel inputModel = JsonConvert.DeserializeObject <PricingModelModel>(pricingModelModel);

            oLog.Debug("Parsed model: {0}", JsonConvert.SerializeObject(inputModel));

            PricingModelModelActionResult pricingModelCalculateResponse =
                this.serviceClient.Instance.PricingModelCalculate(customerId, this.context.UserId, inputModel);

            oLog.Debug("Calculated model: {0}", JsonConvert.SerializeObject(pricingModelCalculateResponse.Value));

            return(Json(pricingModelCalculateResponse.Value, JsonRequestBehavior.AllowGet));
        }         // Calculate
예제 #6
0
        }         // PricingModelCalculate

        public ActionMetaData SavePricingModelSettings(int underwriterId, long scenarioID, PricingModelModel model)
        {
            SavePricingModelSettings instance;

            return(ExecuteSync(out instance, null, underwriterId, scenarioID, model));
        }         // SavePricingModelSettings
예제 #7
0
 public GetPricingModelDefaultRate(int customerId, PricingModelModel model)
 {
     this.customerId = customerId;
     this.model      = model;
 }         // constructor
예제 #8
0
 public SavePricingModelSettings(long scenarioID, PricingModelModel model)
 {
     this.scenarioID = scenarioID;
     this.model      = model;
 }         // constructor
        public GetPricingScenarioDetails(long scenarioID)
        {
            this.scenarioID = scenarioID;

            Model = new PricingModelModel();
        }         // constructor