Beispiel #1
0
        public AdicionarOfertaPageViewModel(INavigationService navigationService, IInputAlertDialogService inputAlertDialogService, IDependencyService dependencyService)
        {
            _navigationService       = navigationService;
            _inputAlertDialogService = inputAlertDialogService;

            _tipoService    = new TipoService();
            _produtoService = new ProdutoService();
            _ofertaService  = new OfertaService();

            TirarFotoCommand        = new DelegateCommand(ExecuteTirarFotoCommandAsync);
            SelecionarImagemCommand = new DelegateCommand(ExecuteSelecionarImagemCommandAsync);

            AdicionarProdutoCommand = new DelegateCommand(ExecuteAdicionarProdutoCommandAsync);
            AdicionarTipoCommand    = new DelegateCommand(ExecuteAdicionarTipoCommandAsync);

            LimparCommand = new DelegateCommand(ExecuteLimparCommand);
            SalvarCommand = new DelegateCommand(ExecuteSalvarCommandAsync);

            Tipos    = new ObservableCollection <Tipo>();
            Produtos = new ObservableCollection <Produto>();

            Sincroniza();

            DataInicioPicker = DateTime.Today;
            DataFimPicker    = DateTime.Today;

            DestaqueSwitch = false;

            IsBusy = false;
        }
 public FechamentosController(FechamentoService fechamentoService, DepartamentoService departamentoService, OperadorService operadorService, TipoService tipoService)
 {
     _fechamentoService   = fechamentoService;
     _departamentoService = departamentoService;
     _operadorService     = operadorService;
     _tipoService         = tipoService;
 }
Beispiel #3
0
 public ActionResult DeletarTipo(int id)
 {
     return(Ok(TipoService.Deletar(id)));
 }
Beispiel #4
0
        public ActionResult <TipoResponse> Editar(int id, [FromBody] TipoRequest tipoRequest)
        {
            Tipo tipo = _mapperRequest.Map <Tipo>(tipoRequest);

            return(Ok(_mapperResponse.Map <TipoResponse>(TipoService.Editar(id, tipo))));
        }
Beispiel #5
0
        public ActionResult <TipoResponse> Salvar([FromBody] TipoRequest funcionarioRequest)
        {
            Tipo pessoa = _mapperRequest.Map <Tipo>(funcionarioRequest);

            return(Ok(_mapperResponse.Map <TipoResponse>(TipoService.Salvar(pessoa))));
        }
Beispiel #6
0
 public ActionResult <TipoResponse> Obter(int id)
 {
     return(Ok(_mapperResponse.Map <TipoResponse>(TipoService.Obter(id))));
 }
Beispiel #7
0
 public IActionResult Listar()
 {
     return(Ok(_mapperResponse.Map <List <TipoResponse> >(TipoService.Listar())));
 }
 public ProdutoController(ProdutoService produtoService, TipoService tipoService)
 {
     _produtoService = produtoService;
     _tipoService    = tipoService;
 }
Beispiel #9
0
 public LocalController(LocalService localService, TipoService tipoService)
 {
     _localService = localService;
     _tipoService  = tipoService;
 }
Beispiel #10
0
 public TiposController(TipoService service)
 {
     this._insumoService = service;
 }
Beispiel #11
0
 public TipoController(TipoService tipoService)
 {
     _tipoService = tipoService;
 }
Beispiel #12
0
        private readonly TipoService _tipoService;  //injeção de dependencia do TipoService

        //construtor
        public TiposController(/*Mesa01Context_context context*/ TipoService tipoService)
        {
            _tipoService = tipoService;
        }