wang hou sheng 10 months ago
parent 638791fb45
commit dac6c74d08
  1. 3
      app/common/library/wxserver/Wholesaler.php

@ -205,10 +205,12 @@ class Wholesaler
*/
public function commit($appid, $template_id): bool
{
Db::table('yoshop_wx_server')->insertGetId(['content' => '进入发体验版', 'created_at' => date('Y-m-d H:i:s')]);
$version = '';
$access_token = $this->authorizerAccessToken($appid);
//获取模板
$templatelist = $this->getTemplatelist();
Db::table('yoshop_wx_server')->insertGetId(['content' => json_encode($templatelist), 'created_at' => date('Y-m-d H:i:s')]);
if ($templatelist) {
foreach ($templatelist as $value) {
if (!empty($value['user_version']) && $value['template_id'] == $template_id) {
@ -217,6 +219,7 @@ class Wholesaler
}
}
}
Db::table('yoshop_wx_server')->insertGetId(['content' => "版本信息$version", 'created_at' => date('Y-m-d H:i:s')]);
if ($version == '') {
throwError('模板不存在');
}

Loading…
Cancel
Save