message-verify 1.0.1-beta.66 → 1.0.1-beta.67
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -55,12 +55,14 @@ const CreateMessageVerifyModal = ({ props }) => {
|
|
55
55
|
// 这里处理收到的数据
|
56
56
|
console.log('收到 response 事件:', data);
|
57
57
|
if (data === 0) {
|
58
|
-
resolveRef.current(
|
59
|
-
|
58
|
+
resolveRef.current({
|
59
|
+
code: data,
|
60
|
+
});
|
60
61
|
}
|
61
62
|
else {
|
62
|
-
rejectRef.current(
|
63
|
-
|
63
|
+
rejectRef.current({
|
64
|
+
code: data,
|
65
|
+
});
|
64
66
|
}
|
65
67
|
setResCode(data);
|
66
68
|
};
|
@@ -135,7 +137,7 @@ const CreateMessageVerifyModal = ({ props }) => {
|
|
135
137
|
});
|
136
138
|
});
|
137
139
|
console.log('res=====>', res);
|
138
|
-
if (res?.data?.status?.code === 0) {
|
140
|
+
if (res?.code === 0 || res?.data?.status?.code === 0) {
|
139
141
|
apiResolve(res);
|
140
142
|
setVisible(false);
|
141
143
|
}
|
package/package.json
CHANGED
@@ -59,11 +59,13 @@ const CreateMessageVerifyModal = ({ props }: { props: VerifyModalConfig }) => {
|
|
59
59
|
// 这里处理收到的数据
|
60
60
|
console.log('收到 response 事件:', data);
|
61
61
|
if (data === 0) {
|
62
|
-
resolveRef.current(
|
63
|
-
|
62
|
+
resolveRef.current({
|
63
|
+
code: data,
|
64
|
+
});
|
64
65
|
} else {
|
65
|
-
rejectRef.current(
|
66
|
-
|
66
|
+
rejectRef.current({
|
67
|
+
code: data,
|
68
|
+
});
|
67
69
|
}
|
68
70
|
setResCode(data);
|
69
71
|
};
|
@@ -152,7 +154,7 @@ const CreateMessageVerifyModal = ({ props }: { props: VerifyModalConfig }) => {
|
|
152
154
|
})
|
153
155
|
}) as any;
|
154
156
|
console.log('res=====>', res);
|
155
|
-
if (res?.data?.status?.code === 0) {
|
157
|
+
if (res?.code === 0 || res?.data?.status?.code === 0) {
|
156
158
|
apiResolve(res);
|
157
159
|
setVisible(false);
|
158
160
|
} else {
|