public static Response <ArticuloTResponse> IdArticuloT() { try { Response <ArticuloTResponse> response; List <ArticuloTEntity> List; List = ArticuloTData.IdArticuloT(); response = new Response <ArticuloTResponse> { EsCorrecto = true, Valor = new ArticuloTResponse { List = List }, Mensaje = "OK", Estado = true, }; return(response); } catch (Exception ex) { return(new Response <ArticuloTResponse>(false, null, Functions.MessageError(ex), false)); } }
public static async Task <Response <ArticuloTResponse> > InsertArticuloT(short IdTarea, short Cod_Mer, short Cantidad, short Orden) { Response <ArticuloTResponse> response; ArticuloTEntity objArticuloT; short IdArtTar = (short)ArticuloTData.IdArticuloT()[0].IdArtTar; try { objArticuloT = await ArticuloTData.InsertArticuloT(IdArtTar, IdTarea, Cod_Mer, Cantidad, Orden); response = new Response <ArticuloTResponse> { EsCorrecto = true, Valor = new ArticuloTResponse { ArticuloT = objArticuloT }, Mensaje = "OK", Estado = true, }; return(response); } catch (FaultException <ServiceError> ) { throw; } catch (Exception ex) { return(new Response <ArticuloTResponse>(false, null, Functions.MessageError(ex), false)); } }