You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

30 lines
857 B

using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.Filters;
using Microsoft.AspNetCore.SignalR;
using Microsoft.CodeAnalysis.CSharp.Syntax;
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Threading.Tasks;
using Volo.Abp.AspNetCore.Mvc.ExceptionHandling;
using Volo.Abp.Http;
using WmsWebApi.ZlldcjLogs;
namespace WmsWebApi
{
public class AbpExceptionFilterExtension: AbpExceptionFilter
{
protected override async Task HandleAndWrapException(ExceptionContext context)
{
await Task.CompletedTask;
var error = context.Exception;
context.Result = new ObjectResult(new ReturnResult()
{
TYPE = 'R',
MESSAGE = error.Message,
});
context.ExceptionHandled = true;
}
}
}