Exemple #1
0
        public HttpResponseMessage GCP0023_ReunionRFC(BEGCP_Reunion oBe)
        {
            var oBeR = new BEResponseReunion();

            try
            {
                var oBr = new BRGCP_Reunion();
                oBe.acci = 1;
                var _be = new BEGCP_Reunion();
                oBr.GCP0023_ReunionRFC(oBe);
                var oList = oBr.GCP0023_ReunionRFC_LIST(oBe);
                oBeR.success = true;
                oList.ForEach(obj => {
                    if (obj.reu_Codigo == oBe.reu_Codigo)
                    {
                        oBeR.data = obj;
                    }
                });
                return(Request.CreateResponse(HttpStatusCode.OK, oBeR));
            }
            catch (Exception ex)
            {
                oBeR.success = false;
                oBeR.data    = new BEGCP_Reunion();
                return(Request.CreateErrorResponse(HttpStatusCode.InternalServerError, ex.Message));
            }
        }
Exemple #2
0
        public HttpResponseMessage GCP0023_ReunionRFC_LIST(int id)
        {
            try
            {
                var oBr = new BRGCP_Reunion();
                var oBe = new BEGCP_Reunion();
                oBe.rfc_Codigo = id;

                var oList = oBr.GCP0023_ReunionRFC_LIST(oBe);

                return(Request.CreateResponse(HttpStatusCode.OK, oList));
            }
            catch (Exception ex)
            {
                return(Request.CreateErrorResponse(HttpStatusCode.InternalServerError, ex.Message));
            }
        }