12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485 |
- <?php
- return array
- (
- # 表名
- 'name' => 'page_module',
- # 显示给用户看的名称
- 'lang' => '页面模块关联表',
- 'menu' => false,
- # 数据结构
- 'struct' => array
- (
- 'id' => array
- (
- 'type' => 'int-11',
- 'name' => 'ID',
- 'default' => '',
- 'desc' => '',
- 'match' => 'is_numeric',
- 'search' => 'order',
- 'list' => true,
- ),
-
- 'page_id' => array
- (
- 'type' => 'int-11',
- 'name' => '页面ID',
- 'default' => '',
- 'desc' => '页面ID',
- 'match' => 'is_numeric',
- 'update' => 'text',
- 'list' => true,
- ),
- 'module_id' => array
- (
- 'type' => 'int-11',
- 'name' => '模块ID',
- 'default' => '',
- 'desc' => '模块ID',
- 'match' => 'is_numeric',
- 'update' => 'text',
- 'list' => true,
- ),
-
- 'cdate' => array
- (
- 'type' => 'int-11',
- 'name' => '录入时间',
- 'match' => array('is_numeric', DEVER_TIME),
- 'desc' => '',
- # 只有insert时才生效
- 'insert' => true,
- 'list' => 'date("Y-m-d H:i:s", {cdate})',
- ),
- ),
- # request 请求接口定义
- 'request' => array
- (
- 'getData' => array
- (
- 'where' => array
- (
- 'page_id' => 'yes-t_1.page_id',
- 'state' => 'yes-t_2.state-1',
- ),
- 'join' => array
- (
- array
- (
- 'table' => 'page/module',
- 'type' => 'left join',
- 'on' => array('module_id','id'),
- 'col' => 't_1.id as tid',
- ),
- ),
- 'type' => 'all',
- 'order' => array('t_2.reorder' => 'desc', 't_2.id' => 'desc'),
- 'col' => 'id,t_2.*',
- ),
- )
- );
|