| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150 | 
							- <?php
 
- $type = array
 
- (
 
- 	1 => '服务号',
 
- 	2 => '订阅号',
 
- 	3 => '小程序',
 
- 	4 => '小游戏',
 
- 	5 => '第三方平台',
 
- 	6 => '开发者',
 
- );
 
- return array
 
- (
 
- 	# 表名
 
- 	'name' => 'project',
 
- 	# 显示给用户看的名称
 
- 	'lang' => '项目管理',
 
- 	'order' => -10,
 
- 	# 数据结构
 
- 	'struct' => array
 
- 	(
 
- 		'id' 		=> array
 
- 		(
 
- 			'type' 		=> 'int-11',
 
- 			'name' 		=> 'ID',
 
- 			'default' 	=> '',
 
- 			'desc' 		=> '',
 
- 			'match' 	=> 'is_numeric',
 
- 			//'search'	=> 'order',
 
- 			'order'		=> 'desc',
 
- 			'list'		=> true,
 
- 		),
 
- 		
 
- 		'name'		=> array
 
- 		(
 
- 			'type' 		=> 'varchar-60',
 
- 			'name' 		=> '项目名称',
 
- 			'default' 	=> '',
 
- 			'desc' 		=> '请输入项目名称',
 
- 			'match' 	=> 'is_string',
 
- 			'update'	=> 'text',
 
- 			'search'	=> 'fulltext',
 
- 			'list'		=> true,
 
- 		),
 
- 		'type'		=> array
 
- 		(
 
- 			'type' 		=> 'tinyint-11',
 
- 			'name' 		=> '项目类型',
 
- 			'default' 	=> '1',
 
- 			'desc' 		=> '项目类型',
 
- 			'match' 	=> 'is_numeric',
 
- 			'update'	=> 'select',
 
- 			'option'	=> $type,
 
- 			'list'		=> true,
 
- 		),
 
- 		'appid'		=> array
 
- 		(
 
- 			'type' 		=> 'varchar-150',
 
- 			'name' 		=> '微信appid',
 
- 			'default' 	=> '',
 
- 			'desc' 		=> '请输入微信appid',
 
- 			'match' 	=> 'is_string',
 
- 			'search'	=> 'order,fulltext',
 
- 			'update'	=> 'text',
 
- 			'list'		=> 'table',
 
- 			'modal' 	=> '详细信息',
 
- 		),
 
- 		'secret'		=> array
 
- 		(
 
- 			'type' 		=> 'varchar-150',
 
- 			'name' 		=> '微信secret',
 
- 			'default' 	=> '',
 
- 			'desc' 		=> '请输入微信secret',
 
- 			'match' 	=> 'is_string',
 
- 			'search'	=> 'order,fulltext',
 
- 			'update'	=> 'text',
 
- 			//'list'		=> 'table',
 
- 			//'modal' 	=> '详细信息',
 
- 		),
 
- 		'token'		=> array
 
- 		(
 
- 			'type' 		=> 'varchar-150',
 
- 			'name' 		=> '通信token(注意不是access_token)',
 
- 			'default' 	=> '',
 
- 			'desc' 		=> '请输入通信token',
 
- 			'match' 	=> 'is_string',
 
- 			'update'	=> 'text',
 
- 		),
 
- 		'key'		=> array
 
- 		(
 
- 			'type' 		=> 'varchar-150',
 
- 			'name' 		=> '消息加解密密钥',
 
- 			'default' 	=> '',
 
- 			'desc' 		=> '请输入消息加解密密钥',
 
- 			'match' 	=> 'option',
 
- 			'update'	=> 'text',
 
- 		),
 
- 		'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,
 
- 			'list'		=> 'date("Y-m-d H:i:s", {cdate})',
 
- 		),
 
- 	),
 
- 	
 
- 	'manage' => array
 
- 	(
 
- 	),
 
- 	'top' => array
 
- 	(
 
- 		# 数据来源
 
- 		'data' => 'state',
 
- 		# 菜单名
 
- 		'name' => '项目选择',
 
- 		# 默认值
 
- 		'value' => 1,
 
- 		# 对应的字段值,设置这个之后,所有设置等于这个值的字段,都要遵循这个权限的控制
 
- 		'key' => 'main/project_id',
 
- 		# 本表中代表名称的字段
 
- 		'col' => 'name',
 
- 	),
 
- 	
 
- 	# request 请求接口定义
 
- 	'request' => array
 
- 	(
 
- 		
 
- 	),
 
- );
 
 
  |