简体中文
FxObjectListLatest
约 551 字大约 2 分钟
2026-10-10
用于在自定义页面中展示业务对象列表,交互与能力与 CRM 标准对象列表页保持一致。
组件/API
Attributes
| 参数 | 说明 | 类型 | 可选值 | 默认值 |
|---|---|---|---|---|
| options | 列表配置对象 | Object | — | — |
options
| 字段 | 说明 | 类型 | 可选值 | 默认值 |
|---|---|---|---|---|
| apiName | 业务对象 apiName(必填) | String | — | — |
| disabledFeatureControls | 隐藏指定列表区域能力;键值为 true 表示隐藏 | Object | — | — |
| hooks | 列表渲染前扩展配置 | Object | — | — |
disabledFeatureControls
下列能力由组件默认隐藏,无需在 disabledFeatureControls 中重复配置,且不能通过配置改为显示:
| 键 | 说明 |
|---|---|
| view | 视图切换 |
| quickFilter | 快速筛选 |
| multiSort | 多字段排序 |
| guide | 列表引导 |
可按需追加下列键(值为 true 时隐藏对应能力):
| 键 | 说明 |
|---|---|
| term | 场景切换 |
| recordType | 业务类型选择 |
| refresh | 刷新按钮 |
| setting | 设置按钮 |
hooks
| 键 | 说明 | 类型 | 可选值 | 默认值 |
|---|---|---|---|---|
| beforeRender | 列表渲染前回调;返回值字段与 list.render.before 相同 | Function | — | — |
签名:
beforeRender(unused, context) {
return {
// 结构见 list.render.before
};
}| 参数 | 说明 |
|---|---|
| unused | 预留参数,业务代码可忽略(示例中用 _) |
| context | 列表上下文,含 recordType 等;通用字段见列表插件通用参数 |
beforeRender 的返回值、buttons.del 的按钮标识规则等,均以 list.render.before 为准。
方法
当前组件未对外暴露公开 Methods。
事件
当前组件未对外暴露公开 Events。
插槽
当前组件未提供对外可配置插槽。
示例
简单使用
组件通过 FxUI.component.get('ObjectListLatest') 获取。
<template>
<div class="list-page">
<object-list-latest :options="options" />
</div>
</template>
<script>
export default {
components: {
ObjectListLatest: FxUI.component.get('ObjectListLatest'),
},
data() {
return {
options: {
apiName: 'AccountObj',
disabledFeatureControls: {
term: true,
recordType: true,
refresh: true,
setting: true,
},
hooks: {
beforeRender(_, context) {
return {
buttons: {
del: ['Add', 'IntelligentForm', 'ExportFile'],
},
termExtendConfig: {
retain: ['Follow'],
},
formatRequestParam(params) {
return params;
},
afterRequestDescribe() {
return {
quickFilterField: ['name'],
};
},
};
},
},
},
};
},
};
</script>
<style>
.list-page {
width: 100%;
height: 600px;
}
</style>注意事项
布局
- 父容器需有明确高度;本组件根节点宽高为
100%,父级无高度时列表区域可能无法正确展示。
接入检查
options.apiName使用真实业务对象 apiName。options.hooks.beforeRender的返回值及buttons.del按钮标识规则,以 list.render.before 为准。view、quickFilter、multiSort、guide由组件默认隐藏,不能通过options.disabledFeatureControls改为显示。
