提交 13f36a1b authored 作者: panwy's avatar panwy

Merge branch 'master' of http://120.79.101.85:8181/dengqi/msk

......@@ -30,6 +30,7 @@ class IndexController extends Controller
$cate = new Cate;
$this->showType=$cate->showType();
$this->showType_b=$cate->showType_bottom();
$this->case_cate = $cate->where('id',18)->first();
}
......@@ -59,11 +60,10 @@ class IndexController extends Controller
$news = $content->where('type',$type)->where('isRecommend','1')->orderBy('add_time','desc')->limit(4)->get();
// echo '<pre>';
// print_r($news);exit;
$packs = $pack->where('is_Hot',1)->select('img','title','id','label')->paginate(10);//产品
$banners = $banner->where('isHot','1')->limit(2)->get();
return view('index.index',['banners'=>$banners,'packs'=>$packs,'records'=>$records,'news'=>$news,'con'=>$con,'img'=>$img,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
return view('index.index',['banners'=>$banners,'packs'=>$packs,'records'=>$records,'news'=>$news,'con'=>$con,'img'=>$img,'case_cate'=>$this->case_cate,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
}
//产品页面
......@@ -119,7 +119,7 @@ class IndexController extends Controller
if(!$request->sort){
$sort='0';
}
return view('index.product',['packs'=>$packs,'province'=>$province,'cates'=>$cates,'type'=>$type,'sort'=>$sort,'node_type'=>$node_type,'node_sort'=>$node_sort,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
return view('index.product',['case_cate'=>$this->case_cate,'packs'=>$packs,'province'=>$province,'cates'=>$cates,'type'=>$type,'sort'=>$sort,'node_type'=>$node_type,'node_sort'=>$node_sort,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
}
//产品详情页
......@@ -140,7 +140,7 @@ class IndexController extends Controller
if(!$request->sort){
$sort='0';
}
return view('index.pro_show',['packs'=>$packs,'type'=>$type,'cates'=>$cates,'sort'=>$sort,'node_type'=>$node_type,'node_sort'=>$node_sort,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
return view('index.pro_show',['case_cate'=>$this->case_cate,'packs'=>$packs,'type'=>$type,'cates'=>$cates,'sort'=>$sort,'node_type'=>$node_type,'node_sort'=>$node_sort,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
}
//画廊页面
......@@ -193,7 +193,7 @@ class IndexController extends Controller
}
$nodes = DB::table("node")->where('id',$type)->first();
$banner=$nodes->banner;
return view('index.gallery',['packs'=>$packs,'banner'=>$banner,'province'=>$province,'cates'=>$cates,'type'=>$type,'sort'=>$sort,'node_type'=>$node_type,'node_sort'=>$node_sort,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
return view('index.gallery',['case_cate'=>$this->case_cate,'packs'=>$packs,'banner'=>$banner,'province'=>$province,'cates'=>$cates,'type'=>$type,'sort'=>$sort,'node_type'=>$node_type,'node_sort'=>$node_sort,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
}
//画廊详情页
......@@ -222,7 +222,7 @@ class IndexController extends Controller
$sort='0';
}
// print_r($type);exit;
return view('index.gallery_show',['packs'=>$packs,'type'=>$type,'cates'=>$cates,'sort'=>$sort,'node_type'=>$node_type,'node_sort'=>$node_sort,'feeds'=>$feeds,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
return view('index.gallery_show',['case_cate'=>$this->case_cate,'packs'=>$packs,'type'=>$type,'cates'=>$cates,'sort'=>$sort,'node_type'=>$node_type,'node_sort'=>$node_sort,'feeds'=>$feeds,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
}
public function guide(Request $request)
......@@ -235,7 +235,7 @@ class IndexController extends Controller
$records = $content->where('type',$tid)->where('aTags','0')->orderBy('isSlide','asc')->get();
$arr = $content->where('type',$tid)->where('aTags','1')->orderBy('isSlide','asc')->get();
// print_r($arr);exit;
return view('index.guide',['cates'=>$cates,'showType'=>$this->showType,'showType_b'=>$this->showType_b,'records'=>$records,'arr'=>$arr]);
return view('index.guide',['case_cate'=>$this->case_cate,'cates'=>$cates,'showType'=>$this->showType,'showType_b'=>$this->showType_b,'records'=>$records,'arr'=>$arr]);
}
......@@ -254,7 +254,7 @@ class IndexController extends Controller
}else{
$records = $content->where('type',$id)->orderBy('add_time','desc')->paginate(6);
}
return view('index.news',['records'=>$records,'cates'=>$cates,'re'=>$re,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
return view('index.news',['case_cate'=>$this->case_cate,'records'=>$records,'cates'=>$cates,'re'=>$re,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
}
//媒体
......@@ -275,7 +275,7 @@ class IndexController extends Controller
$records = $content->where('type',$id)->orderBy('add_time','desc')->paginate(6);
}
return view('index.media',['records'=>$records,'cates'=>$cates,'re'=>$re,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
return view('index.media',['case_cate'=>$this->case_cate,'records'=>$records,'cates'=>$cates,'re'=>$re,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
}
//新闻内页
......@@ -291,7 +291,7 @@ class IndexController extends Controller
// print_r($erecord);exit;
$content->where('id',$id)->increment('anum');
$records = $content->where('id',$id)->first();
return view('index.news_show',['records'=>$records,'cates'=>$cates,'erecord'=>$erecord,'frecord'=>$frecord,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
return view('index.news_show',['case_cate'=>$this->case_cate,'records'=>$records,'cates'=>$cates,'erecord'=>$erecord,'frecord'=>$frecord,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
}
......@@ -311,7 +311,7 @@ class IndexController extends Controller
$cates = Cate::where('id',$id)->first();
$records = $content->where('type',$id)->orderBy('add_time','desc')->first();
// print_r($records);exit;
return view('index.contact_us',['records'=>$records,'cates'=>$cates,'showType'=>$this->showType,'showType_b'=>$this->showType_b,'arr'=>$arr]);
return view('index.contact_us',['case_cate'=>$this->case_cate,'records'=>$records,'cates'=>$cates,'showType'=>$this->showType,'showType_b'=>$this->showType_b,'arr'=>$arr]);
}
......@@ -336,7 +336,7 @@ class IndexController extends Controller
}
}
return view('index.video',['records'=>$records,'cates'=>$cates,'re'=>$re,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
return view('index.video',['case_cate'=>$this->case_cate,'records'=>$records,'cates'=>$cates,'re'=>$re,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
}
//视频详情
......@@ -350,7 +350,7 @@ class IndexController extends Controller
}else{
$url = $records->videourl;
}
return view('index.video_show',['records'=>$records,'url'=>$url,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
return view('index.video_show',['case_cate'=>$this->case_cate,'records'=>$records,'url'=>$url,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
}
//案例
......@@ -376,7 +376,7 @@ class IndexController extends Controller
if(!$request->sid){
$sid='0';
}
return view('index.case',['records'=>$records,'cates'=>$cates,'cates_two'=>$cates_two,'sid'=>$sid,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
return view('index.case',['case_cate'=>$this->case_cate,'records'=>$records,'cates'=>$cates,'cates_two'=>$cates_two,'sid'=>$sid,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
}
//案例
......@@ -396,7 +396,7 @@ class IndexController extends Controller
if(!$request->sid){
$sid='0';
}
return view('index.case_show',['records'=>$records,'cates'=>$cates,'cates_two'=>$cates_two,'sid'=>$sid,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
return view('index.case_show',['case_cate'=>$this->case_cate,'records'=>$records,'cates'=>$cates,'cates_two'=>$cates_two,'sid'=>$sid,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
}
//城市
public function area(Request $request)
......@@ -471,7 +471,7 @@ class IndexController extends Controller
$content = new Content;
$cates = Cate::where('id',$id)->first();
$records = $content->where('type',$id)->orderBy('add_time','desc')->first();
return view('index.di',['cates'=>$cates,'records'=>$records,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
return view('index.di',['case_cate'=>$this->case_cate,'cates'=>$cates,'records'=>$records,'showType'=>$this->showType,'showType_b'=>$this->showType_b]);
}
/**
......@@ -504,13 +504,15 @@ class IndexController extends Controller
//];
$total_num = intval($packs_num + $videos_num + $news_num + $infomations_num);
return view('index.index_search',[
'case_cate'=>$this->case_cate,
'packs'=>$packs,'packs_num'=>$packs_num,'videos'=>$videos,'videos_num'=>$videos_num,
'news'=>$news,'news_num'=>$news_num,'infomations'=>$infomations,'infomations_num'=>$infomations_num,
'total_num'=>$total_num,'showType'=>$this->showType,'showType_b'=>$this->showType_b
]);
}else{
return view('index.index_search',[
'msg' => '搜索内容不能为空!','showType'=>$this->showType,'showType_b'=>$this->showType_b
'msg' => '搜索内容不能为空!','showType'=>$this->showType,'showType_b'=>$this->showType_b,
'case_cate'=>$this->case_cate,
]);
}
}
......
......@@ -52,7 +52,7 @@
<a data-am-collapse="{parent: '#collapase-nav-1'}">艺术画廊</a>
</li>
<li class="am-panel">
<a data-am-collapse="{parent: '#collapase-nav-1'}">工程案例</a>
<a data-am-collapse="@if($case_cate->url) {{$case_cate->url}} @else {parent: '#collapase-nav-1'} @endif">工程案例</a>
</li>
<li class="am-panel">
<a data-am-collapse="{parent: '#collapase-nav-1', target: '#news-nav'}">媒体中心 <i class="am-icon-angle-right am-fr am-margin-right"></i></a>
......
Markdown 格式
0% 或
您添加了 0 人 到此讨论。请谨慎行事。
请先完成此评论的编辑!
请 注册 或者 后发表评论