@byted-apaas/server-sdk-node 1.1.18-beta.3 → 1.1.18-beta.4

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.
@@ -37,12 +37,12 @@ declare class MetaData<mt> implements IMetaData<mt> {
37
37
  page(apiName: string, objectApiName: string, type: string): Page;
38
38
  }
39
39
  declare function metadata<mt>(ctx: any): IMetaData<mt>;
40
- declare class MetaDataV2<mt> implements IMetaData<mt> {
40
+ declare class MetaDataV3<mt> implements IMetaData<mt> {
41
41
  constructor(ctx: any);
42
42
  object<T>(objectApiName: keyof mt): IKObject<T>;
43
43
  page(apiName: string, objectApiName: string, type: string): Page;
44
44
  }
45
- declare function metadataV2<mt>(ctx: any): IMetaData<mt>;
45
+ declare function metadataV3<mt>(ctx: any): IMetaData<mt>;
46
46
  declare class Page implements IPage {
47
47
  pageApiName: string;
48
48
  objectApiName: string;
@@ -61,4 +61,4 @@ declare class Page implements IPage {
61
61
  updateMobileList(componentName: string, params: any): Promise<void>;
62
62
  }
63
63
  declare function metaType(): any;
64
- export { IMetaData, IKObject, IPage, MetaData, metadata, metaType, MetaDataV2, metadataV2, };
64
+ export { IMetaData, IKObject, IPage, MetaData, metadata, metaType, MetaDataV3, metadataV3, };
@@ -2,7 +2,7 @@
2
2
  // Copyright 2022 ByteDance Ltd. and/or its affiliates
3
3
  // SPDX-License-Identifier: MIT
4
4
  Object.defineProperty(exports, "__esModule", { value: true });
5
- exports.metadataV2 = exports.MetaDataV2 = exports.metaType = exports.metadata = exports.MetaData = void 0;
5
+ exports.metadataV3 = exports.MetaDataV3 = exports.metaType = exports.metadata = exports.MetaData = void 0;
6
6
  const components = require("./components/components");
7
7
  const common = require("@byted-apaas/server-common-node");
8
8
  const fields = require("./objects/fields");
@@ -36,7 +36,7 @@ function metadata(ctx) {
36
36
  return new MetaData(ctx);
37
37
  }
38
38
  exports.metadata = metadata;
39
- class MetaDataV2 {
39
+ class MetaDataV3 {
40
40
  constructor(ctx) {
41
41
  }
42
42
  object(objectApiName) {
@@ -58,11 +58,11 @@ class MetaDataV2 {
58
58
  return new Page(apiName, objectApiName, type);
59
59
  }
60
60
  }
61
- exports.MetaDataV2 = MetaDataV2;
62
- function metadataV2(ctx) {
61
+ exports.MetaDataV3 = MetaDataV3;
62
+ function metadataV3(ctx) {
63
63
  return new MetaData(ctx);
64
64
  }
65
- exports.metadataV2 = metadataV2;
65
+ exports.metadataV3 = metadataV3;
66
66
  class KObject {
67
67
  constructor(objectApiName) {
68
68
  this.objectApiName = objectApiName;
@@ -7,7 +7,7 @@ import { _Resources } from '../context/resources/impl/resources';
7
7
  import { Message } from '../context/msg/msg';
8
8
  import { _IIntegration } from '../context/integration/IIntegration';
9
9
  import { DBV3 } from '../context/db/impl/dbV3';
10
- import { MetaDataV2 } from '../context/metadata/metadata';
10
+ import { MetaDataV3 } from '../context/metadata/metadata';
11
11
  declare global {
12
12
  export namespace application {
13
13
  /**
@@ -27,13 +27,13 @@ declare global {
27
27
  */
28
28
  let operator: IOperator;
29
29
  /**
30
- * dataV2 接口
30
+ * dataV3 接口
31
31
  */
32
- let dataV2: DBV3<{}>;
32
+ let dataV3: DBV3<{}>;
33
33
  /**
34
- * metadataV2 接口
34
+ * metadataV3 接口
35
35
  */
36
- let metadataV2: MetaDataV2<{}>;
36
+ let metadataV3: MetaDataV3<{}>;
37
37
  /**
38
38
  * 常量
39
39
  */
package/hooks/hooks.js CHANGED
@@ -74,7 +74,7 @@ function mountApplication(context) {
74
74
  global.application = {};
75
75
  }
76
76
  global.application.data = new db_1.DB();
77
- global.application.dataV2 = new dbV3_1.DBV3();
77
+ global.application.dataV3 = new dbV3_1.DBV3();
78
78
  // publicAPI
79
79
  if (!global.application.publicAPI) {
80
80
  global.application.publicAPI = {};
@@ -86,7 +86,7 @@ function mountApplication(context) {
86
86
  global.application.msg = new msg_1.Message();
87
87
  global.application.resources = new resources_1._Resources();
88
88
  global.application.metadata = metadataApi.metadata(context);
89
- global.application.metadataV2 = metadataApi.metadataV2(context);
89
+ global.application.metadataV3 = metadataApi.metadataV3(context);
90
90
  // globalVar
91
91
  if (!global.application.globalVar) {
92
92
  global.application.globalVar = {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@byted-apaas/server-sdk-node",
3
- "version": "1.1.18-beta.3",
3
+ "version": "1.1.18-beta.4",
4
4
  "description": "aPaaS Server SDK",
5
5
  "author": "zhouwexin <zhouwexin@bytedance.com>",
6
6
  "homepage": "",