静态资源
@@ -43,6 +43,7 @@ class IndexController extends AdminController
|
||||
|
||||
/**
|
||||
* Make a form builder.
|
||||
*
|
||||
* @return Form
|
||||
*/
|
||||
protected function form()
|
||||
|
||||
@@ -33,6 +33,11 @@ class IndexController extends AdminController
|
||||
$grid->column('category.title', '所属分类');
|
||||
$grid->column('title', '文章标题');
|
||||
$grid->column('sort', '序号');
|
||||
$states = [
|
||||
'on' => ['value' => 1, 'text' => '打开', 'color' => 'primary'],
|
||||
'off' => ['value' => 2, 'text' => '关闭', 'color' => 'default'],
|
||||
];
|
||||
$grid->column('status', '状态')->switch($states);
|
||||
$grid->column('created_at', '创建时间');
|
||||
|
||||
return $grid;
|
||||
@@ -44,20 +49,26 @@ class IndexController extends AdminController
|
||||
|
||||
$form->text('title', '文章标题')->rules('min:2');
|
||||
$form->select('category_id', '所属分类')
|
||||
->options(Category::selectOptions(function ($model) {
|
||||
return $model->where('status', 1)->whereIn('type', [Category::TYPE_ARTICLE, Category::TYPE_SHOW]);
|
||||
}, '选择分类'))
|
||||
->rules('required|min:1', [
|
||||
'required' => '必须选择所属分类',
|
||||
'min' => '必须选择所属分类',
|
||||
]);
|
||||
->options(Category::selectOptions(function ($model) {
|
||||
return $model->where('status', 1)->whereIn('type', [Category::TYPE_ARTICLE, Category::TYPE_SHOW]);
|
||||
}, '选择分类'))
|
||||
->rules('required|min:1', [
|
||||
'required' => '必须选择所属分类',
|
||||
'min' => '必须选择所属分类',
|
||||
]);
|
||||
$form->textarea('description', '内容简介');
|
||||
$form->image('cover', '封面')
|
||||
->move('images/' . date('Y/m/d'))
|
||||
->removable()
|
||||
->uniqueName();
|
||||
->move('images/' . date('Y/m/d'))
|
||||
->removable()
|
||||
->uniqueName();
|
||||
$form->ueditor('content', '文章内容')->rules('required', ['required' => '详情不能为空']);
|
||||
$form->number('sort', '序号')->default(0)->rules('required', ['required' => '序号必须填写'])->help('倒序优先');
|
||||
$states = [
|
||||
'on' => ['value' => 1, 'text' => '打开', 'color' => 'success'],
|
||||
'off' => ['value' => 0, 'text' => '关闭', 'color' => 'danger'],
|
||||
];
|
||||
|
||||
$form->switch('status', '状态')->states($states)->default(1);
|
||||
|
||||
return $form;
|
||||
}
|
||||
|
||||
@@ -11,6 +11,7 @@ use Encore\Admin\Layout\Row;
|
||||
use Encore\Admin\Tree;
|
||||
use Encore\Admin\Widgets\Box;
|
||||
use Encore\Admin\Widgets\Form as WidgetsForm;
|
||||
use Illuminate\Support\MessageBag;
|
||||
|
||||
class IndexController extends AdminController
|
||||
{
|
||||
@@ -35,6 +36,14 @@ class IndexController extends AdminController
|
||||
$form->text('title', '分类名称')->rules('required');
|
||||
$form->select('type', '分类类型')
|
||||
->options(Category::TYPES)
|
||||
->when('show', function (WidgetsForm $form) {
|
||||
$form->select('article_id', '关联文章')
|
||||
->options(function ($option, $info) {
|
||||
return Article::whereHas('category', function ($q) {
|
||||
$q->where('type', 'show');
|
||||
})->pluck('title', 'id');
|
||||
})->help('当分类类型是文章详情的时候需要选择关联文章');
|
||||
})
|
||||
->required();
|
||||
$form->textarea('description', '分类简介')
|
||||
->rules('nullable');
|
||||
@@ -43,6 +52,7 @@ class IndexController extends AdminController
|
||||
->removable()
|
||||
->uniqueName();
|
||||
$form->number('order', '排序')->default(0);
|
||||
$form->switch('top_show', '顶部导航显示')->states()->default(0);
|
||||
$form->switch('status', '显示')->states()->default(1);
|
||||
$form->action(admin_url('categories'));
|
||||
|
||||
@@ -89,6 +99,14 @@ class IndexController extends AdminController
|
||||
$form->text('title', '分类名称')->rules('required');
|
||||
$form->select('type', '分类类型')
|
||||
->options(Category::TYPES)
|
||||
->when('show', function (Form $form) {
|
||||
$form->select('article_id', '关联文章')
|
||||
->options(function ($option, $info) {
|
||||
return Article::whereHas('category', function ($q) {
|
||||
$q->where('type', 'show');
|
||||
})->pluck('title', 'id');
|
||||
})->help('当分类类型是文章详情的时候需要选择关联文章');
|
||||
})
|
||||
->required()
|
||||
->rules('required');
|
||||
$form->textarea('description', '分类简介')->rows(4)->rules('nullable');
|
||||
@@ -97,27 +115,19 @@ class IndexController extends AdminController
|
||||
->removable()
|
||||
->uniqueName();
|
||||
$form->number('order', '排序')->default(0);
|
||||
$form->select('article_id', '关联文章')
|
||||
->options(function ($option, $info) {
|
||||
$category = $this;
|
||||
if ($category) {
|
||||
return Article::where('category_id', $category->id)->pluck('title', 'id');
|
||||
} else {
|
||||
return [0 => '没有数据'];
|
||||
}
|
||||
})->help('当分类类型是文章详情的时候需要选择关联文章');
|
||||
$form->switch('top_show', '顶部导航显示')->states()->default(0);
|
||||
|
||||
$form->switch('status', '显示')->states()->default(1);
|
||||
$form->saving(function (Form $form) {
|
||||
|
||||
if (request()->has('title')) {
|
||||
if (request()->type == Category::TYPE_SHOW && empty(request()->article_id)) {
|
||||
$error = new MessageBag([
|
||||
'title' => '错误',
|
||||
'message' => '文章类型是文章详情的时候需要选择关联文章',
|
||||
]);
|
||||
|
||||
return back()->withInput()->with(compact('error'));
|
||||
// $error = new MessageBag([
|
||||
// 'title' => '错误',
|
||||
// 'message' => '文章类型是文章详情的时候需要选择关联文章',
|
||||
// ]);
|
||||
//
|
||||
// return back()->withInput()->with(compact('error'));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,67 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace App\Admin\Controllers;
|
||||
|
||||
use Encore\Admin\Controllers\AdminController;
|
||||
use Encore\Admin\Form;
|
||||
use Encore\Admin\Grid;
|
||||
use Encore\Admin\Show;
|
||||
|
||||
class ExampleController extends AdminController
|
||||
{
|
||||
/**
|
||||
* Title for current resource.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $title = 'Example controller';
|
||||
|
||||
/**
|
||||
* Make a grid builder.
|
||||
*
|
||||
* @return Grid
|
||||
*/
|
||||
protected function grid()
|
||||
{
|
||||
$grid = new Grid(new ExampleModel);
|
||||
|
||||
$grid->column('id', __('ID'))->sortable();
|
||||
$grid->column('created_at', __('Created at'));
|
||||
$grid->column('updated_at', __('Updated at'));
|
||||
|
||||
return $grid;
|
||||
}
|
||||
|
||||
/**
|
||||
* Make a show builder.
|
||||
*
|
||||
* @param mixed $id
|
||||
* @return Show
|
||||
*/
|
||||
protected function detail($id)
|
||||
{
|
||||
$show = new Show(ExampleModel::findOrFail($id));
|
||||
|
||||
$show->field('id', __('ID'));
|
||||
$show->field('created_at', __('Created at'));
|
||||
$show->field('updated_at', __('Updated at'));
|
||||
|
||||
return $show;
|
||||
}
|
||||
|
||||
/**
|
||||
* Make a form builder.
|
||||
*
|
||||
* @return Form
|
||||
*/
|
||||
protected function form()
|
||||
{
|
||||
$form = new Form(new ExampleModel);
|
||||
|
||||
$form->display('id', __('ID'));
|
||||
$form->display('created_at', __('Created At'));
|
||||
$form->display('updated_at', __('Updated At'));
|
||||
|
||||
return $form;
|
||||
}
|
||||
}
|
||||
@@ -10,10 +10,11 @@ use Encore\Admin\Layout\Row;
|
||||
|
||||
class HomeController extends Controller
|
||||
{
|
||||
|
||||
public function index(Content $content)
|
||||
{
|
||||
return $content
|
||||
->title('Dashboard')
|
||||
->title('看板')
|
||||
->description('Description...')
|
||||
->row(Dashboard::title())
|
||||
->row(function (Row $row) {
|
||||
@@ -22,13 +23,14 @@ class HomeController extends Controller
|
||||
$column->append(Dashboard::environment());
|
||||
});
|
||||
|
||||
$row->column(4, function (Column $column) {
|
||||
$column->append(Dashboard::extensions());
|
||||
});
|
||||
|
||||
$row->column(4, function (Column $column) {
|
||||
$column->append(Dashboard::dependencies());
|
||||
});
|
||||
// $row->column(4, function (Column $column) {
|
||||
// $column->append(Dashboard::extensions());
|
||||
// });
|
||||
//
|
||||
// $row->column(4, function (Column $column) {
|
||||
// $column->append(Dashboard::dependencies());
|
||||
// });
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
126
app/Helpers/function.php
Normal file
@@ -0,0 +1,126 @@
|
||||
<?php
|
||||
|
||||
use App\Models\Advert;
|
||||
use App\Models\Category;
|
||||
use App\Models\Article;
|
||||
|
||||
function getOneCategory($categoryId, $return = '')
|
||||
{
|
||||
$category = Category::find($categoryId);
|
||||
if ($category) {
|
||||
if ($return) {
|
||||
return $category->{$return};
|
||||
}
|
||||
|
||||
return $category;
|
||||
}
|
||||
|
||||
return new Category;
|
||||
}
|
||||
|
||||
/**
|
||||
* Notes: 获取文章分类详情
|
||||
* @Author: 玄尘
|
||||
* @Date : 2020/9/10 13:21
|
||||
* @param $categoryId
|
||||
* @param string $result
|
||||
* @return \App\Models\Article
|
||||
*/
|
||||
function getOneArticleBYCate($categoryId, $result = '')
|
||||
{
|
||||
$info = Article::where('category_id', $categoryId)->latest('sort')->latest()->first();
|
||||
|
||||
if ($info) {
|
||||
if ($result) {
|
||||
return $info->{$result};
|
||||
}
|
||||
|
||||
return $info;
|
||||
} else {
|
||||
return '';
|
||||
}
|
||||
|
||||
return new Article;
|
||||
}
|
||||
|
||||
/**
|
||||
* Notes: 获取分类下的文章
|
||||
* @Author: 玄尘
|
||||
* @Date : 2020/9/10 10:05
|
||||
* @param $categoryId
|
||||
* @param $take
|
||||
* @return \App\Models\Article
|
||||
*/
|
||||
function getArticlesBYCate($categoryId, $take = 8, $mark = 'one')
|
||||
{
|
||||
if ($mark == 'one') {
|
||||
$articles = Article::where('category_id', $categoryId)
|
||||
->where('status', 1)
|
||||
->latest('sort')
|
||||
->latest()
|
||||
->take($take)
|
||||
->get();
|
||||
} else {
|
||||
$cate = Category::find($categoryId);
|
||||
$ids = $cate->getAllChildrenId();
|
||||
|
||||
$articles = Article::whereIn('category_id', $ids)
|
||||
->where('status', 1)
|
||||
->latest('sort')
|
||||
->latest()
|
||||
->take($take)
|
||||
->get();
|
||||
}
|
||||
|
||||
return $articles;
|
||||
}
|
||||
|
||||
//获取子分类
|
||||
function getCateChild($categoryId)
|
||||
{
|
||||
return Category::where('status', 1)
|
||||
->where('parent_id', $categoryId)
|
||||
->orderBy('order', 'asc')
|
||||
->get();
|
||||
}
|
||||
|
||||
//获取顶级分类
|
||||
function getTopCate($categoryId)
|
||||
{
|
||||
$parent = Category::find($categoryId);
|
||||
|
||||
while ($parent->parent_id != 0) {
|
||||
$parent = $parent->parent;
|
||||
}
|
||||
|
||||
return $parent;
|
||||
}
|
||||
|
||||
//获取一个广告
|
||||
function getOneAdvertByCate($categoryId, $result = '')
|
||||
{
|
||||
$info = Advert::where('category_id', $categoryId)
|
||||
->latest('sort')
|
||||
->latest()
|
||||
->first();
|
||||
if ($info) {
|
||||
if ($result) {
|
||||
return $info->{$result};
|
||||
}
|
||||
|
||||
return $info;
|
||||
} else {
|
||||
return '';
|
||||
}
|
||||
|
||||
return new Advert;
|
||||
}
|
||||
|
||||
function getAdvertsByCate($categoryId, $take = 8)
|
||||
{
|
||||
return Advert::where('category_id', $categoryId)
|
||||
->latest('sort')
|
||||
->latest()
|
||||
->take($take)->get();
|
||||
}
|
||||
|
||||
@@ -10,18 +10,20 @@ class ArticleController extends Controller
|
||||
|
||||
/**
|
||||
* 显示分类
|
||||
* @param Category $category [description]
|
||||
* @param Category $category [description]
|
||||
* @return [type] [description]
|
||||
*/
|
||||
public function show(Article $article)
|
||||
{
|
||||
$parent = $category = $article->category;
|
||||
if ($category->childrens->isEmpty()) {
|
||||
$parent = $category->parent;
|
||||
}
|
||||
$advert = Advert::where('category_id',73)->first();
|
||||
$category = $article->category;
|
||||
$parent = getTopCate($category->id);
|
||||
|
||||
return view('article.show', compact('article', 'parent', 'category','advert'));
|
||||
$next = Article::where('id', '>', $article->id)
|
||||
->where('category_id', $article->category_id)
|
||||
->where('status', 1)
|
||||
->first();
|
||||
|
||||
return view('article.show', compact('article', 'next', 'parent'));
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ class CategoryController extends Controller
|
||||
|
||||
/**
|
||||
* 显示分类
|
||||
* @param Category $category [description]
|
||||
* @param Category $category [description]
|
||||
* @return [type] [description]
|
||||
*/
|
||||
public function index(Category $category)
|
||||
@@ -18,15 +18,15 @@ class CategoryController extends Controller
|
||||
if ($category->type == Category::TYPE_SHOW && $category->article_id) {
|
||||
return redirect("articles/" . $category->article_id);
|
||||
} else {
|
||||
$articles = $category->relations(Category::TYPE_ARTICLE)->paginate();
|
||||
$articles = $category->relations(Category::TYPE_ARTICLE)->paginate(8);
|
||||
$parent = $category;
|
||||
if ($category->childrens->isEmpty()) {
|
||||
$parent = $category->parent;
|
||||
}
|
||||
|
||||
$advert = Advert::where('category_id',73)->first();
|
||||
$advert = Advert::where('category_id', 73)->first();
|
||||
|
||||
return view('category.show', compact('articles', 'category', 'parent','advert'));
|
||||
return view('category.show', compact('articles', 'category', 'parent', 'advert'));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -4,6 +4,7 @@ namespace App\Http\Controllers;
|
||||
|
||||
use App\Models\Advert;
|
||||
use App\Models\Category;
|
||||
use App\Models\Link;
|
||||
use Illuminate\Foundation\Auth\Access\AuthorizesRequests;
|
||||
use Illuminate\Foundation\Bus\DispatchesJobs;
|
||||
use Illuminate\Foundation\Validation\ValidatesRequests;
|
||||
@@ -19,19 +20,15 @@ class Controller extends BaseController
|
||||
{
|
||||
//顶部分类
|
||||
$categorys = Category::where('status', 1)
|
||||
->whereIn('type', [Category::TYPE_ARTICLE, Category::TYPE_SHOW])
|
||||
->where('top_show', 1)
|
||||
->orderBy('order', 'desc')
|
||||
->select('id', 'title')
|
||||
->get();
|
||||
->whereIn('type', [Category::TYPE_ARTICLE, Category::TYPE_SHOW])
|
||||
->where('top_show', 1)
|
||||
->orderBy('order', 'desc')
|
||||
->select('id', 'title')
|
||||
->get();
|
||||
$links = Link::get();
|
||||
|
||||
//地步友情链接
|
||||
if (url()->current() == route('index.index')) {
|
||||
$adverts = Advert::where('category_id', 26)->get();
|
||||
View::share('adverts', $adverts);
|
||||
|
||||
}
|
||||
View::share('all_categorys', $categorys);
|
||||
View::share('links', $links);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
|
||||
namespace App\Http\Controllers;
|
||||
|
||||
use App\Models\Advert;
|
||||
use App\Models\Article;
|
||||
use App\Models\Link;
|
||||
|
||||
@@ -15,26 +16,29 @@ class IndexController extends Controller
|
||||
*/
|
||||
public function index()
|
||||
{
|
||||
$fydt = $this->getArticle([6], 9); //分院动态
|
||||
$kydt = $this->getArticle([9], 9); //科研动态
|
||||
$ldbz = $this->getArticle([3], 4); //领导班子
|
||||
$kycg = $this->getArticle([10], 8); //科研成果
|
||||
$rctd = $this->getArticle([4], 9); //人才团队介绍
|
||||
$fydt = $this->getArticle([6], 9); //分院动态
|
||||
$kydt = $this->getArticle([9], 9); //科研动态
|
||||
$ldbz = $this->getArticle([3], 4); //领导班子
|
||||
$kycg = $this->getArticle([10], 8); //科研成果
|
||||
$rctd = $this->getArticle([4], 9); //人才团队介绍
|
||||
$info = Article::where('category_id', 2)->first(); //院所介绍
|
||||
$links = Link::get();
|
||||
|
||||
return view('index.index', compact('links', 'fydt', 'kydt', 'ldbz', 'kycg', 'rctd', 'info'));
|
||||
$advert = Advert::where('category_id', 26)->latest('sort')->first();
|
||||
$center_advert = Advert::where('category_id', 28)->latest('sort')->first();
|
||||
|
||||
return view('index.index', compact('advert', 'center_advert', 'fydt', 'kydt', 'ldbz', 'kycg', 'rctd', 'info'));
|
||||
}
|
||||
|
||||
//通用获取文章
|
||||
public function getArticle($category_ids, $take = 3)
|
||||
{
|
||||
return Article::whereIn('category_id', $category_ids)
|
||||
->select('id', 'description', 'title', 'created_at', 'cover', 'content')
|
||||
->latest('sort')
|
||||
->latest()
|
||||
->take($take)
|
||||
->get();
|
||||
->select('id', 'description', 'title', 'created_at', 'cover', 'content')
|
||||
->latest('sort')
|
||||
->latest()
|
||||
->take($take)
|
||||
->get();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -10,6 +10,7 @@ use App\Traits\Tree;
|
||||
|
||||
class TestController extends Controller
|
||||
{
|
||||
|
||||
use Tree;
|
||||
|
||||
public function index()
|
||||
@@ -40,9 +41,12 @@ class TestController extends Controller
|
||||
dump(count($cateids));
|
||||
dump(count($oldids));
|
||||
dump($diffids);
|
||||
|
||||
dd();
|
||||
foreach ($diffids as $diffid) {
|
||||
$info = DedeArctype::where('id', $diffid)->where('ishidden', 0)->select('id', 'reid as parent_id', 'typename as title', 'content')->first();
|
||||
$info = DedeArctype::where('id', $diffid)
|
||||
->where('ishidden', 0)
|
||||
->select('id', 'reid as parent_id', 'typename as title', 'content')
|
||||
->first();
|
||||
$data = $this->getData($info);
|
||||
Category::create($data);
|
||||
}
|
||||
@@ -83,14 +87,20 @@ class TestController extends Controller
|
||||
|
||||
public function checkArticle()
|
||||
{
|
||||
// $lists = Article::where('category_id', 0)->get();
|
||||
// foreach ($lists as $list) {
|
||||
// $old = DedeArchive::find($list->oldid);
|
||||
// $cate = Category::where('oldid', $old->typeid)->first();
|
||||
// $list->category_id = $cate->id;
|
||||
// $list->save();
|
||||
// }
|
||||
// dd();
|
||||
$lists = Article::where('category_id', 0)->get();
|
||||
|
||||
foreach ($lists as $list) {
|
||||
$old = DedeArchive::find($list->oldid);
|
||||
$cate = Category::where('oldid', $old->typeid)->first();
|
||||
if (!$cate || !$old) {
|
||||
dump($old);
|
||||
dump($cate);
|
||||
dd('出问题了');
|
||||
}
|
||||
$list->category_id = $cate->id;
|
||||
$list->save();
|
||||
}
|
||||
dd();
|
||||
$articleids = Article::where('oldid', '>', 0)->pluck('oldid');
|
||||
$oldids = DedeArchive::pluck('id');
|
||||
$diffids = array_diff($oldids->toArray(), $articleids->toArray());
|
||||
@@ -98,7 +108,7 @@ class TestController extends Controller
|
||||
dump(count($oldids));
|
||||
dump($diffids);
|
||||
die();
|
||||
$map = [
|
||||
$map = [
|
||||
'id' => ['in', $diffids],
|
||||
];
|
||||
$list = DedeArchive::whereIn('id', $diffids)->get();
|
||||
@@ -128,7 +138,7 @@ class TestController extends Controller
|
||||
dd('已经导入过数据');
|
||||
}
|
||||
$categorys = Category::get();
|
||||
$error = $success = [];
|
||||
$error = $success = [];
|
||||
DedeArchive::whereNotNull('litpic')->chunk(200, function ($articles) use ($categorys) {
|
||||
|
||||
foreach ($articles as $article) {
|
||||
@@ -168,7 +178,9 @@ class TestController extends Controller
|
||||
if ($categorys->count() > 1) {
|
||||
dd('已经导入过数据');
|
||||
}
|
||||
$lists = DedeArctype::where('ishidden', 0)->select('id', 'reid as parent_id', 'typename as title', 'content')->get();
|
||||
$lists = DedeArctype::where('ishidden', 0)
|
||||
->select('id', 'reid as parent_id', 'typename as title', 'content')
|
||||
->get();
|
||||
$list = Tree::list2tree($lists->toArray(), 'id', 'parent_id', 'children', 0);
|
||||
|
||||
foreach ($list as $key => $value) {
|
||||
@@ -191,6 +203,7 @@ class TestController extends Controller
|
||||
'content' => $category['content'],
|
||||
'status' => 1,
|
||||
];
|
||||
|
||||
return $data;
|
||||
}
|
||||
|
||||
|
||||
@@ -7,8 +7,14 @@ use App\Models\Traits\HasOneCover;
|
||||
|
||||
class Article extends Model
|
||||
{
|
||||
|
||||
use HasOneCover, BelongsToCategory;
|
||||
|
||||
public function getLinkAttribute()
|
||||
{
|
||||
return route('article.show', $this);
|
||||
}
|
||||
|
||||
public function get_content_cover()
|
||||
{
|
||||
preg_match("/<img.*?src=\"([^\"]+)\"[^>].*?>/isU", str_ireplace("\\", "", $this->content), $matches);
|
||||
@@ -39,6 +45,7 @@ class Article extends Model
|
||||
$path = config('app.url') . $path;
|
||||
|
||||
}
|
||||
|
||||
return $path;
|
||||
|
||||
}
|
||||
|
||||
@@ -7,17 +7,22 @@ use Encore\Admin\Traits\ModelTree;
|
||||
|
||||
class Category extends Model
|
||||
{
|
||||
|
||||
use AdminBuilder, ModelTree;
|
||||
|
||||
public const TYPES = [
|
||||
'article' => '文章列表',
|
||||
'show' => '文章详情',
|
||||
'advert' => '广告',
|
||||
];
|
||||
|
||||
public const TYPE_SHOW = 'show';
|
||||
public const TYPE_SHOW = 'show';
|
||||
public const TYPE_ARTICLE = 'article';
|
||||
public const TYPE_ADVERT = 'advert';
|
||||
public const TYPES = [
|
||||
self::TYPE_ARTICLE => '文章列表',
|
||||
self::TYPE_SHOW => '文章详情',
|
||||
self::TYPE_ADVERT => '图片',
|
||||
];
|
||||
|
||||
public function getLinkAttribute()
|
||||
{
|
||||
return route('category.show', $this);
|
||||
}
|
||||
|
||||
/**
|
||||
* 关联的数据
|
||||
@@ -42,12 +47,12 @@ class Category extends Model
|
||||
|
||||
public function childrens()
|
||||
{
|
||||
return $this->hasMany(self::class,'parent_id');
|
||||
return $this->hasMany(self::class, 'parent_id');
|
||||
}
|
||||
|
||||
public function parent()
|
||||
{
|
||||
return $this->hasOne(self::class,'id','parent_id');
|
||||
return $this->hasOne(self::class, 'id', 'parent_id');
|
||||
}
|
||||
|
||||
public function article()
|
||||
|
||||
@@ -40,6 +40,9 @@
|
||||
"classmap": [
|
||||
"database/seeds",
|
||||
"database/factories"
|
||||
],
|
||||
"files": [
|
||||
"app/Helpers/function.php"
|
||||
]
|
||||
},
|
||||
"autoload-dev": {
|
||||
|
||||
4079
newdqb.sql
Normal file
4
public/assets/index/css/font-awesome.min.css
vendored
Normal file
@@ -1,194 +1,733 @@
|
||||
@charset "utf-8";
|
||||
/* CSS Document */
|
||||
*{ margin:0; padding:0}
|
||||
ul li{ list-style:none}
|
||||
img{ border:0; max-width:100%}
|
||||
a{ text-decoration:none; color:#333}
|
||||
.clear{ clear:both}
|
||||
body{ font-family:"微软雅黑"; width:100%; min-width:1200px;color: #333;font-size: 14px;}
|
||||
.ccsl{ display:block;overflow:hidden; white-space:nowrap;text-overflow:ellipsis;}
|
||||
p{text-align:justify}
|
||||
@charset "UTF-8";
|
||||
|
||||
.main{ width:1200px; margin:0 auto;}
|
||||
html, body {
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
font-size: 14px;
|
||||
font-family: "微软雅黑";
|
||||
color: #333;
|
||||
}
|
||||
|
||||
a {
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.banner{ width:100%; min-width:1200px; /*height:400px;*/ overflow:hidden; position:relative;font-size:0; margin:0 auto;}
|
||||
.b-img{ /*height:400px;*/ position:absolute; left:0; top:0;}
|
||||
.b-img img{ display:block; /*height:400px;*/ float:left;}
|
||||
.b-list{ height:20px; /*padding-top:380px;*/ margin:0 auto;position:relative;z-index:1;}
|
||||
.b-list span{ display:block;cursor:pointer; width:10px; height:10px; border-radius:50%; background:#fff; float:left; margin:0 5px; _margin:0 3px;}
|
||||
.b-list .spcss{ background:#0580c8}
|
||||
a:hover {
|
||||
color: #203175;
|
||||
}
|
||||
|
||||
.topbox{ width:100%; min-width:1200px; height:40px; line-height:40px; overflow:hidden;background:#ededed;}
|
||||
.topbox p{ width:1200px; margin:0 auto; font-size:14px; color:#333;}
|
||||
a, a:hover {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.logo{ width:1200px; margin:0 auto; overflow:hidden}
|
||||
.logo img{ display:block; width:1200px;}
|
||||
p, h1, h2, h3, h4 {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.nav{width:100%; min-width:1200px; overflow:hidden;background: #0580c8;height: 54px;}
|
||||
.nav ul{ overflow:hidden}
|
||||
.nav ul li{ float:left;width: 125px;height: 54px;text-align: center;line-height: 54px; overflow:hidden; margin-right:1px}
|
||||
.nav ul li a{color: #fff;font-size: 15px; display:block}
|
||||
.nav ul li:hover,.nav ul li.on{ background:rgb(74, 136, 207)}
|
||||
ul {
|
||||
list-style: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.part1{margin: 20px auto; width:1200px;color: #666;font-size: 14px;line-height: 28px; height:28px; overflow:hidden}
|
||||
.part1 span{ display:block; float:left; font-weight:bold;}
|
||||
.part1 .con{ float:left; max-width:1000px; overflow:hidden}
|
||||
.part1 .con a{ display:inline-block;color: #666; padding-right:5px}
|
||||
img {
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
.part2{ width:100%; min-width:1200px;background:#F3F3F3; padding:20px 0}
|
||||
.part2 .titbox{width: 340px;margin: 20px auto;height: 65px;text-align: center; overflow:hidden}
|
||||
.part2 .titbox p{ text-align:center;color: #0580c8;font-weight:bold;font-size: 30px;}
|
||||
.part2 .titbox em{font-style:normal;text-transform: uppercase;color: #afb2af;font-size: 14px;font-family: arial;text-align: center;margin-left: 10px;}
|
||||
/* 文字裁剪 */
|
||||
.nowrap {
|
||||
max-width: 100%;
|
||||
overflow: hidden;
|
||||
white-space: nowrap;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.part2 ul{ padding-bottom:20px; overflow:hidden}
|
||||
.part2 ul li{background: #fff;width: 285px;height: 324px;float: left;margin: 10px 20px 10px 0;overflow: hidden;}
|
||||
.part2 ul li:nth-child(4n){ margin-right:0}
|
||||
.part2 ul li img{margin: 10px 10px 0 10px;width: 265px;height: 265px;}
|
||||
.part2 ul li p{ text-align:center;line-height: 48px;color: #333; font-size: 16px;}
|
||||
.part2 ul li:hover p{color: #0580c8;}
|
||||
.nowrap-multi {
|
||||
display: -webkit-box;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
-webkit-box-orient: vertical;
|
||||
-webkit-line-clamp: 2;
|
||||
}
|
||||
|
||||
.part3{ padding-top:46px; width:1200px; margin:0 auto; overflow:hidden; padding-bottom:20px}
|
||||
.part3 .titbox{width: 600px;margin:0 auto;text-align: center;}
|
||||
.part3 .titbox p{padding-top: 18px; font-weight:bold;font-size: 28px;color: #000;text-align: center;}
|
||||
.part3 .titbox span{font-style:normal;text-transform: uppercase;color: #afb2af;font-size: 14px;font-family: arial;text-align: center;line-height: 34px;}
|
||||
.part3box{ padding-top:30px;}
|
||||
.part3box .p3L{border: 10px solid #eee;width: 315px;height: 216px;margin-right: 20px;float: left; overflow:hidden}
|
||||
.part3box .p3L img{width: 315px;height: 216px;}
|
||||
.part3box .p3R{width: 845px;float: left; padding-top: 10px;}
|
||||
.part3box .p3R .con{color: #666666;font-size: 14px;line-height: 2;margin-bottom: 10px; max-height:170px; overflow:hidden}
|
||||
.part3box .p3R a.more{border-radius: 20px;padding: 2px 10px;background: #0580c8;color: #fff;margin-top: 10px;display: inline-block;}
|
||||
.part3box .p3R a.more:hover{background: #ccc;color: #000;transition: all .5s;}
|
||||
.marqueeleft{width:1200px;overflow:hidden; padding-top:40px}
|
||||
.marqueeleft ul{float:left;}
|
||||
.marqueeleft li{float:left;display:inline;height:128px;overflow:hidden; padding-right:20px }
|
||||
/* 禁止响应式 */
|
||||
.container {
|
||||
width: 1190px;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
/* 首页 */
|
||||
.mian {
|
||||
background-color: #eff0f4;
|
||||
}
|
||||
|
||||
.part4{width:100%; min-width:1200px; background:url(../images/bg.jpg) repeat;padding: 43px 0;margin: 20px auto;}
|
||||
.part4box{ float:left;width: 582px;overflow: hidden;}
|
||||
.part4box .titbox{ height:27px; overflow:hidden; line-height:27px;}
|
||||
.part4box .titbox h2{ float:left;color: #0580c8;font-size: 18px;font-weight: normal; max-width:450px; overflow:hidden;border-left: 4px solid #0580c8; padding-left: 10px;}
|
||||
.part4box .titbox a{ float:right;color: #333;font-size: 14px;}
|
||||
.mian-title {
|
||||
border-bottom: solid 1px #e6e6e6;
|
||||
padding: 10px 0;
|
||||
margin-bottom: 20px;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.part4box .cons{background: #fff;margin-top: 20px;padding: 10px;}
|
||||
.p4one{ height:147px; overflow:hidden}
|
||||
.p4one .p4oneL{width:183px; height:137px;float: left;margin-right: 10px;margin-bottom: 10px; overflow:hidden}
|
||||
.p4one .p4oneL img{width:183px; height:137px;}
|
||||
.p4one .p4oneR{width: 350px;height:137px;float: right; overflow:hidden}
|
||||
.p4one .p4oneR a{font-weight: bold;color: #333;font-size: 14px;margin: 10px 0; float:left; max-width:250px;}
|
||||
.p4one .p4oneR span{ margin:10px 0; float:right;font-weight: normal;font-size: 14px;color: #666;}
|
||||
.p4one .p4oneR .sub{font-size: 14px;line-height: 1.8; height:75px; overflow:hidden}
|
||||
.p4one .p4oneR a:hover{ color:#0580c8}
|
||||
.mian-title b {
|
||||
font-size: 18px;
|
||||
padding: 0 10px;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.part4 ul{ padding-top:15px; overflow:hidden}
|
||||
.part4 ul li{line-height:35px; overflow:hidden;height:35px;border-bottom: 1px dotted #ccc;}
|
||||
.part4 ul li p{background: #0580c8;width: 14px;height: 14px;border-radius: 50%;float: left;text-align: center;color: #fff;margin-right: 15px;line-height: 14px;margin-top: 10px; font-size:14px;}
|
||||
.part4 ul li a{ float:left;color: #333;font-size: 14px; max-width:410px;}
|
||||
.part4 ul li span{ float:right;color: #666;font-size: 14px;}
|
||||
.part4 ul li:hover p{background: #ccc;color: #000; transition: all .5s;}
|
||||
.part4 ul li:hover a{color: #0580c8;transition: all .5s;}
|
||||
.part4 ul li:hover span{color: #0580c8; transition: all .5s;}
|
||||
.mian-title b::before {
|
||||
content: "";
|
||||
position: absolute;
|
||||
bottom: -11px;
|
||||
left: 0;
|
||||
right: 0;
|
||||
height: 3px;
|
||||
background-color: #203175;
|
||||
}
|
||||
|
||||
.part4box.fr{ float:right}
|
||||
.mian-title span {
|
||||
color: gray;
|
||||
font-size: 14px;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
.mian-title-more {
|
||||
position: absolute;
|
||||
right: 0;
|
||||
line-height: 25px;
|
||||
color: gray;
|
||||
padding: 0 15px;
|
||||
}
|
||||
|
||||
.linkbox{margin: 40px auto; width:1200px; overflow:hidden}
|
||||
.linkbox .linkL{ width:81px; height:70px; overflow:hidden; float:left}
|
||||
.linkbox .linkL .p1{ width:73px; height:35px; padding-left:8px; line-height:35px; color:#fff; font-size:14px; background:url(../images/icon.png) no-repeat}
|
||||
.linkbox .linkL .p2{width:73px; height:35px; padding-left:8px;color:#fff; line-height:35px; font-size:14px; background:url(../images/icon2.png) no-repeat}
|
||||
.linkbox .linkR{width: 1096px;float: right;border: 1px solid #ccc; height: 50px;padding: 10px;font-size: 14px;line-height: 2;overflow: hidden;}
|
||||
.linkbox .linkR a{color: #797979;margin: 0 5px;display: inline-block;}
|
||||
.mian-title-more i {
|
||||
margin-left: 5px;
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
/* 广告条 */
|
||||
.index-ad {
|
||||
width: 100%;
|
||||
margin-top: 30px;
|
||||
}
|
||||
|
||||
.footer{width:100%; min-width:1200px; background: #000;padding: 20px 0;font-size: 14px;}
|
||||
.fnav{ color:#a2a2a2; max-width:1200px; margin:0 auto; text-align:center}
|
||||
.fnav a{display: inline-block;line-height: 2;margin: 0 5px 20px;color: #fff;}
|
||||
.foot{ text-align:center;color: #a2a2a2; line-height:2}
|
||||
.index-ad img {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
/* tool */
|
||||
.tool {
|
||||
background-color: #eff0f4;
|
||||
height: 40px;
|
||||
line-height: 40px;
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
.mainWarp{ width:1200px; margin:0 auto;margin: 40px auto;}
|
||||
.mainLeft{float: left;width: 220px;}
|
||||
.typebox{border: 2px solid #0580c8;width: 212px;min-height:50px;background: #fcfcfc;}
|
||||
.typebox .tit{background:#0580c8;color: #fff;font-size: 18px;font-weight: normal;line-height: 2.5;}
|
||||
.typebox .tit p{ text-align:center}
|
||||
.typebox ul{ overflow:hidden;margin-top: 20px;margin-bottom: 10px;}
|
||||
.typebox ul li{background: #e1e1e1;margin: 10px 15px;line-height:35px;font-size: 14px; height:35px;}
|
||||
.typebox ul li a{ float:left;color: #444444; max-width:140px;}
|
||||
.typebox ul li p{ float:left;margin: 12px 10px;background: #000;border-radius: 50%;width: 12px;height: 12px;color: #fff;line-height: 0.8;text-align: center;}
|
||||
.typebox ul li:hover{background: #0580c8; transition: all .5s;}
|
||||
.typebox ul li:hover p{background: #fff;color: #000; transition: all .5s;}
|
||||
.typebox ul li:hover a{color: #fff;transition: all .5s;}
|
||||
.tool a {
|
||||
color: gray;
|
||||
margin-left: 20px;
|
||||
transition: color .4s;
|
||||
}
|
||||
|
||||
.mainLeft .titboxcon{border-left: 4px solid #0580c8; height:27px;padding-left: 10px;margin:20px 0 10px; overflow:hidden}
|
||||
.mainLeft .titboxcon p{font-size: 18px;color: #0580c8;}
|
||||
.mainLeft .lxwm{}
|
||||
.mainLeft .lxwm .con{line-height: 2; padding-top:10px}
|
||||
ul.newsul{ overflow:hidden}
|
||||
ul.newsul li{ height:35px;line-height:35px;color: #666; border-bottom:1px dashed #ddd}
|
||||
ul.newsul li a{ color:#666}
|
||||
ul.newsul li a:hover{ color:#0580c8}
|
||||
.tool a i {
|
||||
margin-right: 3px;
|
||||
}
|
||||
|
||||
.tool a:hover {
|
||||
color: #203175;
|
||||
}
|
||||
|
||||
/* 导航 */
|
||||
.header {
|
||||
padding: 10px 0;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.mainRight{ float:right; width:962px; overflow:hidden}
|
||||
.brandnav{width: 950px;border: 1px solid #ccc;padding: 5px; height:25px; line-height:25px; overflow:hidden}
|
||||
.brandnav p{ float:left;color: #0580c8;font-size: 16px;font-weight: normal;padding-left: 10px; max-width:200px;}
|
||||
.brandnav .con{ float:right; font-size:14px; color:#333; max-width:300px}
|
||||
.header-logo {
|
||||
height: 68px;
|
||||
width: 395px;
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
ul.piclistul{padding: 15px;width: 930px; border: 1px solid #ccc;margin-top: 10px;min-height:300px; overflow:hidden}
|
||||
ul.piclistul li{ width:217px; height:192px; overflow:hidden; float:left; margin:10px 8px}
|
||||
ul.piclistul li .proimg{ width:215px; height:160px;_display:table;display:table-cell;text-align:center;border:1px solid #ddd;vertical-align:middle}
|
||||
ul.piclistul li .proimg img{vertical-align:middle;max-height:160px; max-width:215px;}
|
||||
ul.piclistul li p{ text-align:center;line-height: 30px; color:#333; padding:0 10px}
|
||||
ul.piclistul li:nth-child(4n){ margin-right:0}
|
||||
ul.piclistul li:hover p{color: #0580c8;}
|
||||
ul.piclistul li:hover .proimg{ border:1px solid #0580c8}
|
||||
.header nav {
|
||||
position: absolute;
|
||||
padding-left: 20px;
|
||||
top: 10px;
|
||||
right: 0;
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
}
|
||||
|
||||
.header nav a {
|
||||
display: inline-block;
|
||||
color: #203175;
|
||||
width: 90px;
|
||||
line-height: 68px;
|
||||
text-align: center;
|
||||
position: relative;
|
||||
transition: all .4s;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.header nav a::before {
|
||||
position: absolute;
|
||||
content: " ";
|
||||
bottom: 0;
|
||||
width: 50px;
|
||||
height: 4px;
|
||||
left: 20px;
|
||||
background-color: #203175;
|
||||
opacity: 0;
|
||||
transition: all .4s;
|
||||
}
|
||||
|
||||
ul.listul{padding: 15px 35px; overflow:hidden;border: 1px solid #ccc;margin-top: 10px;min-height:300px;}
|
||||
ul.listul li{ height:36px; line-height: 36px;border-bottom: 1px dotted #CCC;}
|
||||
ul.listul li p{background: #0580c8;width: 14px; height: 14px; border-radius: 50%;float: left;text-align: center;color: #fff;margin-right: 15px;line-height: 12px;margin-top: 12px;}
|
||||
ul.listul li a{ float:left;color: #333; max-width:600px;font-size: 14px;}
|
||||
ul.listul li span{ float:right;color: #666;font-size: 13px;}
|
||||
.header nav a.show::before,
|
||||
.header nav a:hover::before {
|
||||
bottom: 15px;
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
/* 欢迎语 */
|
||||
.hello {
|
||||
background-color: #203175;
|
||||
}
|
||||
|
||||
.detailbox{padding: 15px;border: 1px solid #ccc;margin-top: 10px;min-height:70vh; overflow:hidden}
|
||||
.detailbox .xq{}
|
||||
.detailbox .xq h1{font-size: 20px;line-height: 40px;text-align: center;color: #0580c8;}
|
||||
.detailbox .xq .date{margin: 10px 0;padding: 5px 10px;font-size: 14px;line-height: 24px;color: #666;text-align: center;border: 1px dotted #ccc;}
|
||||
.detailbox .xq .con{padding: 10px;line-height:30px; padding-bottom:20px}
|
||||
.detailbox .xq .prroimg{ display:block; margin:0 auto; max-width:650px; padding:10px 0}
|
||||
.hello-text {
|
||||
color: #abb2cb;
|
||||
line-height: 40px;
|
||||
}
|
||||
|
||||
/* banner图 */
|
||||
.swiper-slide {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.swiper-banner-img {
|
||||
width: 100%;
|
||||
padding-top: 20%;
|
||||
background-size: 100%;
|
||||
transition: all .2s;
|
||||
background-repeat: no-repeat;
|
||||
background-position: center;
|
||||
position: relative;
|
||||
display: block;
|
||||
}
|
||||
|
||||
.pagebox{ text-align:center; padding-top:30px; padding-bottom:50px}
|
||||
.pagebox a{ border:1px solid #ccc; padding:5px 10px; display:inline-block; color:#333; margin:3px}
|
||||
.pagebox a:hover{background:#0580c8; color:#fff}
|
||||
.pagebox a.on{ background:#0580c8; color:#fff}
|
||||
.swiper-banner-img h3 {
|
||||
background-image: linear-gradient(to left, transparent, rgba(0, 0, 0, .2), transparent);
|
||||
padding: 15px 15px 50px 15px;
|
||||
color: white;
|
||||
font-size: 18px;
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.imgcenter{display: flex; flex-direction: row; justify-content: center;align-items: center;box-sizing: border-box;}
|
||||
.imgcenter li{width: 400px !important; }
|
||||
.imgcenter li img{width: 400px !important;}
|
||||
.swiper-banner-img:hover {
|
||||
background-size: 102%;
|
||||
}
|
||||
|
||||
.swiper-pagination .swiper-pagination-bullet {
|
||||
background-color: white;
|
||||
width: 12px;
|
||||
height: 12px;
|
||||
opacity: .8;
|
||||
}
|
||||
|
||||
.swiper-pagination .swiper-pagination-bullet-active {
|
||||
background-color: #203175;
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
/* 分院新闻 */
|
||||
.news {
|
||||
overflow: hidden;
|
||||
padding-top: 30px;
|
||||
}
|
||||
|
||||
.news-item {
|
||||
float: left;
|
||||
}
|
||||
|
||||
.news-hot {
|
||||
width: 700px;
|
||||
margin-right: 20px;
|
||||
background-color: #EEEEEE;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.news-hot-cover {
|
||||
width: 700px;
|
||||
height: 336px;
|
||||
}
|
||||
|
||||
.news-hot-text {
|
||||
padding: 10px;
|
||||
background-color: rgba(0, 0, 0, .5);
|
||||
height: 100px;
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
}
|
||||
|
||||
.news-hot-text a {
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.news-hot-text h3 {
|
||||
line-height: 30px;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.news-hot-text p {
|
||||
line-height: 20px;
|
||||
color: white;
|
||||
}
|
||||
|
||||
.news-hot-more {
|
||||
text-align: right;
|
||||
padding-top: 10px;
|
||||
}
|
||||
|
||||
.news-hot-more i {
|
||||
margin-left: 5px;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.news-title {
|
||||
padding-top: 0;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.news-ul {
|
||||
width: 470px;
|
||||
}
|
||||
|
||||
.news-ul-li {
|
||||
line-height: 35px;
|
||||
}
|
||||
|
||||
.news-ul-li:last-child {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.news-ul-li a {
|
||||
display: block;
|
||||
transition: all .4s;
|
||||
}
|
||||
|
||||
.news-ul-li a:hover {
|
||||
background-color: #fafafa;
|
||||
padding-left: 10px;
|
||||
}
|
||||
|
||||
.news-time {
|
||||
margin-right: 10px;
|
||||
color: gray;
|
||||
}
|
||||
|
||||
/* 科研动态 */
|
||||
.dynamic {
|
||||
padding-top: 30px;
|
||||
}
|
||||
|
||||
.dynamic-ul {
|
||||
margin: 0 -10px;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.dynamic-ul-item {
|
||||
background-color: white;
|
||||
margin: 0 10px;
|
||||
float: left;
|
||||
width: calc(33.33% - 20px);
|
||||
}
|
||||
|
||||
.dynamic-ul-cover {
|
||||
width: 100%;
|
||||
padding-top: 50%;
|
||||
background-position: center;
|
||||
background-size: cover;
|
||||
display: block;
|
||||
}
|
||||
|
||||
.dynamic-ul-text {
|
||||
background-color: white;
|
||||
height: 70px;
|
||||
padding: 10px 0;
|
||||
}
|
||||
|
||||
.dynamic-ul-text h3 {
|
||||
line-height: 30px;
|
||||
}
|
||||
|
||||
.dynamic-ul-text p {
|
||||
line-height: 20px;
|
||||
color: gray;
|
||||
min-height: 40px;
|
||||
}
|
||||
|
||||
.dynamic-ul-text a {
|
||||
transition: color .4s;
|
||||
}
|
||||
|
||||
/* 党团生活 */
|
||||
.party {
|
||||
width: 700px;
|
||||
}
|
||||
|
||||
.party-ul-li {
|
||||
padding: 5px 10px 5px 95px;
|
||||
background-color: white;
|
||||
position: relative;
|
||||
min-height: 80px;
|
||||
margin-bottom: 10px;
|
||||
box-sizing: border-box;
|
||||
transition: background-color .3s;
|
||||
}
|
||||
|
||||
.party-ul-li:last-child {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.party-ul-li a:hover .party-time {
|
||||
color: white;
|
||||
background-color: #203175;
|
||||
transition: all .3s;
|
||||
border: none;
|
||||
}
|
||||
|
||||
.party-title {
|
||||
font-weight: bold;
|
||||
font-size: 16px;
|
||||
display: block;
|
||||
line-height: 30px;
|
||||
}
|
||||
|
||||
.party-info {
|
||||
line-height: 20px;
|
||||
color: gray;
|
||||
}
|
||||
|
||||
.party-time {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: 0;
|
||||
border-right: solid 1px #EEEEEE;
|
||||
text-align: center;
|
||||
width: 80px;
|
||||
height: 80px;
|
||||
padding: 15px 0;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.party-time h3 {
|
||||
font-size: 20px;
|
||||
line-height: 30px;
|
||||
}
|
||||
|
||||
.party-time p {
|
||||
line-height: 20px;
|
||||
}
|
||||
|
||||
.party-cover {
|
||||
background-size: cover;
|
||||
background-position: center;
|
||||
}
|
||||
|
||||
/* 精神文明 */
|
||||
.spirit {
|
||||
width: 470px;
|
||||
margin-left: 20px;
|
||||
background-color: white;
|
||||
}
|
||||
|
||||
.spiritual-ul-li {
|
||||
padding: 5px 10px;
|
||||
background-color: white;
|
||||
position: relative;
|
||||
border-left: solid 1px transparent;
|
||||
box-sizing: border-box;
|
||||
min-height: 80px;
|
||||
margin-bottom: 10px;
|
||||
box-sizing: border-box;
|
||||
transition: background-color .3s;
|
||||
}
|
||||
|
||||
.spiritual-ul-li:last-child {
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.spiritual-ul-li:hover {
|
||||
background-color: #fafafa;
|
||||
border-left: solid 1px #203175;
|
||||
}
|
||||
|
||||
.spiritual-ul-li a {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.spiritual-title {
|
||||
font-weight: bold;
|
||||
font-size: 16px;
|
||||
display: block;
|
||||
line-height: 30px;
|
||||
}
|
||||
|
||||
.spiritual-info {
|
||||
line-height: 20px;
|
||||
color: gray;
|
||||
}
|
||||
|
||||
/* 国内国际新闻 */
|
||||
.tabs {
|
||||
padding-top: 30px;
|
||||
}
|
||||
|
||||
.tabs-content-block {
|
||||
overflow: hidden;
|
||||
margin: 0 -10px;
|
||||
}
|
||||
|
||||
.tabs-content-block li {
|
||||
line-height: 35px;
|
||||
float: left;
|
||||
width: calc(50% - 20px);
|
||||
margin: 0 10px;
|
||||
}
|
||||
|
||||
.tabs-content-block li a {
|
||||
display: block;
|
||||
transition: all .4s;
|
||||
}
|
||||
|
||||
.tabs-content-block li a:hover {
|
||||
background-color: #fafafa;
|
||||
padding-left: 10px;
|
||||
}
|
||||
|
||||
.tabs-content-block li i {
|
||||
margin-right: 5px;
|
||||
}
|
||||
|
||||
/* tabs */
|
||||
.tabs-title {
|
||||
border-bottom: solid 1px #e6e6e6;
|
||||
padding: 10px 0;
|
||||
margin-bottom: 20px;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.tabs-item {
|
||||
padding: 0 10px;
|
||||
position: relative;
|
||||
cursor: pointer;
|
||||
font-size: 15px;
|
||||
color: gray;
|
||||
}
|
||||
|
||||
.tabs-item:hover {
|
||||
color: #203175;
|
||||
}
|
||||
|
||||
.tabs-item.show {
|
||||
font-size: 18px;
|
||||
font-weight: bold;
|
||||
color: black;
|
||||
}
|
||||
|
||||
.tabs-item.show::before {
|
||||
content: "";
|
||||
position: absolute;
|
||||
bottom: -11px;
|
||||
left: 0;
|
||||
right: 0;
|
||||
height: 3px;
|
||||
background-color: #203175;
|
||||
}
|
||||
|
||||
.tabs-content {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.tabs-content.active {
|
||||
display: block;
|
||||
}
|
||||
|
||||
/* 子页面 */
|
||||
.child {
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.child-nav,
|
||||
.child-content {
|
||||
float: left;
|
||||
}
|
||||
|
||||
.child-nav {
|
||||
width: 220px;
|
||||
}
|
||||
|
||||
.child-content {
|
||||
width: 950px;
|
||||
margin-left: 20px;
|
||||
}
|
||||
|
||||
/* 友情链接 */
|
||||
.href {
|
||||
padding: 30px 0;
|
||||
}
|
||||
|
||||
.href-content {
|
||||
padding-top: 10px;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.href-content a {
|
||||
line-height: 40px;
|
||||
width: 20%;
|
||||
display: inline-block;
|
||||
float: left;
|
||||
}
|
||||
|
||||
/* footer */
|
||||
.footer {
|
||||
background-color: #203175;
|
||||
padding: 40px 0;
|
||||
text-align: center;
|
||||
color: white;
|
||||
line-height: 30px;
|
||||
}
|
||||
|
||||
.footer span {
|
||||
padding: 0 10px;
|
||||
}
|
||||
|
||||
/* 带有日期的列表 */
|
||||
.list-ul {
|
||||
margin-top: 20px;
|
||||
}
|
||||
|
||||
/* 侧边栏导航 */
|
||||
.kj-bjt {
|
||||
margin-top: 20px;
|
||||
min-height: 70px;
|
||||
padding: 10px;
|
||||
font-size: 20px;
|
||||
box-sizing: border-box;
|
||||
color: #fff;
|
||||
text-align: right;
|
||||
background-repeat: no-repeat;
|
||||
background-image: url(../img/beijing.png);
|
||||
background-size: cover;
|
||||
}
|
||||
|
||||
.kj-bjt > b {
|
||||
display: block;
|
||||
line-height: 30px;
|
||||
}
|
||||
|
||||
.kj-bjt > p {
|
||||
line-height: 20px;
|
||||
}
|
||||
|
||||
.child-nav-cover {
|
||||
width: 100%;
|
||||
margin-top: 20px;
|
||||
}
|
||||
|
||||
.child-nav-ul {
|
||||
background: #eee;
|
||||
}
|
||||
|
||||
.child-nav-ul li {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.child-nav-ul li::before {
|
||||
position: absolute;
|
||||
content: " ";
|
||||
height: 1px;
|
||||
background: #ddd;
|
||||
left: 15px;
|
||||
right: 15px;
|
||||
bottom: 0;
|
||||
}
|
||||
|
||||
.child-nav-ul li:last-child::before {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.child-nav-ul a {
|
||||
line-height: 60px;
|
||||
text-align: center;
|
||||
display: block;
|
||||
border-left: solid 4px rgba(0, 0, 0, 0);
|
||||
padding-right: 4px;
|
||||
}
|
||||
|
||||
.child-nav-ul a.show,
|
||||
.child-nav-ul a:hover {
|
||||
color: #203175;
|
||||
background-color: white;
|
||||
border-left: solid 4px #203175;
|
||||
}
|
||||
|
||||
/*交流合作*/
|
||||
.jlhz-border {
|
||||
margin-top: 20px;
|
||||
}
|
||||
|
||||
/*文章详情*/
|
||||
.wzxq {
|
||||
padding: 20px 0;
|
||||
}
|
||||
|
||||
.wzxq h3 {
|
||||
color: #333;
|
||||
font-size: 25px;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
.wzxq p {
|
||||
color: #999898;
|
||||
}
|
||||
|
||||
.xyp {
|
||||
margin-top: 20px;
|
||||
}
|
||||
|
||||
.xyp b {
|
||||
color: #5d5c5c;
|
||||
}
|
||||
|
||||
.xyp a {
|
||||
color: #676767;
|
||||
margin-left: 20px;
|
||||
}
|
||||
|
||||
.ritText img {
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
/* 分页 */
|
||||
.pages {
|
||||
text-align: center;
|
||||
margin-top: 20px;
|
||||
}
|
||||
|
||||
.pages a {
|
||||
display: inline-block;
|
||||
margin: 0 2px;
|
||||
line-height: 30px;
|
||||
padding: 0 12px;
|
||||
text-align: center;
|
||||
background-color: #f1f3f8;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.pages a:hover,
|
||||
.pages a.show {
|
||||
background-color: #273981;
|
||||
color: white;
|
||||
}
|
||||
15
public/assets/index/css/swiper.min.css
vendored
Normal file
BIN
public/assets/index/fonts/FontAwesome.otf
Normal file
BIN
public/assets/index/fonts/fontawesome-webfont.eot
Normal file
2671
public/assets/index/fonts/fontawesome-webfont.svg
Normal file
|
After Width: | Height: | Size: 434 KiB |
BIN
public/assets/index/fonts/fontawesome-webfont.ttf
Normal file
BIN
public/assets/index/fonts/fontawesome-webfont.woff
Normal file
BIN
public/assets/index/fonts/fontawesome-webfont.woff2
Normal file
BIN
public/assets/index/img/banner_00.jpg
Normal file
|
After Width: | Height: | Size: 142 KiB |
BIN
public/assets/index/img/banner_01.png
Normal file
|
After Width: | Height: | Size: 141 KiB |
BIN
public/assets/index/img/banner_02.jpg
Normal file
|
After Width: | Height: | Size: 149 KiB |
BIN
public/assets/index/img/beijing.png
Normal file
|
After Width: | Height: | Size: 19 KiB |
BIN
public/assets/index/img/blue.png
Normal file
|
After Width: | Height: | Size: 2.3 KiB |
BIN
public/assets/index/img/favicon.ico
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
public/assets/index/img/logo.png
Normal file
|
After Width: | Height: | Size: 26 KiB |
5
public/assets/index/js/jquery.min.js
vendored
Normal file
18
public/assets/index/js/swiper.min.js
vendored
Normal file
@@ -2,13 +2,11 @@
|
||||
|
||||
/**
|
||||
* Laravel - A PHP Framework For Web Artisans
|
||||
*
|
||||
* @package Laravel
|
||||
* @author Taylor Otwell <taylor@laravel.com>
|
||||
* @package Laravel
|
||||
*/
|
||||
|
||||
define('LARAVEL_START', microtime(true));
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Register The Auto Loader
|
||||
|
||||
@@ -3,50 +3,26 @@
|
||||
@section('title', '文章详情')
|
||||
|
||||
@section('content')
|
||||
<div class="clear"></div>
|
||||
<div class="mainWarp">
|
||||
<div class="mainLeft">
|
||||
<div class="typebox">
|
||||
<div class="tit">
|
||||
<p class="ccsl">{{ $parent->title }}</p>
|
||||
</div>
|
||||
<ul>
|
||||
@foreach ($parent->childrens as $children)
|
||||
<li>
|
||||
<p>></p>
|
||||
<a href="{{ route('category.show',$children) }}" class="ccsl">{{ $children->title }}</a>
|
||||
</li>
|
||||
@endforeach
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="mainRight">
|
||||
<div class="brandnav">
|
||||
<p class="ccsl">{{ $category->title }}</p>
|
||||
<div class="con">首页>
|
||||
@if ($parent->id==$category->id)
|
||||
{{ $category->title }}
|
||||
@else
|
||||
{{ $parent->title }}
|
||||
<font>></font>
|
||||
{{ $category->title }}
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
<div class="detailbox">
|
||||
<div class="xq">
|
||||
<h1>{{ $article->title }}</h1>
|
||||
<div class="date">日期:{{ $article->created_at }}</div>
|
||||
<div class="con">
|
||||
<!-- mian -->
|
||||
<div class="container child">
|
||||
<div class="wzxq">
|
||||
<h3>{{ $article->title }}</h3>
|
||||
<p>发表时间:{{ $article->created_at }}</p>
|
||||
</div>
|
||||
<div class="ritText">
|
||||
@if ($article->cover)
|
||||
<img src="{{ $article->cover_path }}"></br>
|
||||
<img src="{{ $article->cover_path }}">
|
||||
@endif
|
||||
{!! $article->content !!}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
</div>
|
||||
<p>
|
||||
{!! $article->content !!}
|
||||
</p>
|
||||
</div>
|
||||
@if ($next)
|
||||
<div class="xyp">
|
||||
<b>下一篇</b><a href="{{ $next->link }}">{{ $next->title }}</a>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
</div>
|
||||
<!-- end mian -->
|
||||
@endsection
|
||||
|
||||
75
resources/views/category/list.blade.php
Normal file
@@ -0,0 +1,75 @@
|
||||
@extends('layouts.app')
|
||||
|
||||
@section('title', '首页')
|
||||
|
||||
@section('content')
|
||||
<!-- mian -->
|
||||
<div class="container child">
|
||||
<!-- 侧边导航 -->
|
||||
<div class="child-nav">
|
||||
<div class="kj-bjt">
|
||||
<b>{{ $parent->title }}</b>
|
||||
<p>Exchange and cooperation</p>
|
||||
</div>
|
||||
<ul class="child-nav-ul">
|
||||
@if ($parent->childrens->isNotEmpty())
|
||||
@foreach ($parent->childrens as $child)
|
||||
<li>
|
||||
<a href="{{ $child->link }}" @if($category->id==$child->id) class="show" @endif>{{ $child->title }}</a>
|
||||
</li>
|
||||
@endforeach
|
||||
@endif
|
||||
</ul>
|
||||
</div>
|
||||
<!-- content -->
|
||||
<div class="child-content">
|
||||
<ul class="party-ul list-ul">
|
||||
<li class="party-ul-li">
|
||||
<a href="#">
|
||||
<span class="party-time">
|
||||
<h3>09</h3>
|
||||
<p>2020-05</p>
|
||||
</span>
|
||||
<h3 class="party-title nowrap">创新团队</h3>
|
||||
<p class="party-info nowrap-multi">新华社北京7月25日电
|
||||
为引领推动我国印刷业高质量发展,由国家新闻出版署主办的2019中国印刷业创新大会25日在京开幕。</p>
|
||||
</a>
|
||||
</li>
|
||||
<li class="party-ul-li">
|
||||
<a href="#">
|
||||
<span class="party-time">
|
||||
<h3>09</h3>
|
||||
<p>2020-05</p>
|
||||
</span>
|
||||
<h3 class="party-title nowrap">创新团队</h3>
|
||||
<p class="party-info nowrap-multi">新华社北京7月25日电
|
||||
为引领推动我国印刷业高质量发展,由国家新闻出版署主办的2019中国印刷业创新大会25日在京开幕。</p>
|
||||
</a>
|
||||
</li>
|
||||
<li class="party-ul-li">
|
||||
<a href="#">
|
||||
<span class="party-time">
|
||||
<h3>09</h3>
|
||||
<p>2020-05</p>
|
||||
</span>
|
||||
<h3 class="party-title nowrap">创新团队</h3>
|
||||
<p class="party-info nowrap-multi">新华社北京7月25日电
|
||||
为引领推动我国印刷业高质量发展,由国家新闻出版署主办的2019中国印刷业创新大会25日在京开幕。</p>
|
||||
</a>
|
||||
</li>
|
||||
<li class="party-ul-li">
|
||||
<a href="#">
|
||||
<span class="party-time">
|
||||
<h3>09</h3>
|
||||
<p>2020-05</p>
|
||||
</span>
|
||||
<h3 class="party-title nowrap">创新团队</h3>
|
||||
<p class="party-info nowrap-multi">新华社北京7月25日电
|
||||
为引领推动我国印刷业高质量发展,由国家新闻出版署主办的2019中国印刷业创新大会25日在京开幕。</p>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<!-- end mian -->
|
||||
@endsection
|
||||
@@ -3,53 +3,46 @@
|
||||
@section('title', '首页')
|
||||
|
||||
@section('content')
|
||||
<div class="clear"></div>
|
||||
<div class="mainWarp">
|
||||
<div class="mainLeft">
|
||||
<div class="typebox">
|
||||
<div class="tit">
|
||||
<p class="ccsl">{{ $parent->title }}</p>
|
||||
<!-- mian -->
|
||||
<div class="container child">
|
||||
<!-- 侧边导航 -->
|
||||
<div class="child-nav">
|
||||
<div class="kj-bjt">
|
||||
<b>{{ $parent->title }}</b>
|
||||
<p>Exchange and cooperation</p>
|
||||
</div>
|
||||
<ul>
|
||||
@foreach ($parent->childrens as $children)
|
||||
<li>
|
||||
<p>></p>
|
||||
<a href="{{ route('category.show',$children) }}" class="ccsl">{{ $children->title }}</a>
|
||||
</li>
|
||||
@endforeach
|
||||
<ul class="child-nav-ul">
|
||||
@if ($parent->childrens->isNotEmpty())
|
||||
@foreach ($parent->childrens as $child)
|
||||
<li>
|
||||
<a href="{{ $child->link }}" @if($category->id==$child->id) class="show" @endif>{{ $child->title }}</a>
|
||||
</li>
|
||||
@endforeach
|
||||
@endif
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="mainRight">
|
||||
<div class="brandnav">
|
||||
<p class="ccsl">{{ $category->title }}</p>
|
||||
<div class="con">首页>
|
||||
@if ($parent->id==$category->id)
|
||||
{{ $category->title }}
|
||||
@else
|
||||
{{ $parent->title }}
|
||||
<font>></font>
|
||||
{{ $category->title }}
|
||||
<!-- content -->
|
||||
<div class="child-content">
|
||||
<ul class="spiritual-ul jlhz-border">
|
||||
@if ($articles->isNotEmpty())
|
||||
@foreach ($articles as $article)
|
||||
<li class="spiritual-ul-li">
|
||||
<a href="{{ $article->link }}">
|
||||
<h3 class="spiritual-title nowrap">{{ $article->title }}</h3>
|
||||
<p class="spiritual-info nowrap-multi">
|
||||
{{ $article->description }}
|
||||
</p>
|
||||
</a>
|
||||
</li>
|
||||
@endforeach
|
||||
@endif
|
||||
</div>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="pages">
|
||||
@if ($articles->isNotEmpty())
|
||||
{{ $articles->links('layouts.pagination') }}
|
||||
@endif
|
||||
</div>
|
||||
<ul class="listul">
|
||||
@foreach ($articles as $article)
|
||||
<li>
|
||||
<p>></p>
|
||||
<a href="{{ route('article.show',$article) }}" class="ccsl">{{ $article->title }}</a>
|
||||
<span>{{ $article->created_at }}</span>
|
||||
</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
</br>
|
||||
<div class="clear"></div>
|
||||
|
||||
@if ($articles->isNotEmpty())
|
||||
{{ $articles->links('layouts.pagination') }}
|
||||
@endif
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- end mian -->
|
||||
@endsection
|
||||
|
||||
@@ -3,230 +3,322 @@
|
||||
@section('title', '首页')
|
||||
|
||||
@section('content')
|
||||
|
||||
{{-- 顶部广告 --}}
|
||||
@if ($adverts->isNotEmpty())
|
||||
<div class="clear"></div>
|
||||
<div class="banner">
|
||||
<div class="b-img">
|
||||
@foreach ($adverts as $advert)
|
||||
<img src="{{ $advert->cover_path }}" width="100%"/>
|
||||
@endforeach
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
<div class="b-list"> </div>
|
||||
</div>
|
||||
@endif
|
||||
|
||||
<div class="part4">
|
||||
<div class="main">
|
||||
<div class="part4box">
|
||||
<div class="titbox">
|
||||
<h2 class="ccsl">分院动态</h2>
|
||||
<a href="{{ route('category.show',6) }}">更多>></a>
|
||||
<!-- mian -->
|
||||
<div class="container">
|
||||
<!-- 院所新闻 -->
|
||||
<div class="news">
|
||||
<div class="news-item news-hot">
|
||||
<img class="news-hot-cover" src="lib/img/banner_02.jpg">
|
||||
<div class="news-hot-text">
|
||||
<h3 class="nowrap"><a href="#">杜新宇副院长到大庆分院调研</a></h3>
|
||||
<p class="nowrap-multi">
|
||||
国家新闻出版署日前下发通知,确定《“十三五”国家重点图书、音像、电子出版物出版规划》第三次增补项目235个。规划实行动态管理,公布增补项目的同时,对撤销或变更的项目一并作出调整,确定出版单位申请撤销项目141个、变更项目14个。</p>
|
||||
<p class="news-hot-more"><a href="#">详情<i class="fa fa-chevron-right"></i></a></p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="cons">
|
||||
<div class="p4one">
|
||||
<div class="p4oneL">
|
||||
<a href="{{ route('article.show',$fydt->first()) }}"><img src="{{ $fydt->first()->get_one_cover() }}" /></a>
|
||||
</div>
|
||||
<div class="p4oneR">
|
||||
<a href="detail.html" class="ccsl">{{ $fydt->first()->title }}</a>
|
||||
<span>{{ $fydt->first()->created_at->format('Y-m-d') }}</span>
|
||||
<div class="clear"></div>
|
||||
<div class="sub">{{ $fydt->first()->description }}</div>
|
||||
</div>
|
||||
<div class="news-item news-ul">
|
||||
<div class="mian-title news-title">
|
||||
<b>{{ getOneCategory(6,'title') }}</b>
|
||||
<span>/ School news</span>
|
||||
<a class="mian-title-more" href="{{ getOneCategory(6,'link') }}">更多<i class="fa fa-angle-right"></i></a>
|
||||
</div>
|
||||
<ul>
|
||||
@foreach ($fydt as $new)
|
||||
<li>
|
||||
<p>></p>
|
||||
<a href="{{ route('article.show',$new) }}" class="ccsl">{{ $new->title }}</a>
|
||||
<span>{{ $new->created_at->format('y-m-d') }}</span>
|
||||
</li>
|
||||
@endforeach
|
||||
@if (getArticlesBYCate(6,8)->isNotEmpty())
|
||||
@foreach (getArticlesBYCate(6,8) as $article)
|
||||
<li class="news-ul-li">
|
||||
<a class="nowrap" href="{{ $article->link }}">
|
||||
<span class="news-time">{{ $article->created_at->format('m-d') }}</span>{{ $article->title }}
|
||||
</a>
|
||||
</li>
|
||||
@endforeach
|
||||
@endif
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 科研动态 -->
|
||||
<div class="dynamic">
|
||||
<div class="mian-title">
|
||||
<b>{{ getOneCategory(9,'title') }}</b>
|
||||
<span>/ Scientific research dynamic</span>
|
||||
<a class="mian-title-more" href="{{ getOneCategory(9,'link') }}">更多<i class="fa fa-angle-right"></i></a>
|
||||
</div>
|
||||
<ul class="dynamic-ul">
|
||||
@if (getArticlesBYCate(9,3)->isNotEmpty())
|
||||
@foreach (getArticlesBYCate(9,3) as $article)
|
||||
<li class="dynamic-ul-item">
|
||||
<span class="dynamic-ul-cover" style="background-image: url({{ $article->cover_path }});"></span>
|
||||
<div class="dynamic-ul-text">
|
||||
<h3 class="nowrap"><a href="{{ $article->link }}">{{ $article->title }}</a></h3>
|
||||
<p class="nowrap-multi">{{ $article->description }}</p>
|
||||
</div>
|
||||
</li>
|
||||
@endforeach
|
||||
@endif
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="part4box fr">
|
||||
<div class="titbox">
|
||||
<h2 class="ccsl">科研动态</h2>
|
||||
<a href="{{ route('category.show',9) }}">更多>></a>
|
||||
<!-- 广告条 -->
|
||||
<div class="index-ad">
|
||||
<a href="{{ getOneAdvertByCate(28,'url') }}">
|
||||
<img src="{{ getOneAdvertByCate(28,'cover_path') }}">
|
||||
</a>
|
||||
</div>
|
||||
<div class="cons">
|
||||
<div class="p4one">
|
||||
<div class="p4oneL">
|
||||
<a href="{{ route('article.show',$kydt->first()) }}"><img src="{{ $kydt->first()->get_one_cover() }}" /></a>
|
||||
|
||||
<!-- 党团生活, 精神文明 -->
|
||||
<div class="news">
|
||||
<div class="news-item party">
|
||||
<div class="tabs-title" id="information">
|
||||
<span class="tabs-item show">{{ getOneCategory(30,'title') }}</span>
|
||||
<span class="tabs-item">{{ getOneCategory(29,'title') }}</span>
|
||||
</div>
|
||||
<div class="p4oneR">
|
||||
<a href="detail.html" class="ccsl">{{ $kydt->first()->title }}</a>
|
||||
<span>{{ $kydt->first()->created_at->format('Y-m-d') }}</span>
|
||||
<div class="clear"></div>
|
||||
<div class="sub">{{ $kydt->first()->description }}</div>
|
||||
<div class="tabs-content-wrapper" id="informationContent">
|
||||
<!-- 国内资讯 -->
|
||||
<ul class="party-ul tabs-content active">
|
||||
@if (getArticlesBYCate(30,3)->isNotEmpty())
|
||||
@foreach (getArticlesBYCate(30,3) as $article)
|
||||
<li class="party-ul-li">
|
||||
<a href="{{ $article->link }}">
|
||||
<span class="party-time">
|
||||
<h3>{{ $article->created_at->format('d') }}</h3>
|
||||
<p>{{ $article->created_at->format('Y-m') }}</p>
|
||||
</span>
|
||||
<h3 class="party-title nowrap">{{ $article->title }}</h3>
|
||||
<p class="party-info nowrap-multi">{{ $article->description }}</p>
|
||||
</a>
|
||||
</li>
|
||||
@endforeach
|
||||
@endif
|
||||
</ul>
|
||||
|
||||
<ul class="party-ul tabs-content">
|
||||
@if (getArticlesBYCate(29,12)->isNotEmpty())
|
||||
@foreach (getArticlesBYCate(29,12) as $article)
|
||||
<li class="party-ul-li">
|
||||
<a href="{{ $article->link }}">
|
||||
<span class="party-time">
|
||||
<h3>{{ $article->created_at->format('d') }}</h3>
|
||||
<p>{{ $article->created_at->format('Y-m') }}</p>
|
||||
</span>
|
||||
<h3 class="party-title nowrap">{{ $article->title }}</h3>
|
||||
<p class="party-info nowrap-multi">{{ $article->description }}</p>
|
||||
</a>
|
||||
</li>
|
||||
@endforeach
|
||||
@endif
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<ul>
|
||||
@foreach ($kydt as $new)
|
||||
<li>
|
||||
<p>></p>
|
||||
<a href="{{ route('article.show',$new) }}" class="ccsl">{{ $new->title }}</a>
|
||||
<span>{{ $new->created_at->format('y-m-d') }}</span>
|
||||
</li>
|
||||
@endforeach
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
<div class="part3">
|
||||
<div class="titbox">
|
||||
<p class="ccsl">院所介绍</p>
|
||||
<span class="ccsl">About us</span>
|
||||
</div>
|
||||
<div class="part3box">
|
||||
<div class="p3L">
|
||||
<a href="{{ route('article.show',$info) }}"><img src="{{ $info->get_one_cover() }}" /></a>
|
||||
</div>
|
||||
<div class="p3R">
|
||||
<div class="con">
|
||||
<p style="text-indent:2em">
|
||||
{{ $info->description }}
|
||||
</p>
|
||||
<div class="news-item spirit">
|
||||
<div class="mian-title">
|
||||
<b>{{ getOneCategory(16,'title') }}</b>
|
||||
<span>/ Spiritual civilization</span>
|
||||
<a class="mian-title-more" href="{{ getOneCategory(16,'link') }}">更多<i class="fa fa-angle-right"></i></a>
|
||||
</div>
|
||||
<ul class="spiritual-ul">
|
||||
@if (getArticlesBYCate(16,3)->isNotEmpty())
|
||||
@foreach (getArticlesBYCate(16,3) as $article)
|
||||
<li class="spiritual-ul-li">
|
||||
<a href="{{ $article->link }}">
|
||||
<h3 class="spiritual-title nowrap">{{ $article->title }}</h3>
|
||||
<p class="spiritual-info nowrap-multi">
|
||||
{{ $article->description }}
|
||||
</p>
|
||||
</a>
|
||||
</li>
|
||||
@endforeach
|
||||
@endif
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 广告条 -->
|
||||
<div class="index-ad">
|
||||
<a href="{{ getOneAdvertByCate(31,'url') }}">
|
||||
<img src="{{ getOneAdvertByCate(31,'cover_path') }}">
|
||||
</a>
|
||||
</div>
|
||||
<!-- 新闻列表 -->
|
||||
<div class="news">
|
||||
<!-- tabs -->
|
||||
<div class="news-item party">
|
||||
<div class="tabs-title" id="newsTab">
|
||||
<span class="tabs-item show">创新团队</span>
|
||||
<span class="tabs-item">梯队人才</span>
|
||||
<span class="tabs-item">专家智库</span>
|
||||
<span class="tabs-item">项目推广</span>
|
||||
<span class="tabs-item">成果专利</span>
|
||||
<a class="mian-title-more" href="">更多<i class="fa fa-angle-right"></i></a>
|
||||
</div>
|
||||
<div class="tabs-content-wrapper" id="newsTabContent">
|
||||
<!-- 创新团队 -->
|
||||
<ul class="party-ul tabs-content active">
|
||||
<li class="party-ul-li">
|
||||
<a href="#">
|
||||
<span class="party-time">
|
||||
<h3>09</h3>
|
||||
<p>2020-05</p>
|
||||
</span>
|
||||
<h3 class="party-title nowrap">创新团队</h3>
|
||||
<p class="party-info nowrap-multi">新华社北京7月25日电
|
||||
为引领推动我国印刷业高质量发展,由国家新闻出版署主办的2019中国印刷业创新大会25日在京开幕。</p>
|
||||
</a>
|
||||
</li>
|
||||
<li class="party-ul-li">
|
||||
<a href="#">
|
||||
<span class="party-time">
|
||||
<h3>09</h3>
|
||||
<p>2020-05</p>
|
||||
</span>
|
||||
<h3 class="party-title nowrap">创新团队</h3>
|
||||
<p class="party-info nowrap-multi">新华社北京7月25日电
|
||||
为引领推动我国印刷业高质量发展,由国家新闻出版署主办的2019中国印刷业创新大会25日在京开幕。</p>
|
||||
</a>
|
||||
</li>
|
||||
<li class="party-ul-li">
|
||||
<a href="#">
|
||||
<span class="party-time">
|
||||
<h3>09</h3>
|
||||
<p>2020-05</p>
|
||||
</span>
|
||||
<h3 class="party-title nowrap">创新团队</h3>
|
||||
<p class="party-info nowrap-multi">新华社北京7月25日电
|
||||
为引领推动我国印刷业高质量发展,由国家新闻出版署主办的2019中国印刷业创新大会25日在京开幕。</p>
|
||||
</a>
|
||||
</li>
|
||||
<li class="party-ul-li">
|
||||
<a href="#">
|
||||
<span class="party-time">
|
||||
<h3>09</h3>
|
||||
<p>2020-05</p>
|
||||
</span>
|
||||
<h3 class="party-title nowrap">创新团队</h3>
|
||||
<p class="party-info nowrap-multi">新华社北京7月25日电
|
||||
为引领推动我国印刷业高质量发展,由国家新闻出版署主办的2019中国印刷业创新大会25日在京开幕。</p>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
<!-- 梯队人才 -->
|
||||
<ul class="party-ul tabs-content">
|
||||
<li class="party-ul-li">
|
||||
<a href="#">
|
||||
<span class="party-time party-cover" style="background-image:url(lib/img/banner_02.jpg)">
|
||||
</span>
|
||||
<h3 class="party-title nowrap">梯队人才</h3>
|
||||
<p class="party-info nowrap-multi">新华社北京7月25日电
|
||||
为引领推动我国印刷业高质量发展,由国家新闻出版署主办的2019中国印刷业创新大会25日在京开幕。</p>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
<!-- 专家智库 -->
|
||||
<ul class="party-ul tabs-content">
|
||||
<li class="party-ul-li">
|
||||
<a href="#">
|
||||
<span class="party-time party-cover" style="background-image:url(lib/img/banner_02.jpg)">
|
||||
</span>
|
||||
<h3 class="party-title nowrap">专家智库</h3>
|
||||
<p class="party-info nowrap-multi">新华社北京7月25日电
|
||||
为引领推动我国印刷业高质量发展,由国家新闻出版署主办的2019中国印刷业创新大会25日在京开幕。</p>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
<!-- 项目推广 -->
|
||||
<ul class="party-ul tabs-content">
|
||||
<li class="party-ul-li">
|
||||
<a href="#">
|
||||
<span class="party-time">
|
||||
<h3>02</h3>
|
||||
<p>2020-05</p>
|
||||
</span>
|
||||
<h3 class="party-title nowrap">项目推广</h3>
|
||||
<p class="party-info nowrap-multi">新华社北京7月25日电
|
||||
为引领推动我国印刷业高质量发展,由国家新闻出版署主办的2019中国印刷业创新大会25日在京开幕。</p>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
<!-- 成果专利 -->
|
||||
<ul class="party-ul tabs-content">
|
||||
<li class="party-ul-li">
|
||||
<a href="#">
|
||||
<span class="party-time">
|
||||
<h3>03</h3>
|
||||
<p>2020-05</p>
|
||||
</span>
|
||||
<h3 class="party-title nowrap">成果专利</h3>
|
||||
<p class="party-info nowrap-multi">新华社北京7月25日电
|
||||
为引领推动我国印刷业高质量发展,由国家新闻出版署主办的2019中国印刷业创新大会25日在京开幕。</p>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 项目推广 -->
|
||||
<div class="news-item spirit">
|
||||
<div class="mian-title">
|
||||
<b>媒体报道</b>
|
||||
<span>/ Project promotion</span>
|
||||
<a class="mian-title-more" href="">更多<i class="fa fa-angle-right"></i></a>
|
||||
</div>
|
||||
<ul class="spiritual-ul">
|
||||
<li class="spiritual-ul-li">
|
||||
<a href="#">
|
||||
<h3 class="spiritual-title nowrap">省科学院大庆分院召开“学树典型表彰先进”全体党员大会</h3>
|
||||
<p class="spiritual-info nowrap-multi">新华社北京7月25日电
|
||||
为引领推动我国印刷业高质量发展,由国家新闻出版署主办的2019中国印刷业创新大会25日在京开幕。</p>
|
||||
</a>
|
||||
</li>
|
||||
<li class="spiritual-ul-li">
|
||||
<a href="#">
|
||||
<h3 class="spiritual-title nowrap">省科学院大庆分院召开“学树典型表彰先进”全体党员大会</h3>
|
||||
<p class="spiritual-info nowrap-multi">新华社北京7月25日电
|
||||
为引领推动我国印刷业高质量发展,由国家新闻出版署主办的2019中国印刷业创新大会25日在京开幕。</p>
|
||||
</a>
|
||||
</li>
|
||||
<li class="spiritual-ul-li">
|
||||
<a href="#">
|
||||
<h3 class="spiritual-title nowrap">省科学院大庆分院召开“学树典型表彰先进”全体党员大会</h3>
|
||||
<p class="spiritual-info nowrap-multi">新华社北京7月25日电
|
||||
为引领推动我国印刷业高质量发展,由国家新闻出版署主办的2019中国印刷业创新大会25日在京开幕。</p>
|
||||
</a>
|
||||
</li>
|
||||
<li class="spiritual-ul-li">
|
||||
<a href="#">
|
||||
<h3 class="spiritual-title nowrap">省科学院大庆分院召开“学树典型表彰先进”全体党员大会</h3>
|
||||
<p class="spiritual-info nowrap-multi">新华社北京7月25日电
|
||||
为引领推动我国印刷业高质量发展,由国家新闻出版署主办的2019中国印刷业创新大会25日在京开幕。</p>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<a href="{{ route('article.show',$info) }}" class="more">查看详情</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
<div class="part1">
|
||||
<span></span>
|
||||
<div class="con">
|
||||
<a href=""></a>
|
||||
<a href=""></a>
|
||||
<a href=""></a>
|
||||
<a href=""></a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
<div class="part2">
|
||||
<div class="main">
|
||||
<div class="titbox">
|
||||
{{-- <a href="{{ route('category.show',3) }}"> --}}
|
||||
<p class="ccsl">领导班子</p>
|
||||
<em class="ccsl"></em>
|
||||
{{-- </a> --}}
|
||||
</div>
|
||||
<ul class="imgcenter">
|
||||
@foreach ($ldbz as $new)
|
||||
<li>
|
||||
<a href="{{ route('article.show',$new) }}">
|
||||
<img src="{{ $new->get_one_cover() }}" />
|
||||
<p class="ccsl">{{ $new->title }}</p>
|
||||
</a>
|
||||
</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
|
||||
<div class="titbox">
|
||||
{{-- <a href="{{ route('category.show',10) }}"> --}}
|
||||
<p class="ccsl">科研成果</p>
|
||||
{{-- </a> --}}
|
||||
</div>
|
||||
<ul>
|
||||
@foreach ($kycg as $new)
|
||||
<li>
|
||||
<a href="{{ route('article.show',$new) }}">
|
||||
<img src="{{ $new->get_one_cover() }}" />
|
||||
<p class="ccsl">{{ $new->title }}</p>
|
||||
</a>
|
||||
</li>
|
||||
@endforeach
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
|
||||
<div class="titbox">
|
||||
{{-- <a href="{{ route('category.show',4) }}"> --}}
|
||||
<p class="ccsl">人才团队介绍</p>
|
||||
{{-- </a> --}}
|
||||
</div>
|
||||
<div id="marquee1" class="marqueeleft">
|
||||
<div style="width: 8000px;">
|
||||
<ul id="marquee1_1">
|
||||
@foreach ($rctd as $new)
|
||||
<li><a href="{{ route('article.show',$new) }}"><img src="{{ $new->get_one_cover() }}" style="height:128px;"></a> </li>
|
||||
@endforeach
|
||||
</ul>
|
||||
<ul id="marquee1_2"></ul>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript"></script>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
|
||||
|
||||
<div class="linkbox">
|
||||
<div class="linkL">
|
||||
<p class="p1">友情链接</p>
|
||||
<p class="p2">Links</p>
|
||||
</div>
|
||||
<div class="linkR">
|
||||
@foreach ($links as $element)
|
||||
<a href="{{ $element->url }}"> {{ $element->title }}</a>
|
||||
@endforeach
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- end mian -->
|
||||
@endsection
|
||||
|
||||
@section('script')
|
||||
<script type="text/javascript">
|
||||
//js无缝滚动代码
|
||||
function marquee(i, direction) {
|
||||
var obj = document.getElementById("marquee" + i);
|
||||
console.log(obj);
|
||||
var obj1 = document.getElementById("marquee" + i + "_1");
|
||||
var obj2 = document.getElementById("marquee" + i + "_2");
|
||||
if (direction == "up") {
|
||||
if (obj2.offsetTop - obj.scrollTop <= 0) {
|
||||
obj.scrollTop -= (obj1.offsetHeight + 20);
|
||||
} else {
|
||||
var tmp = obj.scrollTop;
|
||||
obj.scrollTop++;
|
||||
if (obj.scrollTop == tmp) {
|
||||
obj.scrollTop = 1;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if (obj2.offsetWidth - obj.scrollLeft <= 0) {
|
||||
obj.scrollLeft -= obj1.offsetWidth;
|
||||
} else {
|
||||
obj.scrollLeft++;
|
||||
}
|
||||
@push('script')
|
||||
<script type="text/javascript">
|
||||
// swiperBanner
|
||||
var swiperBanner = new Swiper("#swiperBanner", {
|
||||
autoplay: 5000,
|
||||
loop: true,
|
||||
slidesPerView: 'auto',
|
||||
pagination: ".swiper-pagination",
|
||||
paginationClickable: true,
|
||||
autoplayDisableOnInteraction: false
|
||||
})
|
||||
|
||||
}
|
||||
// 新闻列表
|
||||
$(function () {
|
||||
$('#newsTab .tabs-item').hover(function () {
|
||||
$(this).addClass("show").siblings().removeClass("show")
|
||||
$("#newsTabContent .tabs-content").eq($(this).index()).addClass("active").siblings().removeClass("active")
|
||||
})
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
function marqueeStart(i, direction) {
|
||||
console.log(i);
|
||||
|
||||
var obj = document.getElementById("marquee" + i);
|
||||
var obj1 = document.getElementById("marquee" + i + "_1");
|
||||
var obj2 = document.getElementById("marquee" + i + "_2");
|
||||
obj2.innerHTML = obj1.innerHTML;
|
||||
var marqueeVar = window.setInterval("marquee(" + i + ", '" + direction + "')", 20);
|
||||
obj.onmouseover = function () {
|
||||
window.clearInterval(marqueeVar);
|
||||
}
|
||||
obj.onmouseout = function () {
|
||||
marqueeVar = window.setInterval("marquee(" + i + ", '" + direction + "')", 20);
|
||||
}
|
||||
}
|
||||
marqueeStart(1, "left");
|
||||
</script>
|
||||
@endsection
|
||||
// 国内国际资讯
|
||||
$(function () {
|
||||
$('#information .tabs-item').hover(function () {
|
||||
$(this).addClass("show").siblings().removeClass("show")
|
||||
$("#informationContent .tabs-content").eq($(this).index()).addClass("active").siblings().removeClass("active")
|
||||
})
|
||||
});
|
||||
</script>
|
||||
@endpush
|
||||
|
||||
@@ -1,52 +1,83 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<meta name="renderer" content="webkit"/>
|
||||
<meta name="force-rendering" content="webkit"/>
|
||||
<title>{{ config('app.name', '') }}</title>
|
||||
<link rel="stylesheet" href="{{ asset('assets/index/css/style.css') }}?{{ time() }}" type="text/css"/>
|
||||
|
||||
<script type="text/javascript" src="{{ asset('assets/index/js/jquery-1.8.2.min.js') }}"/></script>
|
||||
<script type="text/javascript" src="{{ asset('assets/index/js/banner.js') }}"/></script>
|
||||
<meta charset="utf-8">
|
||||
<title>{{ config('app.name', '') }}</title>
|
||||
<meta charset='utf-8'>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="icon" href="{{ asset('assets/index/img/favicon.ico') }}" mce_href="favicon.ico" type="image/x-icon">
|
||||
<link rel="stylesheet" type="text/css" href="{{ asset('assets/index/css/font-awesome.min.css') }}"/>
|
||||
<link rel="stylesheet" type="text/css" href="{{ asset('assets/index/css/swiper.min.css') }}"/>
|
||||
<link rel="stylesheet" type="text/css" href="{{ asset('assets/index/css/style.css') }}"/>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="clear"></div>
|
||||
<div class="logo">
|
||||
<a href="/"><img src="/assets/index/images/logo.jpg" /></a>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
<div class="nav">
|
||||
<div class="main">
|
||||
<ul>
|
||||
<li @if (!isset($category)) class="on" @endif><a href="/">首页</a></li>
|
||||
<!-- tool -->
|
||||
<div class="tool">
|
||||
<div class="container">
|
||||
<a href="#"><i class="fa fa-star"></i>加入收藏</a>
|
||||
<a href="#"><i class="fa fa-globe"></i>院所网站</a>
|
||||
</div>
|
||||
</div>
|
||||
<!-- end tool -->
|
||||
<!-- header -->
|
||||
<div class="container header">
|
||||
<a href="/">
|
||||
<img src="/assets/index/img/logo.png" class="header-logo">
|
||||
</a>
|
||||
<nav>
|
||||
<a href="/" @if (!isset($parent)) class="show" @endif>网站首页</a>
|
||||
@foreach ($all_categorys as $cate)
|
||||
<li @if (isset($category) && $cate->id==$category->id) class="on" @endif >
|
||||
<a href="{{ route('category.show',$cate) }}">{{ $cate->title }}</a>
|
||||
</li>
|
||||
<a href="{{ route('category.show',$cate) }}" @if (isset($parent) && $cate->id==$parent->id) class="show" @endif>{{ $cate->title }}</a>
|
||||
@endforeach
|
||||
</ul>
|
||||
</nav>
|
||||
</div>
|
||||
<!-- end header -->
|
||||
<!-- 欢迎语 -->
|
||||
<div class="hello">
|
||||
<div class="container hello-text">
|
||||
今天是 {{ now()->isoFormat('Y年m月d日 a h:mm:ss') }} {{ now()->isoFormat('dddd') }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- end 欢迎语 -->
|
||||
@section('content')
|
||||
|
||||
@section('content')
|
||||
@show
|
||||
@show
|
||||
<script src="{{ asset('assets/index/js/jquery.min.js') }}" type="text/javascript" charset="utf-8"></script>
|
||||
<script src="{{ asset('assets/index/js/swiper.min.js') }}" type="text/javascript" charset="utf-8"></script>
|
||||
|
||||
|
||||
<div class="clear"></div>
|
||||
<div class="footer">
|
||||
<div class="main">
|
||||
<div class="foot">
|
||||
<div>黑龙江省科学院大庆分院 版权所有 <br>
|
||||
黑ICP备1000001号<br>
|
||||
地址:大庆高新区博学大街45号 邮箱:hkydqyb@126.com<br>
|
||||
电话:086-459-8998866 传真:086-459-8998866 邮编:163319 <br>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 友情连接 -->
|
||||
<div class="container href">
|
||||
<div class="mian-title">
|
||||
<b>友情连接</b>
|
||||
<span>/ Links</span>
|
||||
</div>
|
||||
</div>
|
||||
@yield('script')
|
||||
<div class="href-content">
|
||||
@if ($links->isNotEmpty())
|
||||
@foreach ($links as $link)
|
||||
<a href="{{ $link->url }}">{{ $link->title}}</a>
|
||||
@endforeach
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
<!-- end 友情连接 -->
|
||||
<!-- footer -->
|
||||
<div class="footer">
|
||||
<p>黑龙江省科学院大庆分院 版权所有 (C)2012 All Right Reserved Power by DedeCms</p>
|
||||
<p>
|
||||
<span>地址:黑龙江省大庆市高新区博学大街45号</span>
|
||||
<span>备案号:黑ICP备1000001号</span>
|
||||
</p>
|
||||
<p>
|
||||
<span>邮箱:hkydqyb@126.com</span>
|
||||
<span>电话:086-459-8998866</span>
|
||||
<span>传真:086-459-8998866</span>
|
||||
<span>邮编:163319</span>
|
||||
</p>
|
||||
<img src="/assets/index/img/blue.png">
|
||||
</div>
|
||||
<!-- end footer -->
|
||||
|
||||
@stack('script')
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
||||
@@ -1,32 +1,32 @@
|
||||
|
||||
@if ($paginator->hasPages())
|
||||
<div class="pagebox">
|
||||
{{-- Previous Page Link --}}
|
||||
@if ($paginator->onFirstPage())
|
||||
<a href="#" style="pointer-events: none;">上一页</a>
|
||||
@else
|
||||
<a href="{{ $paginator->previousPageUrl() }}" >上一页</a>
|
||||
@endif
|
||||
<div class="pages">
|
||||
|
||||
{{-- Pagination Elements --}}
|
||||
@foreach ($elements as $element)
|
||||
{{-- Array Of Links --}}
|
||||
@if (is_array($element))
|
||||
@foreach ($element as $page => $url)
|
||||
@if ($page == $paginator->currentPage())
|
||||
<a href="{{ $url }}" class="on">{{ $page }}</a>
|
||||
@else
|
||||
<a href="{{ $url }}" >{{ $page }}</a>
|
||||
@endif
|
||||
@endforeach
|
||||
@endif
|
||||
@endforeach
|
||||
{{-- Previous Page Link --}}
|
||||
@if ($paginator->onFirstPage())
|
||||
<a href="#" style="pointer-events: none;">上一页</a>
|
||||
@else
|
||||
<a href="{{ $paginator->previousPageUrl() }}">上一页</a>
|
||||
@endif
|
||||
|
||||
{{-- Next Page Link --}}
|
||||
@if ($paginator->hasMorePages())
|
||||
<a href="{{ $paginator->nextPageUrl() }}" >下一页</a>
|
||||
@else
|
||||
<a href="#" style="pointer-events: none;">下一页</a>
|
||||
@endif
|
||||
</div>
|
||||
{{-- Pagination Elements --}}
|
||||
@foreach ($elements as $element)
|
||||
{{-- Array Of Links --}}
|
||||
@if (is_array($element))
|
||||
@foreach ($element as $page => $url)
|
||||
@if ($page == $paginator->currentPage())
|
||||
<a href="{{ $url }}" class="show">{{ $page }}</a>
|
||||
@else
|
||||
<a href="{{ $url }}">{{ $page }}</a>
|
||||
@endif
|
||||
@endforeach
|
||||
@endif
|
||||
@endforeach
|
||||
|
||||
{{-- Next Page Link --}}
|
||||
@if ($paginator->hasMorePages())
|
||||
<a href="{{ $paginator->nextPageUrl() }}">下一页</a>
|
||||
@else
|
||||
<a href="#" style="pointer-events: none;" disabled="">下一页</a>
|
||||
@endif
|
||||
</div>
|
||||
@endif
|
||||
|
||||