The current repo belongs to Paused status, and some functions are restricted. For details, please refer to the description of repo status
1 Star 7 Fork 3

OkCoder / fsonCheckBox
Paused

Create your Gitee Account
Explore and code with more than 8 million developers,Free private repositories !:)
Sign up
Clone or Download
Cancel
Notice: Creating folder will generate an empty file .keep, because not support in Git
Loading...
README.md

fsonCheckBox

项目介绍

layui 拓展插件,二级复选框 输入图片说明

安装教程

输入图片说明 输入图片说明

使用说明

<div id='test1'></div>
<button type='button' id='btn'>button</button>

layui.use(['layer', 'fsonCheckBox'], function () {
        var layer = layui.layer
            , $ = layui.$
            ,fsonCheckBox = layui.fsonCheckBox;
            ,fson = fsonCheckBox.render({
                elem: '#test1'
                , url: "{:url('admin/department/framework')}"
                // 默认值
                , value: [
                    {id: 1, child: [22, 45, 108]}
                    , {id: 3, child: [4, 5, 6, 7]}
                    , {id: 5, child: [11, 22, 33, 44, 55]}
                ]
            });
        $('#btn').click(function () {
            layer.alert(JSON.stringify(fson.config.value))
        })
});

接口返回格式

{
    code:0,
    data:[
        {
            id:1,
            name:'一级',
            child:[
                {
                    id:11,
                    name:'二级'
                },
                {
                    id:12,
                    name:'二级'
                },
            
            ]
        },
        ...
    ]
}

Repository Comments ( 0 )

Sign in to post a comment

About

layui 拓展插件 二级复选框 expand collapse
JavaScript
MIT
Cancel

Releases

No release

Contributors

All

Activities

Load More
can not load any more
JavaScript
1
https://gitee.com/okcoder/fsonCheckBox.git
git@gitee.com:okcoder/fsonCheckBox.git
okcoder
fsonCheckBox
fsonCheckBox
master

Search