changed base url

This commit is contained in:
amirrezaghabeli
2025-09-07 12:33:33 +03:30
parent bc75452d9d
commit b71ab634a9
+8 -10
View File
@@ -1,5 +1,3 @@
import 'package:flutter/foundation.dart';
class AppConfig { class AppConfig {
// این فلگ نشان می‌دهد که آیا برنامه در حالت Development است یا خیر. // این فلگ نشان می‌دهد که آیا برنامه در حالت Development است یا خیر.
// می‌توانید این مقدار را با استفاده از environment variables در زمان بیلد تغییر دهید. // می‌توانید این مقدار را با استفاده از environment variables در زمان بیلد تغییر دهید.
@@ -14,14 +12,14 @@ class AppConfig {
// return '192.168.1.103:8081'; // return '192.168.1.103:8081';
// if (isDevelopment) { // if (isDevelopment) {
// // Handle different platforms for local development // // Handle different platforms for local development
if (kIsWeb) { // if (kIsWeb) {
// For web, use localhost // For web, use localhost
// return 'https://app.opplens.com'; return 'https://app.opplens.com';
return 'http://localhost:8081'; // return 'http://localhost:8081';
} else { // } else {
// For Android emulator, use 10.0.2.2 (special IP for host machine) // For Android emulator, use 10.0.2.2 (special IP for host machine)
return 'http://10.0.2.2:8081'; // return 'http://10.0.2.2:8081';
} // }
// else if (Platform.isIOS) { // else if (Platform.isIOS) {
// // For iOS simulator, use localhost // // For iOS simulator, use localhost
// return 'http://localhost:8081'; // return 'http://localhost:8081';