Example #1
0
        private bool Subscribe(string message, IDictionary <string, object> header)
        {
            var response = JsonConvert.DeserializeObject <InventoryBusMessage>(message);

            if (!response.IsSuccess)
            {
                List <InventoryBusModel> list = JsonConvert.DeserializeObject <List <InventoryBusModel> >(response.Name);
                var orderid = list.FirstOrDefault().OrderId;
                salesMasterService.Delete(orderid);
            }
            return(true);
        }
        public async Task <ActionResult> Delete(Guid id)
        {
            try
            {
                var result = await salesMasterService.Delete(id);

                return(Ok(result));
            }
            catch (Exception)
            {
                return(BadRequest());
            }
        }