25-10-5/1

This commit is contained in:
Hamza-Ayed
2025-10-05 14:12:23 +03:00
parent 729378c507
commit f5dfe2c0fe
19 changed files with 1332 additions and 970 deletions

View File

@@ -123,6 +123,7 @@ class CRUD {
// 401 → دع الطبقة العليا تتعامل مع التجديد
if (sc == 401) {
await Get.put(LoginController()).getJWT();
// لا تستدع getJWT هنا كي لا نضاعف الرحلات
return 'token_expired';
}
@@ -190,6 +191,10 @@ class CRUD {
'Bearer ${r(box.read(BoxName.jwt)).toString().split(Env.addd)[0]}'
},
);
Log.print('response.body: ${response.body}');
Log.print('response.request: ${response.request}');
Log.print('response.payload: ${payload}');
if (response.statusCode == 200) {
var jsonData = jsonDecode(response.body);
if (jsonData['status'] == 'success') {