@cloudbase/cals 1.0.3-alpha.1 → 1.0.3-alpha.11
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.
- package/lib/parser/cals/index.d.ts +46 -0
- package/lib/parser/cals/index.d.ts.map +1 -1
- package/lib/parser/cals/index.js +78 -5
- package/lib/parser/cals/utils/block/index.d.ts +0 -0
- package/lib/parser/cals/utils/block/index.d.ts.map +0 -0
- package/lib/parser/cals/utils/block/index.js +0 -0
- package/lib/parser/cals/utils/code/index.d.ts +0 -0
- package/lib/parser/cals/utils/code/index.d.ts.map +0 -0
- package/lib/parser/cals/utils/code/index.js +0 -0
- package/lib/parser/cals/utils/common.d.ts +0 -0
- package/lib/parser/cals/utils/common.d.ts.map +0 -0
- package/lib/parser/cals/utils/common.js +0 -0
- package/lib/parser/cals/utils/runtime.d.ts +0 -0
- package/lib/parser/cals/utils/runtime.d.ts.map +0 -0
- package/lib/parser/cals/utils/runtime.js +0 -0
- package/lib/parser/cals/utils/spinoff/index.d.ts +0 -0
- package/lib/parser/cals/utils/spinoff/index.d.ts.map +0 -0
- package/lib/parser/cals/utils/spinoff/index.js +0 -0
- package/lib/parser/cals/utils/style.d.ts +0 -0
- package/lib/parser/cals/utils/style.d.ts.map +0 -0
- package/lib/parser/cals/utils/style.js +0 -0
- package/lib/parser/cals/utils/template.d.ts +0 -0
- package/lib/parser/cals/utils/template.d.ts.map +0 -0
- package/lib/parser/cals/utils/template.js +0 -0
- package/lib/parser/cals/utils/version/common.d.ts +0 -0
- package/lib/parser/cals/utils/version/common.d.ts.map +0 -0
- package/lib/parser/cals/utils/version/common.js +0 -0
- package/lib/parser/cals/utils/version/config.d.ts +0 -0
- package/lib/parser/cals/utils/version/config.d.ts.map +0 -0
- package/lib/parser/cals/utils/version/config.js +0 -0
- package/lib/parser/cals/utils/version/index.d.ts +0 -0
- package/lib/parser/cals/utils/version/index.d.ts.map +0 -0
- package/lib/parser/cals/utils/version/index.js +0 -0
- package/lib/parser/cals/utils/version/parses.d.ts +0 -0
- package/lib/parser/cals/utils/version/parses.d.ts.map +0 -0
- package/lib/parser/cals/utils/version/parses.js +0 -0
- package/lib/parser/cals/utils/version/utils.d.ts +0 -0
- package/lib/parser/cals/utils/version/utils.d.ts.map +0 -0
- package/lib/parser/cals/utils/version/utils.js +0 -0
- package/lib/parser/constants.d.ts +2 -0
- package/lib/parser/constants.d.ts.map +1 -0
- package/lib/parser/constants.js +4 -0
- package/lib/parser/expression/index.d.ts +0 -0
- package/lib/parser/expression/index.d.ts.map +0 -0
- package/lib/parser/expression/index.js +0 -0
- package/lib/parser/index.d.ts +0 -0
- package/lib/parser/index.d.ts.map +0 -0
- package/lib/parser/index.js +0 -0
- package/lib/types/basic/app.d.ts +0 -0
- package/lib/types/basic/app.d.ts.map +0 -0
- package/lib/types/basic/app.js +0 -0
- package/lib/types/basic/common.d.ts +1 -1
- package/lib/types/basic/common.d.ts.map +1 -1
- package/lib/types/basic/common.js +0 -0
- package/lib/types/basic/component.d.ts +5 -0
- package/lib/types/basic/component.d.ts.map +1 -1
- package/lib/types/basic/component.js +0 -0
- package/lib/types/basic/datasource.d.ts +0 -0
- package/lib/types/basic/datasource.d.ts.map +0 -0
- package/lib/types/basic/datasource.js +0 -0
- package/lib/types/index.d.ts +1 -0
- package/lib/types/index.d.ts.map +1 -1
- package/lib/types/index.js +0 -0
- package/lib/types/lcds.d.ts +148 -11
- package/lib/types/lcds.d.ts.map +1 -1
- package/lib/types/lcds.js +0 -0
- package/lib/types/platform/app.d.ts +0 -0
- package/lib/types/platform/app.d.ts.map +0 -0
- package/lib/types/platform/app.js +0 -0
- package/lib/types/platform/common.d.ts +11 -1
- package/lib/types/platform/common.d.ts.map +1 -1
- package/lib/types/platform/common.js +0 -0
- package/lib/types/platform/component.d.ts +5 -0
- package/lib/types/platform/component.d.ts.map +1 -1
- package/lib/types/platform/component.js +0 -0
- package/lib/types/platform/datasource.d.ts +0 -0
- package/lib/types/platform/datasource.d.ts.map +0 -0
- package/lib/types/platform/datasource.js +0 -0
- package/lib/types/platform/eventFlow.d.ts +20 -0
- package/lib/types/platform/eventFlow.d.ts.map +1 -0
- package/lib/types/platform/eventFlow.js +2 -0
- package/lib/types/platform/query.d.ts +58 -0
- package/lib/types/platform/query.d.ts.map +1 -0
- package/lib/types/platform/query.js +2 -0
- package/lib/types/platform/widget/form.d.ts +0 -0
- package/lib/types/platform/widget/form.d.ts.map +0 -0
- package/lib/types/platform/widget/form.js +0 -0
- package/lib/types/platform/widget/meta.d.ts +0 -0
- package/lib/types/platform/widget/meta.d.ts.map +0 -0
- package/lib/types/platform/widget/meta.js +0 -0
- package/lib/utils/CSSProperty.d.ts +0 -0
- package/lib/utils/CSSProperty.d.ts.map +0 -0
- package/lib/utils/CSSProperty.js +0 -0
- package/lib/utils/build.d.ts +0 -0
- package/lib/utils/build.d.ts.map +0 -0
- package/lib/utils/build.js +0 -0
- package/lib/utils/constant.d.ts +0 -0
- package/lib/utils/constant.d.ts.map +0 -0
- package/lib/utils/constant.js +0 -0
- package/lib/utils/dts/auto-generated.d.ts +1 -1
- package/lib/utils/dts/auto-generated.d.ts.map +1 -1
- package/lib/utils/dts/auto-generated.js +26 -1107
- package/lib/utils/dts/build.js +4 -1
- package/lib/utils/dts/index.d.ts +2 -39
- package/lib/utils/dts/index.d.ts.map +1 -1
- package/lib/utils/dts/index.js +33 -288
- package/lib/utils/index.d.ts +0 -0
- package/lib/utils/index.d.ts.map +0 -0
- package/lib/utils/index.js +0 -0
- package/package.json +1 -2
|
@@ -21,28 +21,21 @@ exports.wedaDTS = `declare class UserWidget {
|
|
|
21
21
|
// ========== 快捷访问方式 ========== //
|
|
22
22
|
|
|
23
23
|
/**
|
|
24
|
-
* 组件
|
|
24
|
+
* 组件 id
|
|
25
25
|
*/
|
|
26
26
|
readonly id: string;
|
|
27
27
|
/**
|
|
28
|
-
*
|
|
28
|
+
* 组件库名称
|
|
29
29
|
*/
|
|
30
30
|
readonly module: string;
|
|
31
31
|
/**
|
|
32
|
-
*
|
|
32
|
+
* 组件名称
|
|
33
33
|
*/
|
|
34
34
|
readonly component: string;
|
|
35
|
-
|
|
36
|
-
/**
|
|
37
|
-
* 父组件引用
|
|
38
|
-
*/
|
|
39
|
-
readonly parent: UserWidget;
|
|
40
|
-
/**
|
|
41
|
-
* 子组件集合
|
|
42
|
-
*/
|
|
43
|
-
readonly children: UserWidget[];
|
|
44
|
-
|
|
45
35
|
// FIXME: 暂时不对外暴露
|
|
36
|
+
// readonly parent: UserWidget;
|
|
37
|
+
// readonly children: UserWidget[];
|
|
38
|
+
|
|
46
39
|
// closest(filter?: (parentWidget: UserWidget) => boolean): UserWidget | null;
|
|
47
40
|
}
|
|
48
41
|
|
|
@@ -50,10 +43,6 @@ exports.wedaDTS = `declare class UserWidget {
|
|
|
50
43
|
// Used Components - Don't touch me
|
|
51
44
|
// Used Components Inner End
|
|
52
45
|
|
|
53
|
-
// Redefine Any Type Inner Begin
|
|
54
|
-
// Redefine Any Type - Don't touch me
|
|
55
|
-
// Redefine Any Type Inner End
|
|
56
|
-
|
|
57
46
|
declare namespace $app {
|
|
58
47
|
const id: string;
|
|
59
48
|
const label: string;
|
|
@@ -62,10 +51,6 @@ const mpAppId: string;
|
|
|
62
51
|
const mpAppName: string;
|
|
63
52
|
|
|
64
53
|
namespace dataset {
|
|
65
|
-
|
|
66
|
-
/**
|
|
67
|
-
* 全局变量对象
|
|
68
|
-
*/
|
|
69
54
|
const state: {
|
|
70
55
|
// Global State Inner Begin
|
|
71
56
|
// Global State 全局变量 - Don't touch me
|
|
@@ -73,18 +58,12 @@ namespace dataset {
|
|
|
73
58
|
};
|
|
74
59
|
}
|
|
75
60
|
|
|
76
|
-
/**
|
|
77
|
-
* 全局 common 方法
|
|
78
|
-
*/
|
|
79
61
|
namespace common {
|
|
80
62
|
// Global Common Inner Begin
|
|
81
63
|
// Global Common 全局方法 - Don't touch me
|
|
82
64
|
// Global Common Inner End
|
|
83
65
|
}
|
|
84
66
|
|
|
85
|
-
/**
|
|
86
|
-
* 设置页面变量
|
|
87
|
-
*/
|
|
88
67
|
function setState(data: Object): void;
|
|
89
68
|
|
|
90
69
|
}
|
|
@@ -92,267 +71,73 @@ function setState(data: Object): void;
|
|
|
92
71
|
declare const app = $app;
|
|
93
72
|
|
|
94
73
|
declare namespace $w {
|
|
95
|
-
|
|
96
|
-
/**
|
|
97
|
-
* 当前应用实例
|
|
98
|
-
*/
|
|
99
74
|
const app = $app;
|
|
100
75
|
|
|
101
|
-
/**
|
|
102
|
-
* 当前页面实例
|
|
103
|
-
*/
|
|
104
76
|
const page = $page;
|
|
105
77
|
|
|
106
|
-
/**
|
|
107
|
-
* 用户权限相关方法和属性
|
|
108
|
-
*/
|
|
109
78
|
namespace auth {
|
|
110
|
-
|
|
111
|
-
interface CurrentUserInfo {
|
|
112
|
-
/**
|
|
113
|
-
* 用户 ID
|
|
114
|
-
*
|
|
115
|
-
* @privateForWeDa
|
|
116
|
-
* {"group": "globalVar", "displayType": "string", "displayName": "用户 ID"}
|
|
117
|
-
*/
|
|
79
|
+
interface CurrentUserInfo {
|
|
118
80
|
userId?: string;
|
|
119
|
-
/**
|
|
120
|
-
* 手机
|
|
121
|
-
*
|
|
122
|
-
* @privateForWeDa
|
|
123
|
-
* {"group": "globalVar", "displayType": "string", "displayName": "手机"}
|
|
124
|
-
*/
|
|
125
81
|
phone?: string;
|
|
126
|
-
/**
|
|
127
|
-
* 用户类型
|
|
128
|
-
*
|
|
129
|
-
* @privateForWeDa
|
|
130
|
-
* {"group": "globalVar", "displayType": "number", "displayName": "用户类型"}
|
|
131
|
-
*/
|
|
132
82
|
type?: number;
|
|
133
|
-
/**
|
|
134
|
-
* 用户关联角色
|
|
135
|
-
*
|
|
136
|
-
* @privateForWeDa
|
|
137
|
-
* {"group": "globalVar", "displayType": "array", "displayName": "用户关联角色"}
|
|
138
|
-
*/
|
|
139
83
|
relatedRoles?: {
|
|
140
|
-
/**
|
|
141
|
-
* 角色 ID
|
|
142
|
-
*
|
|
143
|
-
* @privateForWeDa
|
|
144
|
-
* {"group": "globalVar", "displayType": "string", "displayName": "角色 ID"}
|
|
145
|
-
*/
|
|
146
84
|
id?: string;
|
|
147
|
-
/**
|
|
148
|
-
* 环境 ID
|
|
149
|
-
*
|
|
150
|
-
* @privateForWeDa
|
|
151
|
-
* {"group": "globalVar", "displayType": "string", "displayName": "环境 ID"}
|
|
152
|
-
*/
|
|
153
85
|
envId?: string;
|
|
154
|
-
/**
|
|
155
|
-
* 角色名称
|
|
156
|
-
*
|
|
157
|
-
* @privateForWeDa
|
|
158
|
-
* {"group": "globalVar", "displayType": "string", "displayName": "角色名称"}
|
|
159
|
-
*/
|
|
160
86
|
name?: string;
|
|
161
|
-
/**
|
|
162
|
-
* 角色标识
|
|
163
|
-
*
|
|
164
|
-
* @privateForWeDa
|
|
165
|
-
* {"group": "globalVar", "displayType": "string", "displayName": "角色标识"}
|
|
166
|
-
*/
|
|
167
87
|
roleIdentity?: string;
|
|
168
88
|
}[];
|
|
169
|
-
/**
|
|
170
|
-
* 微信/企微 openId
|
|
171
|
-
*
|
|
172
|
-
* @privateForWeDa
|
|
173
|
-
* {"group": "globalVar", "displayType": "string", "displayName": "微信/企微 openId"}
|
|
174
|
-
*/
|
|
175
89
|
openId?: string;
|
|
176
|
-
/**
|
|
177
|
-
* 用户名称
|
|
178
|
-
*
|
|
179
|
-
* @privateForWeDa
|
|
180
|
-
* {"group": "globalVar", "displayType": "string", "displayName": "用户名称"}
|
|
181
|
-
*/
|
|
182
90
|
name?: string;
|
|
183
|
-
/**
|
|
184
|
-
* 用户昵称
|
|
185
|
-
*
|
|
186
|
-
* @privateForWeDa
|
|
187
|
-
* {"group": "globalVar", "displayType": "string", "displayName": "用户昵称"}
|
|
188
|
-
*/
|
|
189
91
|
nickName?: string;
|
|
190
|
-
/**
|
|
191
|
-
* 邮箱
|
|
192
|
-
*
|
|
193
|
-
* @privateForWeDa
|
|
194
|
-
* {"group": "globalVar", "displayType": "string", "displayName": "邮箱"}
|
|
195
|
-
*/
|
|
196
92
|
email?: string;
|
|
197
|
-
/**
|
|
198
|
-
* 主岗部门
|
|
199
|
-
*
|
|
200
|
-
* @privateForWeDa
|
|
201
|
-
* {"group": "globalVar", "displayType": "object", "displayName": "主岗部门"}
|
|
202
|
-
*/
|
|
203
93
|
mainOrg?: {
|
|
204
|
-
/**
|
|
205
|
-
* 主岗部门 ID
|
|
206
|
-
*
|
|
207
|
-
* @privateForWeDa
|
|
208
|
-
* {"group": "globalVar", "displayType": "string", "displayName": "主岗部门 ID"}
|
|
209
|
-
*/
|
|
210
94
|
id?: string;
|
|
211
|
-
/**
|
|
212
|
-
* 主岗部门名称
|
|
213
|
-
*
|
|
214
|
-
* @privateForWeDa
|
|
215
|
-
* {"group": "globalVar", "displayType": "string", "displayName": "主岗部门名称"}
|
|
216
|
-
*/
|
|
217
95
|
name?: string;
|
|
218
96
|
};
|
|
219
|
-
/**
|
|
220
|
-
* 兼岗部门
|
|
221
|
-
*
|
|
222
|
-
* @privateForWeDa
|
|
223
|
-
* {"group": "globalVar", "displayType": "object", "displayName": "兼岗部门"}
|
|
224
|
-
*/
|
|
225
97
|
orgs?: {
|
|
226
|
-
/**
|
|
227
|
-
* 兼岗部门 ID
|
|
228
|
-
*
|
|
229
|
-
* @privateForWeDa
|
|
230
|
-
* {"group": "globalVar", "displayType": "string", "displayName": "兼岗部门 ID"}
|
|
231
|
-
*/
|
|
232
98
|
id?: string;
|
|
233
|
-
/**
|
|
234
|
-
* 兼岗部门名称
|
|
235
|
-
*
|
|
236
|
-
* @privateForWeDa
|
|
237
|
-
* {"group": "globalVar", "displayType": "string", "displayName": "兼岗部门名称"}
|
|
238
|
-
*/
|
|
239
99
|
name?: string;
|
|
240
100
|
}[];
|
|
241
101
|
}
|
|
242
|
-
|
|
243
|
-
/**
|
|
244
|
-
* 获取用户信息
|
|
245
|
-
*/
|
|
246
102
|
function getUserInfo(): CurrentUserInfo;
|
|
247
|
-
|
|
248
|
-
/**
|
|
249
|
-
*
|
|
250
|
-
* 登录用户信息
|
|
251
|
-
*
|
|
252
|
-
* @privateForWeDa
|
|
253
|
-
* {"group": "globalVar", "displayType": "object", "displayName": "登录用户信息", "schema": {"type":"object","properties":{"userId":{"type":"string","title":"用户 ID"},"phone":{"type":"string","title":"手机"},"type":{"type":"number","title":"用户类型"},"relatedRoles":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","title":"角色 ID"},"envId":{"type":"string","title":"环境 ID"},"name":{"type":"string","title":"角色名称"},"roleIdentity":{"type":"string","title":"角色标识"}}},"title":"用户关联角色"},"openId":{"type":"string","title":"微信/企微 openId"},"name":{"type":"string","title":"用户名称"},"nickName":{"type":"string","title":"用户昵称"},"email":{"type":"string","title":"邮箱"},"mainOrg":{"type":"object","properties":{"id":{"type":"string","title":"主岗部门 ID"},"name":{"type":"string","title":"主岗部门名称"}},"title":"主岗部门"},"orgs":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","title":"兼岗部门 ID"},"name":{"type":"string","title":"兼岗部门名称"}}},"title":"兼岗部门"}}}, "doc": "https://docs.cloudbase.net/lowcode/framework/app/app#authgetuserinfoauthcurrentuser"}
|
|
254
|
-
*/
|
|
255
103
|
const currentUser: CurrentUserInfo;
|
|
256
104
|
|
|
257
105
|
}
|
|
258
106
|
|
|
259
|
-
/**
|
|
260
|
-
* 数据源等云端能力集合
|
|
261
|
-
*/
|
|
262
107
|
namespace cloud {
|
|
263
108
|
interface ICallDataSourceParams {
|
|
264
|
-
/**
|
|
265
|
-
* 数据源标志
|
|
266
|
-
*/
|
|
267
109
|
dataSourceName: string;
|
|
268
|
-
/**
|
|
269
|
-
* 数据源方法名
|
|
270
|
-
*/
|
|
271
110
|
methodName: string;
|
|
272
|
-
/**
|
|
273
|
-
* 方法参数,根据方法实际入参填写
|
|
274
|
-
*/
|
|
275
111
|
params: Object;
|
|
276
112
|
}
|
|
277
113
|
interface ICallFunctionParams {
|
|
278
|
-
/**
|
|
279
|
-
* TCB云函数名称
|
|
280
|
-
*/
|
|
281
114
|
name: string;
|
|
282
|
-
/**
|
|
283
|
-
* 云函数接收的参数,根据自己创建的云函数入参而定
|
|
284
|
-
*/
|
|
285
115
|
data?: any;
|
|
286
116
|
}
|
|
287
117
|
interface IParseOptions {
|
|
288
|
-
/**
|
|
289
|
-
* 解析 云开发云函数的通用response 包装。为true, 则返回 res.result, 此时会丢失 res.requestId 信息
|
|
290
|
-
*/
|
|
291
118
|
unwrapResult?: boolean;
|
|
292
|
-
/**
|
|
293
|
-
* 解析业务信息,需配合 unwrapResult 使用。为 true 时, res.result.code 非 0 抛出错误, 为 0 则返回 res.result.data
|
|
294
|
-
*/
|
|
295
119
|
parseBusinessInfo?: boolean;
|
|
296
120
|
}
|
|
297
121
|
interface ICallWorkflowParams {
|
|
298
|
-
/**
|
|
299
|
-
* 方法名称
|
|
300
|
-
*/
|
|
301
122
|
action: string;
|
|
302
|
-
/**
|
|
303
|
-
* 方法的自定义参数,其中 envType, envId, uid, source 均无需填写
|
|
304
|
-
*/
|
|
305
123
|
data?: Record<string, any>;
|
|
306
|
-
/**
|
|
307
|
-
* 是否自动将 data 的key 改为大写驼峰。默认为 true, 即使用时 data 可以采用小驼峰的 key
|
|
308
|
-
*/
|
|
309
124
|
capitalizeDataKey?: boolean;
|
|
310
125
|
}
|
|
311
126
|
|
|
312
|
-
/**
|
|
313
|
-
* 调用数据源
|
|
314
|
-
*/
|
|
315
127
|
function callDataSource(params: ICallDataSourceParams): any;
|
|
316
|
-
|
|
317
|
-
/**
|
|
318
|
-
* 通过 cloudid 获取静态文件的 http 访问地址
|
|
319
|
-
*/
|
|
320
128
|
function getTempFileURL(params: string | string[]): Promise<string | string[]>;
|
|
321
|
-
|
|
322
|
-
/**
|
|
323
|
-
* 调用流程
|
|
324
|
-
*/
|
|
325
129
|
function callWorkflow(action: ICallWorkflowParams): Promise<any>;
|
|
326
|
-
|
|
327
|
-
/**
|
|
328
|
-
* 调用云开发的云函数, 与 $w.cloud.getCloudInstance 示例中的效果大体一致
|
|
329
|
-
*/
|
|
330
130
|
function callFunction(params: ICallFunctionParams, parseOptions?: IParseOptions): Promise<any>;
|
|
331
|
-
|
|
332
|
-
/**
|
|
333
|
-
* 返回云开发web-sdk初始化后的实例(无需关心tcb环境信息及认证登录的处理), 即 tcb.init 后返回的对象, 可用该对象直接调用tcb的各种能力
|
|
334
|
-
*/
|
|
335
131
|
function getCloudInstance(): Promise<CloudInstance>;
|
|
336
132
|
|
|
337
133
|
}
|
|
338
134
|
|
|
339
|
-
|
|
340
|
-
* 平台工具方法集合
|
|
341
|
-
*/
|
|
135
|
+
// $w.utils
|
|
342
136
|
namespace utils {
|
|
343
137
|
interface navigatorOptions {
|
|
344
|
-
/**
|
|
345
|
-
* 子应用包地址,例如 packages/subapp
|
|
346
|
-
*/
|
|
347
138
|
packageName: string;
|
|
348
|
-
/**
|
|
349
|
-
* 页面 ID
|
|
350
|
-
*/
|
|
351
139
|
pageId: string;
|
|
352
140
|
data?: Record<string, any>;
|
|
353
|
-
/**
|
|
354
|
-
* query object 对象
|
|
355
|
-
*/
|
|
356
141
|
params?: Record<string, any>;
|
|
357
142
|
events?: Record<string, (data: any) => void>;
|
|
358
143
|
success(res: any);
|
|
@@ -361,61 +146,31 @@ function getCloudInstance(): Promise<CloudInstance>;
|
|
|
361
146
|
}
|
|
362
147
|
|
|
363
148
|
interface navigateBackOptions {
|
|
364
|
-
/**
|
|
365
|
-
* 返回的页面数,如果 delta 大于现有页面数,则返回到首页。
|
|
366
|
-
*/
|
|
367
149
|
delta: number;
|
|
368
150
|
}
|
|
369
151
|
|
|
370
|
-
|
|
371
|
-
* 显示提示框
|
|
372
|
-
*/
|
|
152
|
+
// 显示提示
|
|
373
153
|
function showToast(options);
|
|
374
154
|
|
|
375
|
-
|
|
376
|
-
* 显示全局加载中提示
|
|
377
|
-
*/
|
|
155
|
+
// 显示 loading 提示
|
|
378
156
|
function showLoading(options);
|
|
379
157
|
|
|
380
|
-
|
|
381
|
-
* 隐藏全局加载中提示
|
|
382
|
-
*/
|
|
158
|
+
// 隐藏 loading 提示
|
|
383
159
|
function hideLoading(options);
|
|
384
160
|
|
|
385
|
-
|
|
386
|
-
* 显示模态弹框
|
|
387
|
-
*/
|
|
161
|
+
// 显示模态提示
|
|
388
162
|
function showModal(options);
|
|
389
163
|
|
|
390
|
-
|
|
391
|
-
* 拨打电话
|
|
392
|
-
*/
|
|
164
|
+
// 拨打电话
|
|
393
165
|
function callPhone(options);
|
|
394
166
|
|
|
395
|
-
|
|
396
|
-
* 扫描二维码
|
|
397
|
-
*/
|
|
167
|
+
// sacnCode
|
|
398
168
|
function scanCode(options: {
|
|
399
|
-
/**
|
|
400
|
-
* 是否只能从相机扫码,不允许从相册选择图片
|
|
401
|
-
*/
|
|
402
169
|
onlyFromCamera?: boolean;
|
|
403
170
|
enableDefaultBehavior?: boolean;
|
|
404
|
-
/**
|
|
405
|
-
* 扫码类型
|
|
406
|
-
*/
|
|
407
171
|
scanType?: ('barCode' | 'qrCode')[];
|
|
408
|
-
/**
|
|
409
|
-
* 接口调用成功的回调函数
|
|
410
|
-
*/
|
|
411
172
|
success?: (res: { result: string; scanType: string }) => void;
|
|
412
|
-
/**
|
|
413
|
-
* 接口调用失败的回调函数
|
|
414
|
-
*/
|
|
415
173
|
fail?: (err: Error) => void;
|
|
416
|
-
/**
|
|
417
|
-
* 接口调用结束的回调函数(调用成功、失败都会执行)
|
|
418
|
-
*/
|
|
419
174
|
complete?: () => void;
|
|
420
175
|
}): Promise<ScanCodeResult> | ScanCodeResult;
|
|
421
176
|
|
|
@@ -479,31 +234,14 @@ function createInterstitialAd(options);
|
|
|
479
234
|
// 特制路由
|
|
480
235
|
function navigateTo(options: navigatorOptions);
|
|
481
236
|
|
|
482
|
-
/**
|
|
483
|
-
* 关闭当前页面,跳转到应用内的某个页面
|
|
484
|
-
*/
|
|
485
237
|
function redirectTo(options: navigatorOptions);
|
|
486
238
|
|
|
487
|
-
/**
|
|
488
|
-
* 关闭所有页面,打开到应用内的某个页面
|
|
489
|
-
*/
|
|
490
239
|
function reLaunch(options: navigatorOptions);
|
|
491
240
|
|
|
492
|
-
/**
|
|
493
|
-
* 返回首页
|
|
494
|
-
*/
|
|
495
241
|
function relaunchHome();
|
|
496
242
|
|
|
497
|
-
/**
|
|
498
|
-
* 关闭当前页面,返回上一页面或多级页面
|
|
499
|
-
*/
|
|
500
243
|
function navigateBack(options: navigateBackOptions);
|
|
501
244
|
|
|
502
|
-
/**
|
|
503
|
-
* 格式化枚举
|
|
504
|
-
*/
|
|
505
|
-
function formatEnum(path, optionname, app);
|
|
506
|
-
|
|
507
245
|
}
|
|
508
246
|
|
|
509
247
|
// $w.device
|
|
@@ -569,95 +307,14 @@ const platforms: ('WEB' | 'MOBILEWEB' | 'PCWEB' | 'MP')[];
|
|
|
569
307
|
|
|
570
308
|
}
|
|
571
309
|
|
|
572
|
-
|
|
573
|
-
* 绝对值
|
|
574
|
-
*
|
|
575
|
-
* @remarks
|
|
576
|
-
* 计算传入数字的绝对值
|
|
577
|
-
*
|
|
578
|
-
* @privateForWeDa
|
|
579
|
-
* {"group": "formula", "displayType": "function", "displayName": "绝对值", "insertText": "ABS(1)", "subGroup": "calculation", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "计算传入数字的绝对值" , "definition": "ABS(数字):数字"}
|
|
580
|
-
*/
|
|
581
|
-
function ABS(num: number): number;
|
|
582
|
-
/**
|
|
583
|
-
* 最小值
|
|
584
|
-
*
|
|
585
|
-
* @remarks
|
|
586
|
-
* 返回一组数字中的最小值
|
|
587
|
-
*
|
|
588
|
-
* @privateForWeDa
|
|
589
|
-
* {"group": "formula", "displayType": "function", "displayName": "最小值", "insertText": "Min(1, 2)", "subGroup": "calculation", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回一组数字中的最小值" , "definition": "Min(数字1, [数字2, ...]):数字"}
|
|
590
|
-
*/
|
|
310
|
+
function ABS(num: number): number;
|
|
591
311
|
function Min(...args: number[]): number;
|
|
592
|
-
/**
|
|
593
|
-
* 最大值
|
|
594
|
-
*
|
|
595
|
-
* @remarks
|
|
596
|
-
* 返回一组数字中的最大值
|
|
597
|
-
*
|
|
598
|
-
* @privateForWeDa
|
|
599
|
-
* {"group": "formula", "displayType": "function", "displayName": "最大值", "insertText": "Max(1, 2)", "subGroup": "calculation", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回一组数字中的最大值" , "definition": "Max(数字1, [数字2, ...]):数字"}
|
|
600
|
-
*/
|
|
601
312
|
function Max(...args: number[]): number;
|
|
602
|
-
/**
|
|
603
|
-
* 平均值
|
|
604
|
-
*
|
|
605
|
-
* @remarks
|
|
606
|
-
* 返回一组数字中的平均值
|
|
607
|
-
*
|
|
608
|
-
* @privateForWeDa
|
|
609
|
-
* {"group": "formula", "displayType": "function", "displayName": "平均值", "insertText": "Average(1, 2)", "subGroup": "calculation", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回一组数字中的平均值" , "definition": "Average(数字1, [数字2, ...]):数字"}
|
|
610
|
-
*/
|
|
611
313
|
function Average(...args: number[]): number;
|
|
612
|
-
/**
|
|
613
|
-
* 向下取整
|
|
614
|
-
*
|
|
615
|
-
* @remarks
|
|
616
|
-
* 返回传入数字向下取整的结果
|
|
617
|
-
*
|
|
618
|
-
* @privateForWeDa
|
|
619
|
-
* {"group": "formula", "displayType": "function", "displayName": "向下取整", "insertText": "Floor(1)", "subGroup": "calculation", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回传入数字向下取整的结果" , "definition": "Floor(数字):数字"}
|
|
620
|
-
*/
|
|
621
314
|
function Floor(num: number): number;
|
|
622
|
-
/**
|
|
623
|
-
* 向上取整
|
|
624
|
-
*
|
|
625
|
-
* @remarks
|
|
626
|
-
* 返回传入数字向上取整的结果
|
|
627
|
-
*
|
|
628
|
-
* @privateForWeDa
|
|
629
|
-
* {"group": "formula", "displayType": "function", "displayName": "向上取整", "insertText": "Ceiling(1)", "subGroup": "calculation", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回传入数字向上取整的结果" , "definition": "Ceiling(数字):数字"}
|
|
630
|
-
*/
|
|
631
315
|
function Ceiling(num: number): number;
|
|
632
|
-
/**
|
|
633
|
-
* 四舍五入
|
|
634
|
-
*
|
|
635
|
-
* @remarks
|
|
636
|
-
* 返回传入数字四舍五入后的结果
|
|
637
|
-
*
|
|
638
|
-
* @privateForWeDa
|
|
639
|
-
* {"group": "formula", "displayType": "function", "displayName": "四舍五入", "insertText": "Round(1)", "subGroup": "calculation", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回传入数字四舍五入后的结果" , "definition": "Round(数字):数字"}
|
|
640
|
-
*/
|
|
641
316
|
function Round(num: number): number;
|
|
642
|
-
/**
|
|
643
|
-
* 求和
|
|
644
|
-
*
|
|
645
|
-
* @remarks
|
|
646
|
-
* 返回一组数字中的和
|
|
647
|
-
*
|
|
648
|
-
* @privateForWeDa
|
|
649
|
-
* {"group": "formula", "displayType": "function", "displayName": "求和", "insertText": "Sum(1, 2)", "subGroup": "calculation", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回一组数字中的和" , "definition": "Sum(数字1, [数字2, ...]):数字"}
|
|
650
|
-
*/
|
|
651
317
|
function Sum(...args: number[]): number;
|
|
652
|
-
/**
|
|
653
|
-
* 随机数
|
|
654
|
-
*
|
|
655
|
-
* @remarks
|
|
656
|
-
* 返回一个指定范围的伪随机数,例如 Rand(10),返回一个范围在 10 以内的随机数
|
|
657
|
-
*
|
|
658
|
-
* @privateForWeDa
|
|
659
|
-
* {"group": "formula", "displayType": "function", "displayName": "随机数", "insertText": "Rand(1)", "subGroup": "calculation", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回一个指定范围的伪随机数,例如 Rand(10),返回一个范围在 10 以内的随机数" , "definition": "Rand(数字):数字"}
|
|
660
|
-
*/
|
|
661
318
|
function Rand(num: number): number;
|
|
662
319
|
|
|
663
320
|
interface IIfObjectParam {
|
|
@@ -665,368 +322,49 @@ condition: boolean;
|
|
|
665
322
|
consequent?: any;
|
|
666
323
|
alternate?: any;
|
|
667
324
|
}
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
*
|
|
674
|
-
* @privateForWeDa
|
|
675
|
-
* {"group": "formula", "displayType": "function", "displayName": "条件分支", "insertText": "If(true, '您好', 'hello')", "subGroup": "logic", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "按判断条件进行逻辑比较,满足时返回一个值,不满足时返回另一个值。" , "definition": "If(判断条件, 满足时返回的值, 不满足时返回的值):任何类型"}
|
|
676
|
-
*/
|
|
325
|
+
interface IIfObjectParam {
|
|
326
|
+
condition: boolean;
|
|
327
|
+
consequent?: any;
|
|
328
|
+
alternate?: any;
|
|
329
|
+
}
|
|
677
330
|
function If(params: IIfObjectParam): any;
|
|
678
331
|
function If(condition: boolean, consequent?: any, alternate?: any): any;
|
|
679
|
-
/**
|
|
680
|
-
* 是否为空
|
|
681
|
-
*
|
|
682
|
-
* @remarks
|
|
683
|
-
* 判断传入的文本是否为空
|
|
684
|
-
*
|
|
685
|
-
* @privateForWeDa
|
|
686
|
-
* {"group": "formula", "displayType": "function", "displayName": "是否为空", "insertText": "IsEmpty('hello')", "subGroup": "logic", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "判断传入的文本是否为空" , "definition": "IsEmpty(值):布尔值"}
|
|
687
|
-
*/
|
|
688
332
|
function IsEmpty(text: string | string[]): boolean;
|
|
689
|
-
/**
|
|
690
|
-
* 是否为null
|
|
691
|
-
*
|
|
692
|
-
* @remarks
|
|
693
|
-
* 判断传入的字段值是否包含数据,即不为 NULL
|
|
694
|
-
*
|
|
695
|
-
* @privateForWeDa
|
|
696
|
-
* {"group": "formula", "displayType": "function", "displayName": "是否为null", "insertText": "NotNull(null)", "subGroup": "logic", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "判断传入的字段值是否包含数据,即不为 NULL" , "definition": "NotNull(字段):布尔值"}
|
|
697
|
-
*/
|
|
698
333
|
function NotNull(val: any): boolean;
|
|
699
|
-
/**
|
|
700
|
-
* 与
|
|
701
|
-
*
|
|
702
|
-
* @remarks
|
|
703
|
-
* 用于确定所有判断条件是否为真
|
|
704
|
-
*
|
|
705
|
-
* @privateForWeDa
|
|
706
|
-
* {"group": "formula", "displayType": "function", "displayName": "与", "insertText": "And(true, false)", "subGroup": "logic", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "用于确定所有判断条件是否为真" , "definition": "And(判断条件1, [判断条件2,...]):布尔值"}
|
|
707
|
-
*/
|
|
708
334
|
function And(...args: boolean[]): boolean;
|
|
709
|
-
/**
|
|
710
|
-
* 或
|
|
711
|
-
*
|
|
712
|
-
* @remarks
|
|
713
|
-
* 任意一个判断条件为真,则结果为真;所有条件为否,结果才为否
|
|
714
|
-
*
|
|
715
|
-
* @privateForWeDa
|
|
716
|
-
* {"group": "formula", "displayType": "function", "displayName": "或", "insertText": "Or(true, false)", "subGroup": "logic", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "任意一个判断条件为真,则结果为真;所有条件为否,结果才为否" , "definition": "Or(判断条件1, [判断条件2,...]):布尔值"}
|
|
717
|
-
*/
|
|
718
335
|
function Or(...args: boolean[]): boolean;
|
|
719
336
|
|
|
720
|
-
/**
|
|
721
|
-
* 获取文本长度
|
|
722
|
-
*
|
|
723
|
-
* @remarks
|
|
724
|
-
* 获取传入文本的字符数
|
|
725
|
-
*
|
|
726
|
-
* @privateForWeDa
|
|
727
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取文本长度", "insertText": "Len('文本')", "subGroup": "text", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "获取传入文本的字符数" , "definition": "Len(文本):数字"}
|
|
728
|
-
*/
|
|
729
337
|
function Len(text: string): number;
|
|
730
|
-
/**
|
|
731
|
-
* 是否包含指定文本
|
|
732
|
-
*
|
|
733
|
-
* @remarks
|
|
734
|
-
* 判断文本 1 是否包含文本 2
|
|
735
|
-
*
|
|
736
|
-
* @privateForWeDa
|
|
737
|
-
* {"group": "formula", "displayType": "function", "displayName": "是否包含指定文本", "insertText": "Contains('文本1', '文本2')", "subGroup": "text", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "判断文本 1 是否包含文本 2" , "definition": "Contains(文本1, 文本2):布尔值"}
|
|
738
|
-
*/
|
|
739
338
|
function Contains(text1: string, text2: string): boolean;
|
|
740
|
-
/**
|
|
741
|
-
* 拆分文本
|
|
742
|
-
*
|
|
743
|
-
* @remarks
|
|
744
|
-
* 根据传入的文本 2,将文本 1 拆分成文本数组,例如 Split("张三,李四,王五", ",")
|
|
745
|
-
*
|
|
746
|
-
* @privateForWeDa
|
|
747
|
-
* {"group": "formula", "displayType": "function", "displayName": "拆分文本", "insertText": "Split('文本1', '文本2')", "subGroup": "text", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据传入的文本 2,将文本 1 拆分成文本数组,例如 Split('张三,李四,王五', ',')" , "definition": "Split(文本1,文本2):文本数组"}
|
|
748
|
-
*/
|
|
749
339
|
function Split(text1: string, text2: string): string[];
|
|
750
|
-
/**
|
|
751
|
-
* 删除开头/结尾空格和制表符
|
|
752
|
-
*
|
|
753
|
-
* @remarks
|
|
754
|
-
* 删除文本开头和结尾的所有空格和制表符,文本中间的空格和制表符不会删除
|
|
755
|
-
*
|
|
756
|
-
* @privateForWeDa
|
|
757
|
-
* {"group": "formula", "displayType": "function", "displayName": "删除开头/结尾空格和制表符", "insertText": "Trim('文本')", "subGroup": "text", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "删除文本开头和结尾的所有空格和制表符,文本中间的空格和制表符不会删除" , "definition": "Trim(文本):文本"}
|
|
758
|
-
*/
|
|
759
340
|
function Trim(text: string): string;
|
|
760
|
-
/**
|
|
761
|
-
* 转换为大写
|
|
762
|
-
*
|
|
763
|
-
* @remarks
|
|
764
|
-
* 将传入的文本转为全大写文本
|
|
765
|
-
*
|
|
766
|
-
* @privateForWeDa
|
|
767
|
-
* {"group": "formula", "displayType": "function", "displayName": "转换为大写", "insertText": "Upper('文本')", "subGroup": "text", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "将传入的文本转为全大写文本" , "definition": "Upper(文本):文本"}
|
|
768
|
-
*/
|
|
769
341
|
function Upper(text: string): string;
|
|
770
|
-
/**
|
|
771
|
-
* 转换为小写
|
|
772
|
-
*
|
|
773
|
-
* @remarks
|
|
774
|
-
* 将传入的文本转为全小写文本
|
|
775
|
-
*
|
|
776
|
-
* @privateForWeDa
|
|
777
|
-
* {"group": "formula", "displayType": "function", "displayName": "转换为小写", "insertText": "Lower('文本')", "subGroup": "text", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "将传入的文本转为全小写文本" , "definition": "Lower(文本):文本"}
|
|
778
|
-
*/
|
|
779
342
|
function Lower(text: string): string;
|
|
780
|
-
/**
|
|
781
|
-
* 文本拼接
|
|
782
|
-
*
|
|
783
|
-
* @remarks
|
|
784
|
-
* 返回多个文本拼接后的新文本
|
|
785
|
-
*
|
|
786
|
-
* @privateForWeDa
|
|
787
|
-
* {"group": "formula", "displayType": "function", "displayName": "文本拼接", "insertText": "Concat('文本1', '文本2')", "subGroup": "text", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回多个文本拼接后的新文本" , "definition": "Concat(文本1, [文本2,...]):文本"}
|
|
788
|
-
*/
|
|
789
343
|
function Concat(...text: string[]): string;
|
|
790
344
|
|
|
791
|
-
/**
|
|
792
|
-
* 获取现在时间
|
|
793
|
-
*
|
|
794
|
-
* @remarks
|
|
795
|
-
* 返回当前系统时间,通常与其他日期时间函数搭配使用
|
|
796
|
-
*
|
|
797
|
-
* @privateForWeDa
|
|
798
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取现在时间", "insertText": "Now()", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回当前系统时间,通常与其他日期时间函数搭配使用" , "definition": "Now():日期时间"}
|
|
799
|
-
*/
|
|
800
345
|
function Now(): number;
|
|
801
|
-
/**
|
|
802
|
-
* 获取时间戳
|
|
803
|
-
*
|
|
804
|
-
* @remarks
|
|
805
|
-
* 根据输入的日期时间返回时间戳
|
|
806
|
-
*
|
|
807
|
-
* @privateForWeDa
|
|
808
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取时间戳", "insertText": "Timestamp(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的日期时间返回时间戳" , "definition": "Timestamp(日期时间):日期时间"}
|
|
809
|
-
*/
|
|
810
346
|
function Timestamp(arg: number | string | Date): number;
|
|
811
|
-
/**
|
|
812
|
-
* 获取秒数
|
|
813
|
-
*
|
|
814
|
-
* @remarks
|
|
815
|
-
* 根据输入的日期时间返回该时间的秒数
|
|
816
|
-
*
|
|
817
|
-
* @privateForWeDa
|
|
818
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取秒数", "insertText": "Second(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的日期时间返回该时间的秒数" , "definition": "Second(日期时间):数字"}
|
|
819
|
-
*/
|
|
820
347
|
function Second(arg: number | string | Date): number;
|
|
821
|
-
/**
|
|
822
|
-
* 获取分钟数
|
|
823
|
-
*
|
|
824
|
-
* @remarks
|
|
825
|
-
* 根据输入的日期时间返回该时间的分钟部分
|
|
826
|
-
*
|
|
827
|
-
* @privateForWeDa
|
|
828
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取分钟数", "insertText": "Minute(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的日期时间返回该时间的分钟部分" , "definition": "Minute(日期时间):数字"}
|
|
829
|
-
*/
|
|
830
348
|
function Minute(arg: number | string | Date): number;
|
|
831
|
-
/**
|
|
832
|
-
* 获取小时数
|
|
833
|
-
*
|
|
834
|
-
* @remarks
|
|
835
|
-
* 根据输入的日期时间返回该时间的小时部分,24小时制
|
|
836
|
-
*
|
|
837
|
-
* @privateForWeDa
|
|
838
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取小时数", "insertText": "Hour(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的日期时间返回该时间的小时部分,24小时制" , "definition": "Hour(日期时间):数字"}
|
|
839
|
-
*/
|
|
840
349
|
function Hour(arg: number | string | Date): number;
|
|
841
|
-
/**
|
|
842
|
-
* 获取天数
|
|
843
|
-
*
|
|
844
|
-
* @remarks
|
|
845
|
-
* 根据输入的日期时间返回该时间的日部分,范围为 1-31
|
|
846
|
-
*
|
|
847
|
-
* @privateForWeDa
|
|
848
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取天数", "insertText": "Day(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的日期时间返回该时间的日部分,范围为 1-31" , "definition": "Day(日期时间):数字"}
|
|
849
|
-
*/
|
|
850
350
|
function Day(arg: number | string | Date): number;
|
|
851
|
-
/**
|
|
852
|
-
* 获取星期数
|
|
853
|
-
*
|
|
854
|
-
* @remarks
|
|
855
|
-
* 根据输入的日期时间返回该时间的星期数
|
|
856
|
-
*
|
|
857
|
-
* @privateForWeDa
|
|
858
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取星期数", "insertText": "DayOfWeek(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的日期时间返回该时间的星期数" , "definition": "DayOfWeek(日期时间):数字"}
|
|
859
|
-
*/
|
|
860
351
|
function DayOfWeek(arg: number | string | Date): number;
|
|
861
|
-
/**
|
|
862
|
-
* 获取月数
|
|
863
|
-
*
|
|
864
|
-
* @remarks
|
|
865
|
-
* 根据输入的日期时间返回该时间的月份
|
|
866
|
-
*
|
|
867
|
-
* @privateForWeDa
|
|
868
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取月数", "insertText": "Month(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的日期时间返回该时间的月份" , "definition": "Month(日期时间):数字"}
|
|
869
|
-
*/
|
|
870
352
|
function Month(arg: number | string | Date): number;
|
|
871
|
-
/**
|
|
872
|
-
* 获取年份
|
|
873
|
-
*
|
|
874
|
-
* @remarks
|
|
875
|
-
* 根据输入的日期时间返回该时间的年份
|
|
876
|
-
*
|
|
877
|
-
* @privateForWeDa
|
|
878
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取年份", "insertText": "Year(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的日期时间返回该时间的年份" , "definition": "Year(日期时间):数字"}
|
|
879
|
-
*/
|
|
880
353
|
function Year(arg: number | string | Date): number;
|
|
881
|
-
/**
|
|
882
|
-
* 使用年月日创建日期时间
|
|
883
|
-
*
|
|
884
|
-
* @remarks
|
|
885
|
-
* 根据输入的年月日数值返回一个日期类型的数据,例如 GetDate(2017,3,24)
|
|
886
|
-
*
|
|
887
|
-
* @privateForWeDa
|
|
888
|
-
* {"group": "formula", "displayType": "function", "displayName": "使用年月日创建日期时间", "insertText": "GetDate(2011, 7, 2)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的年月日数值返回一个日期类型的数据,例如 GetDate(2017,3,24)" , "definition": "GetDate(数字,数字,数字):日期时间"}
|
|
889
|
-
*/
|
|
890
354
|
function GetDate(year: number, month: number, day: number): number;
|
|
891
|
-
/**
|
|
892
|
-
* 使用时间日期文本创建日期时间
|
|
893
|
-
*
|
|
894
|
-
* @remarks
|
|
895
|
-
* 将日期时间文本根据指定格式转化为日期时间,例如 DateTimeValue("2021-12-11 01:19:12", "yyyy-MM-dd HH:mm:ss")
|
|
896
|
-
*
|
|
897
|
-
* @privateForWeDa
|
|
898
|
-
* {"group": "formula", "displayType": "function", "displayName": "使用时间日期文本创建日期时间", "insertText": "DateTimeValue('2011-07-02', 'YYYY:MM:DD')", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "将日期时间文本根据指定格式转化为日期时间,例如 DateTimeValue('2021-12-11 01:19:12', 'yyyy-MM-dd HH:mm:ss')" , "definition": "DateTimeValue(文本, 文本):日期时间"}
|
|
899
|
-
*/
|
|
900
355
|
function DateTimeValue(arg: string, val: string): number;
|
|
901
|
-
/**
|
|
902
|
-
* 计算年龄
|
|
903
|
-
*
|
|
904
|
-
* @remarks
|
|
905
|
-
* 根据输入的两个日期时间计算出年龄,例如 Age(Date(2017,3,24), Date(2021,3,24))
|
|
906
|
-
*
|
|
907
|
-
* @privateForWeDa
|
|
908
|
-
* {"group": "formula", "displayType": "function", "displayName": "计算年龄", "insertText": "Age(1661334203345, 1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的两个日期时间计算出年龄,例如 Age(Date(2017,3,24), Date(2021,3,24))" , "definition": "Age(日期时间,日期时间):数字"}
|
|
909
|
-
*/
|
|
910
356
|
function Age(arg: number | string | Date, val: number | string | Date): number;
|
|
911
|
-
/**
|
|
912
|
-
* 计算当前年龄
|
|
913
|
-
*
|
|
914
|
-
* @remarks
|
|
915
|
-
* 计算当前年龄,例如 AgeOfNow(Date(2017,3,24))
|
|
916
|
-
*
|
|
917
|
-
* @privateForWeDa
|
|
918
|
-
* {"group": "formula", "displayType": "function", "displayName": "计算当前年龄", "insertText": "AgeOfNow(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "计算当前年龄,例如 AgeOfNow(Date(2017,3,24))" , "definition": "AgeOfNow(日期时间):数字"}
|
|
919
|
-
*/
|
|
920
357
|
function AgeOfNow(arg: number | string | Date): number;
|
|
921
|
-
/**
|
|
922
|
-
* 增加 X 天
|
|
923
|
-
*
|
|
924
|
-
* @remarks
|
|
925
|
-
* 在传入的日期时间上增加 X 天,支持负数
|
|
926
|
-
*
|
|
927
|
-
* @privateForWeDa
|
|
928
|
-
* {"group": "formula", "displayType": "function", "displayName": "增加 X 天", "insertText": "DateAdd(1661334203345, 1)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "在传入的日期时间上增加 X 天,支持负数" , "definition": "DateAdd(日期时间, 数字):日期时间"}
|
|
929
|
-
*/
|
|
930
358
|
function DateAdd(arg: number | string | Date, day: number): number;
|
|
931
|
-
/**
|
|
932
|
-
* 增加 X 月
|
|
933
|
-
*
|
|
934
|
-
* @remarks
|
|
935
|
-
* 在传入的日期和时间上增加 X 月,支持负数
|
|
936
|
-
*
|
|
937
|
-
* @privateForWeDa
|
|
938
|
-
* {"group": "formula", "displayType": "function", "displayName": "增加 X 月", "insertText": "MonthAdd(1661334203345, 1)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "在传入的日期和时间上增加 X 月,支持负数" , "definition": "MonthAdd(日期时间, 数字):日期时间"}
|
|
939
|
-
*/
|
|
940
359
|
function MonthAdd(arg: number | string | Date, month: number): number;
|
|
941
|
-
/**
|
|
942
|
-
* 增加 X 年
|
|
943
|
-
*
|
|
944
|
-
* @remarks
|
|
945
|
-
* 在传入的日期和时间上增加 X 年,支持负数
|
|
946
|
-
*
|
|
947
|
-
* @privateForWeDa
|
|
948
|
-
* {"group": "formula", "displayType": "function", "displayName": "增加 X 年", "insertText": "YearAdd(1661334203345, 1)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "在传入的日期和时间上增加 X 年,支持负数" , "definition": "YearAdd(日期时间, 数字):日期时间"}
|
|
949
|
-
*/
|
|
950
360
|
function YearAdd(arg: number | string | Date, year: number): number;
|
|
951
|
-
/**
|
|
952
|
-
* 天数差
|
|
953
|
-
*
|
|
954
|
-
* @remarks
|
|
955
|
-
* 返回两个日期时间字段之间的天数差,如果为同一天,差数为零
|
|
956
|
-
*
|
|
957
|
-
* @privateForWeDa
|
|
958
|
-
* {"group": "formula", "displayType": "function", "displayName": "天数差", "insertText": "DateDiff(1661334203345, 1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回两个日期时间字段之间的天数差,如果为同一天,差数为零" , "definition": "DateDiff(日期时间, 日期时间):数字"}
|
|
959
|
-
*/
|
|
960
361
|
function DateDiff(startDay: number | string | Date, endDay: number | string | Date): number;
|
|
961
|
-
/**
|
|
962
|
-
* 小时差
|
|
963
|
-
*
|
|
964
|
-
* @remarks
|
|
965
|
-
* 返回两个日期时间字段之间的小时差,如果为同一小时,差数为零
|
|
966
|
-
*
|
|
967
|
-
* @privateForWeDa
|
|
968
|
-
* {"group": "formula", "displayType": "function", "displayName": "小时差", "insertText": "HourDiff(1661334203345, 1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回两个日期时间字段之间的小时差,如果为同一小时,差数为零" , "definition": "HourDiff(日期时间, 日期时间):数字"}
|
|
969
|
-
*/
|
|
970
362
|
function HourDiff(startDay: number | string | Date, endDay: number | string | Date): number;
|
|
971
|
-
/**
|
|
972
|
-
* 分钟差
|
|
973
|
-
*
|
|
974
|
-
* @remarks
|
|
975
|
-
* 返回两个日期时间字段之间的分钟差,如果为同一分钟,差数为零
|
|
976
|
-
*
|
|
977
|
-
* @privateForWeDa
|
|
978
|
-
* {"group": "formula", "displayType": "function", "displayName": "分钟差", "insertText": "MinuteDiff(1661334203345, 1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回两个日期时间字段之间的分钟差,如果为同一分钟,差数为零" , "definition": "MinuteDiff(日期时间, 日期时间):数字"}
|
|
979
|
-
*/
|
|
980
363
|
function MinuteDiff(startDay: number | string | Date, endDay: number | string | Date): number;
|
|
981
|
-
/**
|
|
982
|
-
* 秒数差
|
|
983
|
-
*
|
|
984
|
-
* @remarks
|
|
985
|
-
* 返回两个日期时间字段之间的天数差,如果为同一天,差数为零
|
|
986
|
-
*
|
|
987
|
-
* @privateForWeDa
|
|
988
|
-
* {"group": "formula", "displayType": "function", "displayName": "秒数差", "insertText": "SecondDiff(1661334203345, 1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回两个日期时间字段之间的天数差,如果为同一天,差数为零" , "definition": "SecondDiff(日期时间, 日期时间):数字"}
|
|
989
|
-
*/
|
|
990
364
|
function SecondDiff(startDay: number | string | Date, endDay: number | string | Date): number;
|
|
991
|
-
/**
|
|
992
|
-
* 月数差
|
|
993
|
-
*
|
|
994
|
-
* @remarks
|
|
995
|
-
* 返回两个日期时间字段之间的月数差,如果为同一月,差数为零
|
|
996
|
-
*
|
|
997
|
-
* @privateForWeDa
|
|
998
|
-
* {"group": "formula", "displayType": "function", "displayName": "月数差", "insertText": "MonthDiff(1661334203345, 1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回两个日期时间字段之间的月数差,如果为同一月,差数为零" , "definition": "MonthDiff(日期时间, 日期时间):数字"}
|
|
999
|
-
*/
|
|
1000
365
|
function MonthDiff(startDay: number | string | Date, endDay: number | string | Date): number;
|
|
1001
|
-
/**
|
|
1002
|
-
* 年数差
|
|
1003
|
-
*
|
|
1004
|
-
* @remarks
|
|
1005
|
-
* 返回两个日期时间字段之间的年数差,如果为同一年,差数为零
|
|
1006
|
-
*
|
|
1007
|
-
* @privateForWeDa
|
|
1008
|
-
* {"group": "formula", "displayType": "function", "displayName": "年数差", "insertText": "YearDiff(1661334203345, 1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回两个日期时间字段之间的年数差,如果为同一年,差数为零" , "definition": "YearDiff(日期时间, 日期时间):数字"}
|
|
1009
|
-
*/
|
|
1010
366
|
function YearDiff(startDay: number | string | Date, endDay: number | string | Date): number;
|
|
1011
|
-
/**
|
|
1012
|
-
* 日期时间格式化
|
|
1013
|
-
*
|
|
1014
|
-
* @remarks
|
|
1015
|
-
* 格式化日期时间为指定格式的文本,例如 DateText(Date(2017,3,24), "yyyy-MM-dd HH:mm:ss")
|
|
1016
|
-
*
|
|
1017
|
-
* @privateForWeDa
|
|
1018
|
-
* {"group": "formula", "displayType": "function", "displayName": "日期时间格式化", "insertText": "DateText(1661334203345, 'YYYY-MM-DD HH:mm:ss')", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "格式化日期时间为指定格式的文本,例如 DateText(Date(2017,3,24), 'yyyy-MM-dd HH:mm:ss')" , "definition": "DateText(日期时间, 文本):文本"}
|
|
1019
|
-
*/
|
|
1020
367
|
function DateText(createdTime: number | string | Date, text: string): string;
|
|
1021
|
-
/**
|
|
1022
|
-
* 是否为今天
|
|
1023
|
-
*
|
|
1024
|
-
* @remarks
|
|
1025
|
-
* 判断传入的日期时间是否为今天,例如 IsToday(Date(2022,4,8))
|
|
1026
|
-
*
|
|
1027
|
-
* @privateForWeDa
|
|
1028
|
-
* {"group": "formula", "displayType": "function", "displayName": "是否为今天", "insertText": "IsToday(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "判断传入的日期时间是否为今天,例如 IsToday(Date(2022,4,8))" , "definition": "IsToday(日期时间):布尔值"}
|
|
1029
|
-
*/
|
|
1030
368
|
function IsToday(date: number | string | Date): boolean;
|
|
1031
369
|
|
|
1032
370
|
|
|
@@ -1050,47 +388,28 @@ declare const forItems = $for;
|
|
|
1050
388
|
|
|
1051
389
|
// $page Begin
|
|
1052
390
|
declare namespace $page {
|
|
1053
|
-
|
|
1054
|
-
* 当前页面的 id
|
|
1055
|
-
*/
|
|
1056
|
-
const id: string;
|
|
391
|
+
const id: string;
|
|
1057
392
|
const label: string;
|
|
1058
393
|
const path: string;
|
|
1059
394
|
|
|
1060
|
-
/**
|
|
1061
|
-
* 页面数据对象
|
|
1062
|
-
*/
|
|
1063
395
|
namespace dataset {
|
|
1064
|
-
/**
|
|
1065
|
-
* 页面变量
|
|
1066
|
-
*/
|
|
1067
396
|
const state: {
|
|
1068
397
|
// Page State Inner Begin
|
|
1069
398
|
// Page State 页面变量 - Don't touch me
|
|
1070
399
|
// Page State Inner End
|
|
1071
400
|
};
|
|
1072
|
-
/**
|
|
1073
|
-
* 页面参数
|
|
1074
|
-
*/
|
|
1075
401
|
const params: {
|
|
1076
402
|
// Page Param Inner Begin
|
|
1077
403
|
// Page Param 页面参数 - Don't touch me
|
|
1078
404
|
// Page Param Inner End
|
|
1079
405
|
};
|
|
1080
406
|
}
|
|
1081
|
-
|
|
1082
|
-
/**
|
|
1083
|
-
* 页面定义 handler 方法
|
|
1084
|
-
*/
|
|
1085
407
|
namespace handler {
|
|
1086
408
|
// Page Handler Inner Begin
|
|
1087
409
|
// Page Handler 页面方法 - Don't touch me
|
|
1088
410
|
// Page Handler Inner End
|
|
1089
411
|
}
|
|
1090
412
|
|
|
1091
|
-
/**
|
|
1092
|
-
* 设置页面变量
|
|
1093
|
-
*/
|
|
1094
413
|
function setState(userSetState: Record<string, any>): void;
|
|
1095
414
|
|
|
1096
415
|
}
|
|
@@ -1130,95 +449,14 @@ declare namespace $comp {
|
|
|
1130
449
|
|
|
1131
450
|
// Global Formula Begin
|
|
1132
451
|
|
|
1133
|
-
/**
|
|
1134
|
-
* 绝对值
|
|
1135
|
-
*
|
|
1136
|
-
* @remarks
|
|
1137
|
-
* 计算传入数字的绝对值
|
|
1138
|
-
*
|
|
1139
|
-
* @privateForWeDa
|
|
1140
|
-
* {"group": "formula", "displayType": "function", "displayName": "绝对值", "insertText": "ABS(1)", "subGroup": "calculation", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "计算传入数字的绝对值" , "definition": "ABS(数字):数字"}
|
|
1141
|
-
*/
|
|
1142
452
|
declare function ABS(num: number): number;
|
|
1143
|
-
/**
|
|
1144
|
-
* 最小值
|
|
1145
|
-
*
|
|
1146
|
-
* @remarks
|
|
1147
|
-
* 返回一组数字中的最小值
|
|
1148
|
-
*
|
|
1149
|
-
* @privateForWeDa
|
|
1150
|
-
* {"group": "formula", "displayType": "function", "displayName": "最小值", "insertText": "Min(1, 2)", "subGroup": "calculation", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回一组数字中的最小值" , "definition": "Min(数字1, [数字2, ...]):数字"}
|
|
1151
|
-
*/
|
|
1152
453
|
declare function Min(...args: number[]): number;
|
|
1153
|
-
/**
|
|
1154
|
-
* 最大值
|
|
1155
|
-
*
|
|
1156
|
-
* @remarks
|
|
1157
|
-
* 返回一组数字中的最大值
|
|
1158
|
-
*
|
|
1159
|
-
* @privateForWeDa
|
|
1160
|
-
* {"group": "formula", "displayType": "function", "displayName": "最大值", "insertText": "Max(1, 2)", "subGroup": "calculation", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回一组数字中的最大值" , "definition": "Max(数字1, [数字2, ...]):数字"}
|
|
1161
|
-
*/
|
|
1162
454
|
declare function Max(...args: number[]): number;
|
|
1163
|
-
/**
|
|
1164
|
-
* 平均值
|
|
1165
|
-
*
|
|
1166
|
-
* @remarks
|
|
1167
|
-
* 返回一组数字中的平均值
|
|
1168
|
-
*
|
|
1169
|
-
* @privateForWeDa
|
|
1170
|
-
* {"group": "formula", "displayType": "function", "displayName": "平均值", "insertText": "Average(1, 2)", "subGroup": "calculation", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回一组数字中的平均值" , "definition": "Average(数字1, [数字2, ...]):数字"}
|
|
1171
|
-
*/
|
|
1172
455
|
declare function Average(...args: number[]): number;
|
|
1173
|
-
/**
|
|
1174
|
-
* 向下取整
|
|
1175
|
-
*
|
|
1176
|
-
* @remarks
|
|
1177
|
-
* 返回传入数字向下取整的结果
|
|
1178
|
-
*
|
|
1179
|
-
* @privateForWeDa
|
|
1180
|
-
* {"group": "formula", "displayType": "function", "displayName": "向下取整", "insertText": "Floor(1)", "subGroup": "calculation", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回传入数字向下取整的结果" , "definition": "Floor(数字):数字"}
|
|
1181
|
-
*/
|
|
1182
456
|
declare function Floor(num: number): number;
|
|
1183
|
-
/**
|
|
1184
|
-
* 向上取整
|
|
1185
|
-
*
|
|
1186
|
-
* @remarks
|
|
1187
|
-
* 返回传入数字向上取整的结果
|
|
1188
|
-
*
|
|
1189
|
-
* @privateForWeDa
|
|
1190
|
-
* {"group": "formula", "displayType": "function", "displayName": "向上取整", "insertText": "Ceiling(1)", "subGroup": "calculation", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回传入数字向上取整的结果" , "definition": "Ceiling(数字):数字"}
|
|
1191
|
-
*/
|
|
1192
457
|
declare function Ceiling(num: number): number;
|
|
1193
|
-
/**
|
|
1194
|
-
* 四舍五入
|
|
1195
|
-
*
|
|
1196
|
-
* @remarks
|
|
1197
|
-
* 返回传入数字四舍五入后的结果
|
|
1198
|
-
*
|
|
1199
|
-
* @privateForWeDa
|
|
1200
|
-
* {"group": "formula", "displayType": "function", "displayName": "四舍五入", "insertText": "Round(1)", "subGroup": "calculation", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回传入数字四舍五入后的结果" , "definition": "Round(数字):数字"}
|
|
1201
|
-
*/
|
|
1202
458
|
declare function Round(num: number): number;
|
|
1203
|
-
/**
|
|
1204
|
-
* 求和
|
|
1205
|
-
*
|
|
1206
|
-
* @remarks
|
|
1207
|
-
* 返回一组数字中的和
|
|
1208
|
-
*
|
|
1209
|
-
* @privateForWeDa
|
|
1210
|
-
* {"group": "formula", "displayType": "function", "displayName": "求和", "insertText": "Sum(1, 2)", "subGroup": "calculation", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回一组数字中的和" , "definition": "Sum(数字1, [数字2, ...]):数字"}
|
|
1211
|
-
*/
|
|
1212
459
|
declare function Sum(...args: number[]): number;
|
|
1213
|
-
/**
|
|
1214
|
-
* 随机数
|
|
1215
|
-
*
|
|
1216
|
-
* @remarks
|
|
1217
|
-
* 返回一个指定范围的伪随机数,例如 Rand(10),返回一个范围在 10 以内的随机数
|
|
1218
|
-
*
|
|
1219
|
-
* @privateForWeDa
|
|
1220
|
-
* {"group": "formula", "displayType": "function", "displayName": "随机数", "insertText": "Rand(1)", "subGroup": "calculation", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回一个指定范围的伪随机数,例如 Rand(10),返回一个范围在 10 以内的随机数" , "definition": "Rand(数字):数字"}
|
|
1221
|
-
*/
|
|
1222
460
|
declare function Rand(num: number): number;
|
|
1223
461
|
|
|
1224
462
|
declare interface IIfObjectParam {
|
|
@@ -1226,368 +464,49 @@ condition: boolean;
|
|
|
1226
464
|
consequent?: any;
|
|
1227
465
|
alternate?: any;
|
|
1228
466
|
}
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
*
|
|
1235
|
-
* @privateForWeDa
|
|
1236
|
-
* {"group": "formula", "displayType": "function", "displayName": "条件分支", "insertText": "If(true, '您好', 'hello')", "subGroup": "logic", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "按判断条件进行逻辑比较,满足时返回一个值,不满足时返回另一个值。" , "definition": "If(判断条件, 满足时返回的值, 不满足时返回的值):任何类型"}
|
|
1237
|
-
*/
|
|
467
|
+
declare interface IIfObjectParam {
|
|
468
|
+
condition: boolean;
|
|
469
|
+
consequent?: any;
|
|
470
|
+
alternate?: any;
|
|
471
|
+
}
|
|
1238
472
|
declare function If(params: IIfObjectParam): any;
|
|
1239
473
|
declare function If(condition: boolean, consequent?: any, alternate?: any): any;
|
|
1240
|
-
/**
|
|
1241
|
-
* 是否为空
|
|
1242
|
-
*
|
|
1243
|
-
* @remarks
|
|
1244
|
-
* 判断传入的文本是否为空
|
|
1245
|
-
*
|
|
1246
|
-
* @privateForWeDa
|
|
1247
|
-
* {"group": "formula", "displayType": "function", "displayName": "是否为空", "insertText": "IsEmpty('hello')", "subGroup": "logic", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "判断传入的文本是否为空" , "definition": "IsEmpty(值):布尔值"}
|
|
1248
|
-
*/
|
|
1249
474
|
declare function IsEmpty(text: string | string[]): boolean;
|
|
1250
|
-
/**
|
|
1251
|
-
* 是否为null
|
|
1252
|
-
*
|
|
1253
|
-
* @remarks
|
|
1254
|
-
* 判断传入的字段值是否包含数据,即不为 NULL
|
|
1255
|
-
*
|
|
1256
|
-
* @privateForWeDa
|
|
1257
|
-
* {"group": "formula", "displayType": "function", "displayName": "是否为null", "insertText": "NotNull(null)", "subGroup": "logic", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "判断传入的字段值是否包含数据,即不为 NULL" , "definition": "NotNull(字段):布尔值"}
|
|
1258
|
-
*/
|
|
1259
475
|
declare function NotNull(val: any): boolean;
|
|
1260
|
-
/**
|
|
1261
|
-
* 与
|
|
1262
|
-
*
|
|
1263
|
-
* @remarks
|
|
1264
|
-
* 用于确定所有判断条件是否为真
|
|
1265
|
-
*
|
|
1266
|
-
* @privateForWeDa
|
|
1267
|
-
* {"group": "formula", "displayType": "function", "displayName": "与", "insertText": "And(true, false)", "subGroup": "logic", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "用于确定所有判断条件是否为真" , "definition": "And(判断条件1, [判断条件2,...]):布尔值"}
|
|
1268
|
-
*/
|
|
1269
476
|
declare function And(...args: boolean[]): boolean;
|
|
1270
|
-
/**
|
|
1271
|
-
* 或
|
|
1272
|
-
*
|
|
1273
|
-
* @remarks
|
|
1274
|
-
* 任意一个判断条件为真,则结果为真;所有条件为否,结果才为否
|
|
1275
|
-
*
|
|
1276
|
-
* @privateForWeDa
|
|
1277
|
-
* {"group": "formula", "displayType": "function", "displayName": "或", "insertText": "Or(true, false)", "subGroup": "logic", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "任意一个判断条件为真,则结果为真;所有条件为否,结果才为否" , "definition": "Or(判断条件1, [判断条件2,...]):布尔值"}
|
|
1278
|
-
*/
|
|
1279
477
|
declare function Or(...args: boolean[]): boolean;
|
|
1280
478
|
|
|
1281
|
-
/**
|
|
1282
|
-
* 获取文本长度
|
|
1283
|
-
*
|
|
1284
|
-
* @remarks
|
|
1285
|
-
* 获取传入文本的字符数
|
|
1286
|
-
*
|
|
1287
|
-
* @privateForWeDa
|
|
1288
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取文本长度", "insertText": "Len('文本')", "subGroup": "text", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "获取传入文本的字符数" , "definition": "Len(文本):数字"}
|
|
1289
|
-
*/
|
|
1290
479
|
declare function Len(text: string): number;
|
|
1291
|
-
/**
|
|
1292
|
-
* 是否包含指定文本
|
|
1293
|
-
*
|
|
1294
|
-
* @remarks
|
|
1295
|
-
* 判断文本 1 是否包含文本 2
|
|
1296
|
-
*
|
|
1297
|
-
* @privateForWeDa
|
|
1298
|
-
* {"group": "formula", "displayType": "function", "displayName": "是否包含指定文本", "insertText": "Contains('文本1', '文本2')", "subGroup": "text", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "判断文本 1 是否包含文本 2" , "definition": "Contains(文本1, 文本2):布尔值"}
|
|
1299
|
-
*/
|
|
1300
480
|
declare function Contains(text1: string, text2: string): boolean;
|
|
1301
|
-
/**
|
|
1302
|
-
* 拆分文本
|
|
1303
|
-
*
|
|
1304
|
-
* @remarks
|
|
1305
|
-
* 根据传入的文本 2,将文本 1 拆分成文本数组,例如 Split("张三,李四,王五", ",")
|
|
1306
|
-
*
|
|
1307
|
-
* @privateForWeDa
|
|
1308
|
-
* {"group": "formula", "displayType": "function", "displayName": "拆分文本", "insertText": "Split('文本1', '文本2')", "subGroup": "text", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据传入的文本 2,将文本 1 拆分成文本数组,例如 Split('张三,李四,王五', ',')" , "definition": "Split(文本1,文本2):文本数组"}
|
|
1309
|
-
*/
|
|
1310
481
|
declare function Split(text1: string, text2: string): string[];
|
|
1311
|
-
/**
|
|
1312
|
-
* 删除开头/结尾空格和制表符
|
|
1313
|
-
*
|
|
1314
|
-
* @remarks
|
|
1315
|
-
* 删除文本开头和结尾的所有空格和制表符,文本中间的空格和制表符不会删除
|
|
1316
|
-
*
|
|
1317
|
-
* @privateForWeDa
|
|
1318
|
-
* {"group": "formula", "displayType": "function", "displayName": "删除开头/结尾空格和制表符", "insertText": "Trim('文本')", "subGroup": "text", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "删除文本开头和结尾的所有空格和制表符,文本中间的空格和制表符不会删除" , "definition": "Trim(文本):文本"}
|
|
1319
|
-
*/
|
|
1320
482
|
declare function Trim(text: string): string;
|
|
1321
|
-
/**
|
|
1322
|
-
* 转换为大写
|
|
1323
|
-
*
|
|
1324
|
-
* @remarks
|
|
1325
|
-
* 将传入的文本转为全大写文本
|
|
1326
|
-
*
|
|
1327
|
-
* @privateForWeDa
|
|
1328
|
-
* {"group": "formula", "displayType": "function", "displayName": "转换为大写", "insertText": "Upper('文本')", "subGroup": "text", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "将传入的文本转为全大写文本" , "definition": "Upper(文本):文本"}
|
|
1329
|
-
*/
|
|
1330
483
|
declare function Upper(text: string): string;
|
|
1331
|
-
/**
|
|
1332
|
-
* 转换为小写
|
|
1333
|
-
*
|
|
1334
|
-
* @remarks
|
|
1335
|
-
* 将传入的文本转为全小写文本
|
|
1336
|
-
*
|
|
1337
|
-
* @privateForWeDa
|
|
1338
|
-
* {"group": "formula", "displayType": "function", "displayName": "转换为小写", "insertText": "Lower('文本')", "subGroup": "text", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "将传入的文本转为全小写文本" , "definition": "Lower(文本):文本"}
|
|
1339
|
-
*/
|
|
1340
484
|
declare function Lower(text: string): string;
|
|
1341
|
-
/**
|
|
1342
|
-
* 文本拼接
|
|
1343
|
-
*
|
|
1344
|
-
* @remarks
|
|
1345
|
-
* 返回多个文本拼接后的新文本
|
|
1346
|
-
*
|
|
1347
|
-
* @privateForWeDa
|
|
1348
|
-
* {"group": "formula", "displayType": "function", "displayName": "文本拼接", "insertText": "Concat('文本1', '文本2')", "subGroup": "text", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回多个文本拼接后的新文本" , "definition": "Concat(文本1, [文本2,...]):文本"}
|
|
1349
|
-
*/
|
|
1350
485
|
declare function Concat(...text: string[]): string;
|
|
1351
486
|
|
|
1352
|
-
/**
|
|
1353
|
-
* 获取现在时间
|
|
1354
|
-
*
|
|
1355
|
-
* @remarks
|
|
1356
|
-
* 返回当前系统时间,通常与其他日期时间函数搭配使用
|
|
1357
|
-
*
|
|
1358
|
-
* @privateForWeDa
|
|
1359
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取现在时间", "insertText": "Now()", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回当前系统时间,通常与其他日期时间函数搭配使用" , "definition": "Now():日期时间"}
|
|
1360
|
-
*/
|
|
1361
487
|
declare function Now(): number;
|
|
1362
|
-
/**
|
|
1363
|
-
* 获取时间戳
|
|
1364
|
-
*
|
|
1365
|
-
* @remarks
|
|
1366
|
-
* 根据输入的日期时间返回时间戳
|
|
1367
|
-
*
|
|
1368
|
-
* @privateForWeDa
|
|
1369
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取时间戳", "insertText": "Timestamp(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的日期时间返回时间戳" , "definition": "Timestamp(日期时间):日期时间"}
|
|
1370
|
-
*/
|
|
1371
488
|
declare function Timestamp(arg: number | string | Date): number;
|
|
1372
|
-
/**
|
|
1373
|
-
* 获取秒数
|
|
1374
|
-
*
|
|
1375
|
-
* @remarks
|
|
1376
|
-
* 根据输入的日期时间返回该时间的秒数
|
|
1377
|
-
*
|
|
1378
|
-
* @privateForWeDa
|
|
1379
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取秒数", "insertText": "Second(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的日期时间返回该时间的秒数" , "definition": "Second(日期时间):数字"}
|
|
1380
|
-
*/
|
|
1381
489
|
declare function Second(arg: number | string | Date): number;
|
|
1382
|
-
/**
|
|
1383
|
-
* 获取分钟数
|
|
1384
|
-
*
|
|
1385
|
-
* @remarks
|
|
1386
|
-
* 根据输入的日期时间返回该时间的分钟部分
|
|
1387
|
-
*
|
|
1388
|
-
* @privateForWeDa
|
|
1389
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取分钟数", "insertText": "Minute(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的日期时间返回该时间的分钟部分" , "definition": "Minute(日期时间):数字"}
|
|
1390
|
-
*/
|
|
1391
490
|
declare function Minute(arg: number | string | Date): number;
|
|
1392
|
-
/**
|
|
1393
|
-
* 获取小时数
|
|
1394
|
-
*
|
|
1395
|
-
* @remarks
|
|
1396
|
-
* 根据输入的日期时间返回该时间的小时部分,24小时制
|
|
1397
|
-
*
|
|
1398
|
-
* @privateForWeDa
|
|
1399
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取小时数", "insertText": "Hour(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的日期时间返回该时间的小时部分,24小时制" , "definition": "Hour(日期时间):数字"}
|
|
1400
|
-
*/
|
|
1401
491
|
declare function Hour(arg: number | string | Date): number;
|
|
1402
|
-
/**
|
|
1403
|
-
* 获取天数
|
|
1404
|
-
*
|
|
1405
|
-
* @remarks
|
|
1406
|
-
* 根据输入的日期时间返回该时间的日部分,范围为 1-31
|
|
1407
|
-
*
|
|
1408
|
-
* @privateForWeDa
|
|
1409
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取天数", "insertText": "Day(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的日期时间返回该时间的日部分,范围为 1-31" , "definition": "Day(日期时间):数字"}
|
|
1410
|
-
*/
|
|
1411
492
|
declare function Day(arg: number | string | Date): number;
|
|
1412
|
-
/**
|
|
1413
|
-
* 获取星期数
|
|
1414
|
-
*
|
|
1415
|
-
* @remarks
|
|
1416
|
-
* 根据输入的日期时间返回该时间的星期数
|
|
1417
|
-
*
|
|
1418
|
-
* @privateForWeDa
|
|
1419
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取星期数", "insertText": "DayOfWeek(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的日期时间返回该时间的星期数" , "definition": "DayOfWeek(日期时间):数字"}
|
|
1420
|
-
*/
|
|
1421
493
|
declare function DayOfWeek(arg: number | string | Date): number;
|
|
1422
|
-
/**
|
|
1423
|
-
* 获取月数
|
|
1424
|
-
*
|
|
1425
|
-
* @remarks
|
|
1426
|
-
* 根据输入的日期时间返回该时间的月份
|
|
1427
|
-
*
|
|
1428
|
-
* @privateForWeDa
|
|
1429
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取月数", "insertText": "Month(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的日期时间返回该时间的月份" , "definition": "Month(日期时间):数字"}
|
|
1430
|
-
*/
|
|
1431
494
|
declare function Month(arg: number | string | Date): number;
|
|
1432
|
-
/**
|
|
1433
|
-
* 获取年份
|
|
1434
|
-
*
|
|
1435
|
-
* @remarks
|
|
1436
|
-
* 根据输入的日期时间返回该时间的年份
|
|
1437
|
-
*
|
|
1438
|
-
* @privateForWeDa
|
|
1439
|
-
* {"group": "formula", "displayType": "function", "displayName": "获取年份", "insertText": "Year(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的日期时间返回该时间的年份" , "definition": "Year(日期时间):数字"}
|
|
1440
|
-
*/
|
|
1441
495
|
declare function Year(arg: number | string | Date): number;
|
|
1442
|
-
/**
|
|
1443
|
-
* 使用年月日创建日期时间
|
|
1444
|
-
*
|
|
1445
|
-
* @remarks
|
|
1446
|
-
* 根据输入的年月日数值返回一个日期类型的数据,例如 GetDate(2017,3,24)
|
|
1447
|
-
*
|
|
1448
|
-
* @privateForWeDa
|
|
1449
|
-
* {"group": "formula", "displayType": "function", "displayName": "使用年月日创建日期时间", "insertText": "GetDate(2011, 7, 2)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的年月日数值返回一个日期类型的数据,例如 GetDate(2017,3,24)" , "definition": "GetDate(数字,数字,数字):日期时间"}
|
|
1450
|
-
*/
|
|
1451
496
|
declare function GetDate(year: number, month: number, day: number): number;
|
|
1452
|
-
/**
|
|
1453
|
-
* 使用时间日期文本创建日期时间
|
|
1454
|
-
*
|
|
1455
|
-
* @remarks
|
|
1456
|
-
* 将日期时间文本根据指定格式转化为日期时间,例如 DateTimeValue("2021-12-11 01:19:12", "yyyy-MM-dd HH:mm:ss")
|
|
1457
|
-
*
|
|
1458
|
-
* @privateForWeDa
|
|
1459
|
-
* {"group": "formula", "displayType": "function", "displayName": "使用时间日期文本创建日期时间", "insertText": "DateTimeValue('2011-07-02', 'YYYY:MM:DD')", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "将日期时间文本根据指定格式转化为日期时间,例如 DateTimeValue('2021-12-11 01:19:12', 'yyyy-MM-dd HH:mm:ss')" , "definition": "DateTimeValue(文本, 文本):日期时间"}
|
|
1460
|
-
*/
|
|
1461
497
|
declare function DateTimeValue(arg: string, val: string): number;
|
|
1462
|
-
/**
|
|
1463
|
-
* 计算年龄
|
|
1464
|
-
*
|
|
1465
|
-
* @remarks
|
|
1466
|
-
* 根据输入的两个日期时间计算出年龄,例如 Age(Date(2017,3,24), Date(2021,3,24))
|
|
1467
|
-
*
|
|
1468
|
-
* @privateForWeDa
|
|
1469
|
-
* {"group": "formula", "displayType": "function", "displayName": "计算年龄", "insertText": "Age(1661334203345, 1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "根据输入的两个日期时间计算出年龄,例如 Age(Date(2017,3,24), Date(2021,3,24))" , "definition": "Age(日期时间,日期时间):数字"}
|
|
1470
|
-
*/
|
|
1471
498
|
declare function Age(arg: number | string | Date, val: number | string | Date): number;
|
|
1472
|
-
/**
|
|
1473
|
-
* 计算当前年龄
|
|
1474
|
-
*
|
|
1475
|
-
* @remarks
|
|
1476
|
-
* 计算当前年龄,例如 AgeOfNow(Date(2017,3,24))
|
|
1477
|
-
*
|
|
1478
|
-
* @privateForWeDa
|
|
1479
|
-
* {"group": "formula", "displayType": "function", "displayName": "计算当前年龄", "insertText": "AgeOfNow(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "计算当前年龄,例如 AgeOfNow(Date(2017,3,24))" , "definition": "AgeOfNow(日期时间):数字"}
|
|
1480
|
-
*/
|
|
1481
499
|
declare function AgeOfNow(arg: number | string | Date): number;
|
|
1482
|
-
/**
|
|
1483
|
-
* 增加 X 天
|
|
1484
|
-
*
|
|
1485
|
-
* @remarks
|
|
1486
|
-
* 在传入的日期时间上增加 X 天,支持负数
|
|
1487
|
-
*
|
|
1488
|
-
* @privateForWeDa
|
|
1489
|
-
* {"group": "formula", "displayType": "function", "displayName": "增加 X 天", "insertText": "DateAdd(1661334203345, 1)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "在传入的日期时间上增加 X 天,支持负数" , "definition": "DateAdd(日期时间, 数字):日期时间"}
|
|
1490
|
-
*/
|
|
1491
500
|
declare function DateAdd(arg: number | string | Date, day: number): number;
|
|
1492
|
-
/**
|
|
1493
|
-
* 增加 X 月
|
|
1494
|
-
*
|
|
1495
|
-
* @remarks
|
|
1496
|
-
* 在传入的日期和时间上增加 X 月,支持负数
|
|
1497
|
-
*
|
|
1498
|
-
* @privateForWeDa
|
|
1499
|
-
* {"group": "formula", "displayType": "function", "displayName": "增加 X 月", "insertText": "MonthAdd(1661334203345, 1)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "在传入的日期和时间上增加 X 月,支持负数" , "definition": "MonthAdd(日期时间, 数字):日期时间"}
|
|
1500
|
-
*/
|
|
1501
501
|
declare function MonthAdd(arg: number | string | Date, month: number): number;
|
|
1502
|
-
/**
|
|
1503
|
-
* 增加 X 年
|
|
1504
|
-
*
|
|
1505
|
-
* @remarks
|
|
1506
|
-
* 在传入的日期和时间上增加 X 年,支持负数
|
|
1507
|
-
*
|
|
1508
|
-
* @privateForWeDa
|
|
1509
|
-
* {"group": "formula", "displayType": "function", "displayName": "增加 X 年", "insertText": "YearAdd(1661334203345, 1)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "在传入的日期和时间上增加 X 年,支持负数" , "definition": "YearAdd(日期时间, 数字):日期时间"}
|
|
1510
|
-
*/
|
|
1511
502
|
declare function YearAdd(arg: number | string | Date, year: number): number;
|
|
1512
|
-
/**
|
|
1513
|
-
* 天数差
|
|
1514
|
-
*
|
|
1515
|
-
* @remarks
|
|
1516
|
-
* 返回两个日期时间字段之间的天数差,如果为同一天,差数为零
|
|
1517
|
-
*
|
|
1518
|
-
* @privateForWeDa
|
|
1519
|
-
* {"group": "formula", "displayType": "function", "displayName": "天数差", "insertText": "DateDiff(1661334203345, 1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回两个日期时间字段之间的天数差,如果为同一天,差数为零" , "definition": "DateDiff(日期时间, 日期时间):数字"}
|
|
1520
|
-
*/
|
|
1521
503
|
declare function DateDiff(startDay: number | string | Date, endDay: number | string | Date): number;
|
|
1522
|
-
/**
|
|
1523
|
-
* 小时差
|
|
1524
|
-
*
|
|
1525
|
-
* @remarks
|
|
1526
|
-
* 返回两个日期时间字段之间的小时差,如果为同一小时,差数为零
|
|
1527
|
-
*
|
|
1528
|
-
* @privateForWeDa
|
|
1529
|
-
* {"group": "formula", "displayType": "function", "displayName": "小时差", "insertText": "HourDiff(1661334203345, 1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回两个日期时间字段之间的小时差,如果为同一小时,差数为零" , "definition": "HourDiff(日期时间, 日期时间):数字"}
|
|
1530
|
-
*/
|
|
1531
504
|
declare function HourDiff(startDay: number | string | Date, endDay: number | string | Date): number;
|
|
1532
|
-
/**
|
|
1533
|
-
* 分钟差
|
|
1534
|
-
*
|
|
1535
|
-
* @remarks
|
|
1536
|
-
* 返回两个日期时间字段之间的分钟差,如果为同一分钟,差数为零
|
|
1537
|
-
*
|
|
1538
|
-
* @privateForWeDa
|
|
1539
|
-
* {"group": "formula", "displayType": "function", "displayName": "分钟差", "insertText": "MinuteDiff(1661334203345, 1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回两个日期时间字段之间的分钟差,如果为同一分钟,差数为零" , "definition": "MinuteDiff(日期时间, 日期时间):数字"}
|
|
1540
|
-
*/
|
|
1541
505
|
declare function MinuteDiff(startDay: number | string | Date, endDay: number | string | Date): number;
|
|
1542
|
-
/**
|
|
1543
|
-
* 秒数差
|
|
1544
|
-
*
|
|
1545
|
-
* @remarks
|
|
1546
|
-
* 返回两个日期时间字段之间的天数差,如果为同一天,差数为零
|
|
1547
|
-
*
|
|
1548
|
-
* @privateForWeDa
|
|
1549
|
-
* {"group": "formula", "displayType": "function", "displayName": "秒数差", "insertText": "SecondDiff(1661334203345, 1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回两个日期时间字段之间的天数差,如果为同一天,差数为零" , "definition": "SecondDiff(日期时间, 日期时间):数字"}
|
|
1550
|
-
*/
|
|
1551
506
|
declare function SecondDiff(startDay: number | string | Date, endDay: number | string | Date): number;
|
|
1552
|
-
/**
|
|
1553
|
-
* 月数差
|
|
1554
|
-
*
|
|
1555
|
-
* @remarks
|
|
1556
|
-
* 返回两个日期时间字段之间的月数差,如果为同一月,差数为零
|
|
1557
|
-
*
|
|
1558
|
-
* @privateForWeDa
|
|
1559
|
-
* {"group": "formula", "displayType": "function", "displayName": "月数差", "insertText": "MonthDiff(1661334203345, 1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回两个日期时间字段之间的月数差,如果为同一月,差数为零" , "definition": "MonthDiff(日期时间, 日期时间):数字"}
|
|
1560
|
-
*/
|
|
1561
507
|
declare function MonthDiff(startDay: number | string | Date, endDay: number | string | Date): number;
|
|
1562
|
-
/**
|
|
1563
|
-
* 年数差
|
|
1564
|
-
*
|
|
1565
|
-
* @remarks
|
|
1566
|
-
* 返回两个日期时间字段之间的年数差,如果为同一年,差数为零
|
|
1567
|
-
*
|
|
1568
|
-
* @privateForWeDa
|
|
1569
|
-
* {"group": "formula", "displayType": "function", "displayName": "年数差", "insertText": "YearDiff(1661334203345, 1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "返回两个日期时间字段之间的年数差,如果为同一年,差数为零" , "definition": "YearDiff(日期时间, 日期时间):数字"}
|
|
1570
|
-
*/
|
|
1571
508
|
declare function YearDiff(startDay: number | string | Date, endDay: number | string | Date): number;
|
|
1572
|
-
/**
|
|
1573
|
-
* 日期时间格式化
|
|
1574
|
-
*
|
|
1575
|
-
* @remarks
|
|
1576
|
-
* 格式化日期时间为指定格式的文本,例如 DateText(Date(2017,3,24), "yyyy-MM-dd HH:mm:ss")
|
|
1577
|
-
*
|
|
1578
|
-
* @privateForWeDa
|
|
1579
|
-
* {"group": "formula", "displayType": "function", "displayName": "日期时间格式化", "insertText": "DateText(1661334203345, 'YYYY-MM-DD HH:mm:ss')", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "格式化日期时间为指定格式的文本,例如 DateText(Date(2017,3,24), 'yyyy-MM-dd HH:mm:ss')" , "definition": "DateText(日期时间, 文本):文本"}
|
|
1580
|
-
*/
|
|
1581
509
|
declare function DateText(createdTime: number | string | Date, text: string): string;
|
|
1582
|
-
/**
|
|
1583
|
-
* 是否为今天
|
|
1584
|
-
*
|
|
1585
|
-
* @remarks
|
|
1586
|
-
* 判断传入的日期时间是否为今天,例如 IsToday(Date(2022,4,8))
|
|
1587
|
-
*
|
|
1588
|
-
* @privateForWeDa
|
|
1589
|
-
* {"group": "formula", "displayType": "function", "displayName": "是否为今天", "insertText": "IsToday(1661334203345)", "subGroup": "time", "doc": "https://cloud.tencent.com/document/product/1301/76328" , "description": "判断传入的日期时间是否为今天,例如 IsToday(Date(2022,4,8))" , "definition": "IsToday(日期时间):布尔值"}
|
|
1590
|
-
*/
|
|
1591
510
|
declare function IsToday(date: number | string | Date): boolean;
|
|
1592
511
|
|
|
1593
512
|
|