Esempio n. 1
0
        public IActionResult UpdateCustomerRole(string JsonPost, string customerId)
        {
            var model = JsonConvert.DeserializeObject <List <UserRole> >(JsonPost);

            if (!string.IsNullOrWhiteSpace(customerId))
            {
                _roleService.DeleteCustomerRoles(customerId);
            }

            _roleService.InsertCustomerRoles(model);
            return(Json(new { status = true, message = "" }));
        }