change db

This commit is contained in:
2026-04-17 21:43:07 +08:00
parent d832271e2e
commit ed3661edd4
3 changed files with 7 additions and 7 deletions
+2 -2
View File
@@ -64,10 +64,10 @@ class HouseNoteApiService {
final request = http.MultipartRequest( final request = http.MultipartRequest(
'POST', 'POST',
// Uri.parse("${GenericApiService.BASE_IP}/xapi/v2/common/upload_file"), // Uri.parse("${GenericApiService.BASE_IP}/xapi/v2/common/upload_file"),
Uri.parse("${GenericApiService.BASE_IP}/upload/eis_demo/images") Uri.parse("${GenericApiService.BASE_IP}/upload/house_hunter/images")
); );
// 取得本地檔案名稱 // 取得本地檔案名稱
String picFileName = "${GenericApiService.BASE_IP}/upload/eis_demo/images/${imageFile.path.split('/').last}"; String picFileName = "${GenericApiService.BASE_IP}/upload/house_hunter/images/${imageFile.path.split('/').last}";
request.files.add(await http.MultipartFile.fromPath('file', imageFile.path)); request.files.add(await http.MultipartFile.fromPath('file', imageFile.path));
+4 -4
View File
@@ -5,7 +5,7 @@ import 'package:intl/intl.dart';
// 共用 API 常數 // 共用 API 常數
//const String BASE_IP = "https://api.gex.com.tw:8033"; //const String BASE_IP = "https://api.gex.com.tw:8033";
//const String COMMON_API_ENDPOINT = "xapi/v2/eis_demo/orm_api_v2/2/"; //const String COMMON_API_ENDPOINT = "xapi/v2/house_hunter/orm_api_v2/2/";
//const String COMMON_API_URL = "$BASE_IP/$COMMON_API_ENDPOINT"; //const String COMMON_API_URL = "$BASE_IP/$COMMON_API_ENDPOINT";
class GenericApiService { class GenericApiService {
@@ -15,7 +15,7 @@ class GenericApiService {
// 修改後的動態 URL 產生器,支援傳入不同的 store procedure 與回傳 dataset 數 // 修改後的動態 URL 產生器,支援傳入不同的 store procedure 與回傳 dataset 數
String _getProcedureUrl(String endpoint, String version) { String _getProcedureUrl(String endpoint, String version) {
// final String db = AuthManager().currentCompany ?? "demo"; // // final String db = AuthManager().currentCompany ?? "demo"; //
final String dbAll = "eis_demo"; // final String dbAll = "house_hunter"; //
return "$BASE_IP/xapi/v2/$dbAll/$endpoint/$version/"; // return "$BASE_IP/xapi/v2/$dbAll/$endpoint/$version/"; //
} }
@@ -89,9 +89,9 @@ class GenericApiService {
// 以下是 orm_api // 以下是 orm_api
String _getDynamicUrl() { String _getDynamicUrl() {
// 從 AuthManager 獲取目前登入的公司別,若無則預設 eis_demo // 從 AuthManager 獲取目前登入的公司別,若無則預設 house_hunter
// final String db = AuthManager().currentCompany ?? "demo"; // final String db = AuthManager().currentCompany ?? "demo";
final String dbAll = "eis_demo"; final String dbAll = "house_hunter";
return "$BASE_IP/xapi/v2/$dbAll/orm_api_v2/2/"; return "$BASE_IP/xapi/v2/$dbAll/orm_api_v2/2/";
} }
+1 -1
View File
@@ -1,4 +1,4 @@
name: home_hunter name: house_hunter
description: "A new Flutter project." description: "A new Flutter project."
# The following line prevents the package from being accidentally published to # The following line prevents the package from being accidentally published to
# pub.dev using `flutter pub publish`. This is preferred for private packages. # pub.dev using `flutter pub publish`. This is preferred for private packages.