diff --git a/extend/weixin/Getgzopenid.php b/extend/weixin/Getgzopenid.php index 85311ed1..d0460144 100644 --- a/extend/weixin/Getgzopenid.php +++ b/extend/weixin/Getgzopenid.php @@ -81,8 +81,9 @@ class Getgzopenid $token_url = "https://api.weixin.qq.com/cgi-bin/message/template/send?access_token=".$access_token; foreach($goods_msg as $key=>$value){ foreach($value['goodscontact'] as $k=>$v){ + // TODO 暂时将openid写死,因为后端在这一块设计的不好,这里的open_id是张姐的 $data=[ - "touser" => $v['open_id'], + "touser" => $v['open_id'] ? $v['open_id'] : 'oUzra6HlpaARciJpUk8eeUxFayPk', "template_id"=>"oWpOaEVOgiORQ4bDj9d5u98YMhWWyuShrxECO5RKBW8", "data"=>[ "thing2"=>["value"=>$user_msg['contact']],