| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281 | 
							- <?php
 
- $excel = false;
 
- $excel[] = array('数据导出','数据导出','active/lib/excel.out_active_order');
 
- $list_button = array();
 
- if (Dever::load('manage/auth')->checkFunc('active.order', 'editRefund', '退款')) {
 
-     $list_button['fast'] = array('退款', '"info_refund&project=active&search_option_order_id={id}"');
 
-     // $list_button['oper'] = array('退款', '"active/lib/manage.refund?id={id}"', '{status} == 2');
 
- }
 
- $list_button['list'] = array('查看详情','"info_code&project=active&id={id}&page_type=1&[refer]"');
 
- $pay_type = array
 
- (
 
-     1 => '在线支付',
 
- );
 
- $status = array
 
- (
 
-     1 => '待支付',
 
-     2 => '已支付',
 
-     3 => '已关闭',#超时未支付
 
-     4 => '已完成',
 
-     5 => '已完成(有退款)',
 
-     6 => '已退款',#(全部退款)
 
- );
 
- $active = function()
 
- {
 
-     $array = array();
 
-     $info = Dever::load('active/info-state');
 
-     if($info)
 
-     {
 
-         $array += $info;
 
-     }
 
-     return $array;
 
- };
 
- return array
 
- (
 
-     # 表名
 
-     'name' => 'order',
 
-     # 显示给用户看的名称
 
-     'lang' => '活动订单',
 
-     'order' => 100,
 
-     'config_status' => $status,
 
-     'config_pay_type' => $pay_type,
 
-     # 数据结构
 
-     'struct' => array
 
-     (
 
-     
 
-         'id'        => array
 
-         (
 
-             'type'      => 'int-11',
 
-             'name'      => 'ID',
 
-             'default'   => '',
 
-             'desc'      => '',
 
-             'match'     => 'is_numeric',
 
-             'search'    => 'order',
 
-             // 'list'      => true,
 
-         ), 
 
-         'order_num'      => array
 
-         (
 
-             'type'      => 'varchar-100',
 
-             'name'      => '订单单号',
 
-             'default'   => '',
 
-             'desc'      => '订单单号',
 
-             'match'     => 'is_string',
 
-             'update'    => 'text',
 
-             'search'    => 'fulltext',
 
-             'list'      => true,
 
-         ),
 
-         'mid'      => array
 
-         (
 
-             'type'      => 'int-11',
 
-             'name'      => '代理商姓名/手机号',
 
-             'default'   => '-1',
 
-             'desc'      => '代理商',
 
-             'match'     => 'is_string',
 
-             'update'    => 'text',
 
-             'search'    => array
 
-             (
 
-                 'api' => 'agent/member-getSearch',
 
-                 'col' => 'col',
 
-                 'result' => 'id',
 
-                 'search' => 'mid',
 
-             ),
 
-             'list_name' => '代理商信息',
 
-             'list'      => 'Dever::load("agent/lib/member.getOne", {mid}, "agent/member", true)',
 
-         ),
 
-         'uid'      => array
 
-         (
 
-             'type'      => 'int-11',
 
-             'name'      => '用户名称',
 
-             'default'   => '-1',
 
-             'desc'      => '用户名称',
 
-             'match'     => 'is_string',
 
-             // 'option'    => $user,
 
-             // 'update'    => 'text',
 
-             // 'search'    => 'text',
 
-             // 'list'      => true,
 
-         ),
 
-         'active_id'      => array
 
-         (
 
-             'type'      => 'int-11',
 
-             'name'      => '活动名称',
 
-             'default'   => '-1',
 
-             'desc'      => '活动名称',
 
-             'match'     => 'is_string',
 
-             'option'    => $active,
 
-             'update'    => 'text',
 
-             // 'search'    => 'text',
 
-             'list'      => true,
 
-         ),
 
-         'num'        => array
 
-         (
 
-             'type'      => 'varchar-100',
 
-             'name'      => '数量',
 
-             'default'   => '',
 
-             'desc'      => '数量',
 
-             'match'     => 'option',
 
-             'list'      => true,
 
-         ),
 
-         'price'        => array
 
-         (
 
-             'type'      => 'varchar-50',
 
-             'name'      => '金额',
 
-             'default'   => '0',
 
-             'desc'      => '金额',
 
-             'match'     => 'option',
 
-             'update'    => 'text',
 
-             'list'      => true,
 
-         ),
 
-         'status'        => array
 
-         (
 
-             'type'      => 'tinyint-1',
 
-             'name'      => '支付状态',
 
-             'default'   => '1',
 
-             'desc'      => '支付状态',
 
-             'match'     => 'is_numeric',
 
-             'option'    => $status,
 
-             'search'    => 'select',
 
-             'list'      => true,
 
-         ),
 
-         'pay_type'        => array
 
-         (
 
-             'type'      => 'tinyint-1',
 
-             'name'      => '支付类型',
 
-             'default'   => '1',
 
-             'desc'      => '支付类型',
 
-             'match'     => 'is_numeric',
 
-             'option'    => $pay_type,
 
-             'search'    => 'select',
 
-             'list'      => true,
 
-         ),
 
-         'path'      => array
 
-         (
 
-             'type'      => 'varchar-300',
 
-             'name'      => '自定义字段',
 
-             'default'   => '',
 
-             'desc'      => '自定义字段',
 
-             'match'     => 'option',
 
-             // 'update'    => 'textarea',
 
-         ),
 
-         'remark'      => array
 
- 	    (
 
- 	        'type'      => 'varchar-300',
 
- 	        'name'      => '订单备注',
 
- 	        'default'   => '',
 
- 	        'desc'      => '订单备注',
 
- 	        'match'     => 'option',
 
- 	        'update'    => 'textarea',
 
- 	    ),
 
- 	    'url'      => array
 
-         (
 
-             'type'      => 'varchar-3000',
 
-             'name'      => '支付链接',
 
-             'default'   => '',
 
-             'desc'      => '支付链接',
 
-             'match'     => 'is_string',
 
-             // 'update'    => 'fulltext',
 
-             //'search'    => 'fulltext',
 
-             //'list'      => true,
 
-         ),
 
-         'refund_admin' => array
 
-         (
 
-             'type'      => 'int-11',
 
-             'name'      => '退款操作人',
 
-             'default'   => '',
 
-             'desc'      => '',
 
-             'match'     => 'is_numeric',
 
-            // 'search'    => 'order',
 
-             'list_name' => '退款操作人<br>退款时间',
 
-             'list'        => 'Dever::load("active/lib/manage.show",{id})',
 
-         ),
 
-         'rdate'     => array
 
-         (
 
-             'type'      => 'int-11',
 
-             'name'      => '退款时间',
 
-             'default'   => '',
 
-             'match'     => 'is_numeric',
 
-             'search'    => 'date',
 
-             // 'desc'      => '',
 
-             // 'list'      => 'date("Y-m-d H:i:s", {zdate})',
 
-         ),
 
-         '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})',
 
-             //'list'      => 'Dever::load("service/lib/manage.showOrderTime", "{id}")',
 
-         ),
 
-     ),
 
-     'manage' => array
 
-     (
 
-         'delete' => false,
 
-         'edit' => false,
 
-         'insert' => false,
 
-         'excel'	=> $excel,
 
-         'list_button' => $list_button,
 
-     ),
 
-     'request' => array
 
-     (
 
-         // # 获取数量
 
-         'getNum' => array
 
-         (
 
-             # 匹配的正则或函数 选填项
 
-             'option' => array
 
-             (
 
-                 'mid' => 'yes',
 
-                 'uid'  => 'yes',
 
-                 'active_id' => 'yes',
 
-                 'status' =>2,
 
-                 'state' => 1,
 
-             ),
 
-             'type' => 'one',
 
-             'col' => 'sum(num) as total',
 
-         ),
 
-         'getAll' => array
 
-         (
 
-             # 匹配的正则或函数 选填项
 
-             'option' => array
 
-             (
 
-                 'mid' => 'yes',
 
-                 'uid' => 'yes',
 
-                 'status' => array('yes','!='),
 
-                 'state' => 1,
 
-             ),
 
-             'type' => 'all',
 
-             'order' => array('cdate'=>'desc'),
 
-             'page' => array(20,'list'),
 
-             'col' => '*',
 
-         ),
 
-     ),
 
- );
 
 
  |