'info', # 显示给用户看的名称 'lang' => '题库列表', # 是否显示在后台菜单 'order' => 100, # 数据结构 'struct' => array ( 'id' => array ( 'type' => 'int-11', 'name' => 'ID', 'default' => '', 'desc' => '', 'match' => 'is_numeric', 'order' => 'desc', 'list' => true, ), 'name' => array ( 'type' => 'varchar-150', 'name' => '标题', 'default' => '', 'desc' => '标题', 'match' => 'is_string', 'update' => 'text', 'search' => 'fulltext', 'list' => true, ), 'level_id' => array ( 'type' => 'int-11', 'name' => '难度', 'default' => '1', 'desc' => '难度', 'match' => 'is_numeric', 'update' => 'select', 'option' => $level, 'search' => 'select', 'list' => '{level_id} > 0 ? Dever::load("question/level-one#name", {level_id}) : "未知"', ), 'cate_id' => array ( 'type' => 'int-11', 'name' => '分类', 'default' => '1', 'desc' => '请选择分类', 'match' => 'is_numeric', 'update' => 'select', 'option' => $cate, 'search' => 'select', //'search_parent' => 'info_id',//根据哪个字段来确定本搜索选项的内容 'list' => '{cate_id} > 0 ? Dever::load("question/cate-one#name", {cate_id}) : "未知"', ), 'pic' => array ( 'type' => 'varchar-150', 'name' => '背景图', 'default' => '', 'desc' => '背景图', 'match' => 'option', 'update' => 'image', 'key' => '1', 'place' => '150', ), 'content' => array ( 'type' => 'text-255', 'name' => '选项设置', 'default' => '', 'desc' => '选项设置', 'match' => 'is_string', 'update' => array ( array ( 'col' => 'score', 'name' => '选项分数-0为错误选项,大于1则为正确选项', 'default' => '0', 'desc' => '选项分数', 'match' => 'is_string', 'update' => 'text', ), array ( 'col' => 'title', 'name' => '选项标题', 'default' => '', 'desc' => '请输入选项标题', 'match' => 'is_string', 'update' => 'text', ), array ( 'col' => 'pic', 'name' => '选项图片', 'default' => '', 'desc' => '选项图片', 'match' => 'is_string', 'update' => 'image', 'key' => '1', ), array ( 'col' => 'info', 'name' => '描述', 'default' => '', 'desc' => '请输入描述', 'match' => 'is_string', 'update' => 'textarea', ), ), ), 'state' => array ( 'type' => 'tinyint-1', 'name' => '状态', 'default' => '1', 'desc' => '请选择状态', 'match' => 'is_numeric', ), 'cdate' => array ( 'type' => 'int-11', 'name' => '录入时间', 'match' => array('is_numeric', time()), 'desc' => '', # 只有insert时才生效 'insert' => true, 'search' => 'date', 'list' => 'date("Y-m-d H:i:s", {cdate})', ), ), 'manage' => array ( ), 'request' => array ( 'getAll' => array ( # 匹配的正则或函数 选填项 'option' => array ( 'cate_id' => array('yes', 'in'), 'ids' => array('yes-id', 'in'), 'level_id' => 'yes', 'idno' => array('yes-id', 'notin'), 'state' => 1, ), 'type' => 'all', //'limit' => '0,100000', 'col' => '*|id', ), ) );