Example #1
0
        public JsonResult OBOUserRegionInserMapping(string User_Code, string Type_Name, List <UserModel> lstUserMappingDetails)
        {
            DataControl.CurrentInfo _objcurrentInfo = new DataControl.CurrentInfo();
            DataControl.BLMessaging objMsg          = new DataControl.BLMessaging();
            string result = string.Empty;

            result = objMsg.InsertOBOMapping(_objcurrentInfo.GetCompanyCode(), User_Code, Type_Name, lstUserMappingDetails, _objcurrentInfo.GetUserCode());

            bool   IsSuccess = false;
            string message   = string.Empty;

            if (result.IndexOf(":") > 0)
            {
                if (result.Split(':')[0].ToLower() == "success")
                {
                    IsSuccess = true;
                }
                message = result.Split(':')[1];
            }
            return(Json(new { Success = IsSuccess, message = message }));
        }