@tacoreai/web-sdk 1.13.0 → 1.15.0

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.
@@ -74,11 +74,19 @@ class AppsClient extends BaseAppsClient {
74
74
 
75
75
  "readData": params => {
76
76
  // readData(modelName, query)
77
+ const { modelName, query, ...rest } = params;
78
+
79
+ // 优先处理显式的 query 参数 (AI 生成的新模式)
80
+ if (query !== undefined) {
81
+ return this.readData(modelName, query);
82
+ }
83
+
77
84
  // 适配逻辑:如果 params 中除了 modelName 只有一个 wyID 字段,则视为单条查询
78
- const { modelName, ...rest } = params;
79
85
  if (rest.wyID && Object.keys(rest).length === 1) {
80
86
  return this.readData(modelName, rest.wyID);
81
87
  }
88
+
89
+ // 兼容旧版平铺参数
82
90
  return this.readData(modelName, rest);
83
91
  },
84
92
 
@@ -213,4 +221,4 @@ Object.assign(
213
221
  appsClientCrawlerMethods
214
222
  );
215
223
 
216
- export { AppsClient };
224
+ export { AppsClient };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@tacoreai/web-sdk",
3
3
  "description": "This file is for app server package, not the real npm package",
4
- "version": "1.13.0",
4
+ "version": "1.15.0",
5
5
  "type": "module",
6
6
  "publishConfig": {
7
7
  "access": "public",
package/utils/index.js CHANGED
@@ -47,10 +47,6 @@ export function getRouterBasename() {
47
47
  }
48
48
 
49
49
  export function getAppsApiBaseUrl() {
50
- // stone手动: 标准构建 ssr 环境,直接返回生产环境地址
51
- if (process.env.MODE === 'production' && process.env.SSR === 'true') {
52
- return `https://api.tacore.chat`;
53
- }
54
50
  // 后端环境逻辑
55
51
  if (isBackend) {
56
52
  // stone 手动: tacore server 内网地址