예제 #1
0
        public TB_PRECO Get(int id)
        {
            pre = new TB_PRECO();

            pre = (TB_PRECO) new Preco().ProducarPeloId(id).Objeto[0];

            return(pre);
        }
예제 #2
0
        public int Delete(int id)
        {
            pre = new TB_PRECO();

            pre = (TB_PRECO) new Preco().ProducarPeloId(id).Objeto[0];

            int retorno = new Preco().Remover(pre).CodigoErro;

            return(retorno);
        }
예제 #3
0
        public int Put(int id, [FromBody] TB_PRECO value)
        {
            int retorno = new Preco().Atualizar(value).CodigoErro;

            return(retorno);
        }
예제 #4
0
        public int Post([FromBody] TB_PRECO value)
        {
            int retorno = new Preco().Cadastrar(value).CodigoErro;

            return(retorno);
        }