Révision 9fd69a0e GES_PAC/ViewModel/CreateMeasureViewModel.cs

Voir les différences:

GES_PAC/ViewModel/CreateMeasureViewModel.cs
27 27

  
28 28
        #region Commandes
29 29
        public ICommand CreateMeasureCommand { get; }
30
        public ICommand BehaviourCommand { get; }
30 31
        #endregion
31 32

  
32 33
        #region Propriétés
......
170 171
        public CreateMeasureViewModel()
171 172
        {
172 173
            CreateMeasureCommand = new Command(async () => await CreateMeasure());
174
            BehaviourCommand = new Command(async () => await GoToBehaviour());
173 175

  
174 176
            HasLastMeasure = false;
175 177
        }
......
190 192

  
191 193
            IsBusy = false;
192 194
        }
195
        private async Task GoToBehaviour()
196
        {
197
            if (IsBusy) return;
198
            IsBusy = true;
193 199

  
200
            await Shell.Current.GoToAsync($"{nameof(CreateBehaviourView)}?chamberId={ChamberId}");
201

  
202
            IsBusy = false;
203
        }
204
        
194 205
        private void ValidateForm()
195 206
        {
196 207
            ConcO2Error = ConcO2 == null;

Formats disponibles : Unified diff