Пример #1
0
        /// <summary>
        /// Webs the internal box to biz internal box.
        /// </summary>
        /// <param name="DataInternalBox">The data internal box.</param>
        /// <returns>BizInternalBox.</returns>
        public static BizInternalBox WebInternalBoxToBizInternalBox(this WebInternalBox DataInternalBox)
        {
            BizInternalBox bizInternalBox = new BizInternalBox
            {
                Amount       = DataInternalBox.Amount,
                CreationDate = DataInternalBox.CreationDate,
            };

            return(bizInternalBox);
        }
Пример #2
0
        /// <summary>
        /// Bizs the internal box to web internal box.
        /// </summary>
        /// <param name="DataInternalBox">The data internal box.</param>
        /// <returns>WebInternalBox.</returns>
        public static WebInternalBox BizInternalBoxToWebInternalBox(this BizInternalBox DataInternalBox)
        {
            WebInternalBox webInternalBox = new WebInternalBox
            {
                Amount       = DataInternalBox.Amount,
                CreationDate = DataInternalBox.CreationDate,
            };

            return(webInternalBox);
        }
Пример #3
0
        public IHttpActionResult Post(WebInternalBox webInternalBox)
        {
            string response = crudFuction.BizInsertInternalBox(webInternalBox.WebInternalBoxToBizInternalBox());

            if (!response.Equals("EXITO"))
            {
                return(BadRequest(response));
            }
            else
            {
                return(Ok(response));
            }
        }