R add isError and isSuccess method

feature/model
RuoYi 2 years ago
parent 87c53a049b
commit f5bec70911

@ -102,4 +102,14 @@ public class R<T> implements Serializable
{
this.data = data;
}
public Boolean isError()
{
return !isSuccess();
}
public Boolean isSuccess()
{
return R.SUCCESS == getCode();
}
}

Loading…
Cancel
Save