public ActionResult _Destroy([DataSourceRequest] DataSourceRequest request, EmailDomainRestrictionsExt model)
        {
            string Msg = "";

            EmailDomainRestrictionsRepository modelRepo = new EmailDomainRestrictionsRepository();

            if (modelRepo.Delete(model, ref Msg, this) == false)
            {
                return(this.Json(new DataSourceResult {
                    Errors = Msg
                }));
            }

            return(Json(request));
        }
        public ActionResult _Update([DataSourceRequest] DataSourceRequest request, EmailDomainRestrictionsExt model)
        {
            if (ModelState.IsValid)
            {
                string Msg = "";

                EmailDomainRestrictionsRepository modelRepo = new EmailDomainRestrictionsRepository();
                if (modelRepo.Update(model, ref Msg, this) == false)
                {
                    return(this.Json(new DataSourceResult {
                        Errors = Msg
                    }));
                }
            }
            else
            {
                string error = ErrorHandling.HandleModelStateErrors(ModelState);
                return(this.Json(new DataSourceResult {
                    Errors = error
                }));
            }
            return(Json(request));
        }