public AlimentosWindowViewModel(IDialogCoordinator dialog) { this.dialog = dialog; alimentoService = new AlimentoService(new AlimentoRepository()); IncluirCommand = new DelegateCommand(Incluir, () => !ModoEdicao).ObservesProperty(() => ModoEdicao); AlterarCommand = new DelegateCommand(Alterar, () => ModoEdicao).ObservesProperty(() => ModoEdicao); InativarCommand = new DelegateCommand(Inativar, () => ModoEdicao).ObservesProperty(() => ModoEdicao); LimparTelaCommand = new DelegateCommand(Limpar); BuscarAlimentos(); }
public AlimentoController(IAlimentoRepository alimentoRepository, IAlimentoService alimentoService) { _alimentoRepository = alimentoRepository; _alimentoService = alimentoService; }
public AlimentoAppService(IAlimentoService serviceBase, IAlimentoService alimentoService) : base(serviceBase) { _alimentoService = alimentoService; }