|
@@ -16,12 +16,16 @@ class WechatService
|
|
|
$this->app = Factory::officialAccount($config);
|
|
|
}
|
|
|
|
|
|
- public function share()
|
|
|
+ public function share($request)
|
|
|
{
|
|
|
$type = true;
|
|
|
if(env('APP_ENV') == 'production'){
|
|
|
$type =false;
|
|
|
}
|
|
|
+ if(isset($request['url'])){
|
|
|
+ $this->app->jssdk->setUrl($request['url']);
|
|
|
+ }
|
|
|
+
|
|
|
return $this->app->jssdk->buildConfig(['updateAppMessageShareData', 'updateTimelineShareData'], $type);
|
|
|
}
|
|
|
}
|