DEVER_PROJECT, # 语言包 暂时无用 'lang' => 'zh-cn', 'lang_pack' => array('zh-cn' => '简体中文', 'en' => '英文'), # 定义类型 订单表会按照这个自动分区,7\8\9是预留 'type' => array ( 1 => 'content', 2 => 'func', 3 => 'goods', 4 => 'agent', 5 => 'data', 6 => 'chat', 7 => '', 8 => '', 9 => '', ), # 路由解析设置 'route' => array ( 'api/notify/(.*?)' => 'notify.common?s=$1', ), # 日志设置 'log' => array('type' => 'file', 'host' => 'host', 'port' => 'port'), # 调试的shell名 'shell' => 'debug', # 定义session //'session' => array('host' => '', 'port' => '', 'path' => '', 'cookie' => ''), # 定义数据库 'database' => array ( # 是否自动建表 默认为true 'create' => true, # sql优化,暂时无用 'opt' => true, //'default' => array($env['db'], $env['db1'], 'type' => 'Pdo'),//读写分离 'default' => $env['db'], 'log' => $env['log'], # 分区设置 'partition' => array ( # 当前数据库是否支持自动建库,不支持改成false,则database不会自动建库,而是类似table按照表拆分 'create' => true, # 类型:database 按照库拆分(分库) table 按照表拆分(分表) field 按照字段拆分(分区) where 按照条件拆分(分条件) Dever::session('database', 1)可以设置值 'database' => 'date("Y")', 'table' => 'date("Ym")', # 字段类型分几种:range范围、list列表、hash哈希、key分区 'field' => array ( 'type' => 'range', 'field' => 'cdate', 'value' => 'date("Y-m-d 23:60:60")'//date("Y-m-d 23:60:60", strtotime("-1 day"))' ), /* 'field' => array ( 'type' => 'list', 'field' => 'type', 'value' => array('1', '2', '3'),//3个值3个分区,然后也可以用Dever::call("manage/admin.test")来返回数组 ), 'field' => array ( 'type' => 'hash', 'field' => 'id', 'value' => '5'//5个分区 ), 'field' => array ( 'type' => 'key', 'field' => 'id', 'value' => '5' ),*/ # where类型,一般在表中设置array('id' => 1), //'where' => 'Dever::call("manage/admin.test")' ), ), # 定义模板 'template' => array ( 'name' => 'pc',//模板配置,如果有手机版,直接配置:'pc,mobile' 'replace' => array ( '../' => '{$host}', ), ), # 定义redis 'redis' => array('host' => 'server-redis', 'port' => '6379', 'password' => 'dm_redis_123', 'expire' => 2147483647), # 根据api增加缓存 /* 'cache' => array ( 'set/home.test' => 3000, ),*/ );