跳转到主要内容

用于deform的jQuery dynatree小部件

项目描述

deform_widget_dynatree

Dynatree 是一个用于jQuery的JavaScript动态树视图插件,支持持久性、键盘、复选框、拖放和懒加载。

deform_widget_dynatree 将其一些功能作为小部件暴露给 deform 表单生成库。

REST API

deform_widget_dynatree 依赖于您必须在服务器端实现的一个REST API。此API只需要实现一个方法,该方法响应带有2个可选参数的GET请求

  • key 请求子节点的节点键。

  • mode 可以是 rootbranch

    如果 modebranch,则只需返回请求节点的子节点(作为JSON对象的列表)

      [
          'child1': {
              'key': '1',
              'title': 'One',
          },
          'child2': {
              'key': '2',
              'title': 'Two',
          },
      ]
    
    If ``mode`` is ``root`` the result must contain the children of the
    requested node (same as with ``branch``) as well as all parent nodes with
    their siblings::
    
      [
          'child1': {
              'key': '1',
              'title': 'One',
              'children': [
                  'subchild1': {
                      'key': '11',
                      'title': 'Sub One',
                          'children': [
                              'subchild11': {
                                  'key': '111',
                                  'title': 'Subsub One',
                              },
                  },
                  'subchild2': {
                      'key': '12',
                      'title': 'Sub Two',
                  },
              ],
          },
          'child2': {
              'key': '2',
              'title': 'Two',
          },
      ]

变更

0.1

  • 初始发布。

项目详情


下载文件

下载适用于您平台的文件。如果您不确定选择哪个,请了解有关安装包的更多信息。

源分布

deform_widget_dynatree-0.1dev.tar.gz (296.3 kB 查看哈希值)

上传时间

支持