select(); return $info; }; $value_type = array ( 1 => '百分比', 2 => '数值', ); $is_give = array ( 1 => '是', 2 => '否', ); $type = array ( 1 => '街道', 5 => '分润创客名额', ); return array ( # 表名 'name' => 'role_reward', # 显示给用户看的名称 'lang' => '奖励管理', 'menu' => false, # 数据结构 'struct' => array ( 'id' => array ( 'type' => 'int-11', 'name' => 'ID', 'default' => '', 'desc' => '', 'match' => 'is_numeric', 'search' => 'order', 'update' => 'hidden', //'list' => true, ), 'role_id' => array ( 'type' => 'int-11', 'name' => '代理商角色', 'default' => '', 'desc' => '代理商角色', 'match' => 'is_numeric', 'update' => 'hidden', 'search' => 'hidden', 'value' => Dever::input('search_option_role_id'), 'list' => 'Dever::load("setting/role-one#name", {role_id})', ), 't_role_id' => array ( 'type' => 'int-11', 'name' => '推荐角色', 'default' => '', 'desc' => '推荐角色', 'match' => 'is_numeric', 'update' => 'select', 'search' => 'select', 'option' => $role, 'list' => 'Dever::load("setting/role-one#name", {t_role_id})', ), 'num' => array ( 'type' => 'int-11', 'name' => '推荐个数-每推荐多少个,奖励多少数值,这里填写推荐个数', 'default' => '1', 'desc' => '推荐个数', 'match' => 'is_numeric', 'update' => 'text', 'list' => true, ), 'value' => array ( 'type' => 'varchar-32', 'name' => '推荐奖励数值-如果是百分比,这里输入10,就是奖励10%,如果是数值,这里以元为单位', 'default' => '0', 'desc' => '推荐奖励数值', 'match' => 'is_string', 'update' => 'text', 'search' => 'fulltext', 'list' => true, ), 'value_type' => array ( 'type' => 'tinyint-1', 'name' => '奖励数值类型', 'default' => '1', 'desc' => '奖励数值类型', 'match' => 'is_numeric', 'update' => 'radio', 'option' => $value_type, 'search' => 'select', 'list' => true, 'control' => 'type', ), 'is_give' => array ( 'type' => 'tinyint-1', 'name' => '是否有额外奖励', 'default' => '2', 'desc' => '是否有额外奖励', 'match' => 'is_numeric', 'update' => 'radio', 'option' => $is_give, 'control' => 'is_give', ), 'give' => array ( 'type' => 'text-1000', 'name' => '额外奖励', 'default' => '', 'desc' => '额外奖励', 'match' => 'is_string', 'show' => 'is_give=1', 'update' => array ( array ( 'col' => 'num', 'name' => '推荐个数', 'default' => '0', 'desc' => '推荐个数', 'match' => 'is_string', 'update' => 'text', ), array ( 'col' => 'type', 'name' => '奖励类型', 'default' => '1', 'desc' => '奖励类型', 'match' => 'is_string', 'update' => 'radio', 'option' => $type, ), array ( 'col' => 'value', 'name' => '奖励数值', 'default' => '0', 'desc' => '奖励数值', 'match' => 'is_string', 'update' => 'text', ), array ( 'col' => 'value_type', 'name' => '数值类型', 'default' => '1', 'desc' => '数值类型', 'match' => 'is_string', 'update' => 'radio', 'option' => $value_type, ), ), ), '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 ( ), );