|
|
@@ -405,8 +405,8 @@ namespace TeamAAS_VP.ViewModels
|
|
|
/// </summary>
|
|
|
async void ExecuteResetCounterCommand()
|
|
|
{
|
|
|
-
|
|
|
- if (management.CurrentProduct == null) return;
|
|
|
+ var currentProduct = _productService.GetCurrentProduct();
|
|
|
+ if (currentProduct == null) return;
|
|
|
var view = new ShowMessage(Lang.计数清零, Lang.是否重置当前产品的计数);
|
|
|
//show the dialog
|
|
|
var result = await DialogHost.Show(view, "RootDialog", null, null, null);
|
|
|
@@ -415,7 +415,7 @@ namespace TeamAAS_VP.ViewModels
|
|
|
if (((bool)result))
|
|
|
{
|
|
|
isCanExecute = false;
|
|
|
- await _systemDatabaseService.ResetProductionAsync(management.CurrentProduct.Name);
|
|
|
+ await _systemDatabaseService.ResetProductionAsync(currentProduct.Name);
|
|
|
isCanExecute = true;
|
|
|
}
|
|
|
}
|