### 获取表单字段

#### 请求接口：

(interface#method#group)

- com.weaver.ebuilder.form.client.service.emobile.IEtFormDatasetService#getFields(java.lang.String, java.lang.Long, java.lang.String, java.lang.Boolean)#ebuilderform
- com.weaver.ebuilder.form.client.service.emobile.IEtFormDatasetService#getFields(com.weaver.ebuilder.form.client.entity.field.FieldsQueryDto)#ebuilderform (推荐使用)

##### 请求接口:    ([为后续项目使用中切换应用独立部署的需要，二开逻辑请使用独立部署方式调用](https://weapp.eteams.cn/build/techdoc/wdoc/index.html#/public/doc/81831572-da60-474d-9328-2309af780fb9))

```java
// 基线版本:10.0.2410.01(含), 版本后必须使用该方式操作 - (为后续项目使用中切换应用独立部署的需要)
// 如 调用RemoteSimpleDataService#saveFormData方法需要按以下方式调整

@Autowired
private PublishKitRuntimeUtil publishKitRuntimeUtil;

RemoteSimpleDataService remoteSimpleDataService = publishKitRuntimeUtil.buildRpcService(com.weaver.ebuilder.form.client.service.data.RemoteSimpleDataService.class, "ebuilderform", appId);
remoteSimpleDataService.saveFormData(ebDataChangeReqDto);

/******************************************************************************************************************/

// 基线版本:10.0.2410.01之前版本可使用:
@RpcReference(group = "ebuilderform")
private com.weaver.ebuilder.form.client.service.data.RemoteSimpleDataService remoteSimpleDataService;

remoteSimpleDataService.saveFormData(ebDataChangeReqDto);
```

#### 请求参数：

| 参数名 | 必选 | 参数类型 | 参数说明 |
| --- | --- | --- | --- |
| module | 否 | String | 模块标识 |
| objId | 是 | String | eb表单id |
| formatType | 否 | String | 组装级联字段("1"组装; 其他值不做处理) |
| needChild | 否 | Boolean | 是否需要返回明细字段 |
| terminal | 否 | String | 系统后台字段(“ebBackend“只显示后台数据) |
| excludeMultiPhysical | 否 | Boolean | 是否过滤多物理表字段-仅对多物理表生效 |
| ebSimpleEmployee | 是 | com.weaver.ebuilder.teams.etform.org.bean.EBSimpleEmployee | 人员对象 - 传递人员和租户信息 |

#### 返回值：

| 类型 | 类型所属包路径 | 描述 |
| --- | --- | --- |
| List\<ModuleField\> | com.weaver.ebuilder.form.client.entity.field.ModuleField | 表单字段集合 |

#### 返回示例：

```json
[
    {
        "componentKey": "Text",
        "config": {},
        "fieldId": "id",
        "fieldInfo": {
            "componentKey": "Text",
            "disableGroupSearch": false,
            "fieldId": "5",
            "fieldName": "id",
            "number": 0,
            "objId": 0,
            "showName": "数据ID",
            "type": "Number"
        },
        "fieldName": "数据ID",
        "fieldType": "Number",
        "id": "5",
        "mainField": true,
        "mainPrimaryKey": true,
        "multiSelect": false,
        "number": 0,
        "objId": "905993982107361280",
        "objShowName": "testkk_rest_share",
        "richEditor": false
    },
    {
        "componentKey": "Text",
        "configString": "",
        "dataKey": "dxwb1",
        "fieldId": "905994068258365440",
        "fieldInfo": {
            "componentKey": "Text",
            "config": "",
            "disableGroupSearch": false,
            "fieldId": "905994068258365440",
            "fieldName": "field_1",
            "fieldType": "string",
            "multiSelect": false,
            "number": 1,
            "objId": 905993982107361280,
            "showName": "单行文本1",
            "type": "String"
        },
        "fieldName": "单行文本1",
        "fieldType": "String",
        "id": "905994068258365440",
        "mainField": true,
        "mainPrimaryKey": false,
        "multiSelect": false,
        "number": 1,
        "objId": "905993982107361280",
        "objShowName": "testkk_rest_share",
        "richEditor": false
    },
    {
        "browserParams": {
            "serviceModule": "ebuilderform"
        },
        "componentKey": "Employee",
        "configString": "",
        "dataKey": "ryxzda1",
        "fieldId": "905994441668861953",
        "fieldInfo": {
            "componentKey": "Employee",
            "config": "",
            "disableGroupSearch": false,
            "fieldId": "905994441668861953",
            "fieldName": "field_11",
            "fieldType": "employee",
            "multiSelect": false,
            "number": 11,
            "objId": 905993982107361280,
            "showName": "人员选择单1",
            "type": "Employee"
        },
        "fieldName": "人员选择单1",
        "fieldType": "Employee",
        "id": "905994441668861953",
        "mainField": true,
        "mainPrimaryKey": false,
        "multiSelect": false,
        "number": 11,
        "objId": "905993982107361280",
        "objShowName": "testkk_rest_share",
        "richEditor": false
    }
]
```

#### 返回主要属性说明:

| 参数名 | 参数类型 | 参数说明 |
| --- | --- | --- |
| id | String | 字段id |
| fieldId | String | 字段id. 系统字段fieldId≠id(如"id"),自定义字段相同 |
| dataKey | String | 字段key |
| fieldType | String | 字段类型 |
| fieldName | String | 字段名称 |
| multiSelect | Boolean | 是否多选 |
| number | Integer | 字段顺序 |
| componentKey | String | 字段组件类型 |
| config | jsonString | 字段配置 |

#### 注意：

	该方法逻辑依赖于com.weaver.framework.rpc.context.impl.TenantRpcContext#getTenantKey, 调用时请确保RPC上下文可以取到tenantKey，否则只能获取到系统字段。  如果是线程调用请使用架构封装com.weaver.common.threadPool.ThreadPoolUtil#getPool 方式获取线程， 或者手动用TTL修饰线程
