<?php
return array
(
    'list' => array
    (
        'field'      => array
        (
            'name',
            'top_id' => array
            (
                'show' => 'Dever::call("cate/level_1-find", "{top_id}")["name"]',
            ),
            'parent_id' => array
            (
                'show' => 'Dever::call("cate/level_2-find", "{parent_id}")["name"]',
            ),
            'icon_id' => array
            (
                //'show' => '"{icon}" ? "<img src=\'{icon}\' width=\'50\' \/>" : ""',
                'show' => 'Dever::call("cate/icon.show", "{icon_id}")',
            ),
            'sort' => array
            (
                'type' => 'input',
                'tips' => '双击修改排序',
            ),
            'status' => array
            (
                'type' => 'switch',
                'show'  => '{status}',
                'active_value' => 1,
                'inactive_value' => 2,
            ),
            'cdate',
        ),
        'button' => array
        (
            '新增' => 'fastadd',
        ),
        'data_button' => array
        (
            '编辑' => 'fastedit',
        ),
        'search'    => array
        (
            'name' => 'like',
            'parent' => array
            (
                'type' => 'cascader',
                'option'    => 'Dever::call("cate/info.getManageList")',
            ),
            'status',
        ),
    ),
    'update' => array
    (
        'field'    => array
        (
            'name' => array
            (
                'rules' => true,
            ),
            'parent' => array
            (
                'type' => 'cascader',
                'option'    => 'Dever::call("cate/info.getManageList")',
            ),
            'icon_id' => array
            (
                'type' => 'selector',
                'option'    => 'Dever::url("cate/icon.getList", array("id" => "{icon_id}", "name" => "{name}"))',
                'search' => 'icon_name',
            ),
            'icon_name' => 'hidden',
        ),
        'start' => 'cate/info.updateManageCate',
    ),
);