Пример #1
0
        public async Task <ResultModel> ExchangeWebMenuAuthorityParentID(ExchangeParentIDRequestModel <Guid> requestModel)
        {
            try
            {
                await _webMenuAuthorityService.ExchangeWebMenuAuthorityParentIDAsync(requestModel.ID, requestModel.ParentID, requestModel.TargetID, requestModel.ForUnder);

                return(ResultModel.Success("修改成功"));
            }
            catch (InvalidOperationException ex)
            {
                return(ResultModel.Fail(ex.Message));
            }
        }
Пример #2
0
        public async Task <ResultModel> ExchangeWebMenuIndex(ExchangeParentIDRequestModel <Guid> requestModel)
        {
            try
            {
                await _webMenuService.ExchangeWebMenuIndexAsync(requestModel.ExchangeID, requestModel.ParentID, requestModel.TargetID, requestModel.ForUnder);

                return(ResultModel.Success("修改成功"));
            }
            catch (AspectInvocationException ex)
            {
                return(ResultModel.Fail(ex.InnerException?.Message));
            }
            catch (InvalidOperationException ex)
            {
                return(ResultModel.Fail(ex.Message));
            }
        }