Add error handling and new API methods for farm assistant features

- Introduced error messages in Persian for image analysis and chat functionalities in FarmAiAssistantChat and PlantPestDetection components.
- Implemented a new postFormData method in ApiClient for handling file uploads.
- Enhanced SmartFertilizationRecommendation and SmartIrrigationRecommendation components to fetch configuration data from the API, improving user experience with loading states and error handling.
- Refactored components to utilize updated API services for better data management and responsiveness.
This commit is contained in:
2026-02-25 23:39:08 +03:30
parent 83b0f88d6e
commit aad5b1c2bd
12 changed files with 778 additions and 160 deletions
+5
View File
@@ -687,6 +687,7 @@
},
"analyze": "تحلیل",
"analyzing": "در حال تحلیل...",
"analyzeError": "خطا در تحلیل تصویر. دوباره تلاش کنید.",
"reset": "بازنشانی",
"resultTitle": "نتیجه تشخیص",
"resultCard": {
@@ -732,6 +733,10 @@
"amount": "مقدار",
"timing": "زمان‌بندی",
"whyThis": "چرا این توصیه؟"
},
"errors": {
"contextLoad": "بارگذاری زمینه مزرعه ناموفق بود.",
"chatSend": "ارسال پیام ناموفق بود. دوباره تلاش کنید."
}
}
}