larksuite / node-sdk

larksuite open sdk for nodejs
MIT License
131 stars 26 forks source link

多维表格:获取字段类型错误 #75

Closed yunyu950908 closed 4 months ago

yunyu950908 commented 4 months ago

多维表格,字段类型约束是 number (int)

但实际获取到的是 string

yunyu950908 commented 4 months ago

获取到这两个字段的 meta

    {
        "field_id": "fldUwXvdmV",
        "field_name": "goal",
        "is_primary": false,
        "property": {
            "formatter": "0"
        },
        "type": 2,
        "ui_type": "Number"
    },
    {
        "field_id": "fld67OpEty",
        "field_name": "exp",
        "is_primary": false,
        "property": {
            "formatter": "0"
        },
        "type": 2,
        "ui_type": "Number"
    },
yunyu950908 commented 4 months ago
{
  "code": 0,
  "data": {
    "has_more": false,
    "items": [
      {
        "fields": {
          "createdAt": 1709205198000,
          "exp": "0",
          "goal": "1",
          "identifier": "1",
          "updatedAt": 1709213408000
        },
        "id": "recEcep89I",
        "record_id": "recEcep89I"
      }
    ],
    "page_token": "recEcep89I",
    "total": 1
  },
  "msg": "success"
}
yunyu950908 commented 4 months ago

sorry 这是一个预期行为。 https://open.feishu.cn/document/server-docs/docs/bitable-v1/bitable-structure