feature 5.0.0

This commit is contained in:
v7lin
2023-02-24 16:27:37 +08:00
parent 5775103ed6
commit 2b3e4ee925
2 changed files with 6 additions and 6 deletions

View File

@ -12,15 +12,15 @@ abstract class TencentApiResp {
/// 网络请求成功发送至服务器,并且服务器返回数据格式正确
/// 这里包括所请求业务操作失败的情况,例如没有授权等原因导致
static const int RET_SUCCESS = 0;
static const int kRetSuccess = 0;
@JsonKey(
defaultValue: RET_SUCCESS,
defaultValue: kRetSuccess,
)
final int ret;
final String? msg;
bool get isSuccessful => ret == RET_SUCCESS;
bool get isSuccessful => ret == kRetSuccess;
Map<String, dynamic> toJson();

View File

@ -21,7 +21,7 @@ class TencentUnionidResp {
_$TencentUnionidRespFromJson(json);
@JsonKey(
defaultValue: ERROR_SUCCESS,
defaultValue: kErrorSuccess,
)
final int error;
final String? errorDescription;
@ -29,9 +29,9 @@ class TencentUnionidResp {
final String? openid;
final String? unionid;
static const int ERROR_SUCCESS = 0;
static const int kErrorSuccess = 0;
bool get isSuccessful => error == ERROR_SUCCESS;
bool get isSuccessful => error == kErrorSuccess;
Map<String, dynamic> toJson() => _$TencentUnionidRespToJson(this);