verify.php 12.4 KB
<?php
return [
    //小程序参数
    'raw' => [
        'app_id' => 'wx322817859bfe5db1',//app_id
        'secret' => '99031bb53087e80ae0ff93411f7ae01d',//秘钥
    ],
    //快递鸟配置
    'express'=>[
        'EBusinessID' =>'1576495',
        'appKey' =>'a504b6fa-f6a1-4de0-82f1-fd6d7b4927a5',
        'url' =>'http://api.kdniao.com/Ebusiness/EbusinessOrderHandle.aspx',//请求地址
    ],
    //微信支付配置
    'wx_pay' => [
        'app_id'             => 'wx322817859bfe5db1',
        'mch_id'             => '1565916131',
        'key'                => 'sflz1pDcxfiNe4Un6jOD4InHIk1Vwwsm',   // 支付 密钥

        // 如需使用敏感接口(如退款、发送红包等)需要配置 API 证书路径(登录商户平台下载 API 证书)
        'cert_path'          => ROOT_PATH.'application/cert/apiclient_cert.pem', // XXX: 绝对路径!!!!
        'key_path'           => ROOT_PATH.'application/cert/apiclient_key.pem',      // XXX: 绝对路径!!!!

        'notify_url'         => '默认的订单回调地址',     // 你也可以在下单时单独设置来想覆盖它
    ],
    //七牛云域名
    'host' => 'http://feifangu.qiniu.brotop.cn',
    //非凡谷域名
    'ffg_host' => 'http://feifangu.w.brotop.cn',
    //商品标识
//    'flag' => [0,1,2,3],//0:普通,1:推荐,2:设计师作品,3:新人特惠
    'flag' => [0,1],//0:否,1:是
    'status' => [0,1,2,3,4,5,6,7,8,9,10],//0: 待付款, 1: 已取消,2: 待发货, 3: 退款申请中,4: 已退款, 5: 待收货,6: 退换货申请中, 7: 已退换货,8: 已完成,9:退换货驳回,10:退款申请驳回
    //优惠券类型
    'type' => [0,1,2],//0:全场,1:品牌,2:商品
    //统计类型
    'browse_type' => [0,1,2],//0:首页(个人中心),1:商品浏览,2:商品收藏
    //分页数
    'limit' => 10,
    //商品分页
    'goods_limit' => 20,
    //大牌专区
    'brand_limit' => 15,
    //小程序登录
    'user' => [
        'rule' => [
            'code'       => 'require',
            'nickname'   => 'require',
            'avatar'     => 'require',
        ],
        'msg' => [
            'name.require'     => '昵称不能为空',
            'code.require'     => 'code码不能为空',
            'avatar'           => '头像不能为空',
        ]
    ],
    //分页
    'page' => [
        'rule' => [
            'page'       => 'require|number',
        ],
        'msg' => [
            'page.require'     => '分页页码不能为空',
            'page.number'      => '分页页码必须为数字',
        ]
    ],
    //品类商品列表
    'sort_goods' => [
        'rule' => [
            's_id'       => 'require|number',
            'page'       => 'require|number',
        ],
        'msg' => [
            's_id.require'     => '品类分类id不能为空',
            's_id.number'      => '品类分类id必须为数字',
            'page.require'     => '分页页码不能为空',
            'page.number'      => '分页页码必须为数字',
        ]
    ],
    //品类商品列表
    'brand_goods' => [
        'rule' => [
            'b_id'       => 'require|number',
            'page'       => 'require|number',
        ],
        'msg' => [
            'b_id.require'     => '品牌分类id不能为空',
            'b_id.number'      => '品牌分类id必须为数字',
            'page.require'     => '分页页码不能为空',
            'page.number'      => '分页页码必须为数字',
        ]
    ],
    //商品详情
    'goods_detail' => [
        'rule' => [
            'goods_id'          => 'require|number',
        ],
        'msg' => [
            'goods_id.require'  => '商品id不能为空',
            'goods_id.number'   => '商品id必须为数字',
        ]
    ],
    //晒单详情
    'u_list_detail' => [
        'rule' => [
            'u_list_id'          => 'require|number',
        ],
        'msg' => [
            'u_list_id.require'  => '晒单id不能为空',
            'u_list_id.number'   => '晒单id必须为数字',
        ]
    ],
    //品牌详情
    'brand_detail' => [
        'rule' => [
            'b_id'          => 'require|number',
        ],
        'msg' => [
            'b_id.require'  => '品牌id不能为空',
            'b_id.number'   => '品牌id必须为数字',
        ]
    ],
    //商品检索列表
    'search_goods' => [
        'rule' => [
            'keyword'       => 'require',
            'page'          => 'require|number',
        ],
        'msg' => [
            'keyword.require'     => '关键字不能为空',
            'page.require'        => '分页页码不能为空',
            'page.number'         => '分页页码必须为数字',
        ]
    ],
    //加入购物车
    'add_car' => [
        'rule' => [
            'goods_id'       => 'require|number',
            'style'          => 'require',
            'price'          => 'require|number',
            'goods_number'   => 'require|number',
        ],
        'msg' => [
            'goods_id.require'     => '商品id不能为空',
            'goods_id.number'      => '商品id必须为数字',
            'style.require'        => '商品规格不能为空',
            'price.require'        => '商品价格不能为空',
            'price.number'         => '商品价格必须为数字',
            'goods_number.require' => '商品数量不能为空',
            'goods_number.number'  => '商品数量必须为数字',
        ]
    ],
    //删除购物车
    'delete_car' => [
        'rule' => [
            'car_id'       => 'require|number',
        ],
        'msg' => [
            'car_id.require'     => '购物车id不能为空',
            'car_id.number'      => '购物车id必须为数字',
        ]
    ],
    //商品结算
    'settle_goods' => [
        'rule' => [
            'goods_id'           => 'require',
            'price'              => 'require',
            'goods_number'       => 'require',
            'style'              => 'require',
        ],
        'msg' => [
            'goods_id.require'          => '商品id不能为空',
            'price.require'             => '商品价格不能为空',
            'goods_number.require'      => '商品数量不能为空',
            'style.require'             => '商品款式不能为空',
        ]
    ],
    //立即购买
    'purchase' => [
        'rule' => [
            'receive_name'       => 'require',
            'receive_mobile'     => 'require',
            'receive_address'    => 'require',
            'openid'             => 'require',
            'goods_id'           => 'require',
            'price'              => 'require',
            'goods_number'       => 'require',
            'style'              => 'require',
            'total_goods_price'  => 'require|number',
            'discount_price'     => 'require|number',
            'total_expense_price'=> 'require|number',
            'total_price'        => 'require|number',
        ],
        'msg' => [
            'receive_name.require'         => '收货人不能为空',
            'receive_mobile.require'       => '联系方式不能为空',
            'receive_address.require'      => '收货地址不能为空',
            'openid.require'               => 'openid不能为空',
            'goods_id.require'             => '商品id不能为空',
            'price.require'                => '商品价格不能为空',
            'goods_number.require'         => '商品数量不能为空',
            'style.require'                => '商品款式不能为空',
            'total_goods_price.require'    => '商品总金额不能为空',
            'total_goods_price.number'     => '商品总金额必须为数字',
            'discount_price.require'       => '优惠金额不能为空',
            'discount_price.number'        => '优惠金额必须为数字',
            'total_expense_price.require'  => '运费总金额不能为空',
            'total_expense_price.number'   => '运费总金额必须为数字',
            'total_price.require'          => '支付金额不能为空',
            'total_price.number'           => '支付金额必须为数字',
        ]
    ],
    //支付订单
    'pay' => [
        'rule' => [
            'openid'             => 'require',
            'order_sn'           => 'require',
        ],
        'msg' => [
            'openid.require'          => 'openid不能为空',
            'order_sn.require'        => '订单号不能为空',
        ]
    ],
    //一键领取优惠券
    'receive_coupon' => [
        'rule' => [
            'coupon_id'              => 'require',
        ],
        'msg' => [
            'coupon_id.require'      => '优惠券id不能为空',
        ]
    ],
    //商品优惠券
    'goods_coupon' => [
        'rule' => [
            'goods_id'              => 'require|number',
        ],
        'msg' => [
            'goods_id.require'      => '商品id不能为空',
            'goods_id.number'       => '商品id必须为数字',
        ]
    ],
    //我的优惠券
    'my_coupon' => [
        'rule' => [
            'is_flag'               => 'require|number',
        ],
        'msg' => [
            'is_flag.require'       => '优惠券标识不能为空',
            'is_flag.number'        => '优惠券标识必须为数字',
        ]
    ],
    //结算商品可使用优惠券
    'settle_use_coupon' => [
        'rule' => [
            'goods_id'              => 'require',
            'price'                 => 'require',
            'total_goods_price'     => 'require|number',
        ],
        'msg' => [
            'goods_id.require'             => '商品id不能为空',
            'price.require'                => '商品金额不能为空',
            'total_goods_price.require'    => '商品总金额不能为空',
            'total_goods_price.number'     => '商品总金额必须为数字',
        ]
    ],
    //我的订单列表
    'my_order' => [
        'rule' => [
            'status'     => 'require|number',
            'page'       => 'require|number',
        ],
        'msg' => [
            'status.require'     => '订单状态不能为空',
            'status.number'      => '订单状态必须为数字',
            'page.require'       => '分页页码不能为空',
            'page.number'        => '分页页码必须为数字',
        ]
    ],
    //我的订单详情
    'order_detail' => [
        'rule' => [
            'order_id'     => 'require|number',
        ],
        'msg' => [
            'order_id.require'     => '订单id不能为空',
            'order_id.number'      => '订单id必须为数字',
        ]
    ],
    //申请退款
    'apply_refund' => [
        'rule' => [
            'order_id'          => 'require|number',
            'refund_reason'     => 'require',
        ],
        'msg' => [
            'order_id.require'          => '订单id不能为空',
            'order_id.number'           => '订单id必须为数字',
            'refund_reason.require'     => '退款原因不能为空',
        ]
    ],
    //申请退换货
    'apply_return' => [
        'rule' => [
            'order_id'             => 'require|number',
            'return_flag'          => 'require|number',
            'return_reason'        => 'require',
        ],
        'msg' => [
            'order_id.require'          => '订单id不能为空',
            'order_id.number'           => '订单id必须为数字',
            'return_flag.require'       => '退换货标识不能为空',
            'return_flag.number'        => '退换货标识必须为数字',
            'return_reason.require'     => '退货/换货原因不能为空',
        ]
    ],
    //分享
    'share' => [
        'rule' => [
            'share_uid'     => 'require|number',
        ],
        'msg' => [
            'share_uid.require'     => '分享人id不能为空',
            'share_uid.number'      => '分享人id必须为数字',
        ]
    ],
    //申请退换货撤销
    'return_flag' => [
        'rule' => [
            'order_id'      => 'require|number',
            'cancel_flag'   => 'require|number',
        ],
        'msg' => [
            'order_id.require'      => '订单id不能为空',
            'order_id.number'       => '订单id必须为数字',
            'cancel_flag.require'   => '撤销标识不能为空',
            'cancel_flag.number'    => '撤销标识必须为数字',
        ]
    ],
];