Beispiel #1
0
            public VmEqVar(VmEquations parent, SingleValue singleValue, bool isCalculated, bool refreshNow = false)
            {
                try
                {
                    DefineCommands();

                    _parent      = parent;
                    _singleValue = singleValue;

                    _IsCalculated = isCalculated;

                    _knownUOM = _parent.ContentManager.DefaultUOMSet.FindFromParamType(singleValue.ParamType);

                    // ------------- Refresh items that will not change after this instance is created
                    OnPropertyChanged("IsCalculated");
                    OnPropertyChanged("CanChangeUom");

                    // ------------- Refresh other items if required
                    if (refreshNow)
                    {
                        RefreshThisData();
                    }
                }
                catch (Exception ex)
                {
                    Logging.LogException(ex);
                    throw;
                }
            }
Beispiel #2
0
 public VmBrowseEquation2(VmEquations vmEquations)
 {
     try
     {
         _vmEquations = vmEquations;
         InitData();
     }
     catch (Exception ex)
     {
         Logging.LogException(ex);
         throw;
     }
 }
Beispiel #3
0
        public VmBrowseEquation1(VmEquations vmEquations)
        {
            try
            {
                _vmEquations = vmEquations;
                InitData();

                // -------------------
                SelectEquation = new Command(
                    execute: () =>
                {
                    _vmEquations.EquationsUiService.SelectEqnCalcFromList(5, GetEquationCalcs(),
                                                                          (eqn) => { CurrentEquationCalc = eqn; return(true); });
                });
            }
            catch (Exception ex)
            {
                Logging.LogException(ex);
                throw;
            }
        }