alibaba / lowcode-engine

An enterprise-class low-code technology stack with scale-out design / 一套面向扩展设计的企业级低代码技术体系
https://lowcode-engine.cn
MIT License
14.66k stars 2.55k forks source link

设置ArraySetter之后,拿到的数据不应该是数组格式嘛? #3091

Open elevenwangyang opened 2 months ago

elevenwangyang commented 2 months ago

image

meta.ts

import type { IPublicTypeComponentMetadata, IPublicTypeSnippet } from "@alilc/lowcode-types";

const DemoTableMeta: IPublicTypeComponentMetadata = {
  "componentName": "DemoTable",
  "title": "DemoTable",
  "docUrl": "",
  "screenshot": "",
  "devMode": "proCode",
  "configure": {
    "props": [
      {
        "title": { "label": '表格列', "tip": '表格列的配置描述,具体项见下表' },
        "name": 'columns',
        "setter": {
          "componentName": 'ArraySetter',
          "props": {
            "itemSetter": {
              "componentName": 'ObjectSetter',
              "props": {
                "config": {
                  "items": [
                    {
                      "name": 'title',
                      "title": { "label": '列标题', "tip": 'title | 列标题' },
                      "setter": "StringSetter"
                    },
                    {
                      "name": 'dataIndex',
                      "title": { "label": '数据字段', "tip": 'dataIndex | 数据字段' },
                      "setter": 'StringSetter',
                      "isRequired": true,
                    },
                  ],
                },
              },
              "defaultValue": { "title": '标题' },
            },
          },
          "defaultValue": []
        },
      },
    ],
    "supports": {
      "style": true
    },
    "component": {}
  },
};
const snippets: IPublicTypeSnippet[] = [
  {
    "title": "DemoTable",
    "screenshot": "",
    "schema": {
      "componentName": "DemoTable",
      "props": {}
    }
  }
];

export default {
  ...DemoTableMeta,
  snippets
};
Cyxwmm commented 2 months ago

可以看看这个2728

elevenwangyang commented 2 months ago

可以看看这个2728

更新后好了,感谢

alonesmall commented 1 month ago

可以看看这个2728

我拉取了lowcode-engine-ext这个项目,发现run start后,并不能正常运行,请问我该如何调试这个项目呢?能麻烦提供一下指导吗?