'待支付', 2 => '待发货', 3 => '待收货', 4 => '已完成', 5 => '已取消', ); return array ( # 表名 'name' => 'order', # 显示给用户看的名称 'lang' => '礼品卡订单', 'status' => $status, # 后台菜单排序 'order' => 100, # 数据结构 'struct' => array ( 'id' => array ( 'type' => 'int-11', 'name' => 'ID', 'default' => '', 'desc' => '', 'match' => 'is_numeric', 'search' => 'order', 'list' => true, 'order' => 'desc', ), 'uid' => array ( 'type' => 'int-11', 'name' => '购买人名称', 'default' => '0', 'desc' => '请选择用户', 'match' => 'is_numeric', 'update' => 'text', //'search' => 'select', 'search' => array ( 'api' => 'passport/user-one', 'col' => 'username', 'result' => 'id', ), 'list' => 'Dever::load("shop/lib/manage.user", {id})', ), 'mobile' => array ( 'type' => 'varchar-300', 'name' => '下单手机号', 'default' => '', 'desc' => '手机号', 'match' => 'option', 'search' => 'fulltext', /* 'search' => array ( 'api' => 'passport/user-select',//接口地址,最好是获取多条数据的地址 'col' => 'mobile',//要查询的字段 'result' => 'id',//返回的字段 'search' => 'uid',//本表的字段,默认为当前的字段 ), */ ), 'shop_id' => array ( 'type' => 'int-11', 'name' => '兑换门店', 'default' => '', 'desc' => '兑换门店', 'match' => 'is_numeric', ), 'address_id' => array ( 'type' => 'int-11', 'name' => '送货地址', 'default' => '', 'desc' => '送货地址', 'match' => 'is_numeric', //'list' => 'Dever::load("passport/address-find#address", {address_id})'; ), 'order_num' => array ( 'type' => 'varchar-100', 'name' => '订单号', 'default' => '', 'desc' => '订单号', 'match' => 'is_string', 'update' => 'text', 'search' => 'fulltext', 'list' => true, ), 'price' => array ( 'type' => 'varchar-50', 'name' => '支付金额', 'default' => '0', 'desc' => '支付金额', 'match' => 'option', 'update' => 'text', 'list' => true, ), 'num' => array ( 'type' => 'int-11', 'name' => '购买数量', 'default' => '', 'desc' => '购买数量', 'match' => 'is_numeric', 'search' => 'select', //'list' => true, ), 'status' => array ( 'type' => 'int-11', 'name' => '状态', 'default' => '1', 'desc' => '状态', 'match' => 'is_numeric', 'option' => $status, 'search' => 'select', 'update' => 'select', 'list' => true, //'mul' => array(1 => '恢复使用', 4 => '已作废'), ), '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 ( 'excel' => true, 'delete' => false, 'edit' => false, 'insert' => false, // 'mul' => '{type} == 1 || {type} == 4', 'list_button' => array ( //'oper' => array('作废', 'goods/lib/manage.drop?id={id}', '{type} == 1'), //'oper2' => array('恢复使用', 'goods/lib/manage.recovery?id={id}', '{type} == 4'), ), ), # 索引 'index' => array ( # 索引名 => 索引id 1 => array ( 'card' => 'card' ), 'version' => 1, ), 'request' => array ( ), );