调整但行
This commit is contained in:
@@ -26,7 +26,7 @@ class IndexController extends AdminController
|
||||
}, '所有分类'));
|
||||
});
|
||||
$filter->column(1 / 2, function ($filter) {
|
||||
$filter->equal('position', '定位')
|
||||
$filter->equal('position', '首页推荐位')
|
||||
->select(Article::POSITIONS);
|
||||
});
|
||||
|
||||
@@ -76,7 +76,7 @@ class IndexController extends AdminController
|
||||
$form->number('sort', '序号')->default(0)->rules('required', ['required' => '序号必须填写'])->help('倒序优先');
|
||||
$form->switch('status', '状态')->default(1);
|
||||
$form->text('url', '外链地址');
|
||||
$form->select('position', '定位')
|
||||
$form->select('position', '首页推荐位')
|
||||
->options(Article::POSITIONS);
|
||||
$form->datetime('created_at', '发布时间');
|
||||
$form->saved(function ($form) {
|
||||
|
||||
@@ -55,7 +55,7 @@ class IndexController extends AdminController
|
||||
->removable()
|
||||
->uniqueName();
|
||||
$form->number('order', '排序')->default(0);
|
||||
$form->switch('top_show', '顶部导航显示')->states()->default(0);
|
||||
// $form->switch('top_show', '顶部导航显示')->states()->default(0);
|
||||
$form->switch('status', '显示')->states()->default(1);
|
||||
$form->text('url', '跳转地址')->help('设置后直接跳转到设置的url');
|
||||
|
||||
@@ -122,7 +122,7 @@ class IndexController extends AdminController
|
||||
$form->number('order', '排序')->default(0)->help('正序优先');
|
||||
|
||||
$form->switch('status', '显示')->states()->default(1);
|
||||
$form->switch('top_show', '顶部导航显示')->states();
|
||||
// $form->switch('top_show', '顶部导航显示')->states();
|
||||
$form->text('url', '跳转地址')->help('设置后直接跳转到设置的url');
|
||||
|
||||
$form->saving(function (Form $form) {
|
||||
|
||||
@@ -182,10 +182,12 @@ function getArtilesByCates($cate_id, $take = 8)
|
||||
$cate_ids = Category::where('parent_id', $cate_id)
|
||||
->orWhere('id', $cate_id)
|
||||
->whereIn('type', [Category::TYPE_ARTICLE, Category::TYPE_SHOW])
|
||||
->get();
|
||||
->pluck('id')
|
||||
->toArray();
|
||||
|
||||
return Article::whereIn('category_id', $cate_ids)
|
||||
->latest()
|
||||
->take($take)
|
||||
->get();
|
||||
}
|
||||
|
||||
|
||||
@@ -15,7 +15,6 @@
|
||||
<!-- 科研领域 -->
|
||||
<div class="sub-title">
|
||||
<b><i class="fa fa-flag"></i>{{ getOneCategory(14,'title') }}</b>
|
||||
<a href="{{ getOneCategory(14,'link') }}">更多</a>
|
||||
</div>
|
||||
<ul class="research-award-ul">
|
||||
@foreach (getArticlesBYCate(14,6) as $article)
|
||||
|
||||
@@ -1,15 +1,46 @@
|
||||
<!-- <img class="mian-nav-cover" src="{{ $parent->cover_path }}" alt="导航封面"> -->
|
||||
<div class="mian-nav-title">
|
||||
@if (getCateChild($category->id)->isNotEmpty())
|
||||
<div class="mian-nav-title">
|
||||
{{ $category->title }}
|
||||
</div>
|
||||
<ul class="mian-nav-ul">
|
||||
|
||||
{{ $category->title }}
|
||||
|
||||
</div>
|
||||
<ul class="mian-nav-ul">
|
||||
@if (getCateChild($category->id)->isNotEmpty())
|
||||
@foreach (getCateChild($category->id) as $children)
|
||||
<li class="show">
|
||||
<a href="{{ $children->link }}">{{ $children->title }}</a>
|
||||
</li>
|
||||
@endforeach
|
||||
@endif
|
||||
</ul>
|
||||
</ul>
|
||||
|
||||
@else
|
||||
<div class="mian-nav-title">
|
||||
{{ $category->parent->title }}
|
||||
</div>
|
||||
<ul class="mian-nav-ul">
|
||||
@foreach (getCateChild($category->parent->id) as $children)
|
||||
<li class="show">
|
||||
<a href="{{ $children->link }}">{{ $children->title }}</a>
|
||||
</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
|
||||
@endif
|
||||
|
||||
{{--<div class="mian-nav-title">--}}
|
||||
{{-- {{ $category->title }}--}}
|
||||
{{--</div>--}}
|
||||
{{--<ul class="mian-nav-ul">--}}
|
||||
{{-- @if (getCateChild($category->id)->isNotEmpty())--}}
|
||||
{{-- @foreach (getCateChild($category->id) as $children)--}}
|
||||
{{-- <li class="show">--}}
|
||||
{{-- <a href="{{ $children->link }}">{{ $children->title }}</a>--}}
|
||||
{{-- </li>--}}
|
||||
{{-- @endforeach--}}
|
||||
{{-- @else--}}
|
||||
{{-- @foreach (getCateChild($category->parent->id) as $children)--}}
|
||||
{{-- <li class="show">--}}
|
||||
{{-- <a href="{{ $children->link }}">{{ $children->title }}</a>--}}
|
||||
{{-- </li>--}}
|
||||
{{-- @endforeach--}}
|
||||
{{-- @endif--}}
|
||||
{{--</ul>--}}
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
<div class="container mian">
|
||||
<!-- content-nav -->
|
||||
<nav class="mian-nav">
|
||||
@include('layouts.left',$parent)
|
||||
@include('category.left',$parent)
|
||||
</nav>
|
||||
<!-- content-content -->
|
||||
<div class="mian-content">
|
||||
@@ -15,7 +15,7 @@
|
||||
|
||||
<!-- 省级领军人才梯队 -->
|
||||
@if(getAllTalent(69)->isNotEmpty())
|
||||
{{-- <div class="sub-title">--}}
|
||||
{{-- <div class="sub-title">--}}
|
||||
{{-- <b><i class="fa fa-line-chart"></i>{{ getOneCategory(69,'title') }}</b>--}}
|
||||
{{-- </div>--}}
|
||||
@foreach(getAllTalent(69) as $talent)
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
<div class="container mian">
|
||||
<!-- content-nav -->
|
||||
<nav class="mian-nav">
|
||||
@include('layouts.left',$parent)
|
||||
@include('category.left',$parent)
|
||||
</nav>
|
||||
<!-- content-content -->
|
||||
<div class="mian-content">
|
||||
@@ -15,7 +15,7 @@
|
||||
|
||||
<!-- 省级领军人才梯队 -->
|
||||
@if(getAllTalent(68)->isNotEmpty())
|
||||
{{-- <div class="sub-title">--}}
|
||||
{{-- <div class="sub-title">--}}
|
||||
{{-- <b><i class="fa fa-line-chart"></i>{{ getOneCategory(68,'title') }}</b>--}}
|
||||
{{-- </div>--}}
|
||||
@foreach(getAllTalent(68) as $talent)
|
||||
@@ -37,8 +37,8 @@
|
||||
<p class="rctd3-p">
|
||||
<span>梯队介绍:</span>
|
||||
<span>
|
||||
{{ $talent->description }}
|
||||
</span>
|
||||
{{ $talent->description }}
|
||||
</span>
|
||||
</p>
|
||||
</div>
|
||||
@endforeach
|
||||
|
||||
@@ -78,7 +78,9 @@
|
||||
|
||||
<a href="{{ $pos_b->link }}" class="index-mian-news-href">
|
||||
<p class="nowrap-multi">{{ $pos_b->title }}</p>
|
||||
<p class="nowrap">{{ $pos_b->created_at->format('Y-m-d') }}</p>
|
||||
<p class="nowrap">
|
||||
{{-- {{ $pos_b->created_at->format('Y-m-d') }}--}}
|
||||
</p>
|
||||
</a>
|
||||
@endif
|
||||
</div>
|
||||
@@ -89,7 +91,7 @@
|
||||
<a href="{{ $info->link }}" class="nowrap">
|
||||
<i class="fa fa-chevron-circle-right"></i>
|
||||
{{ $info->title }}
|
||||
<span>{{ $info->created_at->format('Y-m-d') }}</span>
|
||||
{{-- <span>{{ $info->created_at->format('Y-m-d') }}</span>--}}
|
||||
</a>
|
||||
</li>
|
||||
@endforeach
|
||||
@@ -99,7 +101,7 @@
|
||||
|
||||
<!-- 科技成果 -->
|
||||
<div class="index-mian-title">
|
||||
<span><i class="fa fa-flask"></i>{{ getOneCategory(10,'title') }}</span>
|
||||
<span><i class="fa fa-flask"></i>{{ getOneCategory(19,'title') }}</span>
|
||||
<a href="{{ getOneCategory(19,'link') }}">更多<i class="fa fa-plus"></i></a>
|
||||
</div>
|
||||
<div class="index-mian-news">
|
||||
@@ -111,7 +113,10 @@
|
||||
|
||||
<a href="{{ $pos_c->link }}" class="index-mian-news-href">
|
||||
<p class="nowrap-multi">{{ $pos_c->title }}</p>
|
||||
<p class="nowrap">{{ $pos_c->created_at->format('Y-m-d') }}</p>
|
||||
|
||||
<p class="nowrap">
|
||||
{{-- {{ $pos_c->created_at->format('Y-m-d') }}--}}
|
||||
</p>
|
||||
</a>
|
||||
@endif
|
||||
</div>
|
||||
@@ -122,7 +127,7 @@
|
||||
<a href="{{ $info->link }}" class="nowrap">
|
||||
<i class="fa fa-chevron-circle-right"></i>
|
||||
{{ $info->title }}
|
||||
<span>{{ $info->created_at->format('Y-m-d') }}</span>
|
||||
{{-- <span>{{ $info->created_at->format('Y-m-d') }}</span>--}}
|
||||
</a>
|
||||
</li>
|
||||
@endforeach
|
||||
|
||||
Reference in New Issue
Block a user