|
@@ -123,7 +123,7 @@ class HomeController extends WebBaseController
|
|
//分站
|
|
//分站
|
|
$subsite_id = get_subsite_id();
|
|
$subsite_id = get_subsite_id();
|
|
if ($subsite_id > 0) {
|
|
if ($subsite_id > 0) {
|
|
- return $this->subsite();
|
|
|
|
|
|
+ return $this->_subsite();
|
|
}
|
|
}
|
|
|
|
|
|
$filter_data = [
|
|
$filter_data = [
|
|
@@ -426,12 +426,12 @@ class HomeController extends WebBaseController
|
|
/**
|
|
/**
|
|
* 分站
|
|
* 分站
|
|
*/
|
|
*/
|
|
- private function subsite()
|
|
|
|
|
|
+ private function _subsite()
|
|
{
|
|
{
|
|
//特殊网站
|
|
//特殊网站
|
|
$site_module = explode('.', request()->server('HTTP_HOST'))[0];
|
|
$site_module = explode('.', request()->server('HTTP_HOST'))[0];
|
|
if (method_exists($this, $site_module)) {
|
|
if (method_exists($this, $site_module)) {
|
|
- $this->$site_module();
|
|
|
|
|
|
+ return $this->$site_module();
|
|
}
|
|
}
|
|
|
|
|
|
$return_data = [];
|
|
$return_data = [];
|
|
@@ -495,4 +495,39 @@ class HomeController extends WebBaseController
|
|
|
|
|
|
return json_encode($res, JSON_UNESCAPED_UNICODE + JSON_UNESCAPED_SLASHES);
|
|
return json_encode($res, JSON_UNESCAPED_UNICODE + JSON_UNESCAPED_SLASHES);
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ /**
|
|
|
|
+ * 经开区分站
|
|
|
|
+ */
|
|
|
|
+ private function jkq()
|
|
|
|
+ {
|
|
|
|
+ $return_data = [];
|
|
|
|
+ $subsite_id = get_subsite_id();
|
|
|
|
+
|
|
|
|
+ //公司
|
|
|
|
+ $return_data['seatmeal_companies'] = $this->_dealCompany($subsite_id);
|
|
|
|
+
|
|
|
|
+ //个人登录
|
|
|
|
+ if (auth('web-member')->check()) {
|
|
|
|
+ $return_data['memberInfo'] = $this->memberInfoRepository->getMemberInfo(auth('web-member')->id());
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ //首页轮播图
|
|
|
|
+ $return_data['ad_list'] = [];
|
|
|
|
+ $ad_ids = SubsiteAd::where('subsite_id', $subsite_id)->get(['ad_id'])->pluck('ad_id')->toArray();
|
|
|
|
+ if (!empty($ad_ids)) {
|
|
|
|
+ $return_data['ad_list'] = Ad::whereIn('id', $ad_ids)->get();
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ //文章列表
|
|
|
|
+ $return_data['article_list'] = (new Article())->whereHas('subsites', function ($query) {
|
|
|
|
+ $query->where('subsite_id', get_subsite_id());
|
|
|
|
+ })->orderByRaw('list_order desc,created_at desc')->limit(10)->get();
|
|
|
|
+
|
|
|
|
+ //办理人数
|
|
|
|
+ $jkq_order = collect(DB::table('configs')->where('type_id', '=', 73)->get(['alias', 'value']))->keyBy('alias');
|
|
|
|
+ $return_data['jkq_order'] = $jkq_order;
|
|
|
|
+
|
|
|
|
+ return view('subsite.jkq.index', $return_data);
|
|
|
|
+ }
|
|
}
|
|
}
|